initial commit
This commit is contained in:
parent
fa733375ec
commit
f08962fab4
|
@ -0,0 +1,24 @@
|
||||||
|
|
||||||
|
pkgname := hack-rpm
|
||||||
|
spec := $(pkgname).spec
|
||||||
|
pwd := $(shell pwd)
|
||||||
|
NAME := $(shell rpmspec -q --qf "%{name}" $(spec))
|
||||||
|
VERSION := $(shell rpmspec -q --qf "%{version}" $(spec))
|
||||||
|
RELEASE := $(shell rpmspec -q --qf "%{release}" $(spec))
|
||||||
|
NVR := $(NAME)-$(VERSION)-$(RELEASE)
|
||||||
|
outdir ?= $(pwd)
|
||||||
|
|
||||||
|
default: srpm
|
||||||
|
|
||||||
|
.PHONY:srpm
|
||||||
|
srpm: $(NVR).src.rpm
|
||||||
|
|
||||||
|
$(NVR).src.rpm: $(spec)
|
||||||
|
rpmbuild \
|
||||||
|
--define '_sourcedir $(pwd)' \
|
||||||
|
--define '_specdir $(pwd)' \
|
||||||
|
--define '_builddir $(pwd)' \
|
||||||
|
--define '_srcrpmdir $(outdir)' \
|
||||||
|
--define '_rpmdir $(outdir)' \
|
||||||
|
--nodeps \
|
||||||
|
-bs ./$(spec)
|
|
@ -0,0 +1,39 @@
|
||||||
|
|
||||||
|
%define _disable_source_fetch 0
|
||||||
|
|
||||||
|
Name: hack-rpm
|
||||||
|
Version: 0.1
|
||||||
|
Release: 1%{?dist}
|
||||||
|
Summary: testing
|
||||||
|
|
||||||
|
Group: testing
|
||||||
|
License: MIT
|
||||||
|
URL: https://git.thisco.de/vbatts/hack-rpm
|
||||||
|
Source0: https://git.thisco.de/vbatts/gogzip/archive/v0.1.0.tar.gz
|
||||||
|
|
||||||
|
BuildRequires: golang
|
||||||
|
#Requires:
|
||||||
|
|
||||||
|
%description
|
||||||
|
%{summary}.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q
|
||||||
|
|
||||||
|
|
||||||
|
%build
|
||||||
|
%configure
|
||||||
|
make %{?_smp_mflags}
|
||||||
|
|
||||||
|
|
||||||
|
%install
|
||||||
|
make install DESTDIR=%{buildroot}
|
||||||
|
|
||||||
|
|
||||||
|
%files
|
||||||
|
%doc
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
|
Reference in New Issue