diff --git a/utils/packpack/autosetup.patch b/utils/packpack/autosetup.patch new file mode 100644 index 000000000..ffae62b7a --- /dev/null +++ b/utils/packpack/autosetup.patch @@ -0,0 +1,17 @@ +--- packpack/pack/rpm.mk 2017-01-14 14:01:50.364217882 -0600 ++++ packpack/pack/rpm.mk.new 2017-01-14 14:01:19.594985311 -0600 +@@ -23,11 +23,13 @@ + -e 's/Release:\([ ]*\).*/Release: $(RELEASE)%{dist}/' \ + -e 's/Source0:\([ ]*\).*/Source0: $(TARBALL)/' \ + -e 's/%setup .*/%setup -q -n $(PRODUCT)-$(VERSION)/' \ ++ -e 's/%autosetup -n .*/%autosetup -n $(PRODUCT)-$(VERSION)/' \ + -i $@.tmp + grep -F "Version: $(VERSION)" $@.tmp && \ + grep -F "Release: $(RELEASE)" $@.tmp && \ + grep -F "Source0: $(TARBALL)" $@.tmp && \ +- grep -F "%setup -q -n $(PRODUCT)-$(VERSION)" $@.tmp || \ ++ (grep -F "%setup -q -n $(PRODUCT)-$(VERSION)" $@.tmp || \ ++ grep -F "%autosetup" $@.tmp) || \ + (echo "Failed to patch RPM spec" && exit 1) + @ mv -f $@.tmp $@ + @echo diff --git a/utils/packpack/fedora25_package.mk b/utils/packpack/fedora25_package.mk new file mode 100644 index 000000000..61a5a8430 --- /dev/null +++ b/utils/packpack/fedora25_package.mk @@ -0,0 +1,9 @@ +.PHONY: fedora25_package +.NOTPARALLEL: fedora25_package + +fedora25_package: fedora25_bootstrap package + +fedora25_bootstrap: + sudo dnf install -y curl + sudo dnf install -y --nogpgcheck build/zmrepo-25-1.fc25.noarch.rpm + diff --git a/utils/packpack/startpackpack.sh b/utils/packpack/startpackpack.sh new file mode 100755 index 000000000..753134b57 --- /dev/null +++ b/utils/packpack/startpackpack.sh @@ -0,0 +1,14 @@ +#!/bin/sh +# packpack setup file for ZoneMinder project +# Written by Andrew Bauer + +# This script is jsut a first start. It will change siginificantly as support +# for more distros is added. + +ln -s distros/redhat rpm +mkdir -p build +curl -L https://github.com/FriendsOfCake/crud/archive/v3.0.10.tar.gz > build/crud-3.0.10.tar.gz +git clone https://github.com/packpack/packpack.git packpack +patch < utils/packpack/autosetup.patch +packpack/packpack -f utils/packpack/fedora25_package.mk fedora25_package +