9289859e9fcf97a50662be32ba65d7ca929f3eea
[platform/upstream/xmlsec1.git] / packaging / xmlsec1.spec
1 %define keepstatic 1
2 Name:           xmlsec1
3 Version:        1.2.22
4 Release:        0
5 License:        MIT
6 Summary:        Library providing support for "XML Signature" and "XML Encryption" standards
7 Url:            http://www.aleksey.com/xmlsec/index.html
8 Group:          System/Libraries
9 Source0:        http://www.aleksey.com/xmlsec/download/xmlsec1-%{version}.tar.gz
10 Source1001:     xmlsec1.manifest
11 BuildRequires:  fdupes
12 BuildRequires:  pkgconfig
13 BuildRequires:  pkgconfig(libxml-2.0) >= 2.6.27
14 BuildRequires:  pkgconfig(libxslt)
15 BuildRequires:  pkgconfig(openssl)
16
17 %description
18 This C library allows to transform XML files into other XML files
19 (or HTML, text, ...) using the standard XSLT stylesheet transformation
20 mechanism. To use it you need to have a version of libxml2 >= 2.6.27
21 installed. The xsltproc command is a command line interface to the XSLT engine
22
23 %package gcrypt
24 Summary:        Gcrypt crypto plugin for XML Security Library
25 License:        MIT
26 Group:          System/Libraries
27 Requires:       %{name} = %{version}
28
29 %description gcrypt
30 Gcrypt plugin for XML Security Library provides gcrypt based crypto services
31 for the xmlsec library.
32
33 %package openssl
34 Summary:        OpenSSL crypto plugin for XML Security Library
35 License:        MIT
36 Group:          System/Libraries
37 Requires:       %{name} = %{version}
38
39 %description openssl
40 OpenSSL plugin for XML Security Library provides OpenSSL based crypto services
41 for the xmlsec library.
42
43 %package devel
44 Summary:        Libraries, includes, etc
45 License:        MIT
46 Group:          Development/Libraries
47 Requires:       %{name} = %{version}
48
49 %description devel
50 This C library allows to transform XML files into other XML files
51 (or HTML, text, ...) using the standard XSLT stylesheet transformation
52 mechanism. To use it you need to have a version of libxml2 >= 2.6.27
53 installed.
54
55 %package devel-static
56 Summary:        A library for Perl-compatible regular expressions
57 License:        MIT
58 Group:          System/Libraries
59 Requires:       %{name}-devel = %{version}
60
61 %description devel-static
62 This C library allows to transform XML files into other XML files
63 (or HTML, text, ...) using the standard XSLT stylesheet transformation
64 mechanism. To use it you need to have a version of libxml2 >= 2.6.27
65 installed.
66 This package contains static versions of the libxmlsec1 library.
67
68 %prep
69 %setup -q
70 cp %{SOURCE1001} .
71
72
73 %build
74
75 %reconfigure \
76             --enable-static \
77             --enable-dynamic \
78             --disable-crypto-dl \
79             --disable-apps-crypto-dl \
80             --without-gnutls
81
82 %define cflags -fPIE
83 %define ldflags -pie
84
85 %__make %{?_smp_mflags} CFLAGS="%{cflags}" LDFLAGS="%{ldflags}"
86
87 %install
88 %make_install
89
90 %remove_docs
91
92 %fdupes %{buildroot}
93
94 %post -p /sbin/ldconfig
95
96 %postun -p /sbin/ldconfig
97
98 %post gcrypt -p /sbin/ldconfig
99
100 %postun gcrypt -p /sbin/ldconfig
101
102 %post openssl -p /sbin/ldconfig
103
104 %postun openssl -p /sbin/ldconfig
105
106 %files
107 %manifest %{name}.manifest
108 %license Copyright
109 %{_libdir}/libxmlsec1.so.*
110 %{_bindir}/xmlsec1
111
112 %files gcrypt
113 %manifest %{name}.manifest
114 %license Copyright
115 %{_libdir}/libxmlsec1-gcrypt.so.*
116
117 %files openssl
118 %manifest %{name}.manifest
119 %license Copyright
120 %{_libdir}/libxmlsec1-openssl.so.*
121
122 %files devel
123 %manifest %{name}.manifest
124 %license Copyright
125 %{_includedir}/xmlsec1
126 %{_bindir}/xmlsec1-config
127 %{_libdir}/lib*.so
128 %{_libdir}/pkgconfig/*
129 %{_libdir}/xmlsec1Conf.sh
130 %{_datadir}/aclocal/xmlsec1.m4
131
132 %files devel-static
133 %manifest %{name}.manifest
134 %license Copyright
135 %{_libdir}/*.a