32 lines
609 B
Bash
Executable file
32 lines
609 B
Bash
Executable file
#!/bin/bash
|
|
|
|
VERSION=0.59
|
|
APP=crfpp
|
|
DEPOT=https://github.com/2pc/crfpp.git
|
|
GIT_VERSION=last
|
|
DEB_VERSION=$VERSION-$(date +%Y%m%d%H%M)
|
|
DEBIAN_VERSION_CODENAME=bullseye
|
|
IMAGE_SIZE=1
|
|
PACKAGE_DEPENDENCY="build-essential autoconf"
|
|
|
|
main(){
|
|
base_package_upgrade
|
|
install_package_dependency
|
|
get_git_source
|
|
build
|
|
makedeb
|
|
}
|
|
|
|
build() {
|
|
cd /tmp/${APP}
|
|
sed -i 's/#include "winmain.h"//' crf_*.cpp
|
|
./configure --prefix=/tmp/src/rootfs/usr
|
|
make install
|
|
}
|
|
|
|
makedeb(){
|
|
PATH_DEB=/tmp/src/rootfs
|
|
|
|
sed -i "s/%VERSION%/$DEB_VERSION/" ${PATH_DEB}/DEBIAN/control
|
|
fakeroot dpkg-deb -Z gzip --build ${PATH_DEB} /tmp/dist
|
|
}
|