I have this makefile target that contains these steps:
...
cd $(GRAPHICS_BUILD_DIR)
clang++ -c -I$(SFML_HEADERS) $(GRAPHICS_DIR)/*.cpp
cd $(BASE_DIR)
...
For some reason, Clang outputs the build files into BASE_DIR
, not GRAPHICS_BUILD_DIR
. Everything compiles fine, and when I execute one line at a time manually, it works fine, and the *.o
files are outputted in the correct directory.
Why doesn't make put these files in the correct directory, and how can I force it to?
I'm using clang3.1 and the current version of GNUMake on ubuntu linux kernel 3.2.0-26.