Commit 2f0a92c5 authored by Leo's avatar Leo Committed by Natanael Copa

main/attr: upgrade to 2.4.48

parent 9b669086
# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=attr
pkgver=2.4.47
pkgrel=7
pkgver=2.4.48
pkgrel=0
pkgdesc="Utilities for managing filesystem extended attributes"
options="checkroot !check" # attr.test fails with no error message
url="https://savannah.nongnu.org/projects/attr"
arch="all"
license="GPL-2.0-or-later LGPL-2.0-or-later"
depends=""
makedepends="libtool autoconf automake bash"
subpackages="$pkgname-dev $pkgname-doc libattr"
source="http://download.savannah.nongnu.org/releases/attr/attr-$pkgver.src.tar.gz
fix-decls.patch
fix-throw.patch
busybox-gzip.patch
license="GPL-2.0-or-later"
checkdepends="perl"
subpackages="$pkgname-dev $pkgname-doc lib$pkgname:libs"
source="https://download.savannah.nongnu.org/releases/attr/attr-$pkgver.tar.gz
fix-tests.patch
"
prepare() {
cd "$srcdir"/attr-$pkgver
update_config_sub || return 1
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
sed -i -e '/HAVE_ZIPPED_MANPAGES/s:=.*:=false:' \
include/builddefs.in
}
build() {
cd "$srcdir"/attr-$pkgver
OPTIMIZER="${CFLAGS}" DEBUG=-DNDEBUG INSTALL_USER=root INSTALL_GROUP=root ./configure \
OPTIMIZER="${CFLAGS}" \
DEBUG=-DNDEBUG \
INSTALL_USER=root \
INSTALL_GROUP=root \
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/ \
......@@ -42,31 +30,33 @@ build() {
--libexecdir=/usr/lib \
--includedir=/usr/include \
--mandir=/usr/share/man \
--docdir=/usr/share/doc \
--datadir=/usr/share \
--disable-gettext \
|| return 1
make || return 1
--disable-nls \
--disable-static
make
}
check() {
make check
}
package() {
cd "$srcdir"/attr-$pkgver
make -j1 DESTDIR="$pkgdir" \
install install-lib install-dev || return 1
make DESTDIR="$pkgdir" install
mkdir -p "$pkgdir"/usr/lib
mv "$pkgdir"/lib/pkgconfig "$pkgdir"/usr/lib
}
# provided by man-pages
rm -r "$pkgdir"/usr/share/man/man2 \
"$pkgdir"/usr/share/man/man5/attr.5 \
|| return 1
dev() {
license="LGPL-2.1-or-later"
default_dev
}
libattr() {
pkgdesc="Dynamic library for extended attribute support"
replaces="attr"
mkdir -p "$subpkgdir"/lib
mv "$pkgdir"/lib/lib*.so.* "$subpkgdir"/lib/
libs() {
license="LGPL-2.1-or-later"
default_libs
}
sha512sums="2a333f63655758298650cf8f89c175efdc0112dcc4013e8d023e2a9a69f177e4bcb1f1d10b6666d6f2027dca4dec0833d54749952ab153d28367e1a72e6e2831 attr-2.4.47.src.tar.gz
fa7925f63c611e39b28adbf8fa3838bd91c245e4694957c1a8e212cb8f289eb62e04f50806227f6c1947d432ddf7633a471c13dd08d513d1e2b8a9ac1906cb33 fix-decls.patch
d758b864bac9bdbc3360df2e7a3bc7d04e06789975cf539b8e2b98b1d874744b55c80f0502e283f7233d6ec41f8a39624fe07b512a7fdc6af8d19dd3af5f9f5a fix-throw.patch
c04f3f38eafaa1afbafdf99751cdf1770e81182ebdc20f3cbea81d44638f7100c5c9963c42342c618286f25c435a82fcbcd3dea635725042edd36c6a3a02960c busybox-gzip.patch"
sha512sums="75f870a0e6e19b8975f3fdceee786fbaff3eadaa9ab9af01996ffa8e50fe5b2bba6e4c22c44a6722d11b55feb9e89895d0151d6811c1d2b475ef4ed145f0c923 attr-2.4.48.tar.gz
2ff96b8822c4344035eef6e2edc632e9b7381876cbc2c7e0931dfb43af3b9383c0066f9b9d125c53e030a6bf542dc5ae988610bda250a261a39ee211f6208cf2 fix-tests.patch"
diff --git a/doc/Makefile b/doc/Makefile
index c10ced6..524b5a2 100644
--- a/doc/Makefile
+++ b/doc/Makefile
@@ -28,7 +28,7 @@ default: $(SUBDIRS) CHANGES.gz
include $(BUILDRULES)
CHANGES.gz:
- $(ZIP) --best -c < CHANGES > $@
+ $(ZIP) -c < CHANGES > $@
install: default
$(SUBDIRS_MAKERULE)
diff --git a/include/buildmacros b/include/buildmacros
index 9e81bb8..b33e148 100644
--- a/include/buildmacros
+++ b/include/buildmacros
@@ -139,7 +139,7 @@ endif
MAN_MAKERULE = \
@for f in *.[12345678] ""; do \
if test ! -z "$$f"; then \
- $(ZIP) --best -c < $$f > $$f.gz; \
+ $(ZIP) -c < $$f > $$f.gz; \
fi; \
done
From 667137acaffb8d0cc62b47821a67a52ba0637d5c Mon Sep 17 00:00:00 2001
From: Mike Frysinger <vapier@gentoo.org>
Date: Fri, 10 Jan 2014 13:56:37 +0000
Subject: avoid glibc-specific DECLS defines
This matches what we do in all the other headers.
---
diff --git a/include/xattr.h b/include/xattr.h
index 70a84be..070d7c5 100644
--- a/include/xattr.h
+++ b/include/xattr.h
@@ -30,8 +30,9 @@
#define XATTR_CREATE 0x1 /* set value, fail if attr already exists */
#define XATTR_REPLACE 0x2 /* set value, fail if attr does not exist */
-
-__BEGIN_DECLS
+#ifdef __cplusplus
+extern "C" {
+#endif
extern int setxattr (const char *__path, const char *__name,
const void *__value, size_t __size, int __flags) __THROW;
@@ -58,6 +59,8 @@ extern int removexattr (const char *__path, const char *__name) __THROW;
extern int lremovexattr (const char *__path, const char *__name) __THROW;
extern int fremovexattr (int __filedes, const char *__name) __THROW;
-__END_DECLS
+#ifdef __cplusplus
+}
+#endif
#endif /* __XATTR_H__ */
--
cgit v0.9.0.2
diff --git a/test/run b/test/run
index 4b1f8d0..07e916c 100755
--- a/test/run
+++ b/test/run
@@ -106,7 +106,7 @@ for (;;) {
if (defined $line) {
# Substitute %VAR and %{VAR} with environment variables.
$line =~ s[%(\w+)][$ENV{$1}]eg;
- $line =~ s[%{(\w+)}][$ENV{$1}]eg;
+ $line =~ s[%\{(\w+)}][$ENV{$1}]eg;
}
if (defined $line) {
if ($line =~ s/^\s*< ?//) {
From 92247401984dd9a80d9d0c8c030692323f980678 Mon Sep 17 00:00:00 2001
From: Emmanuel Dreyfus <manu@netbsd.org>
Date: Mon, 30 Jun 2014 13:06:05 +0000
Subject: Portability fixes
- <features.h> is Linux specific
- Define __THROW for non glibc based systems
---
diff --git a/include/xattr.h b/include/xattr.h
index 070d7c5..fd1f268 100644
--- a/include/xattr.h
+++ b/include/xattr.h
@@ -20,7 +20,18 @@
#ifndef __XATTR_H__
#define __XATTR_H__
+#if defined(linux)
#include <features.h>
+#endif
+
+/* Portability non glibc c++ build systems */
+#ifndef __THROW
+# if defined __cplusplus
+# define __THROW throw ()
+# else
+# define __THROW
+# endif
+#endif
#include <errno.h>
#ifndef ENOATTR
--
cgit v0.9.0.2
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment