Modified the Linux build system so that makefiles are now outside the source tree
git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/branches/sfml2@1477 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
parent
fd8fa4e2f8
commit
ca5489a5d6
21 changed files with 477 additions and 21 deletions
28
build/make/Makefile.system
Normal file
28
build/make/Makefile.system
Normal file
|
@ -0,0 +1,28 @@
|
|||
SRC = $(wildcard $(SRCROOT)/System/*.cpp $(SRCROOT)/System/Unix/*.cpp)
|
||||
OBJ = $(SRC:.cpp=.o)
|
||||
|
||||
LIB = libsfml-system.so
|
||||
LIBNAME = $(LIB).$(VERSION)
|
||||
FULLLIBNAME = $(LIBPATH)/$(LIBNAME)
|
||||
LINK = $(LN) $(LNFLAGS) $(LIBNAME) $(DESTLIBDIR)/$(LIB)
|
||||
|
||||
all: $(LIB)
|
||||
|
||||
libsfml-system.so: $(OBJ)
|
||||
$(CPP) $(LDFLAGS) -Wl,-soname,$(LIBNAME) -o $(FULLLIBNAME) $(OBJ) -lpthread
|
||||
|
||||
$(OBJ): %.o: %.cpp
|
||||
$(CPP) -o $@ -c $< $(CFLAGS)
|
||||
|
||||
.PHONY: clean mrproper
|
||||
|
||||
clean:
|
||||
rm -rf $(OBJ)
|
||||
|
||||
mrproper: clean
|
||||
rm -rf $(FULLLIBNAME)
|
||||
|
||||
install:
|
||||
objcopy --only-keep-debug $(FULLLIBNAME) $(DESTDBGDIR)/$(LIBNAME)
|
||||
objcopy --strip-unneeded $(FULLLIBNAME) $(DESTLIBDIR)/$(LIBNAME)
|
||||
$(LINK)
|
Loading…
Add table
Add a link
Reference in a new issue