wok-next annotate fpc/receipt @ rev 19833
Add libidn2, up curl
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Sat Aug 05 13:41:40 2017 +0300 (2017-08-05) |
parents | d6ca18366f41 |
children | c4e53a39395a |
rev | line source |
---|---|
slaxemulator@9411 | 1 # SliTaz package receipt. |
slaxemulator@9411 | 2 |
slaxemulator@9411 | 3 PACKAGE="fpc" |
pascal@16231 | 4 VERSION="2.6.4" |
slaxemulator@9411 | 5 CATEGORY="development" |
pankso@16194 | 6 SHORT_DESC="The Free Pascal Compiler" |
slaxemulator@9411 | 7 MAINTAINER="slaxemulator@gmail.com" |
pascal@15215 | 8 LICENSE="GPL2 LGPL2.1" |
slaxemulator@9411 | 9 SOURCE="fpcbuild" |
slaxemulator@9411 | 10 TARBALL="$SOURCE-$VERSION.tar.gz" |
slaxemulator@9411 | 11 WEB_SITE="http://www.freepascal.org/" |
slaxemulator@9411 | 12 WGET_URL="ftp://ftp.freepascal.org/pub/fpc/dist/$VERSION/source/$TARBALL" |
slaxemulator@9411 | 13 CONFIG_FILE="/etc/fpc.cfg" |
pascal@13034 | 14 TAGS="compiler pascal" |
slaxemulator@9411 | 15 |
pankso@16194 | 16 CROSS_BUGS="arm-slitaz-gnueabi-as: Command not found" |
pankso@16194 | 17 #HOST_ARCH="i486 arm" |
pankso@16194 | 18 |
pascal@15215 | 19 DEPENDS="ncurses" |
pascal@15215 | 20 BUILD_DEPENDS="fpc-bootstrap" |
pascal@15215 | 21 |
pankso@16194 | 22 # Handle cross compilation. ARM: fpc-bootstrap build host must be installed |
pankso@16194 | 23 case "$ARCH" in |
pankso@16194 | 24 arm*) BUILD_DEPENDS="" ;; |
pankso@16194 | 25 esac |
pankso@16194 | 26 |
slaxemulator@9411 | 27 # Rules to configure and make the package. |
slaxemulator@9411 | 28 compile_rules() |
slaxemulator@9411 | 29 { |
pankso@16194 | 30 case "$ARCH" in |
pankso@16194 | 31 i?86) |
pankso@16194 | 32 make ${ARCH_ARGS} NOGDB=1 build |
pankso@16194 | 33 make -j1 NOGDB=1 PREFIX=$DESTDIR/usr install ;; |
pankso@16194 | 34 arm*) |
pankso@16194 | 35 make crossinstall \ |
pankso@16194 | 36 NOGDB=1 \ |
pankso@16194 | 37 CPU_TARGET=arm \ |
pankso@16194 | 38 OS_TARGET=linux \ |
pankso@16194 | 39 OPT=-dFPC_ARMEL \ |
pankso@16194 | 40 CROSSBINDIR=/cross/$ARCH/tools/bin \ |
pankso@16194 | 41 BINUTILSPREFIX=arm-slitaz-gnueabi- \ |
pankso@16194 | 42 INSTALL_PREFIX=$DESTDIR/usr ;; |
pankso@16194 | 43 esac && |
al@18734 | 44 |
slaxemulator@9411 | 45 # install package license |
pankso@16194 | 46 install -m 755 -d $DESTDIR/usr/share/licenses/fpc && |
pankso@16194 | 47 install -m 644 $src/fpcsrc/rtl/COPYING.FPC \ |
pankso@16194 | 48 $DESTDIR/usr/share/licenses/fpc/ |
al@18803 | 49 |
al@18803 | 50 # move man pages to the right place |
al@18803 | 51 mv $install/usr/man $install/usr/share |
slaxemulator@9411 | 52 } |
slaxemulator@9411 | 53 |
slaxemulator@9411 | 54 # Rules to gen a SliTaz package suitable for Tazpkg. |
slaxemulator@9411 | 55 genpkg_rules() |
slaxemulator@9411 | 56 { |
slaxemulator@9411 | 57 mkdir -p $fs/usr $fs/etc |
pascal@15215 | 58 cp -a $install/usr/bin $fs/usr |
pascal@15215 | 59 cp -a $install/usr/lib $fs/usr |
al@18734 | 60 |
slaxemulator@9411 | 61 # create symlink for compiler |
slaxemulator@9411 | 62 ln -s /usr/lib/$PACKAGE/$VERSION/ppc386 $fs/usr/bin |
al@18734 | 63 |
pankso@16194 | 64 # config file |
erjo@16709 | 65 #mkdir -p $fs/etc |
erjo@16709 | 66 #cp -a $fs/usr/lib/fpc/$VERSION/samplecfg $fs/etc/fpc.cfg |
slaxemulator@9411 | 67 } |
slaxemulator@9411 | 68 |
erjo@16709 | 69 post_install() |
erjo@16709 | 70 { |
pascal@18730 | 71 if [ ! -f "$1/etc/fpc.cfg" ]; then |
pascal@18730 | 72 chroot "$1/" fpcmkcfg > /etc/fpc.cfg |
erjo@16709 | 73 fi |
al@18734 | 74 |
erjo@16709 | 75 # Fix units search path |
pascal@18730 | 76 sed -i -e 's!^-Fu/units/$fpctarget!-Fu/usr/lib/fpc/'$VERSION'/units/$fpctarget!' \ |
pascal@18730 | 77 -e 's!^-Fu/units/$fpctarget/*!-Fu/usr/lib/fpc/'$VERSION'/units/$fpctarget/*!' \ |
pascal@18730 | 78 -e 's!^-Fu/units/$fpctarget/rtl!-Fu/usr/lib/fpc/'$VERSION'/units/$fpctarget/rtl!' "$1/etc/fpc.cfg" |
erjo@16709 | 79 } |