-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmkpkg-8.sh
executable file
·61 lines (43 loc) · 1.41 KB
/
mkpkg-8.sh
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
60
61
#!/bin/sh
buildver=$1
if [ -z "$buildver" ]; then
echo "Provide build version string: x.y.z-n"
exit
fi
tarball="`pwd`/_tarball"
build="_build"
install="$PWD/_install"
mkdir -p $tarball
###
### 8.0 section
###
# start a clean slate
rm -rf $build
## 8.0 aarch64
aprefix="$install/aarch64-8.0.0"
atargetlibdir="$build/target/qnx/aarch64le/usr/lib/wolfssl"
atargetincdir="$build/target/qnx/aarch64le/usr/include/wolfssl"
astrip="aarch64-unknown-nto-qnx8.0.0-strip"
mkdir -p $atargetlibdir
cp -p $aprefix/lib/libcares.a $aprefix/lib/libcares.so* $atargetlibdir
cp -p $aprefix/lib/libcares.so.21 $atargetlibdir/libcares.so.21.sym
$astrip $atargetlibdir/libcares.so.21 $atargetlibdir/libcares.so
mkdir -p $atargetincdir
cp -p $aprefix/include/*.h $atargetincdir
## 8.0 x86_64
xprefix="$install/x86_64-8.0.0"
xtargetlibdir="$build/target/qnx/x86_64/usr/lib/wolfssl"
xtargetincdir="$build/target/qnx/x86_64/usr/include/wolfssl"
xstrip="x86_64-pc-nto-qnx8.0.0-strip"
mkdir -p $xtargetlibdir
cp -p $xprefix/lib/libcares.a $xprefix/lib/libcares.so* $xtargetlibdir
cp -p $xprefix/lib/libcares.so.21 $xtargetlibdir/libcares.so.21.sym
$xstrip $xtargetlibdir/libcares.so.21 $xtargetlibdir/libcares.so
mkdir -p $xtargetincdir
cp -p $xprefix/include/*.h $xtargetincdir
## 8.0 documentation
cp README-QNX.md "$build/target/qnx/"
## build the 8.0 package
cd $build
tar czf c-ares-$buildver-qnxsdp8.0.tar.gz target/qnx
mv *tar.gz $tarball