summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordavidovski <david@davidovski.xyz>2022-02-18 01:32:47 +0000
committerdavidovski <david@davidovski.xyz>2022-02-18 01:32:47 +0000
commiteafdfcf7020757b12651a71660f2e1a12af7bc97 (patch)
tree6502ffb9f105a61c6e8251644bec3389c8c27d4a
parent1340cdfc48583514b3a256b53a5966961b08017a (diff)
added build_profile
-rwxr-xr-xxib_env1
-rwxr-xr-xxibuild/build_package.sh5
-rw-r--r--xibuild/build_profile4
-rwxr-xr-x[-rw-r--r--]xibuild/prepare.sh2
4 files changed, 8 insertions, 4 deletions
diff --git a/xib_env b/xib_env
index 5258215..d010c87 100755
--- a/xib_env
+++ b/xib_env
@@ -17,3 +17,4 @@ export DEVELOPMENT_BUILDFILES="/home/david/docs/proj/xilinux/buildfiles"
export BUILDFILES_GIT_REPO="https://xi.davidovski.xyz/git/buildfiles.git"
export INSTALLED_PACKAGES="$XIB_CHROOT/installed"
+export BUILD_PROFILE=$XIB_DIR/build_profile
diff --git a/xibuild/build_package.sh b/xibuild/build_package.sh
index ddbc348..7152464 100755
--- a/xibuild/build_package.sh
+++ b/xibuild/build_package.sh
@@ -113,10 +113,7 @@ prepare_build_env () {
#
make_buildscript () {
- # TODO this should be an external buildprofile file
- echo MAKEFLAGS="$MAKEFLAGS" >> "$XIB_CHROOT/build/profile"
- echo LDFLAGS="$LDFLAGS" >> "$XIB_CHROOT/build/profile"
-
+ cat $BUILD_PROFILE > "$XIB_CHROOT/build/profile"
cat > "$XIB_CHROOT/build/build.sh" << "EOF"
#!/bin/bash
source /build/profile
diff --git a/xibuild/build_profile b/xibuild/build_profile
new file mode 100644
index 0000000..d218fac
--- /dev/null
+++ b/xibuild/build_profile
@@ -0,0 +1,4 @@
+export MAKEFLAGS="-j$(grep "processor" /proc/cpuinfo | wc -l)"
+export XORG_PREFIX="/usr"
+
+export XORG_CONFIG="--prefix=/usr --sysconfdir=/etc --localstatedir=/var --disable-static"
diff --git a/xibuild/prepare.sh b/xibuild/prepare.sh
index 81f52a5..f7f5733 100644..100755
--- a/xibuild/prepare.sh
+++ b/xibuild/prepare.sh
@@ -17,3 +17,5 @@ fi
[ -f $INSTALLED_PACKAGES ] || touch $INSTALLED_PACKAGES
[ -f $XIB_CHROOT/etc/resolv.conf ] || cp /etc/resolv.conf $XIB_CHROOT/etc/resolv.conf
+
+cp build_profile $BUILD_PROFILE