wok-undigest annotate gettext/receipt @ rev 1223
copied libxext recipe from wok-next
author | Hans-G?nter Theisgen |
---|---|
date | Fri Nov 15 17:38:29 2019 +0100 (2019-11-15) |
parents | |
children |
rev | line source |
---|---|
Hans-G?nter@1220 | 1 # SliTaz package receipt v2. |
Hans-G?nter@1220 | 2 |
Hans-G?nter@1220 | 3 PACKAGE="gettext" |
Hans-G?nter@1220 | 4 VERSION="0.19.8.1" |
Hans-G?nter@1220 | 5 CATEGORY="development" |
Hans-G?nter@1220 | 6 SHORT_DESC="Utilities for the GNU Translation Project" |
Hans-G?nter@1220 | 7 MAINTAINER="devel@slitaz.org" |
Hans-G?nter@1220 | 8 LICENSE="GPL3" |
Hans-G?nter@1220 | 9 WEB_SITE="https://www.gnu.org/software/gettext/" |
Hans-G?nter@1220 | 10 LFS="http://www.linuxfromscratch.org/lfs/view/stable/chapter06/gettext.html" |
Hans-G?nter@1220 | 11 |
Hans-G?nter@1220 | 12 TARBALL="$PACKAGE-$VERSION.tar.xz" |
Hans-G?nter@1220 | 13 WGET_URL="$GNU_MIRROR/$PACKAGE/$TARBALL" |
Hans-G?nter@1220 | 14 |
Hans-G?nter@1220 | 15 BUILD_DEPENDS="libcroco-dev libxml2-dev glib-dev acl-dev emacs \ |
Hans-G?nter@1220 | 16 libxrandr-dev libxfixes-dev" |
Hans-G?nter@1220 | 17 SPLIT="$PACKAGE-base $PACKAGE emacs-pkg-po-mode $PACKAGE-dev" |
Hans-G?nter@1220 | 18 |
Hans-G?nter@1220 | 19 compile_rules() { |
Hans-G?nter@1220 | 20 ./configure $CONFIGURE_ARGS && |
Hans-G?nter@1220 | 21 make && |
Hans-G?nter@1220 | 22 make install || return 1 |
Hans-G?nter@1220 | 23 |
Hans-G?nter@1220 | 24 chmod 0755 $install/usr/lib/preloadable_libintl.so |
Hans-G?nter@1220 | 25 |
Hans-G?nter@1220 | 26 # stripped gettext.sh |
Hans-G?nter@1220 | 27 rm $install/usr/bin/gettext.sh |
Hans-G?nter@1220 | 28 install -m755 $stuff/gettext.sh $install/usr/bin |
Hans-G?nter@1220 | 29 |
Hans-G?nter@1220 | 30 # emacs-pkg-po-mode -------- |
Hans-G?nter@1220 | 31 |
Hans-G?nter@1220 | 32 site_lisp="$install/usr/share/emacs/site-lisp" |
Hans-G?nter@1220 | 33 # Installing start file |
Hans-G?nter@1220 | 34 mkdir -p $site_lisp/site-start.d |
Hans-G?nter@1220 | 35 cp -a $src/gettext-tools/misc/start-po.el $site_lisp/site-start.d/50-start-po.el |
Hans-G?nter@1220 | 36 |
Hans-G?nter@1220 | 37 # Installing po-mode |
Hans-G?nter@1220 | 38 mkdir -p $site_lisp/po-mode |
Hans-G?nter@1220 | 39 cp -a $src/gettext-tools/misc/po*.el $site_lisp/po-mode |
Hans-G?nter@1220 | 40 |
Hans-G?nter@1220 | 41 # byte-compile files, remove src |
Hans-G?nter@1220 | 42 for file in $site_lisp/po-mode/*.el; do |
Hans-G?nter@1220 | 43 echo -n "Byte-compiling $(basename $file)" |
Hans-G?nter@1220 | 44 emacs -batch -f batch-byte-compile $file 2>/dev/null; err=$? |
Hans-G?nter@1220 | 45 status |
Hans-G?nter@1220 | 46 [ "$err" -eq 0 ] && rm -f $file |
Hans-G?nter@1220 | 47 done |
Hans-G?nter@1220 | 48 } |
Hans-G?nter@1220 | 49 |
Hans-G?nter@1220 | 50 # Just to be sure when cross compiling, gettext is part of base system. |
Hans-G?nter@1220 | 51 testsuite() { |
Hans-G?nter@1220 | 52 readelf -h $install/usr/bin/gettext |
Hans-G?nter@1220 | 53 } |
Hans-G?nter@1220 | 54 |
Hans-G?nter@1220 | 55 genpkg_rules() { |
Hans-G?nter@1220 | 56 case $PACKAGE in |
Hans-G?nter@1220 | 57 gettext-base) |
Hans-G?nter@1220 | 58 copy gettext gettext.sh envsubst ngettext |
Hans-G?nter@1220 | 59 CAT="base-system|base tools" |
Hans-G?nter@1220 | 60 DEPENDS="glibc-base" |
Hans-G?nter@1220 | 61 ;; |
Hans-G?nter@1220 | 62 gettext) |
Hans-G?nter@1220 | 63 copy msgcat msgfmt msgmerge xgettext \ |
Hans-G?nter@1220 | 64 libgettextlib*.so* libgettextsrc*.so* |
Hans-G?nter@1220 | 65 DEPENDS="acl glib libcroco libgomp libxml2 ncurses" |
Hans-G?nter@1220 | 66 TAGS="LFS" |
Hans-G?nter@1220 | 67 ;; |
Hans-G?nter@1220 | 68 emacs-pkg-po-mode) |
Hans-G?nter@1220 | 69 copy emacs/ |
Hans-G?nter@1220 | 70 DEPENDS="emacs" |
Hans-G?nter@1220 | 71 CAT="development|Emacs major mode for editing or modifying PO files" |
Hans-G?nter@1220 | 72 ;; |
Hans-G?nter@1220 | 73 *-dev) |
Hans-G?nter@1220 | 74 copy @std @dev @rm |
Hans-G?nter@1220 | 75 rm -rf $fs/usr/share/doc/ # @dev files here |
Hans-G?nter@1220 | 76 # Runtime depends, then dev-depends |
Hans-G?nter@1220 | 77 DEPENDS="gettext-base gettext libxml2" |
Hans-G?nter@1220 | 78 ;; |
Hans-G?nter@1220 | 79 esac |
Hans-G?nter@1220 | 80 } |
Hans-G?nter@1220 | 81 |
Hans-G?nter@1220 | 82 post_install_emacs_pkg_po_mode() { |
Hans-G?nter@1220 | 83 chroot "$1/" tazpkg reconfigure emacs |
Hans-G?nter@1220 | 84 } |
Hans-G?nter@1220 | 85 |
Hans-G?nter@1220 | 86 post_remove_emacs_pkg_po_mode() { |
Hans-G?nter@1220 | 87 chroot "$1/" tazpkg reconfigure emacs |
Hans-G?nter@1220 | 88 } |