mirror of
https://github.com/fosslinux/live-bootstrap.git
synced 2026-03-10 21:35:24 +01:00
Avoid exporting variables in build scripts
Environment variables "pollute" the build environment of packages and can affect their output. This change results in the removal of some files from packages that were not meant to be packaged. It also removes the need for a workaround in automake 1.10.3 to manually remove such files. Variables are now saved in an .env file for each system and included in scripts that need them using the dot operation.
This commit is contained in:
parent
a74f3166f3
commit
3921660396
9 changed files with 45 additions and 24 deletions
21
sysc/init
21
sysc/init
|
|
@ -7,12 +7,13 @@
|
|||
|
||||
set -e
|
||||
|
||||
export PATH=/usr/bin:/usr/sbin
|
||||
export PREFIX=/usr
|
||||
export SOURCES=/usr/src
|
||||
export DESTDIR=/tmp/destdir
|
||||
export DISTFILES=/distfiles
|
||||
export SRCDIR="${SOURCES}"
|
||||
PREFIX=/usr
|
||||
SOURCES="${PREFIX}/src"
|
||||
DESTDIR=/tmp/destdir
|
||||
DISTFILES=/distfiles
|
||||
SRCDIR="${SOURCES}"
|
||||
|
||||
export PATH="${PREFIX}/bin:${PREFIX}/sbin"
|
||||
export HOME=/tmp
|
||||
export SOURCE_DATE_EPOCH=0
|
||||
|
||||
|
|
@ -61,4 +62,12 @@ ln -s /usr/bin/bash /usr/bin/sh
|
|||
|
||||
# Begin sysc bootstrapping process
|
||||
cd "${SOURCES}"
|
||||
|
||||
# shellcheck disable=SC2129
|
||||
echo "PREFIX=${PREFIX}" >> .env
|
||||
echo "SOURCES=${SOURCES}" >> .env
|
||||
echo "DESTDIR=${DESTDIR}" >> .env
|
||||
echo "DISTFILES=${DISTFILES}" >> .env
|
||||
echo "SRCDIR=${SRCDIR}" >> .env
|
||||
|
||||
exec ./run.sh
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue