commit 0aca33bb38154a6ffc02cb8fb85a834f245996ac
Author: Jan Palus <[email protected]>
Date:   Sat Sep 10 12:26:29 2022 +0200

    new

 flags.patch | 11 ++++++++++
 proot.spec  | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 78 insertions(+)
---
diff --git a/proot.spec b/proot.spec
new file mode 100644
index 0000000..dc6d306
--- /dev/null
+++ b/proot.spec
@@ -0,0 +1,67 @@
+%ifarch %{x8664}
+%define                with_32bit_loader       1
+%endif
+
+Summary:       chroot, mount --bind, and binfmt_misc without privilege/setup 
for Linux
+Name:          proot
+Version:       5.3.1
+Release:       1
+License:       GPL v2+
+Group:         Applications/System
+Source0:       
https://github.com/proot-me/proot/archive/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5: 1214effe17171eae192ca5414f07f3c6
+Patch0:                flags.patch
+URL:           https://proot-me.github.io/
+BuildRequires: docutils
+BuildRequires: libarchive-devel
+BuildRequires: pkgconfig
+BuildRequires: python3 >= 1:3.8
+BuildRequires: python3-devel >= 1:3.8
+BuildRequires: swig
+BuildRequires: swig-python
+BuildRequires: talloc-devel
+BuildRequires: uthash-devel
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+PRoot is a user-space implementation of chroot, mount --bind, and
+binfmt_misc. This means that users don't need any privileges or setup
+to do things like using an arbitrary directory as the new root
+filesystem, making files accessible somewhere else in the filesystem
+hierarchy, or executing programs built for another CPU architecture
+transparently through QEMU user-mode.
+
+%prep
+%setup -q
+%patch0 -p1
+
+%build
+export CPPFLAGS="%{rpmcppflags}"
+export CFLAGS="%{rpmcflags}"
+export LDFLAGS="%{rpmldflags}"
+%{__make} -C src loader.elf%{?with_32bit_loader: loader-m32.elf} build.h care 
proot \
+       CC="%{__cc}" \
+       V=1
+
+%{__make} -C doc
+
+%install
+rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_mandir}/man1
+
+%{__make} -C src install install-care \
+       DESTDIR=$RPM_BUILD_ROOT \
+       BINDIR="%{_bindir}" \
+       V=1
+
+cp -p doc/proot/man.1 $RPM_BUILD_ROOT%{_mandir}/man1/proot.1
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc AUTHORS CHANGELOG.rst HACKING.rst README.rst
+%attr(755,root,root) %{_bindir}/care
+%attr(755,root,root) %{_bindir}/proot
+%{_mandir}/man1/proot.1*
diff --git a/flags.patch b/flags.patch
new file mode 100644
index 0000000..8e8608a
--- /dev/null
+++ b/flags.patch
@@ -0,0 +1,11 @@
+--- proot-5.3.1/src/GNUmakefile.orig   2022-04-24 22:52:11.000000000 +0200
++++ proot-5.3.1/src/GNUmakefile        2022-09-10 11:50:17.931282079 +0200
+@@ -21,7 +21,7 @@
+ HAS_PYTHON_CONFIG := $(shell ${PYTHON}-config --ldflags ${PYTHON_EMBED} 
2>/dev/null)
+ 
+ CPPFLAGS += -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -I. -I$(VPATH)
+-CFLAGS   += -g -Wall -Wextra -O2
++CFLAGS   += -Wall -Wextra
+ CFLAGS   += $(shell pkg-config --cflags talloc)
+ LDFLAGS  += -Wl,-z,noexecstack
+ LDFLAGS  += $(shell pkg-config --libs talloc)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/proot.git/commitdiff/0aca33bb38154a6ffc02cb8fb85a834f245996ac

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to