[arch-commits] Commit in fakeroot/repos (6 files)

Allan McRae allan at archlinux.org
Mon Feb 15 12:27:54 UTC 2021


    Date: Monday, February 15, 2021 @ 12:27:54
  Author: allan
Revision: 408165

archrelease: copy trunk to testing-x86_64

Added:
  fakeroot/repos/testing-x86_64/
  fakeroot/repos/testing-x86_64/PKGBUILD
    (from rev 408164, fakeroot/trunk/PKGBUILD)
  fakeroot/repos/testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-1.patch
    (from rev 408164, fakeroot/trunk/fakeroot-1.25.3-glibc-2.33-fix-1.patch)
  fakeroot/repos/testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-2.patch
    (from rev 408164, fakeroot/trunk/fakeroot-1.25.3-glibc-2.33-fix-2.patch)
  fakeroot/repos/testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-3.patch
    (from rev 408164, fakeroot/trunk/fakeroot-1.25.3-glibc-2.33-fix-3.patch)
  fakeroot/repos/testing-x86_64/fakeroot.install
    (from rev 408164, fakeroot/trunk/fakeroot.install)

----------------------------------------+
 PKGBUILD                               |   64 +++++++++++++++++++++++++++
 fakeroot-1.25.3-glibc-2.33-fix-1.patch |   37 +++++++++++++++
 fakeroot-1.25.3-glibc-2.33-fix-2.patch |   72 +++++++++++++++++++++++++++++++
 fakeroot-1.25.3-glibc-2.33-fix-3.patch |   60 +++++++++++++++++++++++++
 fakeroot.install                       |   14 ++++++
 5 files changed, 247 insertions(+)

Copied: fakeroot/repos/testing-x86_64/PKGBUILD (from rev 408164, fakeroot/trunk/PKGBUILD)
===================================================================
--- testing-x86_64/PKGBUILD	                        (rev 0)
+++ testing-x86_64/PKGBUILD	2021-02-15 12:27:54 UTC (rev 408165)
@@ -0,0 +1,64 @@
+# Maintainer:  Bartłomiej Piotrowski <bpiotrowski at archlinux.org>
+# Contributor: Allan McRae <allan at archlinux.org>
+# Contributor: Jochem Kossen <j.kossen at home.nl>
+
+pkgname=fakeroot
+pkgver=1.25.3
+pkgrel=2
+pkgdesc='Tool for simulating superuser privileges'
+arch=('x86_64')
+license=('GPL')
+url='https://tracker.debian.org/pkg/fakeroot'
+groups=('base-devel')
+install=fakeroot.install
+depends=('glibc' 'filesystem' 'sed' 'util-linux' 'sh')
+makedepends=('systemd' 'po4a')
+checkdepends=('sharutils')
+source=("https://deb.debian.org/debian/pool/main/f/$pkgname/${pkgname}_${pkgver}.orig.tar.gz"
+        fakeroot-1.25.3-glibc-2.33-fix-1.patch
+        fakeroot-1.25.3-glibc-2.33-fix-2.patch
+        fakeroot-1.25.3-glibc-2.33-fix-3.patch)
+sha256sums=('8e903683357f7f5bcc31b879fd743391ad47691d4be33d24a76be3b6c21e956c'
+            '7b1ea49a4123a6d95329b370cc9edb51dc0c292ee3eeaa034757b555607026ea'
+            '1d2b3c9de24a4249f71e4ed1465ccac462c4ae36bd0a72c796cbfc51fb88a5e6'
+            '669dc27fc4a63d265adffbd7fe04521d9e91f46fdba5465c55c6b2d281aae0dc')
+
+prepare() {
+  cd $pkgname-$pkgver
+
+  patch -p1 -i $srcdir/fakeroot-1.25.3-glibc-2.33-fix-1.patch
+  patch -p1 -i $srcdir/fakeroot-1.25.3-glibc-2.33-fix-2.patch
+  patch -p1 -i $srcdir/fakeroot-1.25.3-glibc-2.33-fix-3.patch
+
+  ./bootstrap
+}
+
+build() {
+  cd $pkgname-$pkgver
+
+  ./configure --prefix=/usr \
+    --libdir=/usr/lib/libfakeroot \
+    --disable-static \
+    --with-ipc=sysv
+
+  make
+
+  cd doc
+  po4a -k 0 --rm-backups --variable 'srcdir=../doc/' po4a/po4a.cfg
+}
+
+check() {
+  cd $pkgname-$pkgver
+  make check
+}
+
+package() {
+  cd $pkgname-$pkgver
+  make DESTDIR="$pkgdir" install
+
+  install -dm0755 "$pkgdir/etc/ld.so.conf.d/"
+  echo '/usr/lib/libfakeroot' > "$pkgdir/etc/ld.so.conf.d/fakeroot.conf"
+
+  # install README for sysv/tcp usage
+  install -Dm0644 README "$pkgdir/usr/share/doc/$pkgname/README"
+}

