From ce21840ea9cd5c2ab2e46db302006b7c3d4ed34d Mon Sep 17 00:00:00 2001 From: Sapan Bhatia Date: Tue, 5 Jun 2012 03:06:06 -0400 Subject: [PATCH] Added specfile --- Makefile | 7 +++++++ procprotect.spec | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 53 insertions(+) create mode 100644 Makefile create mode 100644 procprotect.spec diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..a328711 --- /dev/null +++ b/Makefile @@ -0,0 +1,7 @@ +obj-m += procprotect.o + +all: + make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules + +clean: + make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean diff --git a/procprotect.spec b/procprotect.spec new file mode 100644 index 0000000..57e66ca --- /dev/null +++ b/procprotect.spec @@ -0,0 +1,46 @@ +%define url $URL$ + +%define name procprotect +%define version 0.1 +%define taglevel 1 + +%define release %{taglevel}%{?pldistro:.%{pldistro}}%{?date:.%{date}} + +Vendor: PlanetLab +Packager: PlanetLab Central +Distribution: PlanetLab %{plrelease} +URL: %(echo %{url} | cut -d ' ' -f 2) + +Summary: Proc fs acls +Name: %{name} +Version: %{version} +Release: %{release} +License: GPL +Group: System Environment/Kernel +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot +Source0: procprotect-%{version}.tar.gz + +%description +ACLs for protecting entries in the proc filesystem. + +%prep +%setup -q + +%build +make -C /lib/modules/`ls /lib/modules | head -1`/build M=$PWD modules + +%install +mkdir -p $RPM_BUILD_ROOT/lib/modules/`ls /lib/modules | head -1`/kernel/net/procprotect +cp procprotect.ko $RPM_BUILD_ROOT/lib/modules/`ls /lib/modules | head -1`/kernel/net/procprotect + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +/lib + +%post + +%postun + +%changelog -- 2.43.0