summaryrefslogtreecommitdiff
path: root/packages-i486-stage1
diff options
context:
space:
mode:
authorAndreas Baumann <mail@andreasbaumann.cc>2018-02-02 22:15:14 +0100
committerAndreas Baumann <mail@andreasbaumann.cc>2018-02-02 22:15:14 +0100
commit1c13a88a004d30c0ad7f156df7ca19eb94353621 (patch)
tree26937c8b9d83c3ab2c4186c12b9bc0e590a9ee57 /packages-i486-stage1
parent2f578141b1a7ba3de5a5a2a8400e07c226202009 (diff)
downloadbootstrap32-1c13a88a004d30c0ad7f156df7ca19eb94353621.tar.xz
on the way to openssh
Diffstat (limited to 'packages-i486-stage1')
-rw-r--r--packages-i486-stage1/bc11
-rw-r--r--packages-i486-stage1/ed2
-rw-r--r--packages-i486-stage1/inetutils5
-rw-r--r--packages-i486-stage1/libedit5
-rw-r--r--packages-i486-stage1/linux16
-rw-r--r--packages-i486-stage1/linux-api-headers2
-rw-r--r--packages-i486-stage1/openssh12
7 files changed, 51 insertions, 2 deletions
diff --git a/packages-i486-stage1/bc b/packages-i486-stage1/bc
new file mode 100644
index 0000000..b7720fd
--- /dev/null
+++ b/packages-i486-stage1/bc
@@ -0,0 +1,11 @@
+# bc is needed by linux
+SYSROOT_INSTALL=1
+
+# prepare configure for cross-compilation
+sed -i "s@./configure@./configure --host=$TARGET_ARCH --build=$BUILD_ARCH@g" PKGBUILD
+
+# fbc is built with target compiler instead of host compiler:
+# /bin/sh: ./fbc: No such file or directory
+# http://lists.busybox.net/pipermail/buildroot/2017-July/196239.html
+# we take the host bc instead of the bootstrapped fbc
+sed -i '1!N; /build() *{\n *cd/ a \ sed -i "s@./fbc -c@bc -c@" bc\/Makefile.in' PKGBUILD
diff --git a/packages-i486-stage1/ed b/packages-i486-stage1/ed
index cdcaa7b..9fff229 100644
--- a/packages-i486-stage1/ed
+++ b/packages-i486-stage1/ed
@@ -1,4 +1,4 @@
-# ed is needed for patch
+# ed is needed for patch and bc
SYSROOT_INSTALL=1
# prepare configure for cross-compilation
diff --git a/packages-i486-stage1/inetutils b/packages-i486-stage1/inetutils
new file mode 100644
index 0000000..aa9cde5
--- /dev/null
+++ b/packages-i486-stage1/inetutils
@@ -0,0 +1,5 @@
+# prepare configure for cross-compilation
+sed -i "s@./configure@./configure --host=$TARGET_ARCH --build=$BUILD_ARCH@g" PKGBUILD
+
+# no man page generation
+sed -i "/depends=/s/help2man//" PKGBUILD
diff --git a/packages-i486-stage1/libedit b/packages-i486-stage1/libedit
new file mode 100644
index 0000000..6ee9176
--- /dev/null
+++ b/packages-i486-stage1/libedit
@@ -0,0 +1,5 @@
+# libedit is needed by openssh
+SYSROOT_INSTALL=1
+
+# prepare configure for cross-compilation
+sed -i "s@./configure@./configure --host=$TARGET_ARCH --build=$BUILD_ARCH@g" PKGBUILD
diff --git a/packages-i486-stage1/linux b/packages-i486-stage1/linux
new file mode 100644
index 0000000..37d75a5
--- /dev/null
+++ b/packages-i486-stage1/linux
@@ -0,0 +1,16 @@
+# we currently build a monolitic kernel for the basic stuff which was
+# available since 25 years. :-)
+
+# the Linux kernel has it's own way for cross compilation
+sed -i "s@make prepare@make prepare ARCH=$KERNEL_ARCH CROSS_COMPILE=$XTOOLS_ARCH_PREFIX@g" PKGBUILD
+sed -i "s@make config@make config ARCH=$KERNEL_ARCH CROSS_COMPILE=$XTOOLS_ARCH_PREFIX@g" PKGBUILD
+
+# remove make dependencies, currently we build without module support
+sed -i "s@make bzImage modules@make bzImage ARCH=$KERNEL_ARCH CROSS_COMPILE=$XTOOLS_ARCH_PREFIX@g" PKGBUILD
+sed -i "s@make modules_install@#make modules_install@g" PKGBUILD
+
+# TODO: build what's possible, ommit the rest
+# remove dependencies from kernel package, we don't have modules or a ramdisk right now
+#sed -i 's/ \+\(depends=\)/#\1/' PKGBUILD
+# ignore failing hooks on installation, it's just depmod and mkinitcpio which we both don't need
+#sed -i 's@makedepends\(.*\)@#makedepends\1@g' PKGBUILD
diff --git a/packages-i486-stage1/linux-api-headers b/packages-i486-stage1/linux-api-headers
index 2b9a2e2..b2ad3b4 100644
--- a/packages-i486-stage1/linux-api-headers
+++ b/packages-i486-stage1/linux-api-headers
@@ -1,4 +1,4 @@
-# the Linux kernel has it's own way for cross compilations, we need
+# the Linux kernel has it's own way for cross compilation, we need
# only the header files for glibc later, but it's better to make sure
# to pick the correct target archicture right away
sed -i "s@make@make ARCH=$KERNEL_ARCH CROSS_COMPILE=$XTOOLS_ARCH_PREFIX@g" PKGBUILD
diff --git a/packages-i486-stage1/openssh b/packages-i486-stage1/openssh
new file mode 100644
index 0000000..453eaff
--- /dev/null
+++ b/packages-i486-stage1/openssh
@@ -0,0 +1,12 @@
+# prepare configure for cross-compilation
+sed -i "s@./configure@./configure --host=$TARGET_ARCH --build=$BUILD_ARCH@g" PKGBUILD
+
+# remove ldns and kerberos5 support, keep libedit (as it's easy to build)
+# ssh => not good, openssl <> unbound <> openssl cycle
+sed -i "/depends=/s/krb5//" PKGBUILD
+sed -i "/depends=/s/ldns//" PKGBUILD
+sed -i 's@--with-ldns@--without-ldns@g' PKGBUILD
+sed -i 's@--with-kerberos5=/usr@--without-kerberos5@g' PKGBUILD
+
+#ln: failed to create symbolic link '/build/openssh/pkg/openssh/usr/share/man/man1/slogin.1.gz': No such file or directory
+sed -i 's@\(ln -sf ssh.1.gz.*\)@#\1@g' PKGBUILD