added #!/bin/bash instead #!/bin/sh
This commit is contained in:
+9
-6
@@ -1,16 +1,19 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
. ./scripts/config.sh
|
||||
|
||||
pkgname=bash
|
||||
pkgver=5.2.32
|
||||
|
||||
bash() {
|
||||
printf "$GREEN** Building and installing bash\n$RESET"
|
||||
mkdir $build/bash
|
||||
cd $build/bash
|
||||
tar -xvf $root/downloads/bash-5.2.32.tar.gz
|
||||
check $? "Extract bash"
|
||||
cd bash-5.2.32
|
||||
mkdir $build/${pkgname}
|
||||
cd $build/${pkgname}
|
||||
tar -xvf $root/downloads/${pkgname}-${pkgver}.tar.gz
|
||||
check $? "Extract ${pkgname}"
|
||||
cd ${pkgname}-${pkgver}
|
||||
./configure \
|
||||
--prefix=/usr \
|
||||
--disable-readline \
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/config.sh
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
#--- import rolors ---
|
||||
. ./scripts/colors.sh
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
if [ -d out ]; then
|
||||
rm -rv out;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
#--- reset colors ---
|
||||
RESET="\033[0m"
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
#------------ config ------------------
|
||||
export PATH=$PATH:/opt/toolchains/arm-buildroot-linux-uclibcgnueabihf/bin
|
||||
|
||||
+12
-9
@@ -1,20 +1,23 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
. ./scripts/config.sh
|
||||
. ./scripts/zlib.sh
|
||||
|
||||
pkgname=curl
|
||||
pkgver=8.9.1
|
||||
|
||||
curl() {
|
||||
if [ ! -d $build/zlib ]; then
|
||||
zlib
|
||||
fi
|
||||
printf "$GREEN** Building and installing curl\n$RESET"
|
||||
mkdir $build/curl
|
||||
cd $build/curl
|
||||
tar -xvf $root/downloads/curl-8.9.1.tar.xz
|
||||
check $? "Extract curl"
|
||||
cd curl-8.9.1
|
||||
mkdir $build/${pkgname}
|
||||
cd $build/${pkgname}
|
||||
tar -xvf $root/downloads/${pkgname}-${pkgver}.tar.xz
|
||||
check $? "Extract ${pkgname}"
|
||||
cd ${pkgname}-${pkgver}
|
||||
./configure \
|
||||
--prefix=/usr \
|
||||
--host=$CROSS_COMPILE \
|
||||
@@ -22,9 +25,9 @@ curl() {
|
||||
--disable-static \
|
||||
--enable-shared \
|
||||
--with-zlib=$rootfspath
|
||||
check $? "Configure curl"
|
||||
check $? "Configure ${pkgname}"
|
||||
make $makeflags
|
||||
check $? "Build curl"
|
||||
check $? "Build ${pkgname}"
|
||||
make DESTDIR=$rootfspath install
|
||||
rm \
|
||||
-rv \
|
||||
@@ -35,5 +38,5 @@ curl() {
|
||||
$rootfspath/usr/lib/*.la \
|
||||
$rootfspath/usr/lib/pkgconfig
|
||||
$CROSS_COMPILE-strip --strip-unneeded $rootfspath/usr/bin/curl $rootfspath/usr/lib/libcurl.so.4.8.0
|
||||
check $? "Installing to rootfs curl"
|
||||
check $? "Installing to rootfs ${pkgname}"
|
||||
}
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/funcs.sh
|
||||
. ./scripts/config.sh
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
#--- Import colors ---
|
||||
. ./scripts/colors.sh
|
||||
|
||||
+11
-8
@@ -1,30 +1,33 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
. ./scripts/config.sh
|
||||
. ./scripts/curl.sh
|
||||
|
||||
pkgname=git
|
||||
pkgver=2.46.0
|
||||
|
||||
git() {
|
||||
if [ ! -d $build/curl ]; then
|
||||
curl
|
||||
fi
|
||||
printf "$GREEN** Building and installing git\n$RESET"
|
||||
printf "$GREEN** Building and installing ${pkgname}\n$RESET"
|
||||
mkdir $build/git
|
||||
cd $build/git
|
||||
tar -xvf $root/downloads/git-2.46.0.tar.xz
|
||||
check $? "Extract git"
|
||||
cd git-2.46.0
|
||||
tar -xvf $root/downloads/${pkgname}-${pkgver}.tar.xz
|
||||
check $? "Extract ${pkgname}"
|
||||
cd ${pkgname}-${pkgver}
|
||||
./configure \
|
||||
--prefix=/usr \
|
||||
--host=$CROSS_COMPILE \
|
||||
NO_ICONV=true \
|
||||
ac_cv_fread_reads_directories=true \
|
||||
ac_cv_snprintf_returns_bogus=false
|
||||
check $? "Configure git"
|
||||
check $? "Configure ${pkgname}"
|
||||
make $makeflags
|
||||
check $? "Build git"
|
||||
check $? "Build ${pkgname}"
|
||||
make DESTDIR=$rootfspath install
|
||||
$CROSS_COMPILE-strip --strip-unneeded $rootfspath/usr/bin/* $rootfspath/libexec/git-core/*
|
||||
printf "$GREEN** SUCCESS: Building and installing git\n$RESET"
|
||||
printf "$GREEN** SUCCESS: Building and installing ${pkgname}\n$RESET"
|
||||
}
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
+9
-9
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
@@ -8,11 +8,11 @@ pkgname=libnl
|
||||
pkgver=3.10.0
|
||||
|
||||
libnl() {
|
||||
printf "$GREEN** Building and installing libnl\n$RESET"
|
||||
[ ! -d $build/libnl ] && mkdir $build/libnl
|
||||
cd $build/libnl
|
||||
printf "$GREEN** Building and installing ${pkgname}\n$RESET"
|
||||
[ ! -d $build/${pkgname} ] && mkdir $build/${pkgname}
|
||||
cd $build/${pkgname}
|
||||
tar -xvf $root/downloads/${pkgname}-${pkgver}.tar.gz
|
||||
check $? "Extract $pkgname"
|
||||
check $? "Extract ${pkgname}"
|
||||
cd ${pkgname}-${pkgver}
|
||||
./configure \
|
||||
--host=${CROSS_COMPILE} \
|
||||
@@ -21,18 +21,18 @@ libnl() {
|
||||
--disable-cli \
|
||||
--build=x86_64-pc-linux-gnu \
|
||||
--prefix=/opt/toolchains/arm-buildroot-linux-uclibcgnueabihf/arm-buildroot-linux-uclibcgnueabihf/sysroot/usr
|
||||
check $? "Configure $pkgname"
|
||||
check $? "Configure ${pkgname}"
|
||||
make $makeflags
|
||||
check $? "Build $pkgname"
|
||||
check $? "Build ${pkgname}"
|
||||
make DESTDIR=$(pwd)/bin install
|
||||
rm -rv $(pwd)/bin/opt/toolchains/arm-buildroot-linux-uclibcgnueabihf/arm-buildroot-linux-uclibcgnueabihf/sysroot/usr/lib/{pkgconfig,*.la}
|
||||
${CROSS_COMPILE}-strip $(pwd)/bin/opt/toolchains/arm-buildroot-linux-uclibcgnueabihf/arm-buildroot-linux-uclibcgnueabihf/sysroot/usr/lib/*
|
||||
cd $(pwd)/bin/opt/toolchains/arm-buildroot-linux-uclibcgnueabihf/arm-buildroot-linux-uclibcgnueabihf/sysroot/usr/lib
|
||||
tar -czvf /tmp/libnl.tar.gz .
|
||||
tar -czvf /tmp/${pkgname}.tar.gz .
|
||||
check $? "Archived libs"
|
||||
cd -
|
||||
cd $rootfspath/usr/lib
|
||||
tar -xvf /tmp/libnl.tar.gz
|
||||
tar -xvf /tmp/${pkgname}.tar.gz
|
||||
check $? "Unrchived libs"
|
||||
cd -
|
||||
}
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
|
||||
+15
-12
@@ -1,24 +1,27 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
. ./scripts/config.sh
|
||||
|
||||
pkgname=uClibc-ng
|
||||
pkgver=1.0.50
|
||||
|
||||
#------------ glibc ----------------------------------------
|
||||
uclibc() {
|
||||
printf "$UGREEN** Building uclibc\n$RESET"
|
||||
mkdir -p $build/uclibc # &>> $fulllogfile
|
||||
cd $build/uclibc
|
||||
tar -xvf $root/downloads/uClibc-ng-1.0.50.tar.xz # &>> $fulllogfile
|
||||
check $? "Extract uclibc"
|
||||
cd uClibc-ng-1.0.50
|
||||
cp -rv $root/uclibc/config-1.0.50 .config
|
||||
printf "$UGREEN** Building ${pkgname}\n$RESET"
|
||||
mkdir -p $build/${pkgname} # &>> $fulllogfile
|
||||
cd $build/${pkgname}
|
||||
tar -xvf $root/downloads/${pkgname}-${pkgver}.tar.xz # &>> $fulllogfile
|
||||
check $? "Extract ${pkgname}"
|
||||
cd ${pkgname}-${pkgver}
|
||||
cp -rv $root/uclibc/config-${pkgver} .config
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- oldconfig
|
||||
check $? "Configure uclibc"
|
||||
check $? "Configure ${pkgname}"
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- $makeflags # &>> $fulllogfile
|
||||
check $? "Build uclibc"
|
||||
check $? "Build ${pkgname}"
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- DESTDIR=$rootfspath install # &>> $fulllogfile
|
||||
check $? "Install uclibc to rootfs"
|
||||
check $? "Install ${pkgname} to rootfs"
|
||||
cd $rootfspath
|
||||
find -name \*.a -delete # &>> $fulllogfile
|
||||
find -name \*.o -delete
|
||||
@@ -26,6 +29,6 @@ uclibc() {
|
||||
${CROSS_COMPILE}-strip --strip-unneeded $rootfspath/usr/lib/* $rootfspath/usr/bin/* # &>> $fulllogfile $rootfspath/usr/lib/*
|
||||
rm -rv $rootfspath/usr/include
|
||||
cd $root
|
||||
check $? "Build and install uclibc"
|
||||
check $? "Build and install ${pkgname}"
|
||||
}
|
||||
#-----------------------------------------------------------
|
||||
+14
-11
@@ -1,22 +1,25 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
. ./scripts/colors.sh
|
||||
. ./scripts/funcs.sh
|
||||
. ./scripts/config.sh
|
||||
|
||||
pkgname=zlib
|
||||
pkgver=1.3.1
|
||||
|
||||
zlib() {
|
||||
printf "$GREEN** Building and installing zlib\n$RESET"
|
||||
mkdir $build/zlib
|
||||
cd $build/zlib
|
||||
tar -xvf $root/downloads/zlib-1.3.1.tar.gz
|
||||
check $? "Extract zlib"
|
||||
cd zlib-1.3.1
|
||||
printf "$GREEN** Building and installing ${pkgname}\n$RESET"
|
||||
mkdir $build/${pkgname}
|
||||
cd $build/${pkgname}
|
||||
tar -xvf $root/downloads/${pkgname}-${pkgver}.tar.gz
|
||||
check $? "Extract ${pkgname}"
|
||||
cd ${pkgname}-${pkgver}
|
||||
CC=${CROSS_COMPILE}-gcc ./configure --prefix=/usr --shared
|
||||
check $? "Configure zlib"
|
||||
check $? "Configure ${pkgname}"
|
||||
make $makeflags
|
||||
check $? "Build zlib"
|
||||
check $? "Build ${pkgname}"
|
||||
make DESTDIR=$rootfspath install
|
||||
rm -rv $rootfspath/usr/include $rootfspath/usr/share/man $rootfspath/usr/lib/{pkgconfig,libz.a}
|
||||
${CROSS_COMPILE}-strip --strip-unneeded $rootfspath/usr/lib/libz.so.1.3.1
|
||||
check $? "Installing to rootfs zlib"
|
||||
${CROSS_COMPILE}-strip --strip-unneeded $rootfspath/usr/lib/libz.so.${pkgver}
|
||||
check $? "Installing to rootfs ${pkgname}"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user