Clone of mesa.
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

Makefile 5.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272
  1. # Top-level Mesa makefile
  2. TOP = .
  3. SUBDIRS = src
  4. # The git command below generates an empty string when we're not
  5. # building in a GIT tree (i.e., building from a release tarball).
  6. default: $(TOP)/configs/current
  7. @$(TOP)/bin/extract_git_sha1
  8. @for dir in $(SUBDIRS) ; do \
  9. if [ -d $$dir ] ; then \
  10. (cd $$dir && $(MAKE)) || exit 1 ; \
  11. fi \
  12. done
  13. all: default
  14. doxygen:
  15. cd doxygen && $(MAKE)
  16. clean:
  17. -@touch $(TOP)/configs/current
  18. -@for dir in $(SUBDIRS) ; do \
  19. if [ -d $$dir ] ; then \
  20. (cd $$dir && $(MAKE) clean) ; \
  21. fi \
  22. done
  23. -@test -s $(TOP)/configs/current || rm -f $(TOP)/configs/current
  24. realclean: clean
  25. -rm -rf lib*
  26. -rm -f $(TOP)/configs/current
  27. -rm -f $(TOP)/configs/autoconf
  28. -rm -rf autom4te.cache
  29. -find . '(' -name '*.o' -o -name '*.a' -o -name '*.so' -o \
  30. -name depend -o -name depend.bak ')' -exec rm -f '{}' ';'
  31. distclean: realclean
  32. install:
  33. @for dir in $(SUBDIRS) ; do \
  34. if [ -d $$dir ] ; then \
  35. (cd $$dir && $(MAKE) install) || exit 1 ; \
  36. fi \
  37. done
  38. .PHONY: default doxygen clean realclean distclean install
  39. # If there's no current configuration file
  40. $(TOP)/configs/current:
  41. @echo
  42. @echo
  43. @echo "Please choose a configuration from the following list:"
  44. @ls -1 $(TOP)/configs | grep -v "current\|default\|CVS\|autoconf.*"
  45. @echo
  46. @echo "Then type 'make <config>' (ex: 'make linux-x86')"
  47. @echo
  48. @echo "Or, run './configure' then 'make'"
  49. @echo "See './configure --help' for details"
  50. @echo
  51. @echo "(ignore the following error message)"
  52. @exit 1
  53. # Rules to set/install a specific build configuration
  54. aix \
  55. aix-64 \
  56. aix-64-static \
  57. aix-gcc \
  58. aix-static \
  59. autoconf \
  60. bluegene-osmesa \
  61. bluegene-xlc-osmesa \
  62. beos \
  63. catamount-osmesa-pgi \
  64. darwin \
  65. darwin-fat-32bit \
  66. darwin-fat-all \
  67. freebsd \
  68. freebsd-dri \
  69. freebsd-dri-amd64 \
  70. freebsd-dri-x86 \
  71. hpux10 \
  72. hpux10-gcc \
  73. hpux10-static \
  74. hpux11-32 \
  75. hpux11-32-static \
  76. hpux11-32-static-nothreads \
  77. hpux11-64 \
  78. hpux11-64-static \
  79. hpux11-ia64 \
  80. hpux11-ia64-static \
  81. hpux9 \
  82. hpux9-gcc \
  83. irix6-64 \
  84. irix6-64-static \
  85. irix6-n32 \
  86. irix6-n32-static \
  87. irix6-o32 \
  88. irix6-o32-static \
  89. linux \
  90. linux-i965 \
  91. linux-alpha \
  92. linux-alpha-static \
  93. linux-cell \
  94. linux-cell-debug \
  95. linux-debug \
  96. linux-dri \
  97. linux-dri-debug \
  98. linux-dri-x86 \
  99. linux-dri-x86-64 \
  100. linux-dri-ppc \
  101. linux-dri-xcb \
  102. linux-egl \
  103. linux-indirect \
  104. linux-fbdev \
  105. linux-ia64-icc \
  106. linux-ia64-icc-static \
  107. linux-icc \
  108. linux-icc-static \
  109. linux-llvm \
  110. linux-llvm-debug \
  111. linux-opengl-es \
  112. linux-osmesa \
  113. linux-osmesa-static \
  114. linux-osmesa16 \
  115. linux-osmesa16-static \
  116. linux-osmesa32 \
  117. linux-ppc \
  118. linux-ppc-static \
  119. linux-profile \
  120. linux-sparc \
  121. linux-sparc5 \
  122. linux-static \
  123. linux-ultrasparc \
  124. linux-tcc \
  125. linux-x86 \
  126. linux-x86-debug \
  127. linux-x86-32 \
  128. linux-x86-64 \
  129. linux-x86-64-debug \
  130. linux-x86-64-profile \
  131. linux-x86-64-static \
  132. linux-x86-profile \
  133. linux-x86-static \
  134. netbsd \
  135. openbsd \
  136. osf1 \
  137. osf1-static \
  138. solaris-x86 \
  139. solaris-x86-gcc \
  140. solaris-x86-gcc-static \
  141. sunos4 \
  142. sunos4-gcc \
  143. sunos4-static \
  144. sunos5 \
  145. sunos5-gcc \
  146. sunos5-64-gcc \
  147. sunos5-smp \
  148. sunos5-v8 \
  149. sunos5-v8-static \
  150. sunos5-v9 \
  151. sunos5-v9-static \
  152. sunos5-v9-cc-g++ \
  153. ultrix-gcc:
  154. @ if test -f configs/current -o -L configs/current; then \
  155. if ! cmp configs/$@ configs/current > /dev/null; then \
  156. echo "Please run 'make realclean' before changing configs" ; \
  157. exit 1 ; \
  158. fi ; \
  159. else \
  160. cd configs && rm -f current && ln -s $@ current ; \
  161. fi
  162. $(MAKE) default
  163. # Rules for making release tarballs
  164. PACKAGE_VERSION=7.12-devel
  165. PACKAGE_DIR = Mesa-$(PACKAGE_VERSION)
  166. PACKAGE_NAME = MesaLib-$(PACKAGE_VERSION)
  167. EXTRA_FILES = \
  168. aclocal.m4 \
  169. configure \
  170. src/glsl/glsl_parser.cpp \
  171. src/glsl/glsl_parser.h \
  172. src/glsl/glsl_lexer.cpp \
  173. src/glsl/glcpp/glcpp-lex.c \
  174. src/glsl/glcpp/glcpp-parse.c \
  175. src/glsl/glcpp/glcpp-parse.h \
  176. src/mesa/program/lex.yy.c \
  177. src/mesa/program/program_parse.tab.c \
  178. src/mesa/program/program_parse.tab.h
  179. IGNORE_FILES = \
  180. -x autogen.sh
  181. DEPEND_FILES = \
  182. src/mesa/depend \
  183. src/glx/depend \
  184. src/glw/depend \
  185. src/glu/sgi/depend
  186. parsers: configure
  187. -@touch $(TOP)/configs/current
  188. $(MAKE) -C src/glsl glsl_parser.cpp glsl_parser.h glsl_lexer.cpp
  189. $(MAKE) -C src/glsl/glcpp glcpp-lex.c glcpp-parse.c glcpp-parse.h
  190. $(MAKE) -C src/mesa program/lex.yy.c program/program_parse.tab.c program/program_parse.tab.h
  191. # Everything for new a Mesa release:
  192. ARCHIVES = $(PACKAGE_NAME).tar.gz \
  193. $(PACKAGE_NAME).tar.bz2 \
  194. $(PACKAGE_NAME).zip \
  195. tarballs: md5
  196. rm -f ../$(PACKAGE_DIR) $(PACKAGE_NAME).tar
  197. # Helper for autoconf builds
  198. ACLOCAL = aclocal
  199. ACLOCAL_FLAGS =
  200. AUTOCONF = autoconf
  201. AC_FLAGS =
  202. aclocal.m4: configure.ac acinclude.m4
  203. $(ACLOCAL) $(ACLOCAL_FLAGS)
  204. configure: rm_depend configure.ac aclocal.m4 acinclude.m4
  205. $(AUTOCONF) $(AC_FLAGS)
  206. rm_depend:
  207. @for dep in $(DEPEND_FILES) ; do \
  208. rm -f $$dep ; \
  209. touch $$dep ; \
  210. done
  211. manifest.txt: .git
  212. ( \
  213. ls -1 $(EXTRA_FILES) ; \
  214. git ls-files $(IGNORE_FILES) \
  215. ) | sed -e '/^\(.*\/\)\?\./d' -e "s@^@$(PACKAGE_DIR)/@" > $@
  216. ../$(PACKAGE_DIR):
  217. ln -s $(PWD) $@
  218. $(PACKAGE_NAME).tar: parsers ../$(PACKAGE_DIR) manifest.txt
  219. cd .. ; tar -cf $(PACKAGE_DIR)/$(PACKAGE_NAME).tar -T $(PACKAGE_DIR)/manifest.txt
  220. $(PACKAGE_NAME).tar.gz: $(PACKAGE_NAME).tar ../$(PACKAGE_DIR)
  221. gzip --stdout --best $(PACKAGE_NAME).tar > $(PACKAGE_NAME).tar.gz
  222. $(PACKAGE_NAME).tar.bz2: $(PACKAGE_NAME).tar
  223. bzip2 --stdout --best $(PACKAGE_NAME).tar > $(PACKAGE_NAME).tar.bz2
  224. $(PACKAGE_NAME).zip: parsers ../$(PACKAGE_DIR) manifest.txt
  225. rm -f $(PACKAGE_NAME).zip ; \
  226. cd .. ; \
  227. zip -q -@ $(PACKAGE_NAME).zip < $(PACKAGE_DIR)/manifest.txt ; \
  228. mv $(PACKAGE_NAME).zip $(PACKAGE_DIR)
  229. md5: $(ARCHIVES)
  230. @-md5sum $(PACKAGE_NAME).tar.gz
  231. @-md5sum $(PACKAGE_NAME).tar.bz2
  232. @-md5sum $(PACKAGE_NAME).zip
  233. .PHONY: tarballs rm_depend md5