Copied: fakeroot/repos/testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-1.patch (from rev 408164, fakeroot/trunk/fakeroot-1.25.3-glibc-2.33-fix-1.patch)
===================================================================
--- testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-1.patch	                        (rev 0)
+++ testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-1.patch	2021-02-15 12:27:54 UTC (rev 408165)
@@ -0,0 +1,37 @@
+From 03bc0ee07fb6e293d081ffd8af1654788b434f6a Mon Sep 17 00:00:00 2001
+From: Ilya Lipnitskiy <ilya.lipnitskiy at gmail.com>
+Date: Thu, 11 Feb 2021 20:59:25 -0800
+Subject: [PATCH] libfakeroot.c: define _STAT_VER if not already defined
+
+Based on patch from Jan Pazdziora:
+https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/SMQ3RYXEYTVZH6PLQMKNB3NM4XLPMNZO/
+
+Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy at gmail.com>
+---
+ libfakeroot.c | 10 ++++++++++
+ 1 file changed, 10 insertions(+)
+
+diff --git a/libfakeroot.c b/libfakeroot.c
+index 3e80e38..14cdbc4 100644
+--- a/libfakeroot.c
++++ b/libfakeroot.c
+@@ -90,6 +90,16 @@
+ #define SEND_GET_XATTR64(a,b,c) send_get_xattr64(a,b)
+ #endif
+ 
++#ifndef _STAT_VER
++ #if defined (__aarch64__)
++  #define _STAT_VER 0
++ #elif defined (__x86_64__)
++  #define _STAT_VER 1
++ #else
++  #define _STAT_VER 3
++ #endif
++#endif
++
+ /*
+    These INT_* (which stands for internal) macros should always be used when
+    the fakeroot library owns the storage of the stat variable.
+-- 
+GitLab
+

Copied: fakeroot/repos/testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-2.patch (from rev 408164, fakeroot/trunk/fakeroot-1.25.3-glibc-2.33-fix-2.patch)
===================================================================
--- testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-2.patch	                        (rev 0)
+++ testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-2.patch	2021-02-15 12:27:54 UTC (rev 408165)
@@ -0,0 +1,72 @@
+From feda578ca3608b7fc9a28a3a91293611c0ef47b7 Mon Sep 17 00:00:00 2001
+From: Ilya Lipnitskiy <ilya.lipnitskiy at gmail.com>
+Date: Thu, 11 Feb 2021 21:00:04 -0800
+Subject: [PATCH] libfakeroot.c: add wrappers for new glibc 2.33+ symbols
+
+Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy at gmail.com>
+---
+ libfakeroot.c | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 48 insertions(+)
+
+diff --git a/libfakeroot.c b/libfakeroot.c
+index 14cdbc4..d75c51f 100644
+--- a/libfakeroot.c
++++ b/libfakeroot.c
+@@ -1352,6 +1352,54 @@ int renameat(int olddir_fd, const char *oldpath,
+ #endif /* HAVE_FSTATAT */
+ 
+ 
++#if defined(__GLIBC__) && __GLIBC_PREREQ(2,33)
++/* Glibc 2.33 exports symbols for these functions in the shared lib */
++  int lstat(const char *file_name, struct stat *statbuf) {
++     return WRAP_LSTAT LSTAT_ARG(_STAT_VER, file_name, statbuf);
++  }
++  int stat(const char *file_name, struct stat *st) {
++     return WRAP_STAT STAT_ARG(_STAT_VER, file_name, st);
++  }
++  int fstat(int fd, struct stat *st) {
++     return WRAP_FSTAT FSTAT_ARG(_STAT_VER, fd, st);
++  }
++
++  #ifdef HAVE_FSTATAT
++    int fstatat(int dir_fd, const char *path, struct stat *st, int flags) {
++       return WRAP_FSTATAT FSTATAT_ARG(_STAT_VER, dir_fd, path, st, flags);
++    }
++  #endif
++
++  #ifdef STAT64_SUPPORT
++    int lstat64(const char *file_name, struct stat64 *st) {
++       return WRAP_LSTAT64 LSTAT64_ARG(_STAT_VER, file_name, st);
++    }
++    int stat64(const char *file_name, struct stat64 *st) {
++       return WRAP_STAT64 STAT64_ARG(_STAT_VER, file_name, st);
++    }
++    int fstat64(int fd, struct stat64 *st) {
++       return WRAP_FSTAT64 FSTAT64_ARG(_STAT_VER, fd, st);
++    }
++
++    #ifdef HAVE_FSTATAT
++      int fstatat64(int dir_fd, const char *path, struct stat64 *st, int flags) {
++	 return WRAP_FSTATAT64 FSTATAT64_ARG(_STAT_VER, dir_fd, path, st, flags);
++      }
++    #endif
++  #endif
++
++  int mknod(const char *pathname, mode_t mode, dev_t dev) {
++     return WRAP_MKNOD MKNOD_ARG(_STAT_VER, pathname, mode, &dev);
++  }
++
++  #if defined(HAVE_FSTATAT) && defined(HAVE_MKNODAT)
++    int mknodat(int dir_fd, const char *pathname, mode_t mode, dev_t dev) {
++       return WRAP_MKNODAT MKNODAT_ARG(_STAT_VER, dir_fd, pathname, mode, &dev);
++    }
++  #endif
++#endif /* GLIBC_PREREQ */
++
++
+ #ifdef FAKEROOT_FAKENET
+ pid_t fork(void)
+ {
+-- 
+GitLab
+

Copied: fakeroot/repos/testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-3.patch (from rev 408164, fakeroot/trunk/fakeroot-1.25.3-glibc-2.33-fix-3.patch)
===================================================================
--- testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-3.patch	                        (rev 0)
+++ testing-x86_64/fakeroot-1.25.3-glibc-2.33-fix-3.patch	2021-02-15 12:27:54 UTC (rev 408165)
@@ -0,0 +1,60 @@
+From c3eebec293e35b997bb46c22fb5a4e114afb5e7f Mon Sep 17 00:00:00 2001
+From: Ilya Lipnitskiy <ilya.lipnitskiy at gmail.com>
+Date: Sat, 13 Feb 2021 19:32:08 -0800
+Subject: [PATCH] configure.ac: fix __xmknod{,at} pointer argument
+
+Switch default to assume * and not the absence of *.
+
+On glibc 2.33+, there is no definition for these functions in header
+files, so the compile test doesn't work. But, we can default to using
+the pointer (as is the case with newer glibc), and use the header file
+on older platforms to fail the test and use no pointer.
+
+Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy at gmail.com>
+---
+ configure.ac | 16 ++++++++--------
+ 1 file changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 73415d2..d85566f 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -183,13 +183,13 @@ AC_MSG_CHECKING([for type of arg of __xmknod])
+   ]], [[
+        int __xmknod  ( int ver,
+                        const char *pathname ,
+-                       mode_t  mode ,  dev_t dev);
++                       mode_t  mode ,  dev_t *dev);
+   ]])],[
+-   AC_DEFINE(XMKNOD_FRTH_ARG,)
+-   AC_MSG_RESULT([no extra *])
+-  ],[
+    AC_DEFINE(XMKNOD_FRTH_ARG,[*])
+    AC_MSG_RESULT([needs *])
++  ],[
++   AC_DEFINE(XMKNOD_FRTH_ARG,)
++   AC_MSG_RESULT([no extra *])
+ 
+   ])
+ 
+@@ -210,13 +210,13 @@ AC_MSG_CHECKING([for type of arg of __xmknodat])
+        int __xmknodat  ( int ver,
+                          int dirfd,
+                          const char *pathname ,
+-                         mode_t  mode ,  dev_t dev);
++                         mode_t  mode ,  dev_t *dev);
+   ]])],[
+-   AC_DEFINE(XMKNODAT_FIFTH_ARG,)
+-   AC_MSG_RESULT([no extra *])
+-  ],[
+    AC_DEFINE(XMKNODAT_FIFTH_ARG,[*])
+    AC_MSG_RESULT([needs *])
++  ],[
++   AC_DEFINE(XMKNODAT_FIFTH_ARG,)
++   AC_MSG_RESULT([no extra *])
+ 
+   ])
+ 
+-- 
+GitLab
+

Copied: fakeroot/repos/testing-x86_64/fakeroot.install (from rev 408164, fakeroot/trunk/fakeroot.install)
===================================================================
--- testing-x86_64/fakeroot.install	                        (rev 0)
+++ testing-x86_64/fakeroot.install	2021-02-15 12:27:54 UTC (rev 408165)
@@ -0,0 +1,14 @@
+post_install() {
+  usr/bin/ldconfig -r .
+}
+
+post_upgrade() {
+  if [ "$(vercmp $2 1.14.4-2)" -lt 0 ]; then
+    sed -i -e '/\/usr\/lib\/libfakeroot/d' etc/ld.so.conf
+  fi
+  usr/bin/ldconfig -r .
+}
+
+pre_remove() {
+  usr/bin/ldconfig -r .
+}


More information about the arch-commits mailing list