diff options
author | clyne <clyne@bitgloo.com> | 2022-11-17 07:41:09 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-17 07:41:09 -0500 |
commit | 6663c25633a27fcc14d0648bd1afea7ea12f497f (patch) | |
tree | dcc2ec993db3c4b75c3e7e3df35b0494a9ce1f32 /Makefile | |
parent | da0913771538fd9b1ca538615fd9aa0388608466 (diff) | |
parent | 57013add5b7c524086272be7d395f9ec5109bde2 (diff) |
Lib cleanup
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 35 |
1 files changed, 27 insertions, 8 deletions
@@ -37,14 +37,18 @@ DEPEXT = d LIBDIR = lib LIBS = -L$(LIBDIR) -lSDL2 -lpthread -lentityx -lluajit -ldl -lGLEW -lGL \ - -lSDL2_image -lSOIL -lfreetype -lopenal -lalut + -lSDL2_image -lsoil -lfreetype -lopenal -lalut CXXFLAGS = -ggdb -std=c++17 -Wall -Wextra -Werror -pedantic \ - -Wno-class-memaccess -Wno-implicit-fallthrough -m64 + -Wno-class-memaccess -Wno-implicit-fallthrough -Wno-unused-parameter -CXXINCS = -Isrc -I$(LIBDIR)/LuaJIT/src -I$(LIBDIR)/entityx \ - -I$(LIBDIR)/LuaBridge/Source -I$(LIBDIR)/sol2/include \ - -I$(LIBDIR)/soil -I$(LIBDIR)/cereal/include -I$(LIBDIR)/freetype +CXXINCS = -I$(SRCDIR) \ + -I$(LIBDIR)/entityx \ + -I$(LIBDIR)/luajit/src \ + -I$(LIBDIR)/sol2/include \ + -I$(LIBDIR)/soil \ + -I$(LIBDIR)/cereal/include \ + -I$(LIBDIR)/freetype CXXSRC := $(shell find $(SRCDIR) -type f -name *.$(SRCEXT)) CXXOBJ := $(patsubst $(SRCDIR)/%,$(OUTDIR)/%,$(CXXSRC:.$(SRCEXT)=.$(OBJEXT))) @@ -65,10 +69,12 @@ clean: @echo " CLEAN" @$(RM) -rf $(OUTDIR) +cleanall: clean + @$(RM) -f lib/libentityx.a lib/libluajit.a lib/libsoil.a + cleaner: clean -#@$(RM) -rf $(EXECDIR) -$(EXEC): $(CXXOBJ) +$(EXEC): lib/libentityx.a lib/libluajit.a lib/libsoil.a $(CXXOBJ) @echo " CXX " $(EXEC) @$(CXX) -o $(EXECDIR)/$(EXEC) $^ $(LIBS) @@ -82,5 +88,18 @@ $(OUTDIR)/%.$(OBJEXT): $(SRCDIR)/%.$(SRCEXT) @sed -e 's/.*://' -e 's/\\$$//' < $(OUTDIR)/$*.$(DEPEXT).tmp | fmt -1 | sed -e 's/^ *//' -e 's/$$/:/' >> $(OUTDIR)/$*.$(DEPEXT) @rm -f $(OUTDIR)/$*.$(DEPEXT).tmp -.PHONY: all remake clean cleaner resources +lib/libentityx.a: + @cmake -S lib/entityx -B lib/entityx -DENTITYX_BUILD_SHARED=FALSE + @make -Clib/entityx -j4 entityx + @cp lib/entityx/libentityx.a lib/libentityx.a + +lib/libluajit.a: + @make -Clib/luajit -j4 + @cp lib/luajit/src/libluajit.a lib/libluajit.a + +lib/libsoil.a: + @make -Clib/soil -j4 + @cp lib/soil/libsoil.a lib/libsoil.a + +.PHONY: all remake clean cleaner cleanall resources |