# HG changeset patch # User mas01cr # Date 1250026921 0 # Node ID 08811763ccfa697050d0398daa2ef713d2cf8d36 # Parent e190b7f2ad7cd5baa982de22749ee906838e4235 Use $(CC) and $(CXX) rather than hard-coding compilers Because someone someday might want to try cross-compiling diff -r e190b7f2ad7c -r 08811763ccfa Makefile --- a/Makefile Thu Aug 06 12:00:46 2009 +0000 +++ b/Makefile Tue Aug 11 21:42:01 2009 +0000 @@ -54,19 +54,19 @@ $(SOAPCPP2) audioDBws.h $(LIBOBJS): %.o: %.cpp audioDB_API.h audioDB-internals.h accumulator.h accumulators.h - g++ -c $(CFLAGS) $(GSL_INCLUDE) -Wall $< + $(CXX) -c $(CFLAGS) $(GSL_INCLUDE) -Wall $< %.o: %.cpp audioDB.h audioDB_API.h adb.nsmap cmdline.h reporter.h ReporterBase.h lshlib.h - g++ -c $(CFLAGS) $(GSOAP_INCLUDE) $(GSL_INCLUDE) -Wall $< + $(CXX) -c $(CFLAGS) $(GSOAP_INCLUDE) $(GSL_INCLUDE) -Wall $< cmdline.o: cmdline.c cmdline.h - gcc -c $(CFLAGS) $< + $(CC) -c $(CFLAGS) $< $(EXECUTABLE): $(OBJS) soapServer.cpp soapClient.cpp soapC.cpp - g++ -o $(EXECUTABLE) $(CFLAGS) $^ $(LIBGSL) $(GSOAP_INCLUDE) $(GSOAP_CPP) + $(CXX) -o $(EXECUTABLE) $(CFLAGS) $^ $(LIBGSL) $(GSOAP_INCLUDE) $(GSOAP_CPP) $(LIBRARY): $(LIBOBJS) - g++ $(SHARED_LIB_FLAGS)$(LIBRARY) -o $(LIBRARY) $(CFLAGS) $(LIBGSL) $^ + $(CXX) $(SHARED_LIB_FLAGS)$(LIBRARY) -o $(LIBRARY) $(CFLAGS) $(LIBGSL) $^ tags: ctags *.cpp *.h @@ -94,7 +94,7 @@ sh -c "cd tests && sh ./run-tests.sh" xthresh: xthresh.c - gcc -o $@ $(CFLAGS) $(GSL_INCLUDE) $(LIBGSL) $< + $(CC) -o $@ $(CFLAGS) $(GSL_INCLUDE) $(LIBGSL) $< install: cp $(LIBRARY) /usr/local/lib/