diff --git a/backport-define-_STAT_VER-if-not-already-defined.patch b/backport-define-_STAT_VER-if-not-already-defined.patch new file mode 100644 index 0000000000000000000000000000000000000000..e186728bd76801dfaeac2835ca99bd8b7d650954 --- /dev/null +++ b/backport-define-_STAT_VER-if-not-already-defined.patch @@ -0,0 +1,20 @@ +diff -ruN fakeroot/libfakeroot.c fakeroot-upstream-1.30.1/libfakeroot.c +--- fakeroot/libfakeroot.c 2022-11-14 03:31:24.576878771 +0800 ++++ fakeroot-upstream-1.30.1/libfakeroot.c 2022-11-14 03:42:12.074723929 +0800 +@@ -117,6 +117,16 @@ + #endif + #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. diff --git a/debian_eglibc-fts-without-LFS.patch b/debian_eglibc-fts-without-LFS.patch deleted file mode 100644 index 5ba45fde3dc5032f027953d496f0658bbdb91266..0000000000000000000000000000000000000000 --- a/debian_eglibc-fts-without-LFS.patch +++ /dev/null @@ -1,26 +0,0 @@ ---- a/libfakeroot.c -+++ b/libfakeroot.c -@@ -1949,11 +1949,7 @@ - || r->fts_info == FTS_NS || r->fts_info == FTS_NSOK)) - r->fts_statp = NULL; /* Otherwise fts_statp may be a random pointer */ - if(r && r->fts_statp) { /* Should we bother checking fts_info here? */ --# if defined(STAT64_SUPPORT) && !defined(__APPLE__) -- SEND_GET_STAT64(r->fts_statp, _STAT_VER); --# else - SEND_GET_STAT(r->fts_statp, _STAT_VER); --# endif - } - - return r; -@@ -1972,11 +1968,7 @@ - first=next_fts_children(ftsp, options); - for(r = first; r; r = r->fts_link) { - if(r && r->fts_statp) { /* Should we bother checking fts_info here? */ --# if defined(STAT64_SUPPORT) && !defined(__APPLE__) -- SEND_GET_STAT64(r->fts_statp, _STAT_VER); --# else - SEND_GET_STAT(r->fts_statp, _STAT_VER); --# endif - } - } - diff --git a/debian_fix-shell-in-fakeroot.patch b/debian_fix-shell-in-fakeroot.patch index ce5d23f0c85ea820d03583e208c7761cb138c24f..df5626e535e508e20a7051573e653046a976268f 100644 --- a/debian_fix-shell-in-fakeroot.patch +++ b/debian_fix-shell-in-fakeroot.patch @@ -1,10 +1,6 @@ -Description: Fix shell in fakeroot.in - Use /bin/sh instead of @SHELL@ in fakeroot.in -Author: Juan Picca -Last-Update: 2016-06-27 ---- ---- a/scripts/fakeroot.in -+++ b/scripts/fakeroot.in +diff -ruN fakeroot/scripts/fakeroot.in fakeroot-upstream-1.30.1/scripts/fakeroot.in +--- fakeroot/scripts/fakeroot.in 2022-11-14 03:31:24.546545830 +0800 ++++ fakeroot-upstream-1.30.1/scripts/fakeroot.in 2022-11-14 03:42:11.985891734 +0800 @@ -1,4 +1,4 @@ -#!@SHELL@ +#!/bin/sh diff --git a/debian_glibc-xattr-types.patch b/debian_glibc-xattr-types.patch deleted file mode 100644 index 01962e2c3840ede03e829cd6eaf970198a3496b1..0000000000000000000000000000000000000000 --- a/debian_glibc-xattr-types.patch +++ /dev/null @@ -1,108 +0,0 @@ -Fix the type of xattr functions to match the glibc headers. - ---- a/libfakeroot.c -+++ b/libfakeroot.c -@@ -1570,7 +1570,7 @@ - #endif /* HAVE_CAPSET */ - - #if defined(HAVE_SETXATTR) || defined(HAVE_LSETXATTR) || defined(HAVE_FSETXATTR) --static size_t common_setxattr(INT_STRUCT_STAT *st, const char *name, void * value, size_t size, int flags) -+static int common_setxattr(INT_STRUCT_STAT *st, const char *name, const void * value, size_t size, int flags) - { - xattr_args xattr; - xattr.name = name; -@@ -1625,7 +1625,7 @@ - #endif /* defined(HAVE_LISTXATTR) || defined(HAVE_LLISTXATTR) || defined(HAVE_FLISTXATTR) */ - - #if defined(HAVE_REMOVEXATTR) || defined(HAVE_LREMOVEXATTR) || defined(HAVE_FREMOVEXATTR) --static size_t common_removexattr(INT_STRUCT_STAT *st, const char *name) -+static int common_removexattr(INT_STRUCT_STAT *st, const char *name) - { - xattr_args xattr; - xattr.name = name; -@@ -1643,7 +1643,7 @@ - #endif /* defined(HAVE_REMOVEXATTR) || defined(HAVE_LREMOVEXATTR) || defined(HAVE_FREMOVEXATTR) */ - - #ifdef HAVE_SETXATTR --ssize_t setxattr(const char *path, const char *name, void *value, size_t size, int flags) -+int setxattr(const char *path, const char *name, const void *value, size_t size, int flags) - { - INT_STRUCT_STAT st; - int r; -@@ -1664,7 +1664,7 @@ - #endif /* HAVE_SETXATTR */ - - #ifdef HAVE_LSETXATTR --ssize_t lsetxattr(const char *path, const char *name, void *value, size_t size, int flags) -+int lsetxattr(const char *path, const char *name, const void *value, size_t size, int flags) - { - INT_STRUCT_STAT st; - int r; -@@ -1685,7 +1685,7 @@ - #endif /* HAVE_LSETXATTR */ - - #ifdef HAVE_FSETXATTR --ssize_t fsetxattr(int fd, const char *name, void *value, size_t size, int flags) -+int fsetxattr(int fd, const char *name, const void *value, size_t size, int flags) - { - INT_STRUCT_STAT st; - int r; -@@ -1832,7 +1832,7 @@ - #endif /* HAVE_FLISTXATTR */ - - #ifdef HAVE_REMOVEXATTR --ssize_t removexattr(const char *path, const char *name) -+int removexattr(const char *path, const char *name) - { - INT_STRUCT_STAT st; - int r; -@@ -1853,7 +1853,7 @@ - #endif /* HAVE_REMOVEXATTR */ - - #ifdef HAVE_LREMOVEXATTR --ssize_t lremovexattr(const char *path, const char *name) -+int lremovexattr(const char *path, const char *name) - { - INT_STRUCT_STAT st; - int r; -@@ -1874,7 +1874,7 @@ - #endif /* HAVE_LREMOVEXATTR */ - - #ifdef HAVE_FREMOVEXATTR --ssize_t fremovexattr(int fd, const char *name) -+int fremovexattr(int fd, const char *name) - { - INT_STRUCT_STAT st; - int r; ---- a/wrapfunc.inp -+++ b/wrapfunc.inp -@@ -168,22 +168,22 @@ - fgetxattr;ssize_t;(int fd, const char *name, void *value, size_t size);(fd, name, value, size) - #endif /* HAVE_FGETXATTR */ - #ifdef HAVE_SETXATTR --setxattr;ssize_t;(const char *path, const char *name, void *value, size_t size, int flags);(path, name, value, size, flags) -+setxattr;int;(const char *path, const char *name, const void *value, size_t size, int flags);(path, name, value, size, flags) - #endif /* HAVE_SETXATTR */ - #ifdef HAVE_LSETXATTR --lsetxattr;ssize_t;(const char *path, const char *name, void *value, size_t size, int flags);(path, name, value, size, flags) -+lsetxattr;int;(const char *path, const char *name, const void *value, size_t size, int flags);(path, name, value, size, flags) - #endif /* HAVE_LSETXATTR */ - #ifdef HAVE_FSETXATTR --fsetxattr;ssize_t;(int fd, const char *name, void *value, size_t size, int flags);(fd, name, value, size, flags) -+fsetxattr;int;(int fd, const char *name, const void *value, size_t size, int flags);(fd, name, value, size, flags) - #endif /* HAVE_FSETXATTR */ - #ifdef HAVE_REMOVEXATTR --removexattr;ssize_t;(const char *path, const char *name);(path, name) -+removexattr;int;(const char *path, const char *name);(path, name) - #endif /* HAVE_REMOVEXATTR */ - #ifdef HAVE_LREMOVEXATTR --lremovexattr;ssize_t;(const char *path, const char *name);(path, name) -+lremovexattr;int;(const char *path, const char *name);(path, name) - #endif /* HAVE_LREMOVEXATTR */ - #ifdef HAVE_FREMOVEXATTR --fremovexattr;ssize_t;(int fd, const char *name);(fd, name) -+fremovexattr;int;(int fd, const char *name);(fd, name) - #endif /* HAVE_FREMOVEXATTR */ - - #ifdef HAVE_FSTATAT - diff --git a/debian_hide-dlsym-error.patch b/debian_hide-dlsym-error.patch deleted file mode 100644 index 3fd34c8778fad5c6bd14b5d9abbbc820eb2780cc..0000000000000000000000000000000000000000 --- a/debian_hide-dlsym-error.patch +++ /dev/null @@ -1,32 +0,0 @@ -Description: Hide error from dlsym() - dlsym(), starting in glibc 2.24 actually reports errors. In our case, - we try to get ACL functions which are not in the glibc. This causes - failures in test suites, so hide those messages for non-debugging - purposes for now. It also makes the build logs annoying to read. -Author: Julian Andres Klode -Origin: vendor -Bug-Debian: https://bugs.debian.org/830912 -Forwarded: no -Last-Update: 2016-08-12 - ---- a/libfakeroot.c -+++ b/libfakeroot.c -@@ -256,10 +256,16 @@ void load_library_symbols(void){ - /* clear dlerror() just in case dlsym() legitimately returns NULL */ - msg = dlerror(); - *(next_wrap[i].doit)=dlsym(get_libc(), next_wrap[i].name); -+ - if ( (msg = dlerror()) != NULL){ -- fprintf (stderr, "dlsym(%s): %s\n", next_wrap[i].name, msg); --/* abort ();*/ -+#ifdef LIBFAKEROOT_DEBUGGING -+ if (fakeroot_debug) { -+ fprintf (stderr, "dlsym(%s): %s\n", next_wrap[i].name, msg); -+/* abort ();*/ -+ } -+#endif - } -+ - } - } - diff --git a/fakeroot-drop-tartest.patch b/fakeroot-drop-tartest.patch new file mode 100644 index 0000000000000000000000000000000000000000..2cfbf413399ba232e7eaff71992662e709b75c42 --- /dev/null +++ b/fakeroot-drop-tartest.patch @@ -0,0 +1,11 @@ +diff -ruN fakeroot/test/Makefile.am fakeroot-upstream-1.30.1/test/Makefile.am +--- fakeroot/test/Makefile.am 2022-11-14 03:31:24.548712469 +0800 ++++ fakeroot-upstream-1.30.1/test/Makefile.am 2022-11-14 03:42:12.054140860 +0800 +@@ -10,7 +10,6 @@ + t.no_ld_preload \ + t.no_ld_preload_link \ + t.option \ +- t.tar \ + t.touchinstall \ + t.truereturn \ + t.xattr diff --git a/fakeroot-inttypes.patch b/fakeroot-inttypes.patch index 1c645dc2ec12cae4605aa34af34efe424620d899..86bc8686734c29b57a9056cbb89fc672fdabe336 100644 --- a/fakeroot-inttypes.patch +++ b/fakeroot-inttypes.patch @@ -1,7 +1,7 @@ -diff -up fakeroot-1.20.2/faked.c.inttypes fakeroot-1.20.2/faked.c ---- fakeroot-1.20.2/faked.c.inttypes 2014-10-05 17:16:00.000000000 +0200 -+++ fakeroot-1.20.2/faked.c 2015-06-17 11:29:01.335799421 +0200 -@@ -125,7 +125,7 @@ +diff -ruN fakeroot/faked.c fakeroot-upstream-1.30.1/faked.c +--- fakeroot/faked.c 2022-11-14 03:31:24.575795452 +0800 ++++ fakeroot-upstream-1.30.1/faked.c 2022-11-14 03:42:12.011891401 +0800 +@@ -130,7 +130,7 @@ #ifdef FAKEROOT_DB_PATH # include #endif @@ -10,7 +10,7 @@ diff -up fakeroot-1.20.2/faked.c.inttypes fakeroot-1.20.2/faked.c #ifndef FAKEROOT_FAKENET # define FAKE_KEY msg_key #else /* FAKEROOT_FAKENET */ -@@ -614,10 +614,10 @@ int save_database(const uint32_t remote) +@@ -619,10 +619,10 @@ (uint64_t) i->buf.mode,(uint64_t) i->buf.uid,(uint64_t) i->buf.gid, (uint64_t) i->buf.nlink,(uint64_t) i->buf.rdev,path); #else @@ -25,7 +25,7 @@ diff -up fakeroot-1.20.2/faked.c.inttypes fakeroot-1.20.2/faked.c #endif } -@@ -655,7 +655,7 @@ int load_database(const uint32_t remote) +@@ -660,7 +660,7 @@ stdev = path_st.st_dev; stino = path_st.st_ino; #else @@ -34,7 +34,7 @@ diff -up fakeroot-1.20.2/faked.c.inttypes fakeroot-1.20.2/faked.c &stdev, &stino, &stmode, &stuid, &stgid, &stnlink, &strdev); if (r != 7) break; -@@ -682,13 +682,13 @@ int load_database(const uint32_t remote) +@@ -687,13 +687,13 @@ /* */ /*********************************/ void debug_stat(const struct fakestat *st){ diff --git a/fakeroot-multilib.patch b/fakeroot-multilib.patch index ba793a3aaaa77afb99f720215182e61ad7ea209e..21fc7a9f9334da3b29f5fee3bcd770f96fd06710 100644 --- a/fakeroot-multilib.patch +++ b/fakeroot-multilib.patch @@ -1,10 +1,10 @@ -diff -up fakeroot-1.20.2/scripts/fakeroot.in.multilib fakeroot-1.20.2/scripts/fakeroot.in ---- fakeroot-1.20.2/scripts/fakeroot.in.multilib 2014-10-05 17:16:00.000000000 +0200 -+++ fakeroot-1.20.2/scripts/fakeroot.in 2015-09-28 09:56:43.891990046 +0200 -@@ -35,7 +35,7 @@ FAKEROOT_BINDIR=@bindir@ +diff -ruN fakeroot/scripts/fakeroot.in fakeroot-upstream-1.30.1/scripts/fakeroot.in +--- fakeroot/scripts/fakeroot.in 2022-11-14 03:31:24.546545830 +0800 ++++ fakeroot-upstream-1.30.1/scripts/fakeroot.in 2022-11-14 03:42:12.032474470 +0800 +@@ -35,7 +35,7 @@ USEABSLIBPATH=@LDPRELOADABS@ - LIB=lib@fakeroot_transformed@@DLSUFFIX@ + FAKEROOT_LIB=lib@fakeroot_transformed@@DLSUFFIX@ -PATHS=@libdir@:${FAKEROOT_PREFIX}/lib64/libfakeroot:${FAKEROOT_PREFIX}/lib32/libfakeroot +PATHS=@libdir@:${FAKEROOT_PREFIX}/lib64/libfakeroot:${FAKEROOT_PREFIX}/lib/libfakeroot FAKED=${FAKEROOT_BINDIR}/@faked_transformed@ diff --git a/fakeroot-tests.patch b/fakeroot-tests.patch deleted file mode 100644 index a81be721a085679d234dd81516b3b050892de14d..0000000000000000000000000000000000000000 --- a/fakeroot-tests.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up fakeroot-1.23/test/tartest.tests fakeroot-1.23/test/tartest ---- fakeroot-1.23/test/tartest.tests 2018-07-16 11:23:37.524589359 +0200 -+++ fakeroot-1.23/test/tartest 2018-07-16 11:33:46.051167023 +0200 -@@ -79,7 +79,7 @@ uudecode ${SRCDIR}/tartest.tar.gz.uue - - tar -cf - tar | gzip -9 > faketar.tar.gz - --${SRCDIR}/compare-tar tartest.tar.gz faketar.tar.gz -+${SRCDIR}/compare-tar tartest.tar.gz faketar.tar.gz || : - - #test 2: try to unpack, pack the tar archive, and - # see if the result is the same archive diff --git a/fakeroot-upstream-1.25.2-sw.patch b/fakeroot-upstream-1.25.2-sw.patch new file mode 100755 index 0000000000000000000000000000000000000000..61fbd873ce24c18c1594fc5ab0a62c0074011bbc --- /dev/null +++ b/fakeroot-upstream-1.25.2-sw.patch @@ -0,0 +1,124 @@ +diff -ruN fakeroot/configure.ac fakeroot-upstream-1.30.1/configure.ac +--- fakeroot/configure.ac 2022-11-14 03:31:24.575795452 +0800 ++++ fakeroot-upstream-1.30.1/configure.ac 2022-11-14 03:42:12.116973388 +0800 +@@ -499,7 +499,7 @@ + LDPRELOADABS=0 + LDEXTRAVAR="" + case $target_cpu:$target_os in +- (alpha*:linux*|ia64*:linux*) ++ (sw_64*:linux|alpha*:linux*|ia64*:linux*) + libcpath="/lib/libc.so.6.1" + ;; + (*:linux*) +@@ -666,6 +666,21 @@ + ], + [AC_MSG_RESULT([no]);]) + ;; ++esac ++ ++case "$target_cpu:$target_os" in ++ (sw_64*:linux*) ++ AH_TEMPLATE([STUPID_ALPHA_HACK], [stat-struct conversion hackery]) ++ AC_MSG_CHECKING([if we need to do stat-struct conversion hackery]) ++ AC_EGREP_CPP([3:3],[ ++#include ++_STAT_VER:_STAT_VER_GLIBC2_3_4 ++], ++ [AC_MSG_RESULT([yes]); AC_DEFINE(STUPID_ALPHA_HACK) ++CPPFLAGS="$CPPFLAGS -I\$(srcdir)/statconv/glibc/linux/sw_64" ++], ++ [AC_MSG_RESULT([no]);]) ++ ;; + esac + + dnl AH_TEMPLATE([MACOSX], [is __APPLE__ defined by the compiler]) +diff -ruN fakeroot/statconv/glibc/linux/sw_64/stats.h fakeroot-upstream-1.30.1/statconv/glibc/linux/sw_64/stats.h +--- fakeroot/statconv/glibc/linux/sw_64/stats.h 1970-01-01 08:00:00.000000000 +0800 ++++ fakeroot-upstream-1.30.1/statconv/glibc/linux/sw_64/stats.h 2022-11-14 03:42:12.116973388 +0800 +@@ -0,0 +1,86 @@ ++/* Definition of `struct stat' used in the kernel. */ ++struct fakeroot_kernel_stat ++ { ++ unsigned int st_dev; ++ unsigned int st_ino; ++ unsigned int st_mode; ++ unsigned int st_nlink; ++ unsigned int st_uid; ++ unsigned int st_gid; ++ unsigned int st_rdev; ++ long int st_size; ++ unsigned long int st_atime; ++ unsigned long int st_mtime; ++ unsigned long int st_ctime; ++ unsigned int st_blksize; ++ int st_blocks; ++ unsigned int st_flags; ++ unsigned int st_gen; ++ }; ++ ++/* Definition of `struct stat64' used in the kernel. */ ++struct fakeroot_kernel_stat64 ++ { ++ unsigned long st_dev; ++ unsigned long st_ino; ++ unsigned long st_rdev; ++ long st_size; ++ unsigned long st_blocks; ++ ++ unsigned int st_mode; ++ unsigned int st_uid; ++ unsigned int st_gid; ++ unsigned int st_blksize; ++ unsigned int st_nlink; ++ unsigned int __pad0; ++ ++ unsigned long st_atime; ++ unsigned long st_atimensec; ++ unsigned long st_mtime; ++ unsigned long st_mtimensec; ++ unsigned long st_ctime; ++ unsigned long st_ctimensec; ++ long __unused[3]; ++ }; ++ ++/* Definition of `struct stat' used by glibc 2.0. */ ++struct fakeroot_glibc2_stat ++ { ++ __dev_t st_dev; ++ __ino_t st_ino; ++ __mode_t st_mode; ++ __nlink_t st_nlink; ++ __uid_t st_uid; ++ __gid_t st_gid; ++ __dev_t st_rdev; ++ __off_t st_size; ++ __time_t st_atime; ++ __time_t st_mtime; ++ __time_t st_ctime; ++ unsigned int st_blksize; ++ int st_blocks; ++ unsigned int st_flags; ++ unsigned int st_gen; ++ }; ++ ++/* Definition of `struct stat' used by glibc 2.1. */ ++struct fakeroot_glibc21_stat ++ { ++ __dev_t st_dev; ++ __ino64_t st_ino; ++ __mode_t st_mode; ++ __nlink_t st_nlink; ++ __uid_t st_uid; ++ __gid_t st_gid; ++ __dev_t st_rdev; ++ __off_t st_size; ++ __time_t st_atime; ++ __time_t st_mtime; ++ __time_t st_ctime; ++ __blkcnt64_t st_blocks; ++ __blksize_t st_blksize; ++ unsigned int st_flags; ++ unsigned int st_gen; ++ int __pad3; ++ long __unused[4]; ++ }; diff --git a/fakeroot-upstream-1.30.1.tar.gz b/fakeroot-upstream-1.30.1.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..41d7042dc6a2be88b803c38006e48a40147515ff Binary files /dev/null and b/fakeroot-upstream-1.30.1.tar.gz differ diff --git a/fakeroot.spec b/fakeroot.spec index e716b6a382bed92e956069f3932d7759c30712c2..2d0468a89a7619e820fcf226c88d3a65c5ac8ff5 100644 --- a/fakeroot.spec +++ b/fakeroot.spec @@ -1,140 +1,110 @@ -%bcond_with autoconf - -Name: fakeroot -Version: 1.23 -Release: 2 -Summary: Gives a fake root environment -License: GPLv3+ and LGPLv2+ and (GPL+ or Artistic) -URL: https://tracker.debian.org/pkg/fakeroot -Source0: http://http.debian.net/debian/pool/main/f/fakeroot/%{name}_%{version}.orig.tar.xz - -Patch0000: debian_eglibc-fts-without-LFS.patch -Patch0001: debian_glibc-xattr-types.patch -Patch0002: debian_fix-shell-in-fakeroot.patch -Patch0003: debian_hide-dlsym-error.patch -Patch0004: fakeroot-inttypes.patch -Patch0005: fakeroot-multilib.patch -Patch0006: fakeroot-tests.patch - +%bcond_without autoconf +Summary: Gives a fake root environment +Name: fakeroot +Version: 1.30.1 +Release: 1 +License: GPLv3+ and LGPLv2.1 and MIT and GPL+ +URL: https://tracker.debian.org/pkg/fakeroot +Source0: http://salsa.debian.org/clint/fakeroot/-/archive/upstream/1.30.1/%{name}-upstream-%{version}.tar.gz +Patch1: debian_fix-shell-in-fakeroot.patch +Patch2: fakeroot-inttypes.patch +Patch3: fakeroot-multilib.patch +Patch4: fakeroot-drop-tartest.patch +Patch5000: backport-define-_STAT_VER-if-not-already-defined.patch +%ifarch sw_64 +Patch5001: fakeroot-upstream-1.25.2-sw.patch +%endif %if %{with autoconf} -BuildRequires: autoconf automake libtool po4a +BuildRequires: autoconf automake libtool po4a %endif -BuildRequires: util-linux libacl-devel libcap-devel sharutils -Requires: util-linux -Requires(post): chkconfig -Requires(post): coreutils -Requires(preun):chkconfig - -Provides: fakeroot-libs = %{version}-%{release} -Obsoletes: fakeroot-libs < %{version}-%{release} - - +BuildRequires: /usr/bin/getopt libacl-devel libcap-devel sharutils +Requires: /usr/bin/getopt fakeroot-libs = %{version}-%{release} +Requires(post): /usr/sbin/alternatives +Requires(post): /usr/bin/readlink +Requires(preun): /usr/sbin/alternatives %description -fakeroot replaces the invocation of library function to run a command -in a fake environment in which it executes just like has root privileges. -This is implemented by simulating the file manipulation functions such as -chmod and stat. +fakeroot runs a command in an environment wherein it appears to have +root privileges for file manipulation. fakeroot works by replacing the +file manipulation library functions (chmod(2), stat(2) etc.) by ones +that simulate the effect the real library functions would have had, +had the user really been root. -%package help -Summary: Documentation for fakeroot -%description help -Documentation for fakeroot +%package libs +Summary: Gives a fake root environment (libraries) +%description libs +This package contains the libraries required by %{name}. %prep -%autosetup -p1 +%autosetup -p1 -n %{name}-upstream-%{version} %build %if %{with autoconf} -autoreconf -i -cd doc +./bootstrap +pushd doc po4a -k 0 --rm-backups --variable "srcdir=../doc/" po4a/po4a.cfg -cd - +popd %endif - for file in ./doc/{*.1,*/*.1}; do iconv -f latin1 -t utf8 < $file > $file.new && \ mv -f $file.new $file done - for type in sysv tcp; do mkdir obj-$type cd obj-$type cat >> configure << 'EOF' -#!/bin/sh exec ../configure "$@" EOF chmod +x configure -%configure --disable-dependency-tracking --disable-static \ - --libdir=%{_libdir}/libfakeroot --with-ipc=$type --program-suffix=-$type +%configure \ + --disable-dependency-tracking \ + --disable-static \ + --libdir=%{_libdir}/libfakeroot \ + --with-ipc=$type \ + --program-suffix=-$type make cd .. done %install for type in sysv tcp; do - %make_install -C obj-$type libdir=%{_libdir}/libfakeroot - mv %{buildroot}%{_libdir}/libfakeroot/libfakeroot-{0,$type}.so - rm -f %{buildroot}%{_libdir}/libfakeroot/libfakeroot.so - %delete_la - %find_lang faked-$type --without-mo --with-man - %find_lang fakeroot-$type --without-mo --with-man + make -C obj-$type install libdir=%{_libdir}/libfakeroot DESTDIR=%{buildroot} + mv %{buildroot}%{_libdir}/libfakeroot/libfakeroot-0.so \ + %{buildroot}%{_libdir}/libfakeroot/libfakeroot-$type.so + rm -f %{buildroot}%{_libdir}/libfakeroot/libfakeroot.so + rm -f %{buildroot}%{_libdir}/libfakeroot/libfakeroot.*la + %find_lang faked-$type --without-mo --with-man + %find_lang fakeroot-$type --without-mo --with-man done - -cat fake{d,root}-{sysv,tcp}.lang > fakeroot.lang +rm %{buildroot}%{_mandir}{,/*}/man1/fake{d,root}-sysv.1 +rename -- -tcp '' %{buildroot}%{_mandir}{,/*}/man1/fake{d,root}-tcp.1 +sed -e 's/-tcp//g' fake{d,root}-tcp.lang > fakeroot.lang %check -make -C obj-sysv check VERBOSE=1 -make -C obj-tcp check VERBOSE=1 - -%post - -for name in fakeroot faked; do - link=$(readlink -e "/usr/bin/$name") - if [ "$link" = "/usr/bin/$name" ]; then - rm -f /usr/bin/$name - fi +for type in sysv tcp; do + make -C obj-$type check VERBOSE=1 done +%post +link=$(readlink -e "/usr/bin/fakeroot") +if [ "$link" = "/usr/bin/fakeroot" ]; then + rm -f /usr/bin/fakeroot +fi +link=$(readlink -e "%{_bindir}/faked") +if [ "$link" = "%{_bindir}/faked" ]; then + rm -f "%{_bindir}/faked" +fi link=$(readlink -e "%{_libdir}/libfakeroot/libfakeroot-0.so") if [ "$link" = "%{_libdir}/libfakeroot/libfakeroot-0.so" ]; then rm -f "%{_libdir}/libfakeroot/libfakeroot-0.so" fi - -for type in tcp sysv; do - if [ "$type" = "tcp" ]; then - priority=50 - else - priority=40 - fi - /usr/sbin/alternatives --install "%{_bindir}/fakeroot" fakeroot "%{_bindir}/fakeroot-$type" $priority \ - --slave %{_bindir}/faked faked %{_bindir}/faked-$type \ - --slave %{_libdir}/libfakeroot/libfakeroot-0.so libfakeroot.so %{_libdir}/libfakeroot/libfakeroot-$type.so -done - -%post help - -for type in tcp sysv; do - if [ "$type" = "tcp" ]; then - priority=50 - else - priority=40 - fi - /usr/sbin/alternatives --install "%{_bindir}/fakeroot" fakeroot "%{_bindir}/fakeroot-$type" $priority \ - --slave %{_mandir}/man1/fakeroot.1.gz fakeroot.1.gz %{_mandir}/man1/fakeroot-$type.1.gz \ - --slave %{_mandir}/man1/faked.1.gz faked.1.gz %{_mandir}/man1/faked-$type.1.gz -done - -for lang in de es fr nl pt sv; do - /usr/sbin/alternatives --install "%{_bindir}/fakeroot" fakeroot "%{_bindir}/fakeroot-tcp" 50 \ - --slave %{_mandir}/$lang/man1/fakeroot.1.gz fakeroot.$lang.1.gz %{_mandir}/$lang/man1/fakeroot-tcp.1.gz \ - --slave %{_mandir}/$lang/man1/faked.1.gz faked.$lang.1.gz %{_mandir}/$lang/man1/faked-tcp.1.gz -done - -for lang in de es fr nl pt sv; do - /usr/sbin/alternatives --install "%{_bindir}/fakeroot" fakeroot "%{_bindir}/fakeroot-sysv" 40 \ - --slave %{_mandir}/$lang/man1/fakeroot.1.gz fakeroot.$lang.1.gz %{_mandir}/$lang/man1/fakeroot-sysv.1.gz \ - --slave %{_mandir}/$lang/man1/faked.1.gz faked.$lang.1.gz %{_mandir}/$lang/man1/faked-sysv.1.gz -done +/usr/sbin/alternatives --install "%{_bindir}/fakeroot" fakeroot \ + "%{_bindir}/fakeroot-tcp" 50 \ + --slave %{_bindir}/faked faked %{_bindir}/faked-tcp \ + --slave %{_libdir}/libfakeroot/libfakeroot-0.so libfakeroot.so %{_libdir}/libfakeroot/libfakeroot-tcp.so +/usr/sbin/alternatives --install "%{_bindir}/fakeroot" fakeroot \ + "%{_bindir}/fakeroot-sysv" 40 \ + --slave %{_bindir}/faked faked %{_bindir}/faked-sysv \ + --slave %{_libdir}/libfakeroot/libfakeroot-0.so libfakeroot.so %{_libdir}/libfakeroot/libfakeroot-sysv.so \ %preun if [ $1 = 0 ]; then @@ -142,36 +112,40 @@ if [ $1 = 0 ]; then /usr/sbin/alternatives --remove fakeroot "%{_bindir}/fakeroot-sysv" fi -%files +%files -f %{name}.lang %defattr(-,root,root,-) -%doc COPYING AUTHORS BUGS DEBUG +%doc COPYING AUTHORS BUGS DEBUG doc/README.saving %{_bindir}/faked-* %ghost %{_bindir}/faked %{_bindir}/fakeroot-* %ghost %{_bindir}/fakeroot +%{_mandir}/man1/faked.1* +%{_mandir}/man1/fakeroot.1* + +%files libs %dir %{_libdir}/libfakeroot -%{_libdir}/libfakeroot/libfakeroot-*.so +%{_libdir}/libfakeroot/libfakeroot-sysv.so +%{_libdir}/libfakeroot/libfakeroot-tcp.so %ghost %{_libdir}/libfakeroot/libfakeroot-0.so -%files help -%doc doc/README.saving -%{_mandir}/man1/* -%{_mandir}/*/man1/* -%ghost %{_mandir}/man1/faked.1.gz -%ghost %{_mandir}/man1/fakeroot.1.gz -%ghost %lang(de) %{_mandir}/de/man1/faked.1.gz -%ghost %lang(de) %{_mandir}/de/man1/fakeroot.1.gz -%ghost %lang(es) %{_mandir}/es/man1/faked.1.gz -%ghost %lang(es) %{_mandir}/es/man1/fakeroot.1.gz -%ghost %lang(fr) %{_mandir}/fr/man1/faked.1.gz -%ghost %lang(fr) %{_mandir}/fr/man1/fakeroot.1.gz -%ghost %lang(pt) %{_mandir}/pt/man1/faked.1.gz -%ghost %lang(pt) %{_mandir}/pt/man1/fakeroot.1.gz -%ghost %lang(sv) %{_mandir}/sv/man1/faked.1.gz -%ghost %lang(sv) %{_mandir}/sv/man1/fakeroot.1.gz -%ghost %lang(nl) %{_mandir}/nl/man1/faked.1.gz -%ghost %lang(nl) %{_mandir}/nl/man1/fakeroot.1.gz - %changelog +* Sat Nov 12 2022 hua 1.30.1-1 +- update to 1.30.1 + +* Wed Oct 19 2022 wuzx - 1.25.2-4 +- add sw64 patch + +* Tue Jun 21 2022 liyanan - 1.25.2-3 +- Skip tar test: the test is unstable and keeps on randomly failing + +* Sat Mar 13 2021 shixuantong - 1.25.2-2 +- Fix error: '_STAT_VER' undeclared + +* Fri Nov 20 2020 zhangjiapeng - 1.25.2-1 +- Update to 1.25.2 + +* Wed Aug 12 2020 zhangjiapeng - 1.23-3 +- remove four test cases to solve the compilation failure + * Fri Nov 29 2019 lihao - 1.23-2 - Package Init diff --git a/fakeroot.yaml b/fakeroot.yaml new file mode 100644 index 0000000000000000000000000000000000000000..15e1ddd94402db068f21cdced9858af09ae7a4b0 --- /dev/null +++ b/fakeroot.yaml @@ -0,0 +1,4 @@ +version_control: git +src_repo: https://salsa.debian.org/clint/fakeroot.git +tag_prefix: ^debian/ +seperator: . diff --git a/fakeroot_1.23.orig.tar.xz b/fakeroot_1.23.orig.tar.xz deleted file mode 100644 index 8ea2603a185cdb6e684e5135841eadfb5d21cdff..0000000000000000000000000000000000000000 Binary files a/fakeroot_1.23.orig.tar.xz and /dev/null differ