Skip to content

Commit

Permalink
save build envirement info to firmware
Browse files Browse the repository at this point in the history
  • Loading branch information
guoxiaoqiao committed May 6, 2022
1 parent a1917b5 commit 64d5ac3
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,4 @@ git-src
.cproject
.ccache
.vscode
/files/build
3 changes: 3 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,8 @@ VERSION=Gainstrong-$(./scripts/getver.sh)
echo "CONFIG_KERNEL_BUILD_DOMAIN=\"$VERSION\"" >> .config
make package/symlinks
make defconfig

source scripts/save-build-env.sh

make package/busybox/clean
make -j8 V=sc
9 changes: 9 additions & 0 deletions scripts/save-build-env.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/bash

BUILD_CONF_DIR=files/build
rm -rf $BUILD_CONF_DIR
mkdir -p $BUILD_CONF_DIR
git log -40 --stat > $BUILD_CONF_DIR/git-log.txt
cp -a .config $BUILD_CONF_DIR
cat /etc/os-release > $BUILD_CONF_DIR/build-host-os.txt
dpkg -l | grep ^i | awk '{print $2"\t"$3}' > $BUILD_CONF_DIR/build-host-pkg.txt

0 comments on commit 64d5ac3

Please sign in to comment.