-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathperl-GRNOC-RabbitMQ.spec
59 lines (45 loc) · 1.73 KB
/
perl-GRNOC-RabbitMQ.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
%global debug_package %{nil} # Don't generate debug info
%global _binaries_in_noarch_packages_terminate_build 0
AutoReqProv: no # Keep rpmbuild from trying to figure out Perl on its own
Summary: GRNOC RabbitMQ Perl Libraries
Name: perl-GRNOC-RabbitMQ
Version: 1.2.2
Release: 1%{?dist}
License: APL 2.0
Group: Network
URL: http://globalnoc.iu.edu
Source0: %{name}-%{version}.tar.gz
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
BuildArch:noarch
BuildRequires: perl
Requires: perl-GRNOC-Log
Requires: perl-GRNOC-WebService
%description
The GRNOC::RabbitMQ collection is a set of perl modules which are used to
provide and interact with GRNOC RabbitMQ services.
%prep
%setup -q -n perl-GRNOC-RabbitMQ-%{version}
%build
%install
rm -rf %{buildroot}
%{__install} -d -p %{buildroot}/%{perl_vendorlib}/GRNOC/RabbitMQ/
%{__install} -d -p %{buildroot}/opt/grnoc/venv/%{name}/lib/perl5
%{__install} lib/GRNOC/RabbitMQ.pm %{buildroot}/%{perl_vendorlib}/GRNOC
%{__install} lib/GRNOC/RabbitMQ/Client.pm %{buildroot}/%{perl_vendorlib}/GRNOC/RabbitMQ
%{__install} lib/GRNOC/RabbitMQ/Dispatcher.pm %{buildroot}/%{perl_vendorlib}/GRNOC/RabbitMQ
%{__install} lib/GRNOC/RabbitMQ/Method.pm %{buildroot}/%{perl_vendorlib}/GRNOC/RabbitMQ
# add virtual environment files
cp -r venv/lib/perl5/* -t %{buildroot}/opt/grnoc/venv/%{name}/lib/perl5
# clean up buildroot
find %{buildroot} -name .packlist -exec %{__rm} {} \;
%{_fixperms} $RPM_BUILD_ROOT/*
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(644, root, root, -)
%{perl_vendorlib}/GRNOC/RabbitMQ.pm
%{perl_vendorlib}/GRNOC/RabbitMQ/Dispatcher.pm
%{perl_vendorlib}/GRNOC/RabbitMQ/Method.pm
%{perl_vendorlib}/GRNOC/RabbitMQ/Client.pm
%defattr(644, root, root, 755)
/opt/grnoc/venv/%{name}/lib/perl5/*