diff options
Diffstat (limited to 'templates')
-rwxr-xr-x | templates/turris4x.run | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/templates/turris4x.run b/templates/turris4x.run index b14821e..2842d08 100755 --- a/templates/turris4x.run +++ b/templates/turris4x.run @@ -22,30 +22,35 @@ else echo_stage "Prepare SDK" mkdir openwrt + ( cd openwrt - GIT_MIRROR="$TWORKSPACE/openwrt-git-mirror" \ - CCACHE_HOST_DIR="$TWORKSPACE/ccache-host" \ - CCACHE_TARGET_DIR="$WORKSPACE/ccache-target" \ - ../turris-build/compile_fw -a "$njobs" -t $BOARD -p $BRANCH repo_prepare + cat > .turris-build.conf <<EOF +GIT_MIRROR="$TWORKSPACE/openwrt-git-mirror" +DL_MIRROR="$TWORKSPACE/openwrt-dl-mirror" +CCACHE_HOST_DIR="$TWORKSPACE/ccache-host" +CCACHE_TARGET_DIR="$WORKSPACE/ccache-target" +EOF + ../turris-build/compile_fw -t "$BOARD" -p "$BRANCH" repo_prepare $make toolchain/compile target/compile package/usign/host/compile - cd .. + ) tar -czf openwrt.tar.gz openwrt mv openwrt.tar.gz "$WORKSPACE/openwrt.tar.gz" mv git-hash "$WORKSPACE/openwrt-git-hash" fi cd openwrt -echo_stage "Add our repository as feed" +echo_stage "Get personal repository feed" echo "src-git personal git@cynerd.cz:openwrt-personal-pkgs" >> feeds.conf ./scripts/feeds update personal -./scripts/feeds uninstall $(./scripts/feeds list -r personal | awk '{print $1}') +./scripts/feeds list -r personal | awk '{print $1}' | xargs ./scripts/feeds uninstall # Remove any package provided by personal feed ./scripts/feeds install -p personal -d y -f -a # TODO drop this and replace it with autopkg deployment using compile_fw cp ./feeds/personal/autopkg-*.mk include/ echo_stage "Compile packages from personal feed" -$make $(ls package/feeds/personal | sed -n 's/^\([^ ]*\).*$/package\/\1\/compile/p' | tr '\n' ' ') +find package/feeds/personal -maxdepth 1 -type d -printf 'package/%P/compile\\0' | \ + xargs --null $make echo_stage "Generate index and sign" $make package/index BUILD_KEY=~/openwrt-repo.key |