Makefile.in 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225
  1. # Makefile to build and install the SDL library
  2. top_builddir = .
  3. srcdir = @srcdir@
  4. objects = build
  5. prefix = @prefix@
  6. exec_prefix = @exec_prefix@
  7. bindir = @bindir@
  8. libdir = @libdir@
  9. includedir = @includedir@
  10. datarootdir = @datarootdir@
  11. datadir = @datadir@
  12. auxdir = @ac_aux_dir@
  13. distpath = $(srcdir)/..
  14. distdir = SDL2-@SDL_VERSION@
  15. distfile = $(distdir).tar.gz
  16. @SET_MAKE@
  17. SHELL = @SHELL@
  18. CC = @CC@
  19. INCLUDE = @INCLUDE@
  20. CFLAGS = @BUILD_CFLAGS@
  21. EXTRA_CFLAGS = @EXTRA_CFLAGS@
  22. LDFLAGS = @BUILD_LDFLAGS@
  23. EXTRA_LDFLAGS = @EXTRA_LDFLAGS@
  24. LIBTOOL = @LIBTOOL@
  25. INSTALL = @INSTALL@
  26. AR = @AR@
  27. RANLIB = @RANLIB@
  28. WINDRES = @WINDRES@
  29. TARGET = libSDL2.la
  30. OBJECTS = @OBJECTS@
  31. VERSION_OBJECTS = @VERSION_OBJECTS@
  32. SDLMAIN_TARGET = libSDL2main.a
  33. SDLMAIN_OBJECTS = @SDLMAIN_OBJECTS@
  34. SDLTEST_TARGET = libSDL2_test.a
  35. SDLTEST_OBJECTS = @SDLTEST_OBJECTS@
  36. SRC_DIST = *.txt acinclude Android.mk autogen.sh android-project build-scripts cmake configure configure.in debian include Makefile.* sdl2-config.in sdl2.m4 sdl2.pc.in SDL2.spec.in src test VisualC.html VisualC Xcode Xcode-iOS
  37. GEN_DIST = SDL2.spec
  38. HDRS = \
  39. SDL.h \
  40. SDL_assert.h \
  41. SDL_atomic.h \
  42. SDL_audio.h \
  43. SDL_bits.h \
  44. SDL_blendmode.h \
  45. SDL_clipboard.h \
  46. SDL_cpuinfo.h \
  47. SDL_egl.h \
  48. SDL_endian.h \
  49. SDL_error.h \
  50. SDL_events.h \
  51. SDL_filesystem.h \
  52. SDL_gamecontroller.h \
  53. SDL_gesture.h \
  54. SDL_haptic.h \
  55. SDL_hints.h \
  56. SDL_joystick.h \
  57. SDL_keyboard.h \
  58. SDL_keycode.h \
  59. SDL_loadso.h \
  60. SDL_log.h \
  61. SDL_main.h \
  62. SDL_messagebox.h \
  63. SDL_mouse.h \
  64. SDL_mutex.h \
  65. SDL_name.h \
  66. SDL_opengl.h \
  67. SDL_opengl_glext.h \
  68. SDL_opengles.h \
  69. SDL_opengles2_gl2ext.h \
  70. SDL_opengles2_gl2.h \
  71. SDL_opengles2_gl2platform.h \
  72. SDL_opengles2.h \
  73. SDL_opengles2_khrplatform.h \
  74. SDL_pixels.h \
  75. SDL_platform.h \
  76. SDL_power.h \
  77. SDL_quit.h \
  78. SDL_rect.h \
  79. SDL_render.h \
  80. SDL_rwops.h \
  81. SDL_scancode.h \
  82. SDL_shape.h \
  83. SDL_stdinc.h \
  84. SDL_surface.h \
  85. SDL_system.h \
  86. SDL_syswm.h \
  87. SDL_thread.h \
  88. SDL_timer.h \
  89. SDL_touch.h \
  90. SDL_types.h \
  91. SDL_version.h \
  92. SDL_video.h \
  93. begin_code.h \
  94. close_code.h
  95. SDLTEST_HDRS = $(shell ls $(srcdir)/include | fgrep SDL_test)
  96. LT_AGE = @LT_AGE@
  97. LT_CURRENT = @LT_CURRENT@
  98. LT_RELEASE = @LT_RELEASE@
  99. LT_REVISION = @LT_REVISION@
  100. LT_LDFLAGS = -no-undefined -rpath $(DESTDIR)$(libdir) -release $(LT_RELEASE) -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
  101. all: $(srcdir)/configure Makefile $(objects) $(objects)/$(TARGET) $(objects)/$(SDLMAIN_TARGET) $(objects)/$(SDLTEST_TARGET)
  102. $(srcdir)/configure: $(srcdir)/configure.in
  103. @echo "Warning, configure.in is out of date"
  104. #(cd $(srcdir) && sh autogen.sh && sh configure)
  105. @sleep 3
  106. Makefile: $(srcdir)/Makefile.in
  107. $(SHELL) config.status $@
  108. Makefile.in:;
  109. $(objects):
  110. $(SHELL) $(auxdir)/mkinstalldirs $@
  111. update-revision:
  112. $(SHELL) $(auxdir)/updaterev.sh
  113. .PHONY: all update-revision install install-bin install-hdrs install-lib install-data uninstall uninstall-bin uninstall-hdrs uninstall-lib uninstall-data clean distclean dist $(OBJECTS:.lo=.d)
  114. $(objects)/$(TARGET): $(OBJECTS) $(VERSION_OBJECTS)
  115. $(LIBTOOL) --tag=CC --mode=link $(CC) -o $@ $(OBJECTS) $(VERSION_OBJECTS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(LT_LDFLAGS)
  116. $(objects)/$(SDLMAIN_TARGET): $(SDLMAIN_OBJECTS)
  117. $(AR) cru $@ $(SDLMAIN_OBJECTS)
  118. $(RANLIB) $@
  119. $(objects)/$(SDLTEST_TARGET): $(SDLTEST_OBJECTS)
  120. $(AR) cru $@ $(SDLTEST_OBJECTS)
  121. $(RANLIB) $@
  122. install: all install-bin install-hdrs install-lib install-data
  123. install-bin:
  124. $(SHELL) $(auxdir)/mkinstalldirs $(DESTDIR)$(bindir)
  125. $(INSTALL) -m 755 sdl2-config $(DESTDIR)$(bindir)/sdl2-config
  126. install-hdrs: update-revision
  127. $(SHELL) $(auxdir)/mkinstalldirs $(DESTDIR)$(includedir)/SDL2
  128. for file in $(HDRS) $(SDLTEST_HDRS); do \
  129. $(INSTALL) -m 644 $(srcdir)/include/$$file $(DESTDIR)$(includedir)/SDL2/$$file; \
  130. done
  131. $(INSTALL) -m 644 include/SDL_config.h $(DESTDIR)$(includedir)/SDL2/SDL_config.h
  132. if test -f include/SDL_revision.h; then \
  133. $(INSTALL) -m 644 include/SDL_revision.h $(DESTDIR)$(includedir)/SDL2/SDL_revision.h; \
  134. else \
  135. $(INSTALL) -m 644 $(srcdir)/include/SDL_revision.h $(DESTDIR)$(includedir)/SDL2/SDL_revision.h; \
  136. fi
  137. install-lib: $(objects) $(objects)/$(TARGET) $(objects)/$(SDLMAIN_TARGET) $(objects)/$(SDLTEST_TARGET)
  138. $(SHELL) $(auxdir)/mkinstalldirs $(DESTDIR)$(libdir)
  139. $(LIBTOOL) --mode=install $(INSTALL) $(objects)/$(TARGET) $(DESTDIR)$(libdir)/$(TARGET)
  140. $(INSTALL) -m 644 $(objects)/$(SDLMAIN_TARGET) $(DESTDIR)$(libdir)/$(SDLMAIN_TARGET)
  141. $(RANLIB) $(DESTDIR)$(libdir)/$(SDLMAIN_TARGET)
  142. $(INSTALL) -m 644 $(objects)/$(SDLTEST_TARGET) $(DESTDIR)$(libdir)/$(SDLTEST_TARGET)
  143. $(RANLIB) $(DESTDIR)$(libdir)/$(SDLTEST_TARGET)
  144. install-data:
  145. $(SHELL) $(auxdir)/mkinstalldirs $(DESTDIR)$(datadir)/aclocal
  146. $(INSTALL) -m 644 $(srcdir)/sdl2.m4 $(DESTDIR)$(datadir)/aclocal/sdl2.m4
  147. $(SHELL) $(auxdir)/mkinstalldirs $(DESTDIR)$(libdir)/pkgconfig
  148. $(INSTALL) -m 644 sdl2.pc $(DESTDIR)$(libdir)/pkgconfig
  149. uninstall: uninstall-bin uninstall-hdrs uninstall-lib uninstall-data
  150. uninstall-bin:
  151. rm -f $(DESTDIR)$(bindir)/sdl2-config
  152. uninstall-hdrs:
  153. for file in $(HDRS) $(SDLTEST_HDRS); do \
  154. rm -f $(DESTDIR)$(includedir)/SDL2/$$file; \
  155. done
  156. rm -f $(DESTDIR)$(includedir)/SDL2/SDL_config.h
  157. rm -f $(DESTDIR)$(includedir)/SDL2/SDL_revision.h
  158. -rmdir $(DESTDIR)$(includedir)/SDL2
  159. uninstall-lib:
  160. $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(libdir)/$(TARGET)
  161. rm -f $(DESTDIR)$(libdir)/$(SDLMAIN_TARGET)
  162. rm -f $(DESTDIR)$(libdir)/$(SDLTEST_TARGET)
  163. uninstall-data:
  164. rm -f $(DESTDIR)$(datadir)/aclocal/sdl2.m4
  165. rm -f $(DESTDIR)$(libdir)/pkgconfig/sdl2.pc
  166. clean:
  167. rm -rf $(objects)
  168. if test -f test/Makefile; then (cd test; $(MAKE) $@); fi
  169. distclean: clean
  170. rm -f Makefile Makefile.rules sdl2-config
  171. rm -f config.status config.cache config.log libtool
  172. rm -rf $(srcdir)/autom4te*
  173. find $(srcdir) \( \
  174. -name '*~' -o \
  175. -name '*.bak' -o \
  176. -name '*.old' -o \
  177. -name '*.rej' -o \
  178. -name '*.orig' -o \
  179. -name '.#*' \) \
  180. -exec rm -f {} \;
  181. if test -f test/Makefile; then (cd test; $(MAKE) $@); fi
  182. dist $(distfile):
  183. $(SHELL) $(auxdir)/mkinstalldirs $(distdir)
  184. (cd $(srcdir); tar cf - $(SRC_DIST)) | (cd $(distdir); tar xf -)
  185. tar cf - $(GEN_DIST) | (cd $(distdir); tar xf -)
  186. find $(distdir) \( \
  187. -name '*~' -o \
  188. -name '*.bak' -o \
  189. -name '*.old' -o \
  190. -name '*.rej' -o \
  191. -name '*.orig' -o \
  192. -name '.#*' \) \
  193. -exec rm -f {} \;
  194. if test -f $(distdir)/test/Makefile; then (cd $(distdir)/test && make distclean); fi
  195. (cd $(distdir); build-scripts/updaterev.sh)
  196. tar cvf - $(distdir) | gzip --best >$(distfile)
  197. rm -rf $(distdir)
  198. rpm: $(distfile)
  199. rpmbuild -ta $?