Advertisement
surya-x

Untitled

Oct 20th, 2021
1,701
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CMake 21.92 KB | None | 0 0
  1. # First, test for a proper version of make, but only where one is required.
  2.  
  3. ifeq (,$(.VARIABLES)) # The variable .VARIABLES, new with 3.80, is never empty.
  4. $(error GNU make version 3.80 or newer is required.)
  5. endif
  6.  
  7. # -------------------------------
  8. # Standard Autoconf-set variables
  9. # -------------------------------
  10. VPATH=../gcc-10.2.0
  11.  
  12. build_alias=arm-apple-darwin21.1.0
  13. build_vendor=apple
  14. build_os=darwin21.1.0
  15. build=arm-apple-darwin21.1.0
  16. host_alias=arm-apple-darwin21.1.0
  17. host_vendor=apple
  18. host_os=darwin21.1.0
  19. host=arm-apple-darwin21.1.0
  20. target_alias=i686-elf
  21. target_vendor=pc
  22. target_os=elf
  23. target=i686-pc-elf
  24.  
  25. program_transform_name = s&^&i686-elf-&
  26.  
  27. prefix = /usr/local/x86_64elfgcc
  28. exec_prefix = ${prefix}
  29.  
  30. srcdir = ../gcc-10.2.0
  31.  
  32. bindir = ${exec_prefix}/bin
  33. sbindir = ${exec_prefix}/sbin
  34. libexecdir = ${exec_prefix}/libexec
  35. datadir = ${datarootdir}
  36. sysconfdir = ${prefix}/etc
  37. sharedstatedir = ${prefix}/com
  38. localstatedir = ${prefix}/var
  39. libdir = ${exec_prefix}/lib
  40. includedir = ${prefix}/include
  41. oldincludedir = /usr/include
  42. infodir = ${datarootdir}/info
  43. datarootdir = ${prefix}/share
  44. docdir = ${datarootdir}/doc/${PACKAGE}
  45. pdfdir = ${docdir}
  46. htmldir = ${docdir}
  47. mandir = ${datarootdir}/man
  48. man1dir = $(mandir)/man1
  49. man2dir = $(mandir)/man2
  50. man3dir = $(mandir)/man3
  51. man4dir = $(mandir)/man4
  52. man5dir = $(mandir)/man5
  53. man6dir = $(mandir)/man6
  54. man7dir = $(mandir)/man7
  55. man8dir = $(mandir)/man8
  56. man9dir = $(mandir)/man9
  57.  
  58. INSTALL = /usr/bin/install -c
  59. INSTALL_PROGRAM = ${INSTALL}
  60. INSTALL_SCRIPT = ${INSTALL}
  61. INSTALL_DATA = ${INSTALL} -m 644
  62. LN = ln
  63. LN_S = ln -s
  64. MAINT = #
  65. MAINTAINER_MODE_FALSE =
  66. MAINTAINER_MODE_TRUE = #
  67.  
  68. # -------------------------------------------------
  69. # Miscellaneous non-standard autoconf-set variables
  70. # -------------------------------------------------
  71.  
  72. # The gcc driver likes to know the arguments it was configured with.
  73. TOPLEVEL_CONFIGURE_ARGUMENTS=../gcc-10.2.0/configure --prefix=/usr/local/x86_64elfgcc --target=i686-elf --disable-nls --enable-languages=c,c++ --without-headers --enable-interwork --enable-multilib --with-gmp=/opt/homebrew/Cellar/gmp/6.2.1 --with-mpc=/opt/homebrew/Cellar/libmpc/1.2.1 --with-mpfr=/opt/homebrew/Cellar/mpfr/4.1.0
  74.  
  75. tooldir = ${exec_prefix}/i686-elf
  76. build_tooldir = ${exec_prefix}/i686-elf
  77.  
  78. # This is the name of the environment variable used for the path to
  79. # the libraries.
  80. RPATH_ENVVAR = DYLD_LIBRARY_PATH
  81.  
  82. # On targets where RPATH_ENVVAR is PATH, a subdirectory of the GCC build path
  83. # is used instead of the directory itself to avoid including built
  84. # executables in PATH.
  85. GCC_SHLIB_SUBDIR =
  86.  
  87. # Build programs are put under this directory.
  88. BUILD_SUBDIR = build-arm-apple-darwin21.1.0
  89. # This is set by the configure script to the arguments to use when configuring
  90. # directories built for the build system.
  91. BUILD_CONFIGARGS =  --cache-file=./config.cache '--prefix=/usr/local/x86_64elfgcc' '--disable-nls' '--without-headers' '--enable-interwork' '--enable-multilib' '--with-gmp=/opt/homebrew/Cellar/gmp/6.2.1' '--with-mpc=/opt/homebrew/Cellar/libmpc/1.2.1' '--with-mpfr=/opt/homebrew/Cellar/mpfr/4.1.0' '--enable-languages=c,c++,lto' --program-transform-name='s&^&i686-elf-&' --disable-option-checking --with-build-subdir="$(BUILD_SUBDIR)"
  92.  
  93. # Linker flags to use on the host, for stage1 or when not
  94. # bootstrapping.
  95. STAGE1_LDFLAGS =
  96.  
  97. # Libraries to use on the host, for stage1 or when not bootstrapping.
  98. STAGE1_LIBS =
  99.  
  100. # Linker flags to use for stage2 and later.
  101. POSTSTAGE1_LDFLAGS = -static-libstdc++ -static-libgcc
  102.  
  103. # Libraries to use for stage2 and later.
  104. POSTSTAGE1_LIBS =
  105.  
  106. # This is the list of variables to export in the environment when
  107. # configuring any subdirectory.  It must also be exported whenever
  108. # recursing into a build directory in case that directory's Makefile
  109. # re-runs configure.
  110. BASE_EXPORTS = \
  111.     FLEX="$(FLEX)"; export FLEX; \
  112.     LEX="$(LEX)"; export LEX; \
  113.     BISON="$(BISON)"; export BISON; \
  114.     YACC="$(YACC)"; export YACC; \
  115.     M4="$(M4)"; export M4; \
  116.     SED="$(SED)"; export SED; \
  117.     AWK="$(AWK)"; export AWK; \
  118.     MAKEINFO="$(MAKEINFO)"; export MAKEINFO;
  119.  
  120. # This is the list of variables to export in the environment when
  121. # configuring subdirectories for the build system.
  122. BUILD_EXPORTS = \
  123.     $(BASE_EXPORTS) \
  124.     AR="$(AR_FOR_BUILD)"; export AR; \
  125.     AS="$(AS_FOR_BUILD)"; export AS; \
  126.     CC="$(CC_FOR_BUILD)"; export CC; \
  127.     CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
  128.     CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
  129.     CXX="$(CXX_FOR_BUILD)"; export CXX; \
  130.     CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
  131.     GFORTRAN="$(GFORTRAN_FOR_BUILD)"; export GFORTRAN; \
  132.     GOC="$(GOC_FOR_BUILD)"; export GOC; \
  133.     GOCFLAGS="$(GOCFLAGS_FOR_BUILD)"; export GOCFLAGS; \
  134.     GDC="$(GDC_FOR_BUILD)"; export GDC; \
  135.     GDCFLAGS="$(GDCFLAGS_FOR_BUILD)"; export GDCFLAGS; \
  136.     DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
  137.     LD="$(LD_FOR_BUILD)"; export LD; \
  138.     LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
  139.     NM="$(NM_FOR_BUILD)"; export NM; \
  140.     RANLIB="$(RANLIB_FOR_BUILD)"; export RANLIB; \
  141.     WINDRES="$(WINDRES_FOR_BUILD)"; export WINDRES; \
  142.     WINDMC="$(WINDMC_FOR_BUILD)"; export WINDMC;
  143.  
  144. # These variables must be set on the make command line for directories
  145. # built for the build system to override those in BASE_FLAGS_TO_PASS.
  146. EXTRA_BUILD_FLAGS = \
  147.     CFLAGS="$(CFLAGS_FOR_BUILD)" \
  148.     LDFLAGS="$(LDFLAGS_FOR_BUILD)"
  149.  
  150. # This is the list of directories to built for the host system.
  151. SUBDIRS =  intl libiberty zlib libbacktrace libcpp libdecnumber fixincludes gcc libcc1 lto-plugin
  152. TARGET_CONFIGDIRS =  libgcc libstdc++-v3 libssp libquadmath
  153. # This is set by the configure script to the arguments to use when configuring
  154. # directories built for the host system.
  155. HOST_CONFIGARGS =  --cache-file=./config.cache  '--prefix=/usr/local/x86_64elfgcc' '--disable-nls' '--without-headers' '--enable-interwork' '--enable-multilib' '--with-gmp=/opt/homebrew/Cellar/gmp/6.2.1' '--with-mpc=/opt/homebrew/Cellar/libmpc/1.2.1' '--with-mpfr=/opt/homebrew/Cellar/mpfr/4.1.0' '--enable-languages=c,c++,lto' --program-transform-name='s&^&i686-elf-&' --disable-option-checking
  156. # Host programs are put under this directory, which is . except if building
  157. # with srcdir=..
  158. HOST_SUBDIR = .
  159. # This is the list of variables to export in the environment when
  160. # configuring subdirectories for the host system.  We need to pass
  161. # some to the GCC configure because of its hybrid host/target nature.
  162. HOST_EXPORTS = \
  163.     $(BASE_EXPORTS) \
  164.     CC="$(CC)"; export CC; \
  165.     ADA_CFLAGS="$(ADA_CFLAGS)"; export ADA_CFLAGS; \
  166.     CFLAGS="$(CFLAGS)"; export CFLAGS; \
  167.     CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
  168.     CXX="$(CXX)"; export CXX; \
  169.     CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
  170.     GFORTRAN="$(GFORTRAN)"; export GFORTRAN; \
  171.     GOC="$(GOC)"; export GOC; \
  172.     GDC="$(GDC)"; export GDC; \
  173.     AR="$(AR)"; export AR; \
  174.     AS="$(AS)"; export AS; \
  175.     CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
  176.     CXX_FOR_BUILD="$(CXX_FOR_BUILD)"; export CXX_FOR_BUILD; \
  177.     DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
  178.     LD="$(LD)"; export LD; \
  179.     LDFLAGS="$(STAGE1_LDFLAGS) $(LDFLAGS)"; export LDFLAGS; \
  180.     NM="$(NM)"; export NM; \
  181.     RANLIB="$(RANLIB)"; export RANLIB; \
  182.     WINDRES="$(WINDRES)"; export WINDRES; \
  183.     WINDMC="$(WINDMC)"; export WINDMC; \
  184.     OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
  185.     OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
  186.     OTOOL="$(OTOOL)"; export OTOOL; \
  187.     READELF="$(READELF)"; export READELF; \
  188.     AR_FOR_TARGET="$(AR_FOR_TARGET)"; export AR_FOR_TARGET; \
  189.     AS_FOR_TARGET="$(AS_FOR_TARGET)"; export AS_FOR_TARGET; \
  190.     GCC_FOR_TARGET="$(GCC_FOR_TARGET)"; export GCC_FOR_TARGET; \
  191.     LD_FOR_TARGET="$(LD_FOR_TARGET)"; export LD_FOR_TARGET; \
  192.     NM_FOR_TARGET="$(NM_FOR_TARGET)"; export NM_FOR_TARGET; \
  193.     OBJDUMP_FOR_TARGET="$(OBJDUMP_FOR_TARGET)"; export OBJDUMP_FOR_TARGET; \
  194.     OBJCOPY_FOR_TARGET="$(OBJCOPY_FOR_TARGET)"; export OBJCOPY_FOR_TARGET; \
  195.     OTOOL_FOR_TARGET="$(OTOOL_FOR_TARGET)"; export OTOOL_FOR_TARGET; \
  196.     RANLIB_FOR_TARGET="$(RANLIB_FOR_TARGET)"; export RANLIB_FOR_TARGET; \
  197.     READELF_FOR_TARGET="$(READELF_FOR_TARGET)"; export READELF_FOR_TARGET; \
  198.     TOPLEVEL_CONFIGURE_ARGUMENTS="$(TOPLEVEL_CONFIGURE_ARGUMENTS)"; export TOPLEVEL_CONFIGURE_ARGUMENTS; \
  199.     HOST_LIBS="$(STAGE1_LIBS)"; export HOST_LIBS; \
  200.     GMPLIBS="$(HOST_GMPLIBS)"; export GMPLIBS; \
  201.     GMPINC="$(HOST_GMPINC)"; export GMPINC; \
  202.     ISLLIBS="$(HOST_ISLLIBS)"; export ISLLIBS; \
  203.     ISLINC="$(HOST_ISLINC)"; export ISLINC; \
  204.     LIBELFLIBS="$(HOST_LIBELFLIBS)"; export LIBELFLIBS; \
  205.     LIBELFINC="$(HOST_LIBELFINC)"; export LIBELFINC; \
  206.     XGCC_FLAGS_FOR_TARGET="$(XGCC_FLAGS_FOR_TARGET)"; export XGCC_FLAGS_FOR_TARGET; \
  207.     $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH)$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
  208.  
  209. POSTSTAGE1_CXX_EXPORT = \
  210.     CXX='$(CXX)'; export CXX; \
  211.     CXX_FOR_BUILD='$(CXX_FOR_BUILD)'; export CXX_FOR_BUILD;
  212.  
  213. # Similar, for later GCC stages.
  214. POSTSTAGE1_HOST_EXPORTS = \
  215.     $(HOST_EXPORTS) \
  216.     CC="$(STAGE_CC_WRAPPER) $$r/$(HOST_SUBDIR)/prev-gcc/xgcc$(exeext) \
  217.       -B$$r/$(HOST_SUBDIR)/prev-gcc/ -B$(build_tooldir)/bin/ \
  218.       $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export CC; \
  219.     CC_FOR_BUILD="$$CC"; export CC_FOR_BUILD; \
  220.     $(POSTSTAGE1_CXX_EXPORT) \
  221.     $(LTO_EXPORTS) \
  222.     GDC="$$r/$(HOST_SUBDIR)/prev-gcc/gdc$(exeext) -B$$r/$(HOST_SUBDIR)/prev-gcc/ \
  223.       -B$(build_tooldir)/bin/ $(GDC_FLAGS_FOR_TARGET) \
  224.       -B$$r/prev-$(TARGET_SUBDIR)/libphobos/src \
  225.       -I$$r/prev-$(TARGET_SUBDIR)/libphobos/libdruntime -I$$s/libphobos/libdruntime \
  226.       -L$$r/prev-$(TARGET_SUBDIR)/libphobos/src/.libs \
  227.       -L$$r/prev-$(TARGET_SUBDIR)/libphobos/libdruntime/.libs"; \
  228.     export GDC; \
  229.     GDC_FOR_BUILD="$$GDC"; export GDC_FOR_BUILD; \
  230.     GNATBIND="$$r/$(HOST_SUBDIR)/prev-gcc/gnatbind"; export GNATBIND; \
  231.     LDFLAGS="$(POSTSTAGE1_LDFLAGS) $(BOOT_LDFLAGS)"; export LDFLAGS; \
  232.     HOST_LIBS="$(POSTSTAGE1_LIBS)"; export HOST_LIBS;
  233.  
  234. # Target libraries are put under this directory:
  235. TARGET_SUBDIR = i686-elf
  236. # This is set by the configure script to the arguments to use when configuring
  237. # directories built for the target.
  238. TARGET_CONFIGARGS = --cache-file=./config.cache --with-cross-host=arm-apple-darwin21.1.0   '--prefix=/usr/local/x86_64elfgcc' '--disable-nls' '--without-headers' '--enable-interwork' '--enable-multilib' '--enable-languages=c,c++,lto' --program-transform-name='s&^&i686-elf-&' --disable-option-checking --with-target-subdir="$(TARGET_SUBDIR)"
  239. # This is the list of variables to export in the environment when
  240. # configuring subdirectories for the target system.
  241. BASE_TARGET_EXPORTS = \
  242.     $(BASE_EXPORTS) \
  243.     AR="$(AR_FOR_TARGET)"; export AR; \
  244.     AS="$(COMPILER_AS_FOR_TARGET)"; export AS; \
  245.     CC="$(CC_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export CC; \
  246.     CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
  247.     CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
  248.     CPPFLAGS="$(CPPFLAGS_FOR_TARGET)"; export CPPFLAGS; \
  249.     CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
  250.     GFORTRAN="$(GFORTRAN_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export GFORTRAN; \
  251.     GOC="$(GOC_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export GOC; \
  252.     GDC="$(GDC_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export GDC; \
  253.     DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
  254.     LD="$(COMPILER_LD_FOR_TARGET)"; export LD; \
  255.     LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
  256.     LIPO="$(LIPO_FOR_TARGET)"; export LIPO; \
  257.     NM="$(COMPILER_NM_FOR_TARGET)"; export NM; \
  258.     OBJDUMP="$(OBJDUMP_FOR_TARGET)"; export OBJDUMP; \
  259.     OBJCOPY="$(OBJCOPY_FOR_TARGET)"; export OBJCOPY; \
  260.     OTOOL="$(OTOOL_FOR_TARGET)"; export OTOOL; \
  261.     RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
  262.     READELF="$(READELF_FOR_TARGET)"; export READELF; \
  263.     STRIP="$(STRIP_FOR_TARGET)"; export STRIP; \
  264.     WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
  265.     WINDMC="$(WINDMC_FOR_TARGET)"; export WINDMC; \
  266.     $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH)$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR); \
  267.     TARGET_CONFIGDIRS="$(TARGET_CONFIGDIRS)"; export TARGET_CONFIGDIRS;
  268.  
  269. RAW_CXX_TARGET_EXPORTS = \
  270.     $(BASE_TARGET_EXPORTS) \
  271.     CXX_FOR_TARGET="$(RAW_CXX_FOR_TARGET)"; export CXX_FOR_TARGET; \
  272.     CXX="$(RAW_CXX_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export CXX;
  273.  
  274. NORMAL_TARGET_EXPORTS = \
  275.     $(BASE_TARGET_EXPORTS) \
  276.     CXX="$(CXX_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export CXX;
  277.  
  278. # Where to find GMP
  279. HOST_GMPLIBS = -L/opt/homebrew/Cellar/gmp/6.2.1/lib -L/opt/homebrew/Cellar/mpfr/4.1.0/lib -L/opt/homebrew/Cellar/libmpc/1.2.1/lib -lmpc -lmpfr -lgmp
  280. HOST_GMPINC = -I/opt/homebrew/Cellar/gmp/6.2.1/include -I/opt/homebrew/Cellar/mpfr/4.1.0/include -I/opt/homebrew/Cellar/libmpc/1.2.1/include
  281.  
  282. # Where to find isl
  283. HOST_ISLLIBS =
  284. HOST_ISLINC =
  285.  
  286. # Where to find libelf
  287. HOST_LIBELFLIBS = @libelflibs@
  288. HOST_LIBELFINC = @libelfinc@
  289.  
  290. # ----------------------------------------------
  291. # Programs producing files for the BUILD machine
  292. # ----------------------------------------------
  293.  
  294. SHELL = /bin/sh
  295.  
  296. # pwd command to use.  Allow user to override default by setting PWDCMD in
  297. # the environment to account for automounters.  The make variable must not
  298. # be called PWDCMD, otherwise the value set here is passed to make
  299. # subprocesses and overrides the setting from the user's environment.
  300. # Don't use PWD since it is a common shell environment variable and we
  301. # don't want to corrupt it.
  302. PWD_COMMAND = $${PWDCMD-pwd}
  303.  
  304. # compilers to use to create programs which must be run in the build
  305. # environment.
  306. AR_FOR_BUILD = $(AR)
  307. AS_FOR_BUILD = $(AS)
  308. CC_FOR_BUILD = $(CC)
  309. CFLAGS_FOR_BUILD = -g -O2
  310. CXXFLAGS_FOR_BUILD = -g -O2
  311. CXX_FOR_BUILD = $(CXX)
  312. DLLTOOL_FOR_BUILD = $(DLLTOOL)
  313. GFORTRAN_FOR_BUILD = $(GFORTRAN)
  314. GOC_FOR_BUILD = $(GOC)
  315. GDC_FOR_BUILD = $(GDC)
  316. LDFLAGS_FOR_BUILD = -L/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib
  317. LD_FOR_BUILD = $(LD)
  318. NM_FOR_BUILD = $(NM)
  319. RANLIB_FOR_BUILD = $(RANLIB)
  320. WINDMC_FOR_BUILD = $(WINDMC)
  321. WINDRES_FOR_BUILD = $(WINDRES)
  322.  
  323. # Special variables passed down in EXTRA_GCC_FLAGS.  They are defined
  324. # here so that they can be overridden by Makefile fragments.
  325. BUILD_PREFIX = @BUILD_PREFIX@
  326. BUILD_PREFIX_1 = @BUILD_PREFIX_1@
  327.  
  328. # Flags to pass to stage2 and later makes.  They are defined
  329. # here so that they can be overridden by Makefile fragments.
  330. BOOT_CFLAGS= -g -O2
  331. BOOT_LDFLAGS=
  332. BOOT_ADAFLAGS= -gnatpg
  333.  
  334. AWK = awk
  335. SED = /usr/bin/sed
  336. BISON = bison
  337. YACC = bison -y
  338. FLEX = flex
  339. LEX = flex
  340. M4 = gm4
  341. MAKEINFO = makeinfo
  342. EXPECT = expect
  343. RUNTEST = runtest
  344.  
  345. AUTO_PROFILE = gcc-auto-profile -c 10000000
  346.  
  347. # This just becomes part of the MAKEINFO definition passed down to
  348. # sub-makes.  It lets flags be given on the command line while still
  349. # using the makeinfo from the object tree.
  350. # (Default to avoid splitting info files by setting the threshold high.)
  351. MAKEINFOFLAGS = --split-size=5000000
  352.  
  353. # ---------------------------------------------
  354. # Programs producing files for the HOST machine
  355. # ---------------------------------------------
  356.  
  357. AS = as
  358. AR = ar
  359. AR_FLAGS = rc
  360. CC = gcc
  361. CXX = g++
  362. DLLTOOL = dlltool
  363. LD = /Library/Developer/CommandLineTools/usr/bin/ld
  364. LIPO = lipo
  365. NM = nm
  366. OBJDUMP = objdump
  367. OTOOL = otool
  368. RANLIB = ranlib
  369. READELF = readelf
  370. STRIP = strip
  371. WINDRES = windres
  372. WINDMC = windmc
  373.  
  374. GDC = @GDC@
  375. GNATBIND = no
  376. GNATMAKE = no
  377.  
  378. CFLAGS = -g -O2
  379. LDFLAGS = -L/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib
  380. LIBCFLAGS = $(CFLAGS)
  381. CXXFLAGS = -g -O2
  382. LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
  383. GOCFLAGS = $(CFLAGS)
  384. GDCFLAGS = $(CFLAGS)
  385.  
  386. CREATE_GCOV = create_gcov
  387.  
  388. TFLAGS =
  389.  
  390. # Defaults for all stages; some are overridden below.
  391.  
  392. STAGE_CFLAGS = $(BOOT_CFLAGS)
  393. STAGE_TFLAGS = $(TFLAGS)
  394. STAGE_CONFIGURE_FLAGS=
  395.  
  396.  
  397. # Defaults for stage 1; some are overridden below.
  398. STAGE1_CFLAGS = $(STAGE_CFLAGS)
  399. STAGE1_CXXFLAGS = $(CXXFLAGS)
  400. STAGE1_TFLAGS = $(STAGE_TFLAGS)
  401. STAGE1_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  402.  
  403. # Defaults for stage 2; some are overridden below.
  404. STAGE2_CFLAGS = $(STAGE_CFLAGS)
  405. STAGE2_CXXFLAGS = $(CXXFLAGS)
  406. STAGE2_TFLAGS = $(STAGE_TFLAGS)
  407. STAGE2_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  408.  
  409. # Defaults for stage 3; some are overridden below.
  410. STAGE3_CFLAGS = $(STAGE_CFLAGS)
  411. STAGE3_CXXFLAGS = $(CXXFLAGS)
  412. STAGE3_TFLAGS = $(STAGE_TFLAGS)
  413. STAGE3_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  414.  
  415. # Defaults for stage 4; some are overridden below.
  416. STAGE4_CFLAGS = $(STAGE_CFLAGS)
  417. STAGE4_CXXFLAGS = $(CXXFLAGS)
  418. STAGE4_TFLAGS = $(STAGE_TFLAGS)
  419. STAGE4_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  420.  
  421. # Defaults for stage profile; some are overridden below.
  422. STAGEprofile_CFLAGS = $(STAGE_CFLAGS)
  423. STAGEprofile_CXXFLAGS = $(CXXFLAGS)
  424. STAGEprofile_TFLAGS = $(STAGE_TFLAGS)
  425. STAGEprofile_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  426.  
  427. # Defaults for stage train; some are overridden below.
  428. STAGEtrain_CFLAGS = $(STAGE_CFLAGS)
  429. STAGEtrain_CXXFLAGS = $(CXXFLAGS)
  430. STAGEtrain_TFLAGS = $(STAGE_TFLAGS)
  431. STAGEtrain_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  432.  
  433. # Defaults for stage feedback; some are overridden below.
  434. STAGEfeedback_CFLAGS = $(STAGE_CFLAGS)
  435. STAGEfeedback_CXXFLAGS = $(CXXFLAGS)
  436. STAGEfeedback_TFLAGS = $(STAGE_TFLAGS)
  437. STAGEfeedback_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  438.  
  439. # Defaults for stage autoprofile; some are overridden below.
  440. STAGEautoprofile_CFLAGS = $(STAGE_CFLAGS)
  441. STAGEautoprofile_CXXFLAGS = $(CXXFLAGS)
  442. STAGEautoprofile_TFLAGS = $(STAGE_TFLAGS)
  443. STAGEautoprofile_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  444.  
  445. # Defaults for stage autofeedback; some are overridden below.
  446. STAGEautofeedback_CFLAGS = $(STAGE_CFLAGS)
  447. STAGEautofeedback_CXXFLAGS = $(CXXFLAGS)
  448. STAGEautofeedback_TFLAGS = $(STAGE_TFLAGS)
  449. STAGEautofeedback_CONFIGURE_FLAGS = $(STAGE_CONFIGURE_FLAGS)
  450.  
  451.  
  452. # By default, C and C++ are the only stage1 languages, because they are the
  453. # only ones we require to build with the bootstrap compiler, and also the
  454. # only ones useful for building stage2.
  455.  
  456. STAGE1_CFLAGS = -g
  457. STAGE1_CHECKING = --enable-checking=yes,types
  458. STAGE1_LANGUAGES = c,c++,lto
  459. # * We force-disable intermodule optimizations, even if
  460. #   --enable-intermodule was passed, since the installed compiler
  461. #   probably can't handle them.  Luckily, autoconf always respects
  462. #   the last argument when conflicting --enable arguments are passed.
  463. # * Likewise, we force-disable coverage flags, since the installed
  464. #   compiler probably has never heard of them.
  465. # * We also disable -Wformat, since older GCCs don't understand newer %s.
  466. STAGE1_CONFIGURE_FLAGS = --disable-intermodule $(STAGE1_CHECKING) \
  467.       --disable-coverage --enable-languages="$(STAGE1_LANGUAGES)" \
  468.       --disable-build-format-warnings
  469.  
  470. # When using the slow stage1 compiler disable IL verification and forcefully
  471. # enable it when using the stage2 compiler instead.  As we later compare
  472. # stage2 and stage3 we are merely avoid doing redundant work, plus we apply
  473. # checking when building all target libraries for release builds.
  474. STAGE1_TFLAGS += -fno-checking
  475. STAGE2_CFLAGS += -fno-checking
  476. STAGE2_TFLAGS += -fno-checking
  477. STAGE3_CFLAGS += -fchecking=1
  478. STAGE3_TFLAGS += -fchecking=1
  479.  
  480. STAGEprofile_CFLAGS = $(STAGE2_CFLAGS) -fprofile-generate
  481. STAGEprofile_TFLAGS = $(STAGE2_TFLAGS)
  482.  
  483. STAGEtrain_CFLAGS = $(filter-out -fchecking=1,$(STAGE3_CFLAGS))
  484. STAGEtrain_TFLAGS = $(filter-out -fchecking=1,$(STAGE3_TFLAGS))
  485.  
  486. STAGEfeedback_CFLAGS = $(STAGE4_CFLAGS) -fprofile-use
  487. STAGEfeedback_TFLAGS = $(STAGE4_TFLAGS)
  488.  
  489. STAGEautoprofile_CFLAGS = $(STAGE2_CFLAGS) -g
  490. STAGEautoprofile_TFLAGS = $(STAGE2_TFLAGS)
  491.  
  492. STAGEautofeedback_CFLAGS = $(STAGE3_CFLAGS)
  493. STAGEautofeedback_TFLAGS = $(STAGE3_TFLAGS)
  494.  
  495. do-compare = cmp --ignore-initial=16 $$f1 $$f2
  496. do-compare3 = $(do-compare)
  497.  
  498. # -----------------------------------------------
  499. # Programs producing files for the TARGET machine
  500. # -----------------------------------------------
  501.  
  502. AR_FOR_TARGET=i686-elf-ar
  503. AS_FOR_TARGET=i686-elf-as
  504. CC_FOR_TARGET=$(STAGE_CC_WRAPPER) $$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/
  505.  
  506. # If GCC_FOR_TARGET is not overriden on the command line, then this
  507. # variable is passed down to the gcc Makefile, where it is used to
  508. # build libgcc2.a.  We define it here so that it can itself be
  509. # overridden on the command line.
  510. GCC_FOR_TARGET=$(STAGE_CC_WRAPPER) $$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/
  511. CXX_FOR_TARGET=$(STAGE_CC_WRAPPER) $$r/$(HOST_SUBDIR)/gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs
  512. RAW_CXX_FOR_TARGET=$(STAGE_CC_WRAPPER) $$r/$(HOST_SUBDIR)/gcc/xgcc -shared-libgcc -B$$r/$(HOST_SUBDIR)/gcc -nostdinc++ -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs
  513. GFORTRAN_FOR_TARGET=$(STAGE_CC_WRAPPER) i686-elf-gfortran
  514. GOC_FOR_TARGET=$(STAGE_CC_WRAPPER) i686-elf-gccgo
  515. GDC_FOR_TARGET=$(STAGE_CC_WRAPPER) i686-elf-gdc
  516. DLLTOOL_FOR_TARGET=i686-elf-dlltool
  517. LD_FOR_TARGET=i686-elf-ld
  518.  
  519. LIPO_FOR_TARGET=i686-elf-lipo
  520. NM_FOR_TARGET=i686-elf-nm
  521. OBJDUMP_FOR_TARGET=i686-elf-objdump
  522. OBJCOPY_FOR_TARGET=i686-elf-objcopy
  523. OTOOL_FOR_TARGET=i686-elf-otool
  524. RANLIB_FOR_TARGET=i686-elf-ranlib
  525. READELF_FOR_TARGET=i686-elf-readelf
  526. STRIP_FOR_TARGET=i686-elf-strip
  527. WINDRES_FOR_TARGET=i686-elf-windres
  528. WINDMC_FOR_TARGET=i686-elf-windmc
  529.  
  530. COMPILER_AS_FOR_TARGET=$$r/$(HOST_SUBDIR)/gcc/as
  531. COMPILER_LD_FOR_TARGET=$$r/$(HOST_SUBDIR)/gcc/collect-ld
  532. COMPILER_NM_FOR_TARGET=$$r/$(HOST_SUBDIR)/gcc/nm
  533.  
  534. CFLAGS_FOR_TARGET = -g -O2
  535. CXXFLAGS_FOR_TARGET = -g -O2
  536.  
  537. LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
  538. LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
  539. LDFLAGS_FOR_TARGET =
  540. GOCFLAGS_FOR_TARGET = -O2 -g
  541. GDCFLAGS_FOR_TARGET = -O2 -g
  542.  
  543. FLAGS_FOR_TARGET =  -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include
  544. SYSROOT_CFLAGS_FOR_TARGET =
  545. DEBUG_PREFIX_CFLAGS_FOR_TARGET =
  546.  
  547. XGCC_FLAGS_FOR_TARGET = $(FLAGS_FOR_TARGET) $(SYSROOT_CFLAGS_FOR_TARGET) $(DEBUG_PREFIX_CFLAGS_FOR_TARGET)
  548. .
  549. .
  550. .
  551. .
  552. .
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement