Mercurial > sdl-ios-xcode
comparison Makefile.in @ 3334:61ea9005fddf
Use gcc's built-in dependency generation, thanks to Adam Strzelecki
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sun, 04 Oct 2009 03:38:01 +0000 |
parents | 0679e03ef8fa |
children | ae9c65fa9772 |
comparison
equal
deleted
inserted
replaced
3333:b334b4f7dfa0 | 3334:61ea9005fddf |
---|---|
1 # Makefile to build and install the SDL library | 1 # Makefile to build and install the SDL library |
2 | 2 |
3 top_builddir = . | 3 top_builddir = . |
4 srcdir = @srcdir@ | 4 srcdir = @srcdir@ |
5 objects = build | 5 objects = build |
6 depend = build-deps | |
7 prefix = @prefix@ | 6 prefix = @prefix@ |
8 exec_prefix = @exec_prefix@ | 7 exec_prefix = @exec_prefix@ |
9 bindir = @bindir@ | 8 bindir = @bindir@ |
10 libdir = @libdir@ | 9 libdir = @libdir@ |
11 includedir = @includedir@ | 10 includedir = @includedir@ |
31 AR = @AR@ | 30 AR = @AR@ |
32 RANLIB = @RANLIB@ | 31 RANLIB = @RANLIB@ |
33 WINDRES = @WINDRES@ | 32 WINDRES = @WINDRES@ |
34 | 33 |
35 TARGET = libSDL.la | 34 TARGET = libSDL.la |
36 SOURCES = @SOURCES@ | |
37 OBJECTS = @OBJECTS@ | 35 OBJECTS = @OBJECTS@ |
36 VERSION_OBJECTS = @VERSION_OBJECTS@ | |
38 | 37 |
39 SDLMAIN_TARGET = libSDLmain.a | 38 SDLMAIN_TARGET = libSDLmain.a |
40 SDLMAIN_SOURCES = @SDLMAIN_SOURCES@ | |
41 SDLMAIN_OBJECTS = @SDLMAIN_OBJECTS@ | 39 SDLMAIN_OBJECTS = @SDLMAIN_OBJECTS@ |
42 | 40 |
43 # PS3 SPU programs | 41 # PS3 SPU programs |
44 SPU_GCC = @SPU_GCC@ | 42 SPU_GCC = @SPU_GCC@ |
45 EMBEDSPU = @EMBEDSPU@ | 43 EMBEDSPU = @EMBEDSPU@ |
72 $(srcdir)/include/SDL_revision.h: update-revision | 70 $(srcdir)/include/SDL_revision.h: update-revision |
73 | 71 |
74 update-revision: | 72 update-revision: |
75 $(SHELL) $(auxdir)/updaterev.sh | 73 $(SHELL) $(auxdir)/updaterev.sh |
76 | 74 |
77 .PHONY: all update-revision depend install install-bin install-hdrs install-lib install-data install-man uninstall uninstall-bin uninstall-hdrs uninstall-lib uninstall-data uninstall-man clean distclean dist | 75 .PHONY: all update-revision install install-bin install-hdrs install-lib install-data install-man uninstall uninstall-bin uninstall-hdrs uninstall-lib uninstall-data uninstall-man clean distclean dist |
78 depend: update-revision | 76 |
79 @SOURCES="$(SOURCES)" INCLUDE="$(INCLUDE)" output="$(depend)" \ | 77 -include $(OBJECTS:.lo=.d) |
80 $(SHELL) $(auxdir)/makedep.sh | 78 @DEPENDS@ |
81 @for src in $(SDLMAIN_SOURCES); do \ | 79 @VERSION_DEPENDS@ |
82 obj=`echo $$src | sed -e 's|.*/||' -e 's|\.[^\.]*$$|.o|'`; \ | 80 @SDLMAIN_DEPENDS@ |
83 echo "\$$(objects)/$$obj: $$src" >>$(depend); \ | 81 |
84 echo " \$$(CC) \$$(CFLAGS) \$$(EXTRA_CFLAGS) -c $$src -o \$$@" >>$(depend); \ | 82 $(objects)/$(TARGET): $(OBJECTS) $(VERSION_OBJECTS) |
85 done | 83 $(LIBTOOL) --mode=link $(CC) -o $@ $(OBJECTS) $(VERSION_OBJECTS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(LT_LDFLAGS) |
86 | |
87 include $(depend) | |
88 | |
89 $(objects)/$(TARGET): $(OBJECTS) | |
90 $(LIBTOOL) --mode=link $(CC) -o $@ $(OBJECTS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(LT_LDFLAGS) | |
91 | 84 |
92 $(objects)/$(SDLMAIN_TARGET): $(SDLMAIN_OBJECTS) | 85 $(objects)/$(SDLMAIN_TARGET): $(SDLMAIN_OBJECTS) |
93 $(AR) cru $@ $(SDLMAIN_OBJECTS) | 86 $(AR) cru $@ $(SDLMAIN_OBJECTS) |
94 $(RANLIB) $@ | 87 $(RANLIB) $@ |
95 | 88 |
145 if test -f test/Makefile; then (cd test; $(MAKE) $@); fi | 138 if test -f test/Makefile; then (cd test; $(MAKE) $@); fi |
146 | 139 |
147 distclean: clean | 140 distclean: clean |
148 rm -f Makefile include/SDL_config.h sdl-config | 141 rm -f Makefile include/SDL_config.h sdl-config |
149 rm -f SDL.qpg | 142 rm -f SDL.qpg |
150 rm -f config.status config.cache config.log libtool $(depend) | 143 rm -f config.status config.cache config.log libtool |
151 rm -rf $(srcdir)/autom4te* | 144 rm -rf $(srcdir)/autom4te* |
152 find $(srcdir) \( \ | 145 find $(srcdir) \( \ |
153 -name '*~' -o \ | 146 -name '*~' -o \ |
154 -name '*.bak' -o \ | 147 -name '*.bak' -o \ |
155 -name '*.old' -o \ | 148 -name '*.old' -o \ |