Skip to content

Commit

Permalink
* (1/3) cleanup : use $CXXFLAGS instead $CPU_FLAGS
Browse files Browse the repository at this point in the history
  • Loading branch information
hagen committed Dec 13, 2014
1 parent bc0f0e9 commit 4e94bc9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,16 @@ obj:

# weaker rule for building files without headers
obj/%.o : %.cpp
$(CXX) $(CXXFLAGS) $(NEEDED_CXXFLAGS) $(INCFLAGS) $(CPU_FLAGS) -c -o $@ $<
$(CXX) $(CXXFLAGS) $(NEEDED_CXXFLAGS) $(INCFLAGS) -c -o $@ $<

obj/%.o : %.cpp %.h
$(CXX) $(CXXFLAGS) $(NEEDED_CXXFLAGS) $(INCFLAGS) $(CPU_FLAGS) -c -o $@ $<
$(CXX) $(CXXFLAGS) $(NEEDED_CXXFLAGS) $(INCFLAGS) -c -o $@ $<

$(I2PD): $(patsubst %.cpp,obj/%.o,$(DAEMON_SRC))
$(CXX) -o $@ $^ $(LDLIBS) $(LDFLAGS) $(LIBS)

$(SHLIB): $(patsubst %.cpp,obj/%.o,$(LIB_SRC))
$(CXX) $(CXXFLAGS) $(NEEDED_CXXFLAGS) $(INCFLAGS) $(CPU_FLAGS) -shared -o $@ $^
$(CXX) $(CXXFLAGS) $(NEEDED_CXXFLAGS) $(INCFLAGS) -shared -o $@ $^

clean:
rm -fr obj $(I2PD) $(SHLIB)
Expand Down
2 changes: 1 addition & 1 deletion Makefile.linux
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ ifeq ($(USE_AESNI),yes)
ifeq ($(IS_64),1)
#check if AES-NI is supported by CPU
ifneq ($(shell grep -c aes /proc/cpuinfo),0)
CPU_FLAGS = -maes -DAESNI
CXXFLAGS += -maes -DAESNI
endif
endif
endif
Expand Down

0 comments on commit 4e94bc9

Please sign in to comment.