Skip to content

Commit 23dc5cc

Browse files
committed
target: tuning
1 parent adf68e0 commit 23dc5cc

3 files changed

Lines changed: 10 additions & 6 deletions

File tree

scripts/build_target.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ chmod -R o+rX,o-w "$TARGET/etc/"
2222
chmod -R o-r "$TARGET/etc/ssh/" 2> /dev/null || true
2323
chmod -R o+rX "$TARGET/usr/share/" 2> /dev/null || true
2424
chmod -R o-rwx "$TARGET/root/"
25-
chmod o+rx "$TARGET/usr/bin/busybox"
2625

2726

2827
# Replace some $TARGET/usr files with our own build support

storage/build/linux/rebuild_and_reinstall.sh

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,21 @@ if ! findmnt /boot; then
66
echo 'Mount /boot partition!'
77
exit 1
88
fi
9+
if ! test -r .config; then
10+
echo 'No .config found! Maybe use one from /boot/kernel.config'
11+
exit 1
12+
fi
913

1014
TARGET=''
1115
LINUX_SRC="/usr/src/xxLINUX_VERSIONxx"
1216

1317
cd $LINUX_SRC
1418

15-
make $* vmlinux bzImage modules
16-
make INSTALL_MOD_PATH=$TARGET/usr INSTALL_MOD_STRIP=1 modules_install
17-
make INSTALL_HDR_PATH=$TARGET/usr INSTALL_MOD_STRIP=1 headers_install
19+
make $*
20+
grep -q '^CONFIG_MODULES=y$' .config && make INSTALL_MOD_PATH="$TARGET/usr" INSTALL_MOD_STRIP=1 modules_install || true
21+
make INSTALL_HDR_PATH="$TARGET/usr" INSTALL_MOD_STRIP=1 headers_install
1822

1923
cp -f $LINUX_SRC/.config $TARGET/boot/kernel.config
2024
cp -f $LINUX_SRC/System.map $TARGET/boot/System.map
21-
cp -f $LINUX_SRC/arch/x86/boot/bzImage $TARGET/boot/vmlinuz
25+
cp -f $LINUX_SRC/arch/$(uname -m)/boot/*Image $TARGET/boot/vmlinuz
26+
[ -r "$LINUX_SRC/arch/$(uname -m)/boot/dts/" ] && rm -rf "$TARGET/boot/dts/" && cp -r "$LINUX_SRC/arch/$(uname -m)/boot/dts/" "$TARGET/boot/" || true

target/etc/shadow

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ http:x:99999::::::
77
uuidd:x:99999::::::
88
dbus:x:99999::::::
99
nobody:x:99999::::::
10-
user:f7K76jopVNJxE:101101:0:99999::::
10+
user:x:99999::::::
1111
builder::99999:0:99999::::

0 commit comments

Comments
 (0)