[x49gp] don't package binaries, run post-install.sh
This commit is contained in:
parent
611e4b87c8
commit
33d7792130
1 changed files with 23 additions and 34 deletions
|
@ -4,11 +4,11 @@ set -x
|
|||
CWD=$(pwd)
|
||||
|
||||
PRGNAM=$(basename $CWD)
|
||||
GITHUB_REPO=claudiobsd/x49gp
|
||||
GITHUB_REPO=gwenhael-le-moine/x49gp #claudiobsd/x49gp
|
||||
VERSION=${VERSION:-$(curl -s https://api.github.com/repos/${GITHUB_REPO}/releases/latest | jq -r .tag_name | sed 's|^null$|trunk|')} # or VERSION=trunk
|
||||
NEWRPL_VERSION=1487
|
||||
|
||||
BUILD=4
|
||||
BUILD=5
|
||||
|
||||
ARCH=$(uname -m)
|
||||
LIBSUFFIX=$(echo $ARCH | grep -o "\(64\)")
|
||||
|
@ -45,14 +45,6 @@ find . \
|
|||
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
|
||||
-exec chmod 644 {} \;
|
||||
|
||||
# Building
|
||||
./pull-roms.sh
|
||||
|
||||
# temporary fix
|
||||
[ ! -e ./firmware/boot-49g+.bin ] && [ -e $CWD/boot-49g+.bin ] && cp $CWD/boot-49g+.bin firmware/
|
||||
[ ! -e ./firmware/boot-50g.bin ] && [ -e $CWD/boot-50g.bin ] && cp $CWD/boot-50g.bin firmware/
|
||||
sed -i 's|= boot-|= firmware/boot-|g' Makefile
|
||||
|
||||
make INSTALL_PREFIX=/usr INSTALL_MAN_DIR=/usr/man/man1
|
||||
make sdcard INSTALL_PREFIX=/usr INSTALL_MAN_DIR=/usr/man/man1
|
||||
|
||||
|
@ -60,35 +52,31 @@ make sdcard INSTALL_PREFIX=/usr INSTALL_MAN_DIR=/usr/man/man1
|
|||
mkdir -p $PKG
|
||||
make install DESTDIR=$PKG INSTALL_PREFIX=/usr INSTALL_MAN_DIR=/usr/man/man1
|
||||
|
||||
mkdir -p $PKG$PREFIX/share/$PRGNAM
|
||||
[ ! -e $CWD/hp4950v215.zip ] && wget -c -O $CWD/hp4950v215.zip https://www.hpcalc.org/hp49/pc/rom/hp4950v215.zip
|
||||
unzip -d $PKG$PREFIX/share/$PRGNAM/ $CWD/hp4950v215.zip
|
||||
|
||||
# mkdir -p $PKG$PREFIX/share/$PRGNAM/newrpl-${NEWRPL_VERSION}/
|
||||
# wget -c -O $PKG$PREFIX/share/$PRGNAM/newrpl-${NEWRPL_VERSION}/newrpl.bin https://phoenixnap.dl.sourceforge.net/project/newrpl/TARGET%2050g-ROM/newRPL-${NEWRPL_VERSION}-firmware-50g.bin
|
||||
# echo "newrpl.bin" > $PKG$PREFIX/share/$PRGNAM/newrpl-${NEWRPL_VERSION}/update.scp
|
||||
|
||||
mkdir -p $PKG$PREFIX/share/$PRGNAM/newrpl/
|
||||
wget -c -O $PKG$PREFIX/share/$PRGNAM/newrpl/newrplfw.bin https://www.hpgcc3.org/downloads/newrplfw.bin
|
||||
echo "newrplfw.bin" > $PKG$PREFIX/share/$PRGNAM/newrpl/update.scp
|
||||
|
||||
mkdir -p $PKG$PREFIX/doc/$PRGNAM/
|
||||
cp README* sdcard $PKG$PREFIX/doc/$PRGNAM/
|
||||
|
||||
mkdir -p $PKG$PREFIX/doc/$PRGNAM/HP_50g_Advanced_User-s_Reference_Manual_Edition_2
|
||||
[ ! -e $CWD/hp50gaur.zip ] && wget -c -O $CWD/hp50gaur.zip https://www.hpcalc.org/hp49/docs/misc/hp50gaur.zip
|
||||
unzip -d $PKG$PREFIX/doc/$PRGNAM/HP_50g_Advanced_User-s_Reference_Manual_Edition_2/ $CWD/hp50gaur.zip
|
||||
cat <<EOF > $PKG$PREFIX/doc/$PRGNAM/post-install.sh
|
||||
#!/bin/bash
|
||||
|
||||
mkdir -p $PKG$PREFIX/doc/$PRGNAM/HP_50g_User-s_Guide
|
||||
[ ! -e $CWD/hp50gug.zip ] && wget -c -O $CWD/hp50gug.zip https://www.hpcalc.org/hp49/docs/misc/hp50gug.zip
|
||||
unzip -d $PKG$PREFIX/doc/$PRGNAM/HP_50g_User-s_Guide/ $CWD/hp50gug.zip
|
||||
mkdir -p $PREFIX/share/$PRGNAM
|
||||
[ ! -e $PREFIX/doc/$PRGNAM/hp-arm-models-bootloader.zip ] && wget -c -O $PREFIX/doc/$PRGNAM/hp-arm-models-bootloader.zip https://www.hpcalc.org/hp49/pc/rom/hp-arm-models-bootloader.zip
|
||||
unzip -d $PREFIX/share/$PRGNAM/ $PREFIX/doc/$PRGNAM/hp-arm-models-bootloader.zip
|
||||
|
||||
[ ! -e $REPOSITORIES/newRPL-hp50g-usersguide ] && git clone https://github.com/smartin-calc/newRPL-hp50g-usersguide.git $REPOSITORIES/newRPL-hp50g-usersguide
|
||||
cd $REPOSITORIES/newRPL-hp50g-usersguide
|
||||
git pull --all
|
||||
[ ! -e $PREFIX/doc/$PRGNAM/hp4950v215.zip ] && wget -c -O $PREFIX/doc/$PRGNAM/hp4950v215.zip https://www.hpcalc.org/hp49/pc/rom/hp4950v215.zip
|
||||
unzip -d $PREFIX/share/$PRGNAM/ $PREFIX/doc/$PRGNAM/hp4950v215.zip
|
||||
|
||||
cp -R $REPOSITORIES/newRPL-hp50g-usersguide $PKG$PREFIX/doc/$PRGNAM/
|
||||
rm -fr $PKG$PREFIX/doc/$PRGNAM/newRPL-hp50g-usersguide/.git
|
||||
mkdir -p $PREFIX/share/$PRGNAM/newrpl/
|
||||
wget -c -O $PREFIX/share/$PRGNAM/newrpl/newrplfw.bin https://www.hpgcc3.org/downloads/newrplfw.bin
|
||||
echo "newrplfw.bin" > $PREFIX/share/$PRGNAM/newrpl/update.scp
|
||||
|
||||
mkdir -p $PREFIX/doc/$PRGNAM/HP_50g_Advanced_User-s_Reference_Manual_Edition_2
|
||||
[ ! -e $PREFIX/doc/$PRGNAM/hp50gaur.zip ] && wget -c -O $PREFIX/doc/$PRGNAM/hp50gaur.zip https:/www.hpcalc.org/hp49/docs/misc/hp50gaur.zip
|
||||
unzip -d $PREFIX/doc/$PRGNAM/HP_50g_Advanced_User-s_Reference_Manual_Edition_2/ $PREFIX/doc/$PRGNAM/hp50gaur.zip
|
||||
|
||||
mkdir -p $PREFIX/doc/$PRGNAM/HP_50g_User-s_Guide
|
||||
[ ! -e $PREFIX/doc/$PRGNAM/hp50gug.zip ] && wget -c -O $PREFIX/doc/$PRGNAM/hp50gug.zip https:/www.hpcalc.org/hp49/docs/misc/hp50gug.zip
|
||||
unzip -d $PREFIX/doc/$PRGNAM/HP_50g_User-s_Guide/ $PREFIX/doc/$PRGNAM/hp50gug.zip
|
||||
EOF
|
||||
|
||||
# Cleaning
|
||||
cd $PKG
|
||||
|
@ -111,8 +99,9 @@ cat <<EOF > install/doinst.sh
|
|||
|
||||
cat /usr/doc/x49gp/README.md | grep "First launch setup" --before-context=2 --after-context=28
|
||||
|
||||
echo "Prepared folders are installed in $PREFIX/share/$PRGNAM/hp4950v215"
|
||||
echo "Run $PREFIX/doc/$PRGNAM/post-install.sh"
|
||||
EOF
|
||||
|
||||
cat <<EOF > install/slack-desc
|
||||
$PRGNAM: $PRGNAM (HP49/50 emulator)
|
||||
$PRGNAM:
|
||||
|
|
Loading…
Add table
Reference in a new issue