Skip to content

Commit

Permalink
feat: deb build script for arm64
Browse files Browse the repository at this point in the history
  • Loading branch information
debuggerx01 committed Feb 23, 2022
1 parent c238771 commit 67246fa
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions app/build_deb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,6 @@ if [ -e deb_builder ]; then
rm -rf deb_builder
fi

ARCH="x64"

if [[ $(uname -m) == aarch64 ]]; then
ARCH="arm64"
fi

echo "开始打包 $ARCH deb"

mkdir "deb_builder"

Expand All @@ -59,14 +52,22 @@ echo Version: "$VERSION" >> deb_builder/DEBIAN/control

mkdir -p deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/

cp -r dde_package_info/* deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/

ARCH="x64"

if [[ $(uname -m) == aarch64 ]]; then
ARCH="arm64"
sed -i "s/amd64/$ARCH/g" deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/info
sed -i "s/amd64/$ARCH/g" deb_builder/DEBIAN/control
fi

cp -r build/linux/"$ARCH"/release/bundle deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/files

rm -rf deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/files/data/flutter_assets/noto_fonts/

ln -s /usr/share/fonts/opentype/noto/ deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/files/data/flutter_assets/noto_fonts

cp -r dde_package_info/* deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/

mkdir -p deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/entries/icons/hicolor/scalable/apps/

cp web/icons/Icon-512.png deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/entries/icons/hicolor/scalable/apps/dgm.png
Expand All @@ -75,6 +76,8 @@ sed -i "s/VERSION/$VERSION/g" deb_builder/opt/apps/com.debuggerx.dde-gesture-man

sed -i "s/VERSION/$VERSION/g" deb_builder/opt/apps/com.debuggerx.dde-gesture-manager/entries/applications/com.debuggerx.dde-gesture-manager.desktop

echo "开始打包 $ARCH deb"

fakeroot dpkg-deb -b deb_builder

if [[ $ARCH == "x64" ]]; then
Expand Down

0 comments on commit 67246fa

Please sign in to comment.