# llvmgcc17/cfg - "Build" settings for package #--------------------------------------------------------------------- [technotes] 1. The source tarball used by this package was created based on "git" upstream sources. The sources were obtained as follows: ocgitfetch --run \ --checkout=llvmorg-17.0.6 \ --deletegit \ https://github.com/llvm/llvm-project.git #--------------------------------------------------------------------- 2. If you'd like to build this package on a 32-bit system -- as oppos- ed to cross-compiling it for the same system -- you'll probably need to set up a large amount of swap space, 16GB or more, or the build may lock up the system. #--------------------------------------------------------------------- 3. This package builds "clang" and "clang++" compilers that work well enough to build the parts of "xorg" and most other packages that re- quire "clang*". The compilers are built using "gcc" and linked against "gcc" librar- ies, so they aren't self-hosted. #--------------------------------------------------------------------- 4. It isn't recommended that these compilers be used to rebuild large parts of the distro. This probably won't work. Examples of past and/or present problems include: * "mariadb" built using "clang*" segfaulted at runtime * "gdb" is "gcc"-specific * "podofo" caused "clang" to crash at build time #--------------------------------------------------------------------- 5. Possible entries in the "-DLLVM_ENABLE_PROJECTS=" list include: -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra;libcxx;\ libcxxabi;libunwind;lldb;\ compiler-rt;lld;polly;debuginfo-tests" For Laclin's purposes, the following setting is presently sufficient: -DLLVM_ENABLE_PROJECTS="clang" #--------------------------------------------------------------------- [buildtimes] 01.46 hours (or 087.42 minutes) - 2023 dedi Xeon E3-1200 v3 4x2 32GB RAM # Older times. Not directly comparable to the above due to changes in # the code. 00.65 hours (or 038.70 minutes) - 2021 L.A. dedi box: 6x2 CPU 32GB RAM 00.85 hours (or 051.18 minutes) - 2021 Utah dedi box: 4x2 CPU 32GB RAM 01.20 hours (or 072.15 minutes) - HP EliteBook 8560w 32GB RAM 01.89 hours (or 113.55 minutes) - Lenovo E520 with a 32-bit distro # Note: In a 32-bit distro, only the first 4GB of RAM can be used ex- # cept as swap space. 00.67 hours (or 040.23 minutes) - ThinkPad E540 i7 4x2 16GB RAM 00.98 hours (or 058.97 minutes) - HP EliteBook 8560w 32GB RAM 01.16 hours (or 069.75 minutes) - HP Pavilion dv8 8GB RAM 02.07 hours (or 124.18 minutes) - Toshiba Satellite C655 E-300 CPU 4GB RAM #--------------------------------------------------------------------- [settings] altpkg = yes configure = none license = See "license*.txt" in installed tree licfile = llvm/LICENSE.TXT nosyslinks = yes purge = yes tmpsize = 4669M unpack = relaxed setpaths = libicu libxml2 ncurses python3 zlib zstd #--------------------------------------------------------------------- [depends] actools bzip2 cmake:forward doxygen:forward findutils git:forward grep groff groff-full:forward gv:forward gzip infozip libedit libffi libicu libxml2:forward lndir ncurses ocaml:forward perl python:forward tcltk:forward valgrind:forward zlib #--------------------------------------------------------------------- [build] MANBASE=$PKGDIR_PROD/man mkdir -p $MANBASE rm -fr flang tools/flang rm -fr libclc tools/libclc rm -fr lld tools/lld rm -fr lldb tools/lldb #--------------------------------------------------------------------- BUILD32= if [ "@$LACARCH" == "@glibc32" ]; then M=`uname -m` if [ "@$M" == "@x86_64" ]; then BUILD32="-DLLVM_BUILD_32_BITS=ON" fi fi export BUILD32=$BUILD32 echo export BUILD32=$BUILD32 #--------------------------------------------------------------------- export TOPDIR=`pwd` export PKGDIR_PROD=$PKGDIR_PROD export PKGDIR_SPECIAL=$PKGDIR_SPECIAL export BINDIR=$PKGDIR_PROD/bin export INCDIR=$PKGDIR_PROD/include export OLDINC=/$LACARCH/pkg/glibc/include export LACINCDIRS=$INCDIR:$PRODTREE/libicu/include export PATH=$BINDIR:$PATH echo export TOPDIR=$TOPDIR echo export PKGDIR_PROD=$PKGDIR_PROD echo export PKGDIR_SPECIAL=$PKGDIR_SPECIAL echo export BINDIR=$BINDIR echo export INCDIR=$INCDIR echo export OLDINC=$OLDINC echo export LACINCDIRS=$LACINCDIRS echo 'export PATH=$BINDIR:$PATH' #--------------------------------------------------------------------- export LACARCHBUILD=$LACARCHBUILD export LACDONTFIND="libffi,libunwind,llvm,llvmself" export LACFIXLECHROM=yes export LACSMPERRORPAUSE=1 export LACSMPTRIES=50 export USECCACHE=yes echo export CCPAUSE=$CCPAUSE echo export LACARCHBUILD=$LACARCHBUILD echo export LACDONTFIND="$LACDONTFIND" echo export LACFIXLECHROM=yes echo export LACSLOWDOWN=$LACSLOWDOWN echo export LACSMPERRORPAUSE=$LACSMPERRORPAUSE echo export LACSMPEXTRANICE=$LACSMPEXTRANICE echo export LACSMPTRIES=$LACSMPTRIES echo export USECCACHE=$USECCACHE #--------------------------------------------------------------------- mkdir -p $BINDIR $INCDIR #--------------------------------------------------------------------- hash gcc g++ export CLANG_EXE=`which gcc` export CLANGPP_EXE=`which g++` export LACLLVMBOOT=no export LACSTATICCXX=no #--------------------------------------------------------------------- cd $TOPDIR || exit 1 rm -fr build || exit 1 mkdir build || exit 1 cd build || exit 1 echo `date` stage: clang cmake start CC=$CLANG_EXE CXX=$CLANGPP_EXE \ cmake -DCMAKE_INSTALL_PREFIX=$PKGDIR_PROD \ -DCMAKE_INSTALL_OLDINCLUDEDIR=$OLDINC \ -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_C_COMPILER=$CLANG_EXE \ -DCMAKE_CXX_COMPILER=$CLANGPP_EXE \ \ -DCLANG_DEFAULT_CXX_STDLIB=libstdc++ \ -DCLANG_DEFAULT_RTLIB=libgcc \ -DLIBCXX_CXX_ABI=libstdc++ \ -DLLVM_DEFAULT_TARGET_TRIPLE=$LACARCHBUILD \ -DLLVM_ENABLE_LIBCXX=OFF \ -DLLVM_TARGETS_TO_BUILD="host;AMDGPU" \ -DLLVM_ENABLE_PROJECTS="clang" \ \ -DGCC_INSTALL_PREFIX=$PRODTREE/gcc \ -DLINK_POLLY_INTO_TOOLS=ON \ -DWITH_POLLY=ON \ $BUILD32 \ -Wno-dev \ ../llvm || exit 1 echo `date` stage: clang cmake end #--------------------------------------------------------------------- echo `date` stage: clang build start smpmake smpmake install echo `date` stage: clang build end #--------------------------------------------------------------------- echo `date` stage: clang wrapper start cd $BINDIR cp -p $PKGDIR_SPECIAL/wrap*.txt . chmod 755 wrap*.txt sed -e 's@\(.*ENV.*LACLLVMSELF.*=\).*@\n\1 "llvmself";@' \ -i wrapclang.txt for x in clang clang++ do trueifexe $x && mv $x $x.bin touch $x rm $x cp -p wrapclang.txt $x done rm wrapclang.txt sed -e "s@\(.*ENV.*'CLANGC'.*=\).*@\n\1 'yes';@" \ -i clang pushd $PKGDIR_PROD rm -fr xbin mkdir xbin cd xbin cp -a $PKGDIR_SPECIAL/xbin/* . chmod 755 * popd echo `date` stage: clang wrapper end #--------------------------------------------------------------------- cd $TOPDIR echo `date` stage: Done #--------------------------------------------------------------------- # Original URLs. These URLs were valid at one point, but may have died # since then. If you download newer versions of tarballs [etc.], don't # delete the original versions, as you may not be able to replace # them. [urls] url_debian = Not clear url_home = http://llvm.org/ url_lfs = Not checked yet url_tarball = git # See "technotes" in "cfg" file #--------------------------------------------------------------------- [history] 170703 Updated from 4.0.0 to 4.0.1 170910 Updated to 5.0.0 171221 Updated to 5.0.1 180430 Updated to 6.0.0 180626 Updated to 6.0.1 180628 Updated from 6.0.1 to 180628 ("git" date; approx. llvm 7.0.0) 180908 Updated to 180908 (circa llvm 8.0.0) 181110 Updated to 181110 181216 Updated to 181216 190216 Updated to 190216 190502 Updated to 190502 190607 Downdated to 8.0.0 190825 Updated to 8.0.1 210126 Updated to 11.0.1 210612 Updated to 0a0800c4d ("git" hash; pre-13.0.0) 230219 Updated to 8dfdcc7b7 - same as 15.0.7 240114 Updated to 6009708b4 - same as 17.0.6