1
0
Fork 0
mirror of https://github.com/pygos/build.git synced 2024-11-22 02:59:47 +01:00

Merge base-files package with rootfs package

Signed-off-by: David Oberhollenzer <david.oberhollenzer@tele2.at>
This commit is contained in:
David Oberhollenzer 2018-01-29 10:24:52 +01:00
parent 875a348d2d
commit bcd68ce86a
10 changed files with 15 additions and 32 deletions

View file

@ -1,4 +1,3 @@
base-files
coreutils
bash
bash-completion

View file

@ -1,4 +1,3 @@
base-files
coreutils
bash
bash-completion

View file

@ -1,29 +0,0 @@
DEPENDS=""
build() {
return
}
deploy() {
local SOURCE="$1"
local BUILD="$2"
local DEPLOY="$3"
# home directory of root user
mkdir -p "$DEPLOY/root"
chmod 750 "$DEPLOY/root"
cp "$SCRIPTDIR/pkg/base-files/bash_profile" "$DEPLOY/root/.bash_profile"
cp "$SCRIPTDIR/pkg/base-files/bashrc" "$DEPLOY/root/.bashrc"
# /etc base files
mkdir -p "$DEPLOY/etc/skel"
cp "$SCRIPTDIR/pkg/base-files/bash_profile" "$DEPLOY/etc/skel/.bash_profile"
cp "$SCRIPTDIR/pkg/base-files/bashrc" "$DEPLOY/etc/skel/.bashrc"
cp "$SCRIPTDIR/pkg/base-files/hostname" "$DEPLOY/etc/hostname"
cp "$SCRIPTDIR/pkg/base-files/hosts" "$DEPLOY/etc/hosts"
cp "$SCRIPTDIR/pkg/base-files/passwd" "$DEPLOY/etc/passwd"
cp "$SCRIPTDIR/pkg/base-files/group" "$DEPLOY/etc/group"
}

View file

@ -7,7 +7,7 @@ build() {
# setup skeleton
mkdir -pv ${BUILD}/{bin,lib,etc,dev,sys,proc,tmp,var,run}
mkdir -pv ${BUILD}/{boot,usr,srv,mnt,opt}
mkdir -pv ${BUILD}/{boot,usr,srv,mnt,opt,root}
mkdir -pv ${BUILD}/cfg/{preserve,overlay}
echo "/lib" > "$BUILD/etc/ld-musl-${MUSL_CPU}.path"
@ -16,6 +16,19 @@ build() {
cat "$SCRIPTDIR/cfg/$CFG/LDPATH" >> "$BUILD/etc/ld-musl-${MUSL_CPU}.path"
fi
chmod 750 "$BUILD/root"
cp "$SCRIPTDIR/pkg/$PKGNAME/bash_profile" "$BUILD/root/.bash_profile"
cp "$SCRIPTDIR/pkg/$PKGNAME/bashrc" "$BUILD/root/.bashrc"
mkdir -pv ${BUILD}/etc/skel
cp "$SCRIPTDIR/pkg/$PKGNAME/bash_profile" "$BUILD/etc/skel/.bash_profile"
cp "$SCRIPTDIR/pkg/$PKGNAME/bashrc" "$BUILD/etc/skel/.bashrc"
cp "$SCRIPTDIR/pkg/$PKGNAME/hostname" "$BUILD/etc/hostname"
cp "$SCRIPTDIR/pkg/$PKGNAME/hosts" "$BUILD/etc/hosts"
cp "$SCRIPTDIR/pkg/$PKGNAME/passwd" "$BUILD/etc/passwd"
cp "$SCRIPTDIR/pkg/$PKGNAME/group" "$BUILD/etc/group"
# install packages to rootfs
dependencies | tsort | tac | grep -v "$PKGNAME" > "$BUILD/etc/packages"
echo "toolchain" >> "$BUILD/etc/packages"
@ -37,6 +50,7 @@ build() {
mv ${BUILD}/root ${BUILD}/cfg/preserve
mkdir -p ${BUILD}/root
chmod 750 ${BUILD}/root
chmod 750 ${BUILD}/cfg/preserve/root
}
deploy() {