]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - make.sh
perl-Net-HTTP: New package.
[people/pmueller/ipfire-2.x.git] / make.sh
diff --git a/make.sh b/make.sh
index 77fe5e7ac868f79a237f24789f947d4169283626..923f728e72b82f904a7a6110a031675e840cb389 100755 (executable)
--- a/make.sh
+++ b/make.sh
@@ -38,7 +38,7 @@ GIT_BRANCH="$(git rev-parse --abbrev-ref HEAD)"                       # Git Branch
 GIT_TAG="$(git tag | tail -1)"                                 # Git Tag
 GIT_LASTCOMMIT="$(git rev-parse --verify HEAD)"                        # Last commit
 
-TOOLCHAINVER=20210701
+TOOLCHAINVER=20220203
 
 # use multicore and max compression
 ZSTD_OPT="-T0 --ultra -22"
@@ -145,35 +145,35 @@ configure_build() {
 
        case "${build_arch}" in
                x86_64)
-                       BUILDTARGET="${build_arch}-unknown-linux-gnu"
+                       BUILDTARGET="${build_arch}-pc-linux-gnu"
                        CROSSTARGET="${build_arch}-cross-linux-gnu"
                        BUILD_PLATFORM="x86"
                        CFLAGS_ARCH="-m64 -mtune=generic -fstack-clash-protection -fcf-protection"
                        ;;
 
                aarch64)
-                       BUILDTARGET="${build_arch}-unknown-linux-gnu"
+                       BUILDTARGET="${build_arch}-pc-linux-gnu"
                        CROSSTARGET="${build_arch}-cross-linux-gnu"
                        BUILD_PLATFORM="arm"
                        CFLAGS_ARCH="-fstack-clash-protection"
                        ;;
 
                armv7hl)
-                       BUILDTARGET="${build_arch}-unknown-linux-gnueabi"
+                       BUILDTARGET="${build_arch}-pc-linux-gnueabi"
                        CROSSTARGET="${build_arch}-cross-linux-gnueabi"
                        BUILD_PLATFORM="arm"
                        CFLAGS_ARCH="-march=armv7-a -mfpu=vfpv3-d16 -mfloat-abi=hard"
                        ;;
 
                armv6l)
-                       BUILDTARGET="${build_arch}-unknown-linux-gnueabi"
+                       BUILDTARGET="${build_arch}-pc-linux-gnueabi"
                        CROSSTARGET="${build_arch}-cross-linux-gnueabi"
                        BUILD_PLATFORM="arm"
                        CFLAGS_ARCH="-march=armv6zk+fp -mfpu=vfp -mfloat-abi=softfp -fomit-frame-pointer"
                        ;;
 
                riscv64)
-                       BUILDTARGET="${build_arch}-unknown-linux-gnu"
+                       BUILDTARGET="${build_arch}-pc-linux-gnu"
                        CROSSTARGET="${build_arch}-cross-linux-gnu"
                        BUILD_PLATFORM="riscv"
                        CFLAGS_ARCH="-fstack-clash-protection"
@@ -554,7 +554,12 @@ enterchroot() {
        # Install QEMU helper, if needed
        qemu_install_helper
 
-       local PATH="${TOOLS_DIR}/ccache/bin:/bin:/usr/bin:/sbin:/usr/sbin:${TOOLS_DIR}/bin"
+       local PATH="${TOOLS_DIR}/ccache/bin:/bin:/usr/bin:/sbin:/usr/sbin:${TOOLS_DIR}/sbin:${TOOLS_DIR}/bin"
+
+       # Prepend any custom changes to PATH
+       if [ -n "${CUSTOM_PATH}" ]; then
+               PATH="${CUSTOM_PATH}:${PATH}"
+       fi
 
        PATH="${PATH}" chroot ${LFS} env -i \
                HOME="/root" \
@@ -658,8 +663,15 @@ lfsmake1() {
        lfsmakecommoncheck $*
        [ $? == 1 ] && return 0
 
+       # Set PATH to use the toolchain tools first and then whatever the host has set
+       local PATH="${TOOLS_DIR}/ccache/bin:${TOOLS_DIR}/sbin:${TOOLS_DIR}/bin:${PATH}"
+
+       if [ -n "${CUSTOM_PATH}" ]; then
+               PATH="${CUSTOM_PATH}:${PATH}"
+       fi
+
        cd $BASEDIR/lfs && env -i \
-               PATH="${TOOLS_DIR}/ccache/bin:${TOOLS_DIR}/bin:$PATH" \
+               PATH="${PATH}" \
                CCACHE_DIR="${CCACHE_DIR}"/${BUILD_ARCH}/${TOOLCHAINVER} \
                CCACHE_TEMPDIR="${CCACHE_TEMPDIR}" \
                CCACHE_COMPILERCHECK="${CCACHE_COMPILERCHECK}" \
@@ -695,7 +707,7 @@ lfsmake2() {
        local PS1='\u:\w$ '
 
        enterchroot \
-               ${EXTRA_PATH}bash -x -c "cd /usr/src/lfs && \
+               bash -x -c "cd /usr/src/lfs && \
                        make -f $* \
                        LFS_BASEDIR=/usr/src install" \
                >> ${LOGFILE} 2>&1 &
@@ -1057,7 +1069,7 @@ buildtoolchain() {
        lfsmake1 bison
        lfsmake1 flex
        lfsmake1 fake-environ
-       lfsmake1 strip
+       CUSTOM_PATH="${PATH}" lfsmake1 strip
        lfsmake1 cleanup-toolchain
 }
 
@@ -1364,6 +1376,9 @@ buildipfire() {
   lfsmake2 perl-Apache-Htpasswd
   lfsmake2 perl-Parse-Yapp
   lfsmake2 perl-Data-UUID
+  lfsmake2 perl-Try-Tiny
+  lfsmake2 perl-HTTP-Message
+  lfsmake2 perl-HTTP-Date
   lfsmake2 gnupg
   lfsmake2 hdparm
   lfsmake2 sdparm
@@ -1388,6 +1403,8 @@ buildipfire() {
   lfsmake2 Digest-SHA1
   lfsmake2 Digest-HMAC
   lfsmake2 libwww-perl
+  lfsmake2 perl-LWP-Protocol-https
+  lfsmake2 perl-Net-HTTP
   lfsmake2 Net-DNS
   lfsmake2 Net-IPv4Addr
   lfsmake2 Net_SSLeay
@@ -1496,7 +1513,6 @@ buildipfire() {
   lfsmake2 rsync
   lfsmake2 rpcbind
   lfsmake2 keyutils
-  lfsmake2 libnfsidmap
   lfsmake2 nfs
   lfsmake2 gnu-netcat
   lfsmake2 ncat
@@ -1694,7 +1710,7 @@ buildinstaller() {
   lfsmake2 memtest
   lfsmake2 installer
   # use toolchain bash for chroot to strip
-  EXTRA_PATH=${TOOLS_DIR}/bin/ lfsmake2 strip
+  CUSTOM_PATH="${TOOLS_DIR}/bin" lfsmake2 strip
 }
 
 buildpackages() {