initial import
This commit is contained in:
61
intltool/PKGBUILD
Normal file
61
intltool/PKGBUILD
Normal file
@@ -0,0 +1,61 @@
|
||||
# Maintainer: Jesus E. <heckyel@riseup.net>
|
||||
|
||||
pkgname=intltool
|
||||
pkgver=0.51.0
|
||||
_debver=0.51.0
|
||||
_debrel=5
|
||||
pkgrel=3
|
||||
pkgdesc="The internationalization tool collection"
|
||||
arch=('any')
|
||||
url="https://launchpad.net/intltool"
|
||||
license=('GPL-2')
|
||||
depends=('perl-xml-parser')
|
||||
makedepends=('quilt')
|
||||
source=(https://launchpad.net/intltool/trunk/${pkgver}/+download/${pkgname}-${pkgver}.tar.gz{,.asc}
|
||||
https://deb.debian.org/debian/pool/main/i/intltool/intltool_$_debver-$_debrel.debian.tar.xz
|
||||
intltool-0.51.0-perl-5.26.patch
|
||||
intltool-merge-Create-cache-file-atomically.patch
|
||||
intltool_distcheck-fix.patch)
|
||||
sha512sums=('4c93cb26592ed0b1622d3b7800b5d6622ffa36f58ac73f2ef0bddfab522565fdfb8fa73d81914b9a202f1d62bc995a08960f8adb9f62c86918e75498e85fbfdf'
|
||||
'SKIP'
|
||||
'b8783917774aa4e5276c44227823ac25790dcf566bb08db93be427b38abc8213a63ce1dd763ee3a7ea08aa928da805553e1d7b1b332e0dfa02044bbd844b7717'
|
||||
'338d203b290d4334477ac88991ff587b938f70415bbbc1d00bde9e0cf9c780f3e2c2e5ea9f4e49b973b9f0101ccf3bae5f769dd9543b603239171a62a2e04fd6'
|
||||
'5432474871b46da3675ba34da2822d5a46d35d99282eaacfb1574126bef5ded784be31e662d5e9ecfccf4fe77b7d4abec063e8df267b767036fdf25a35f9fc77'
|
||||
'75ebec0675e9321aaf2020f5cbf2feff6aac097cd45f1ceee6eec651f42e989cfda785d956a3ed34cdc4788f2dc02b02efaf46219af7a6a0a5050aa1022f7be1')
|
||||
validpgpkeys=('9EBD001680E8C8F9FAC61A9BE1A701D4C9DE75B5')
|
||||
|
||||
prepare() {
|
||||
cd ${pkgname}-${pkgver}
|
||||
if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
|
||||
# Debian patches
|
||||
export QUILT_PATCHES=debian/patches
|
||||
export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
|
||||
export QUILT_DIFF_ARGS='--no-timestamps'
|
||||
|
||||
mv "$srcdir"/debian .
|
||||
|
||||
quilt push -av
|
||||
else
|
||||
patch -Np1 -i ../intltool-0.51.0-perl-5.26.patch
|
||||
fi
|
||||
patch -Np1 -i ../intltool-merge-Create-cache-file-atomically.patch
|
||||
patch -Np1 -i ../intltool_distcheck-fix.patch
|
||||
}
|
||||
|
||||
build() {
|
||||
cd ${pkgname}-${pkgver}
|
||||
./configure --prefix=/usr
|
||||
make
|
||||
}
|
||||
|
||||
check() {
|
||||
cd ${pkgname}-${pkgver}
|
||||
make check
|
||||
}
|
||||
|
||||
package() {
|
||||
cd ${pkgname}-${pkgver}
|
||||
make DESTDIR="${pkgdir}" install
|
||||
install -D -m644 doc/I18N-HOWTO "${pkgdir}/usr/share/doc/${pkgname}/I18N-HOWTO"
|
||||
install -D -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
|
||||
}
|
||||
51
intltool/intltool-0.51.0-perl-5.26.patch
Normal file
51
intltool/intltool-0.51.0-perl-5.26.patch
Normal file
@@ -0,0 +1,51 @@
|
||||
diff -Naur intltool-0.51.0.orig/intltool-update.in intltool-0.51.0/intltool-update.in
|
||||
--- intltool-0.51.0.orig/intltool-update.in 2015-03-09 02:39:54.000000000 +0100
|
||||
+++ intltool-0.51.0/intltool-update.in 2017-07-21 22:35:10.613631420 +0200
|
||||
@@ -1062,13 +1062,13 @@
|
||||
}
|
||||
}
|
||||
|
||||
- if ($str =~ /^(.*)\${?([A-Z_]+)}?(.*)$/)
|
||||
+ if ($str =~ /^(.*)\$\{?([A-Z_]+)}?(.*)$/)
|
||||
{
|
||||
my $rest = $3;
|
||||
my $untouched = $1;
|
||||
my $sub = "";
|
||||
# Ignore recursive definitions of variables
|
||||
- $sub = $varhash{$2} if defined $varhash{$2} and $varhash{$2} !~ /\${?$2}?/;
|
||||
+ $sub = $varhash{$2} if defined $varhash{$2} and $varhash{$2} !~ /\$\{?$2}?/;
|
||||
|
||||
return SubstituteVariable ("$untouched$sub$rest");
|
||||
}
|
||||
@@ -1190,10 +1190,10 @@
|
||||
$name =~ s/\(+$//g;
|
||||
$version =~ s/\(+$//g;
|
||||
|
||||
- $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\${?AC_PACKAGE_NAME}?/);
|
||||
- $varhash{"PACKAGE"} = $name if (not $name =~ /\${?PACKAGE}?/);
|
||||
- $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\${?AC_PACKAGE_VERSION}?/);
|
||||
- $varhash{"VERSION"} = $version if (not $name =~ /\${?VERSION}?/);
|
||||
+ $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\$\{?AC_PACKAGE_NAME}?/);
|
||||
+ $varhash{"PACKAGE"} = $name if (not $name =~ /\$\{?PACKAGE}?/);
|
||||
+ $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\$\{?AC_PACKAGE_VERSION}?/);
|
||||
+ $varhash{"VERSION"} = $version if (not $name =~ /\$\{?VERSION}?/);
|
||||
}
|
||||
|
||||
if ($conf_source =~ /^AC_INIT\(([^,\)]+),([^,\)]+)[,]?([^,\)]+)?/m)
|
||||
@@ -1219,11 +1219,11 @@
|
||||
$version =~ s/\(+$//g;
|
||||
$bugurl =~ s/\(+$//g if (defined $bugurl);
|
||||
|
||||
- $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\${?AC_PACKAGE_NAME}?/);
|
||||
- $varhash{"PACKAGE"} = $name if (not $name =~ /\${?PACKAGE}?/);
|
||||
- $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\${?AC_PACKAGE_VERSION}?/);
|
||||
- $varhash{"VERSION"} = $version if (not $name =~ /\${?VERSION}?/);
|
||||
- $varhash{"PACKAGE_BUGREPORT"} = $bugurl if (defined $bugurl and not $bugurl =~ /\${?\w+}?/);
|
||||
+ $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\$\{?AC_PACKAGE_NAME}?/);
|
||||
+ $varhash{"PACKAGE"} = $name if (not $name =~ /\$\{?PACKAGE}?/);
|
||||
+ $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\$\{?AC_PACKAGE_VERSION}?/);
|
||||
+ $varhash{"VERSION"} = $version if (not $name =~ /\$\{?VERSION}?/);
|
||||
+ $varhash{"PACKAGE_BUGREPORT"} = $bugurl if (defined $bugurl and not $bugurl =~ /\$\{?\w+}?/);
|
||||
}
|
||||
|
||||
# \s makes this not work, why?
|
||||
38
intltool/intltool-merge-Create-cache-file-atomically.patch
Normal file
38
intltool/intltool-merge-Create-cache-file-atomically.patch
Normal file
@@ -0,0 +1,38 @@
|
||||
From d328542bea50b9445c63cdf2454052392282a1ce Mon Sep 17 00:00:00 2001
|
||||
From: Colin Walters <walters@verbum.org>
|
||||
Date: Thu, 8 Oct 2015 16:25:47 -0400
|
||||
Subject: [PATCH] intltool-merge: Create cache file atomically
|
||||
|
||||
It's going to be relatively common for build systems operating in
|
||||
parallel to run multiple copies of `intltool-merge`, yet the cache
|
||||
file is not created atomically (i.e. with the "open .tmp file and
|
||||
rename()" dance).
|
||||
|
||||
I suspect (but have not yet determined conclusively) this is the cause
|
||||
of some systemd build issues where translations don't appear in the
|
||||
merged file.
|
||||
|
||||
Regardless, this patch can't hurt.
|
||||
---
|
||||
intltool-merge.in | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/intltool-merge.in b/intltool-merge.in
|
||||
index 1afa2a4..d1eba8f 100644
|
||||
--- a/intltool-merge.in
|
||||
+++ b/intltool-merge.in
|
||||
@@ -371,9 +371,10 @@ sub create_cache
|
||||
|
||||
&create_translation_database;
|
||||
|
||||
- open CACHE, ">$cache_file" || die;
|
||||
+ open CACHE, ">$cache_file" . ".tmp" || die;
|
||||
print CACHE join "\x01", %translations;
|
||||
close CACHE;
|
||||
+ rename("$cache_file" . ".tmp", "$cache_file");
|
||||
}
|
||||
|
||||
sub load_cache
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
30
intltool/intltool_distcheck-fix.patch
Normal file
30
intltool/intltool_distcheck-fix.patch
Normal file
@@ -0,0 +1,30 @@
|
||||
diff -upr intltool-0.51.0-orig/intltool-update.in intltool-0.51.0/intltool-update.in
|
||||
--- intltool-0.51.0-orig/intltool-update.in 2016-07-29 14:08:06.276987000 +0200
|
||||
+++ intltool-0.51.0/intltool-update.in 2016-07-29 14:11:09.562126918 +0200
|
||||
@@ -620,6 +620,14 @@ sub FindLeftoutFiles
|
||||
|
||||
my @result;
|
||||
|
||||
+ # If the builddir is a subdir of srcdir, the list of files found will be prefixed with
|
||||
+ # an additional prefix (e.g. "_build/sub" for automake 1.15 make distcheck). Try to
|
||||
+ # handle that, by removing those matches as well.
|
||||
+ my $absbuilddir = Cwd::abs_path("..\/");
|
||||
+ my $abssrcdir = Cwd::abs_path("$SRCDIR/..");
|
||||
+ # Check if builddir is a subdir of srcdir
|
||||
+ my ($abspath,$relpath) = split /\s*$abssrcdir\/\s*/, $absbuilddir, 2;
|
||||
+
|
||||
foreach (@buf_allfiles_sorted)
|
||||
{
|
||||
my $dummy = $_;
|
||||
@@ -628,7 +636,10 @@ sub FindLeftoutFiles
|
||||
$srcdir =~ s#^../##;
|
||||
$dummy =~ s#^$srcdir/../##;
|
||||
$dummy =~ s#^$srcdir/##;
|
||||
- $dummy =~ s#_build/##;
|
||||
+ if ($relpath)
|
||||
+ {
|
||||
+ $dummy =~ s#^$relpath/##;
|
||||
+ }
|
||||
if (!exists($in2{$dummy}))
|
||||
{
|
||||
push @result, $dummy
|
||||
Reference in New Issue
Block a user