Im using the batch-mode rule for my makefile. Currently i have the following targets:
DIR_SRC = src
DIR_INCLUDE = include
DIR_LIB = lib
DIR_BIN = bin\x64
DIR_BUILD = build\x64
{$(DIR_SRC)}.cpp{$(DIR_BUILD)}.obj ::
@echo Compiling...
cl /c /EHsc /Fo$(DIR_BUILD)\ /MD /I$(DIR_INCLUDE) $<
$(EXECUTABLE_NAME) : $(DIR_BUILD)\*.obj
@echo Linking $(EXECUTABLE_NAME)...
link /out:$(DIR_BIN)\$(EXECUTABLE_NAME) $(DIR_BUILD)\*.obj
The "bin/x64/*.obj" target uses all cpp files inside the "src" folder. Is it possible to add another source path to it?
I want something like this
{$(DIR_SRC) $(ANOTHER_DIR)}.cpp{$(DIR_BUILD)}.obj ::