3cacaf85f1
This makes sure that e.g. "make clean" actually removes the built exe files, and avoids relinking the exe files each time make is run when cross compiling from linux to windows. (Make on windows seems to have an exception that knows to skip rebuilding the 'h264enc' target if 'h264enc' doesn't exist but 'h264enc.exe' does, but this exception doesn't work on normal unix make.)
17 lines
591 B
Makefile
17 lines
591 B
Makefile
H264ENC_PREFIX=H264ENC
|
|
H264ENC_SRCDIR=codec/console/enc
|
|
H264ENC_CPP_SRCS=\
|
|
$(H264ENC_SRCDIR)/./src/read_config.cpp\
|
|
$(H264ENC_SRCDIR)/./src/welsenc.cpp\
|
|
|
|
H264ENC_OBJS += $(H264ENC_CPP_SRCS:.cpp=.o)
|
|
OBJS += $(H264ENC_OBJS)
|
|
$(H264ENC_SRCDIR)/%.o: $(H264ENC_SRCDIR)/%.cpp
|
|
$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(H264ENC_CFLAGS) $(H264ENC_INCLUDES) -c $(CXX_O) $<
|
|
|
|
h264enc$(EXEEXT): $(H264ENC_OBJS) $(LIBS) $(H264ENC_LIBS) $(H264ENC_DEPS)
|
|
$(CXX) $(CXX_LINK_O) $(H264ENC_OBJS) $(H264ENC_LDFLAGS) $(H264ENC_LIBS) $(LDFLAGS) $(LIBS)
|
|
|
|
binaries: h264enc$(EXEEXT)
|
|
BINARIES += h264enc$(EXEEXT)
|