.PHONY: kafel_init
kafel_init:
ifeq ("$(wildcard kafel/Makefile)","")
- git submodule update --init
+ tar xvfz kafel.tar.gz
+# git submodule update --init
endif
kafel/include/kafel.h: kafel_init
--- /dev/null
+#
+# spec file for package nsjail
+#
+
+Name: nsjail
+Version: 3.0.20210707
+Release: 0
+Summary: A light-weight process isolation tool
+License: Apache-2.0
+Group: System/Other
+URL: https://nsjail.com
+Source0: nsjail-%{version}.tar.gz
+#Source1: kafel.tar.gz
+BuildRequires: autoconf
+BuildRequires: bison
+BuildRequires: flex
+BuildRequires: gcc-c++
+#BuildRequires: git-core
+BuildRequires: glibc-devel
+BuildRequires: libnl3-devel
+BuildRequires: make
+BuildRequires: pkgconfig
+BuildRequires: protobuf-devel
+
+%description
+A light-weight process isolation tool, making use of Linux namespaces and
+seccomp-bpf syscall filters (with help of the kafel bpf language)
+
+%prep
+%setup -q
+
+%build
+%define _lto_cflags %{nil}
+export CFLAGS="%{optflags}"
+export CXXFLAGS="$CFLAGS"
+make %{?_smp_mflags}
+
+%install
+mkdir -p %{buildroot}/%{_bindir}/
+cp nsjail %{buildroot}/%{_bindir}/
+
+%files
+%license LICENSE
+%{_bindir}/nsjail
+
+%changelog
+* Mon Jul 7 2021 Baik
+ - Initial import of version latest version of nsjail - 2021-07-07 version