...
 
Commits (3)
# Contributor: A. Wilcox <awilfox@adelielinux.org>
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=gettext-tiny
pkgver=0.3.0_pre1
pkgrel=7
pkgver=0.3.1_git20191130
pkgrel=0
pkgdesc="An internationalisation and localisation system"
url="https://github.com/sabotage-linux/gettext-tiny"
arch="all"
......@@ -12,13 +12,8 @@ depends=""
makedepends=""
subpackages="$pkgname-dev"
source="https://distfiles.adelielinux.org/source/$pkgname-$pkgver.tar.xz
omg-i-cant-believe-im-doing-ua-crap.patch
respect-cflags.patch
stop-doing-macro-crap.patch
cpp-compat.patch
double-stack-size.patch
m4-installation.patch
dynamic.patch
"
build() {
......@@ -29,11 +24,6 @@ package() {
make LIBINTL=MUSL DESTDIR="$pkgdir" prefix=/usr install
}
sha512sums="3795b9923f6820ce6e2c6a27480365a4ee1cb1f8f8916256887a40c8e0f0b582ada049a528330297f8daa1bff7d5877a15169095332456c57dc3fdb49407ef98 gettext-tiny-0.3.0_pre1.tar.xz
2951ad99fd04ee7d8dc06b4de575b7838e350737e3b40ecd93eae9f6f2b4c15883a392370e25dfaf834a57bc801721894e946d24910cfd65c44c2e025321ade4 omg-i-cant-believe-im-doing-ua-crap.patch
cea1596f3f20c8983e57d2e49e955a43ed2e261b244f6c4c2ae7d8b869e3cfce3bb87b0a17c16bdac59afd99703cef9c7ef4e93fca536bf1bf9aa5f9be9fa34f respect-cflags.patch
d2a1a6b1f135c25172cf98dfed64739ff85f6016a31c3ce028b3a7aa72de0b55c1f9a54c5ba2c58817f5222c3d2a5bc3d03ec9058ae5fbae2c798df9227a4e52 stop-doing-macro-crap.patch
0f1a1be10a038e6d30976f060c271e926f8f6b0541af7044f1b0ac2641825fc784ce3e3ff6ca13f3a5d15bbcd355a0999b60d4aa6f30c7b75254ca0edcaccc4d cpp-compat.patch
331bd0442b400407d690cce4a90aac09acf64e1a26f9951dc1d1332cc29916987d34cc13bc13e84482c6950908cedad50f6aaf325f99118d769bb1286dd4db1b double-stack-size.patch
090b685f6846b1cf4c266cbc982701283c7e30ddcbb1d3d263d50f83645ed168530db4bc03b6b688e46a32ac7ad09f0cd3f0e94f5c1a39e86d904f010353d91e m4-installation.patch
06ca61de36d41ad9545c7c60e54fe0fe77eb67bb4902679f2828e7a14ad01cfc244b7b136e31debbb60d9dc9b4101b4f0463d46f95c263939017fd38fbe31b19 dynamic.patch"
sha512sums="a318135626a0403a30a81fa475f7e1878b8af5a87053b0e00876c73b591508f3cf1e66d01f8d6a45013d1dc36a4da9f21fbf2b5050676826cb618b5b659aaaf7 gettext-tiny-0.3.1_git20191130.tar.xz
b4e7db4e415f6bc31f2214f2044506ad18ea0bd3cae4200d93bbd34aa493c7478a7f953d0a7e08f29f0fd5a5d7b7cbfa2bcfd5692c37e423706a1c193239bf1d respect-cflags.patch
cd4cfc8cc6ea998f1e33ef666e3b9c3de3f3253994bccc942b177773c94f785e3892cb7d5f34bec1102dc7558236c07c5eac90e15d755e12ee06836336373526 stop-doing-macro-crap.patch"
--- gettext-tiny-0.3.0_pre1/include/libintl.h.old 2018-06-21 19:55:29.646162973 -0500
+++ gettext-tiny-0.3.0_pre1/include/libintl.h 2018-06-21 19:56:16.886116203 -0500
@@ -1,6 +1,9 @@
#ifndef LIBINTL_H
#define LIBINTL_H
+#ifdef __cplusplus
+extern "C" {
+#endif
char *gettext(const char *msgid);
char *dgettext(const char *domainname, const char *msgid);
char *dcgettext(const char *domainname, const char *msgid, int category);
@@ -11,6 +14,9 @@
char *textdomain(const char *domainname);
char *bind_textdomain_codeset(const char *domainname, const char *codeset);
char *bindtextdomain(const char *domainname, const char *dirname);
+#ifdef __cplusplus
+}
+#endif
#undef gettext_noop
#define gettext_noop(X) X
Seen in the Dzongkha translation of GConf 3.2.6:
/bin/sh: line 1: 25453 Aborted /usr/bin/msgfmt -o $file dz.po
This is what we expect to see having a short read of the line; the line in
question is 4,279 bytes long.
--- gettext-tiny-0.3.0_pre1/src/msgfmt.c.old 2018-06-21 04:47:19.927932643 +0000
+++ gettext-tiny-0.3.0_pre1/src/msgfmt.c 2018-07-12 01:23:59.250000000 +0000
@@ -370,8 +370,8 @@
int process(FILE *in, FILE *out) {
struct mo_hdr mohdr = def_hdr;
- char line[4096]; char *lp;
- char convbuf[16384];
+ char line[8448]; char *lp;
+ char convbuf[33792];
struct callbackdata d = {
.num = {
GDB/symbol splitting doesn't work on static binaries.
For debugability, build dynamic.
--- gettext-tiny-0.3.0_pre1/Makefile.old 2018-07-25 23:41:05.120000000 +0000
+++ gettext-tiny-0.3.0_pre1/Makefile 2018-07-25 23:42:51.350000000 +0000
@@ -62,10 +62,10 @@
$(RANLIB) $@
msgmerge: $(OBJS)
- $(CC) $(LDFLAGS) -static -o $@ src/msgmerge.o $(PARSEROBJS)
+ $(CC) $(LDFLAGS) -o $@ src/msgmerge.o $(PARSEROBJS)
msgfmt: $(OBJS)
- $(CC) $(LDFLAGS) -static -o $@ src/msgfmt.o $(PARSEROBJS)
+ $(CC) $(LDFLAGS) -o $@ src/msgfmt.o $(PARSEROBJS)
xgettext:
cp src/xgettext.sh ./xgettext
From 7698cca6d5634ce0de4bb382e0535e1f02d7fb17 Mon Sep 17 00:00:00 2001
From: xhe <xw897002528@gmail.com>
Date: Sat, 14 Jul 2018 18:45:45 +0800
Subject: [PATCH] install: symlink m4 files to $(dataroot)/aclocal follow
https://github.com/sabotage-linux/gettext-tiny/issues/27.
According to @awilfox, GNU gettext will install m4 files to aclocal dir.
But gettext-tiny did not. So autoreconf just stops working and complains
that it can not find needed macros.
Suggested by rofl0r, symlinking all m4 files into $(dataroot)/aclocal is
a good idea. Save a little disk space.
---
Makefile | 22 ++++++++++++---------
install.sh | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 80 insertions(+), 9 deletions(-)
create mode 100644 install.sh
diff --git a/Makefile b/Makefile
index 7842c0f..927d02e 100644
--- a/Makefile
+++ b/Makefile
@@ -3,7 +3,9 @@ bindir=$(prefix)/bin
includedir=$(prefix)/include
libdir=$(prefix)/lib
sysconfdir=$(prefix)/etc
-datadir=$(prefix)/share/gettext-tiny
+datarootdir=$(prefix)/share
+datadir=$(datarootdir)/gettext-tiny
+acdir=$(datarootdir)/aclocal
ifeq ($(LIBINTL), MUSL)
LIBSRC = libintl/libintl-musl.c
@@ -36,13 +38,15 @@ AR ?= $(CROSS_COMPILE)ar
RANLIB ?= $(CROSS_COMPILE)ranlib
CC ?= $(CROSS_COMPILE)cc
+INSTALL ?= ./install.sh
+
-include config.mak
BUILDCFLAGS=$(CFLAGS)
all: $(ALL_LIBS) $(ALL_TOOLS)
-install: $(ALL_LIBS:lib%=$(DESTDIR)$(libdir)/lib%) $(ALL_INCLUDES:%=$(DESTDIR)$(includedir)/%) $(ALL_TOOLS:%=$(DESTDIR)$(bindir)/%) $(ALL_M4S:%=$(DESTDIR)$(datadir)/%) $(ALL_DATA:%=$(DESTDIR)$(datadir)/%)
+install: $(ALL_LIBS:lib%=$(DESTDIR)$(libdir)/lib%) $(ALL_INCLUDES:%=$(DESTDIR)$(includedir)/%) $(ALL_TOOLS:%=$(DESTDIR)$(bindir)/%) $(ALL_M4S:%=$(DESTDIR)$(datadir)/%) $(ALL_M4S:%=$(DESTDIR)$(acdir)/%) $(ALL_DATA:%=$(DESTDIR)$(datadir)/%)
clean:
rm -f $(ALL_LIBS)
@@ -70,18 +74,18 @@ autopoint: src/autopoint.in
cat $< | sed 's,@datadir@,$(datadir),' > $@
$(DESTDIR)$(libdir)/%.a: %.a
- install -D -m 755 $< $@
+ $(INSTALL) -D -m 755 $< $@
$(DESTDIR)$(includedir)/%.h: include/%.h
- install -D -m 644 $< $@
+ $(INSTALL) -D -m 644 $< $@
$(DESTDIR)$(bindir)/%: %
- install -D -m 755 $< $@
+ $(INSTALL) -D -m 755 $< $@
$(DESTDIR)$(datadir)/%: %
- install -D -m 644 $< $@
-
-.PHONY: all clean install
-
+ $(INSTALL) -D -m 644 $< $@
+$(DESTDIR)$(acdir)/%: %
+ $(INSTALL) -D -l ../$(subst $(datarootdir)/,,$(datadir))/$< $(subst m4/,,$@)
+.PHONY: all clean install
diff --git a/install.sh b/install.sh
new file mode 100755
index 0000000..0410883
--- /dev/null
+++ b/install.sh
@@ -0,0 +1,67 @@
+#!/bin/sh
+#
+# Written by Rich Felker, originally as part of musl libc.
+# Multi-licensed under MIT, 0BSD, and CC0.
+#
+# This is an actually-safe install command which installs the new
+# file atomically in the new location, rather than overwriting
+# existing files.
+#
+
+usage() {
+printf "usage: %s [-D] [-l] [-m mode] src dest\n" "$0" 1>&2
+exit 1
+}
+
+mkdirp=
+symlink=
+mode=755
+
+while getopts Dlm: name ; do
+case "$name" in
+D) mkdirp=yes ;;
+l) symlink=yes ;;
+m) mode=$OPTARG ;;
+?) usage ;;
+esac
+done
+shift $(($OPTIND - 1))
+
+test "$#" -eq 2 || usage
+src=$1
+dst=$2
+tmp="$dst.tmp.$$"
+
+case "$dst" in
+*/) printf "%s: %s ends in /\n", "$0" "$dst" 1>&2 ; exit 1 ;;
+esac
+
+set -C
+set -e
+
+if test "$mkdirp" ; then
+umask 022
+case "$2" in
+*/*) mkdir -p "${dst%/*}" ;;
+esac
+fi
+
+trap 'rm -f "$tmp"' EXIT INT QUIT TERM HUP
+
+umask 077
+
+if test "$symlink" ; then
+ln -s "$1" "$tmp"
+else
+cat < "$1" > "$tmp"
+chmod "$mode" "$tmp"
+fi
+
+mv -f "$tmp" "$2"
+test -d "$2" && {
+rm -f "$2/$tmp"
+printf "%s: %s is a directory\n" "$0" "$dst" 1>&2
+exit 1
+}
+
+exit 0
It turns out CMake requires the format to be:
^msgmerge \(.*\) (gettext-version-number-here)
So, this fixes CMake's test suite, and properly sets GETTEXT_VERSION_STRING
to be the same as the m4 scripts shipped.
--- gettext-tiny-0.3.0_pre1/src/msgmerge.c.old 2018-06-20 23:47:19.927932643 -0500
+++ gettext-tiny-0.3.0_pre1/src/msgmerge.c 2018-06-20 23:55:12.997464272 -0500
@@ -18,7 +18,7 @@
__attribute__((noreturn))
static void version(void) {
fprintf(stdout,
- "these are not (GNU gettext-tools) 99.9999.9999\n");
+ "msgmerge (GNU gettext-tools compatible) 99.9999.9999\n");
exit(0);
}
--- gettext-tiny-0.2.0/Makefile.old 2017-08-02 06:14:20.000000000 -0500
+++ gettext-tiny-0.2.0/Makefile 2018-06-16 21:21:57.148735892 -0500
@@ -29,7 +29,7 @@
ALL_TOOLS=msgfmt msgmerge xgettext autopoint
@@ -32,7 +32,7 @@
ALL_M4S=$(sort $(wildcard m4/*.m4))
ALL_DATA=$(sort $(wildcard data/*))
-CFLAGS=-O0 -fPIC
+CFLAGS ?= -O0 -fPIC
......
--- gettext-tiny-0.2.0/include/libintl.h.old 2017-08-02 06:14:20.000000000 -0500
+++ gettext-tiny-0.2.0/include/libintl.h 2018-06-15 02:31:14.241446687 -0500
@@ -15,14 +15,14 @@
@@ -34,14 +34,14 @@
#undef gettext_noop
#define gettext_noop(X) X
......
# Contributor: Łukasz Jendrysik <scadu@yandex.com>
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=git
pkgver=2.24.1
pkgver=2.25.0
pkgrel=0
pkgdesc="Distributed version control system"
url="https://www.git-scm.com/"
......@@ -22,6 +22,7 @@ subpackages="$pkgname-doc
$pkgname-gitweb
$pkgname-subtree::noarch
$pkgname-subtree-doc:subtree_doc:noarch
$pkgname-lang
"
replaces="git-perl perl-git"
source="https://www.kernel.org/pub/software/scm/git/git-$pkgver.tar.xz
......@@ -50,7 +51,6 @@ _gitcoredir=/usr/libexec/git-core
prepare() {
default_prepare
cat >> config.mak <<-EOF
NO_GETTEXT=YesPlease
NO_SVN_TESTS=YesPlease
NO_REGEX=YesPlease
USE_ASCIIDOCTOR=1
......@@ -173,7 +173,7 @@ subtree_doc() {
gzip -9 "$subpkgdir"/usr/share/man/man1/git-subtree.1
}
sha512sums="010c13d4023c142876d0e075a394b74bef422944d8ca602325d0b2b47bf28b1d534283c7f295751113c83fdfcc0c91f97090e8f906560d44b04a94607fd8fcf7 git-2.24.1.tar.xz
315e4666c425b31a7f7a447e777cbf2a1050feac9b4d4b8a61c05248024e790d4d18f3336faf2a2c68584e05e8194c22a09e1caba1352cfec194e0bc01277a6c dont-test-other-encodings.patch
sha512sums="8bbada0451fe0a3314e1b9a43a74135115449aa41f5b3e7f960279e4a7fe6069c36e78825fc4b60d06806e3a6fa8158f327cb8a3801686ac22a35e3704244191 git-2.25.0.tar.xz
0a0935d876024d96156df3aeec06b47fd9e370484d4552786c450cb500ae671a631e64c30994ec39f43a2f313f75d68909688ea92b47327d1af65e365dc77480 dont-test-other-encodings.patch
89528cdd14c51fd568aa61cf6c5eae08ea0844e59f9af9292da5fc6c268261f4166017d002d494400945e248df6b844e2f9f9cd2d9345d516983f5a110e4c42a git-daemon.initd
fbf1f425206a76e2a8f82342537ed939ff7e623d644c086ca2ced5f69b36734695f9f80ebda1728f75a94d6cd2fcb71bf845b64239368caab418e4d368c141ec git-daemon.confd"
We can't support Japanese people using musl
--- git-2.14.1/t/t3900-i18n-commit.sh.old 2017-08-09 14:54:31.000000000 -0500
+++ git-2.14.1/t/t3900-i18n-commit.sh 2017-09-10 21:10:09.269860087 -0500
@@ -76,132 +76,4 @@
test_i18ngrep "did not conform" "$HOME"/stderr
'
-for H in ISO8859-1 eucJP ISO-2022-JP
-do
- test_expect_success "$H setup" '
- git config i18n.commitencoding $H &&
- git checkout -b $H C0 &&
- echo $H >F &&
- git commit -a -F "$TEST_DIRECTORY"/t3900/$H.txt
- '
-done
-
-for H in ISO8859-1 eucJP ISO-2022-JP
-do
- test_expect_success "check encoding header for $H" '
- E=$(git cat-file commit '$H' | sed -ne "s/^encoding //p") &&
- test "z$E" = "z'$H'"
- '
-done
-
-test_expect_success 'config to remove customization' '
- git config --unset-all i18n.commitencoding &&
- if Z=$(git config --get-all i18n.commitencoding)
- then
- echo Oops, should have failed.
- false
- else
- test z = "z$Z"
- fi &&
- git config i18n.commitencoding UTF-8
-'
-
-test_expect_success 'ISO8859-1 should be shown in UTF-8 now' '
- compare_with ISO8859-1 "$TEST_DIRECTORY"/t3900/1-UTF-8.txt
-'
-
-for H in eucJP ISO-2022-JP
-do
- test_expect_success "$H should be shown in UTF-8 now" '
- compare_with '$H' "$TEST_DIRECTORY"/t3900/2-UTF-8.txt
- '
-done
-
-test_expect_success 'config to add customization' '
- git config --unset-all i18n.commitencoding &&
- if Z=$(git config --get-all i18n.commitencoding)
- then
- echo Oops, should have failed.
- false
- else
- test z = "z$Z"
- fi
-'
-
-for H in ISO8859-1 eucJP ISO-2022-JP
-do
- test_expect_success "$H should be shown in itself now" '
- git config i18n.commitencoding '$H' &&
- compare_with '$H' "$TEST_DIRECTORY"/t3900/'$H'.txt
- '
-done
-
-test_expect_success 'config to tweak customization' '
- git config i18n.logoutputencoding UTF-8
-'
-
-test_expect_success 'ISO8859-1 should be shown in UTF-8 now' '
- compare_with ISO8859-1 "$TEST_DIRECTORY"/t3900/1-UTF-8.txt
-'
-
-for H in eucJP ISO-2022-JP
-do
- test_expect_success "$H should be shown in UTF-8 now" '
- compare_with '$H' "$TEST_DIRECTORY"/t3900/2-UTF-8.txt
- '
-done
-
-for J in eucJP ISO-2022-JP
-do
- if test "$J" = ISO-2022-JP
- then
- ICONV=$J
- else
- ICONV=
- fi
- git config i18n.logoutputencoding $J
- for H in eucJP ISO-2022-JP
- do
- test_expect_success "$H should be shown in $J now" '
- compare_with '$H' "$TEST_DIRECTORY"/t3900/'$J'.txt $ICONV
- '
- done
-done
-
-for H in ISO8859-1 eucJP ISO-2022-JP
-do
- test_expect_success "No conversion with $H" '
- compare_with "--encoding=none '$H'" "$TEST_DIRECTORY"/t3900/'$H'.txt
- '
-done
-
-test_commit_autosquash_flags () {
- H=$1
- flag=$2
- test_expect_success "commit --$flag with $H encoding" '
- git config i18n.commitencoding $H &&
- git checkout -b $H-$flag C0 &&
- echo $H >>F &&
- git commit -a -F "$TEST_DIRECTORY"/t3900/$H.txt &&
- test_tick &&
- echo intermediate stuff >>G &&
- git add G &&
- git commit -a -m "intermediate commit" &&
- test_tick &&
- echo $H $flag >>F &&
- git commit -a --$flag HEAD~1 &&
- E=$(git cat-file commit '$H-$flag' |
- sed -ne "s/^encoding //p") &&
- test "z$E" = "z$H" &&
- git config --unset-all i18n.commitencoding &&
- git rebase --autosquash -i HEAD^^^ &&
- git log --oneline >actual &&
- test_line_count = 3 actual
- '
-}
-
-test_commit_autosquash_flags eucJP fixup
-
-test_commit_autosquash_flags ISO-2022-JP squash
-
test_done
--- git-2.14.1/t/t5100-mailinfo.sh.old 2017-08-09 14:54:31.000000000 -0500
+++ git-2.14.1/t/t5100-mailinfo.sh 2017-09-10 23:26:39.206126739 -0500
@@ -27,6 +27,7 @@
......
......@@ -3,13 +3,14 @@
# Contributor: zlg <zlg+adelie@zlg.space>
# Maintainer:
pkgname=cgit
pkgver=1.2.1
pkgrel=1
_gitver=2.18.0
pkgver=1.2.2
pkgrel=0
_gitver=2.25.0
pkgdesc="A fast Web interface for Git"
url="https://git.zx2c4.com/cgit/"
arch="all"
license="GPL-2.0-only"
depends=""
makedepends="openssl-dev zlib-dev lua5.3-libs lua5.3-dev asciidoctor gettext-tiny-dev"
subpackages="$pkgname-doc"
source="http://git.zx2c4.com/$pkgname/snapshot/$pkgname-$pkgver.tar.xz
......@@ -27,8 +28,6 @@ _makeopts="NO_CURL=1
prefix=/usr"
prepare() {
cd "$builddir"
# check that upstream git ver corresponds with ours
local _ver="$(awk -F'[ \t]*=[ \t]*' '/^GIT_VER/ { print $2 }' Makefile)"
if [ "$_ver" != "$_gitver" ]; then
......@@ -43,23 +42,20 @@ prepare() {
}
build() {
cd "$builddir"
sed -i -e 's:a2x -f:asciidoctor -b:' Makefile
make $_makeopts all doc-man
}
check() {
cd "$builddir"
make $_makeopts test
}
package() {
cd "$builddir"
make $_makeopts DESTDIR="$pkgdir" \
CGIT_SCRIPT_PATH=/usr/share/webapps/cgit \
install install-man
ln -s cgit.cgi "$pkgdir"/usr/share/webapps/cgit/cgit
}
sha512sums="c7380df9afbc3735ef9e4f196f4f5bbd26cf52e473fa6f435e7d0c00dc295cc8de6bee6bfb1857144025c8591d41a6a74efb1af551e8610848d90ac40fcfab36 cgit-1.2.1.tar.xz
db19363c9c2042248322d49874a27c0614acfb912183725e5d4f0331d6b44cef66a9a7da6a49bd4a17e5d86d30c5fed6bef7527f386494184595a433c4060e46 git-2.18.0.tar.xz"
sha512sums="ac006db0b14ae84fc9304b4cb1b49c3445d229593071be39b2d6e2709b54d03b11efd0ac1b5daef8160278303a7611c897fb6cf1e008c66c3f2463151e650af9 cgit-1.2.2.tar.xz
8bbada0451fe0a3314e1b9a43a74135115449aa41f5b3e7f960279e4a7fe6069c36e78825fc4b60d06806e3a6fa8158f327cb8a3801686ac22a35e3704244191 git-2.25.0.tar.xz"