3a72b926459546eb94859700d2b73789991041cd
[shibboleth/cpp-opensaml.git] / opensaml.spec.in
1 Name:           @PACKAGE_NAME@
2 Version:        @PACKAGE_VERSION@
3 Release:        1
4 Summary:        OpenSAML SAML library
5 Group:          Development/Libraries/C and C++
6 Vendor:         Shibboleth Consortium
7 License:        Apache 2.0
8 URL:            http://www.opensaml.org/
9 Source0:        %{name}-%{version}.tar.bz2
10 BuildRoot:      %{_tmppath}/%{name}-%{version}-root
11 %if 0%{?rhel} >= 7 || 0%{?centos_version} >= 700
12 BuildRequires:  xerces-c-devel >= 3.1
13 %else
14 BuildRequires:  libxerces-c-devel >= 3.1
15 %endif
16 BuildRequires:  libxml-security-c-devel >= 1.4.0
17 BuildRequires:  libxmltooling-devel >= 1.4
18 %{?_with_log4cpp:BuildRequires: liblog4cpp-devel >= 1.0}
19 %{!?_with_log4cpp:BuildRequires: liblog4shib-devel >= 1.0.4}
20 BuildRequires:  gcc-c++, boost-devel >= 1.32.0
21 %if 0%{?suse_version} > 1000
22 BuildRequires: pkg-config
23 %endif
24 %{!?_without_doxygen:BuildRequires: doxygen}
25 %if "%{_vendor}" == "redhat"
26 BuildRequires: redhat-rpm-config
27 %endif
28
29 %if "%{_vendor}" == "suse"
30 %define pkgdocdir %{_docdir}/%{name}
31 %else
32 %define pkgdocdir %{_docdir}/%{name}-%{version}
33 %endif
34
35 %description
36 OpenSAML is an open source implementation of the OASIS Security Assertion
37 Markup Language Specification. It contains a set of open source C++ classes
38 that support the SAML 1.0, 1.1, and 2.0 specifications.
39
40 %package -n @PACKAGE_NAME@-bin
41 Summary:    Utilities for OpenSAML library
42 Group:      Development/Libraries/C and C++
43
44 %description -n @PACKAGE_NAME@-bin
45 OpenSAML is an open source implementation of the OASIS Security Assertion
46 Markup Language Specification. It contains a set of open source C++ classes
47 that support the SAML 1.0, 1.1, and 2.0 specifications.
48
49 This package contains the utility programs.
50
51 %package -n libsaml8
52 Summary:    OpenSAML SAML library
53 Group:      Development/Libraries/C and C++
54 Provides:   @PACKAGE_NAME@ = %{version}-%{release}
55 Obsoletes:  @PACKAGE_NAME@ < %{version}-%{release}
56
57 %description -n libsaml8
58 OpenSAML is an open source implementation of the OASIS Security Assertion
59 Markup Language Specification. It contains a set of open source C++ classes
60 that support the SAML 1.0, 1.1, and 2.0 specifications.
61
62 This package contains just the shared library.
63
64 %package -n libsaml-devel
65 Summary:        OpenSAML development Headers
66 Group:          Development/Libraries/C and C++
67 Requires:       libsaml8 = %{version}-%{release}
68 Provides:       @PACKAGE_NAME@-devel = %{version}-%{release}
69 Obsoletes:      @PACKAGE_NAME@-devel < %{version}-%{release}
70 %if 0%{?rhel} >= 7 || 0%{?centos_version} >= 700
71 Requires:  xerces-c-devel >= 3.1
72 %else
73 Requires:  libxerces-c-devel >= 3.1
74 %endif
75 Requires: libxml-security-c-devel >= 1.4.0
76 Requires: libxmltooling-devel >= 1.4
77 %{?_with_log4cpp:Requires: liblog4cpp-devel >= 1.0}
78 %{!?_with_log4cpp:Requires: liblog4shib-devel >= 1.0.4}
79
80 %description -n libsaml-devel
81 OpenSAML is an open source implementation of the OASIS Security Assertion
82 Markup Language Specification. It contains a set of open source C++ classes
83 that support the SAML 1.0, 1.1, and 2.0 specifications.
84
85 This package includes files needed for development with OpenSAML.
86
87 %package -n @PACKAGE_NAME@-schemas
88 Summary:        OpenSAML schemas and catalog
89 Group:          Development/Libraries/C and C++
90
91 %description -n @PACKAGE_NAME@-schemas
92 OpenSAML is an open source implementation of the OASIS Security Assertion
93 Markup Language Specification. It contains a set of open source C++ classes
94 that support the SAML 1.0, 1.1, and 2.0 specifications.
95
96 This package includes XML schemas and related files.
97
98 %prep
99 %setup -q
100
101 %build
102 %configure %{?saml_options}
103 %{__make}
104
105 %install
106 %{__make} install DESTDIR=$RPM_BUILD_ROOT pkgdocdir=%{pkgdocdir}
107 # Don't package unit tester if present.
108 %{__rm} -f $RPM_BUILD_ROOT/%{_bindir}/samltest
109
110 %check
111 %{__make} check
112
113 %clean
114 [ "$RPM_BUILD_ROOT" != "/" ] && %{__rm} -rf $RPM_BUILD_ROOT
115
116 %ifnos solaris2.8 solaris2.9 solaris2.10
117 %post -n libsaml8 -p /sbin/ldconfig
118 %endif
119
120 %ifnos solaris2.8 solaris2.9 solaris2.10
121 %postun -n libsaml8 -p /sbin/ldconfig
122 %endif
123
124 %files -n @PACKAGE_NAME@-bin
125 %defattr(-,root,root,-)
126 %{_bindir}/samlsign
127
128 %files -n libsaml8
129 %defattr(-,root,root,-)
130 %{_libdir}/libsaml.so.*
131
132 %files -n @PACKAGE_NAME@-schemas
133 %defattr(-,root,root,-)
134 %dir %{_datadir}/xml/@PACKAGE_NAME@
135 %{_datadir}/xml/@PACKAGE_NAME@/*
136
137 %files -n libsaml-devel
138 %defattr(-,root,root,-)
139 %{_includedir}/*
140 %{_libdir}/*.so
141 %{_libdir}/pkgconfig/@PACKAGE_NAME@.pc
142 %doc %{pkgdocdir}
143
144 %changelog
145 * Mon Mar 9 2015 Scott Cantor <cantor.2@osu.edu> - 2.5.4-1
146 - Require Xerces 3.1 even on older platforms
147 - Switch to bz2 source to avoid future SuSE issues
148
149 * Tue May 13 2014 Ian Young <ian@iay.org.uk> - 2.5.3-1.2
150 - Update package dependencies for RHEL/CentOS 7
151 - Fixed bogus dates in changelog
152
153 * Wed Dec 14 2011 Scott Cantor  <cantor.2@osu.edu>  - 2.5-1
154 - Update lib package number.
155 - Add boost-devel dependency.
156
157 * Tue Oct 26 2010  Scott Cantor  <cantor.2@osu.edu>  - 2.4-1
158 - Update version
159 - Add pkg-config support.
160 - Sync package names for side by side install.
161 - Adjust Xerces dependency name and Group setting
162 - Split out schemas into separate subpackage
163
164 * Mon Aug 31 2009   Scott Cantor  <cantor.2@osu.edu>  - 2.3-1
165 - Bump soname for SUSE packaging.
166
167 * Sat Aug 8 2009  Scott Cantor  <cantor.2@osu.edu>  - 2.2.1-1
168 - SuSE conventions
169 - Stop packaging unit tester
170
171 * Wed Dec 3 2008  Scott Cantor  <cantor.2@osu.edu>  - 2.2-1
172 - Bumping for minor update.
173 - Fixing SUSE Xerces dependency name.
174
175 * Tue Jul 1 2008  Scott Cantor  <cantor.2@osu.edu>  - 2.1-1
176 - Bumping for minor update.
177
178 * Mon Mar 17 2008  Scott Cantor  <cantor.2@osu.edu>  - 2.0-6
179 - Official release.
180
181 * Fri Jan 18 2008  Scott Cantor  <cantor.2@osu.edu>  - 2.0-5
182 - Release candidate 1.
183
184 * Thu Nov 08 2007 Scott Cantor  <cantor.2@osu.edu>  - 2.0-4
185 - Second public beta.
186
187 * Thu Aug 16 2007 Scott Cantor  <cantor.2@osu.edu>  - 2.0-3
188 - First public beta.
189
190 * Fri Jul 13 2007  Scott Cantor  <cantor.2@osu.edu>  - 2.0-2
191 - Second alpha.
192
193 * Mon Apr 16 2007  Scott Cantor  <cantor.2@osu.edu>  - 2.0-1
194 - First SPEC file for 2.0.