crypto/libressl/libressl.sh

Fri, 15 Nov 2019 20:11:00 +0100

author
David Demelier <markand@malikania.fr>
date
Fri, 15 Nov 2019 20:11:00 +0100
changeset 1210
422313c3fcbd
parent 1115
297b5eef115e
child 1216
6710613b88b9
permissions
-rw-r--r--

text/rarian: initial import, closes #2311

1115
297b5eef115e vanilla: change shebangs to /bin/sh
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
1 #!/bin/sh
608
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
2 #
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
3 # Copyright (c) 2019 David Demelier <markand@malikania.fr>
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
4 #
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
5 # Permission to use, copy, modify, and/or distribute this software for any
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
6 # purpose with or without fee is hereby granted, provided that the above
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
7 # copyright notice and this permission notice appear in all copies.
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
8 #
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
9 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
10 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
11 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
12 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
13 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
14 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
15 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
16 #
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
17
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
18 PKGNAME=libressl
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
19 PKGVERSION=2.9.2
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
20 PKGREVISION=1
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
21 PKGLICENSE="CUSTOM"
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
22 PKGSUMMARY="OpenSSL fork from OpenBSD"
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
23 PKGDOWNLOAD="https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.9.2.tar.gz"
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 645
diff changeset
24 PKGDEPENDS="cmake:build"
608
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
25
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
26 : ${CC:=clang}
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
27 : ${CFLAGS:=-O2}
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
28
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
29 build()
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
30 {
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
31 rm -rf $PKGNAME-$PKGVERSION
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
32 tar xvf $PKGNAME-$PKGVERSION.tar.gz
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
33 cd $PKGNAME-$PKGVERSION
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
34
645
af3c84369341 crypto/libressl: fix build
David Demelier <markand@malikania.fr>
parents: 608
diff changeset
35 patch -p0 < ../patch-musl.patch
608
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
36 mkdir build && cd build
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
37 cmake .. \
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
38 -DBUILD_SHARED_LIBS=On \
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
39 -DCMAKE_BUILD_TYPE=Release \
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
40 -DCMAKE_C_COMPILER="$CC" \
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
41 -DCMAKE_C_FLAGS="$CFLAGS" \
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
42 -DCMAKE_INSTALL_PREFIX=
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
43 make
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
44 make install DESTDIR=$DESTDIR
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
45 cd ..
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
46
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
47 cd ..
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
48 rm -rf $PKGNAME-$PKGVERSION
2929b2af4c15 crypto/libressl: initial import, closes #1687
David Demelier <markand@malikania.fr>
parents:
diff changeset
49 }

mercurial