]> git.ipfire.org Git - ipfire-3.x.git/blame - compat-openssl/compat-openssl.nm
compat-openssl: Fix build
[ipfire-3.x.git] / compat-openssl / compat-openssl.nm
CommitLineData
41388a63
MT
1###############################################################################
2# IPFire.org - An Open Source Firewall Solution #
3# Copyright (C) - IPFire Development Team <info@ipfire.org> #
4###############################################################################
5
6name = compat-openssl
36f93688 7version = 1.1.1s
41388a63
MT
8release = 1
9thisapp = openssl-%{version}
10
11maintainer = Michael Tremer <michael.tremer@ipfire.org>
12groups = System/Libraries
36f93688 13url = https://www.openssl.org/
41388a63
MT
14license = OpenSSL
15summary = A general purpose cryptography library with TLS implementation.
16
17description
18 The OpenSSL toolkit provides support for secure communications between
19 machines. OpenSSL includes a certificate management tool and shared
20 libraries which provide various cryptographic algorithms and protocols.
21end
22
36f93688 23source_dl = https://openssl.org/source/
41388a63
MT
24
25build
26 requires
27 bc
28 gnutls-devel
29 perl
36f93688 30 perl(Test::Harness)
41388a63
MT
31 util-linux
32 zlib-devel
33 end
34
35 CFLAGS += -DPURIFY
36 export RPM_OPT_FLAGS = %{CFLAGS} %{LDFLAGS}
37
38 prepare_cmds
39 sed -e 's/SHLIB_VERSION_NUMBER "1.0.0"/SHLIB_VERSION_NUMBER "%{version}"/' \
36f93688 40 -i include/openssl/opensslv.h
41388a63
MT
41
42 find crypto/ -name Makefile -exec \
43 sed 's/^ASFLAGS=/&-Wa,--noexecstack /' -i {} \;
41388a63
MT
44 end
45
46 # Set default ssl_arch.
47 ssl_arch = linux-%{DISTRO_ARCH}
48
41388a63
MT
49 build
50 ./Configure \
51 --prefix=/usr \
52 --openssldir=/etc/pki/tls \
41388a63
MT
53 shared \
54 zlib-dynamic \
55 enable-camellia \
56 enable-md2 \
57 enable-seed \
41388a63
MT
58 enable-rfc3779 \
59 no-idea \
60 no-mdc2 \
61 no-rc5 \
62 no-ec2m \
63 no-srp \
64 -DSSL_FORBID_ENULL \
65 %{ssl_arch}
66
67 # Build.
68 make depend
69 make all
41388a63
MT
70 end
71
36f93688
PM
72 #test
73 #
74 # #make test
75 #end
41388a63
MT
76
77 install
1dfdb514 78 make install DESTDIR=%{BUILDROOT}
41388a63 79
1dfdb514
PM
80 # Remove man pages and configuration files
81 rm -rfv %{BUILDROOT}%{sysconfdir} %{BUILDROOT}/usr/share/man*
41388a63
MT
82
83 # Remove engines
84 rm -rfv %{BUILDROOT}%{libdir}/{engines,openssl}
85
86 # Remove binaries
87 rm -rfv %{BUILDROOT}%{bindir}
88 end
89end
90
91packages
92 package %{name}
93 requires
94 ca-certificates
95 end
96
97 provides
98 openssl = %{thisver}
99 end
100
101 obsoletes
102 openssl <= %{thisver}
103 end
104 end
105
106 package %{name}-devel
107 template DEVEL
108
109 provides
110 openssl-devel = %{thisver}
111 end
112
113 obsoletes
114 openssl-devel <= %{thisver}
115 end
116 end
117
118 package %{name}-debuginfo
119 template DEBUGINFO
120 end
121end