blob: 59035042dd9d215590496b4e6e42ed665265229c (
plain)
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
|
# Maintainer: rpx <rpx at clearlight dot systems>
# Contributor: acxz <akashpatel2008 at yahoo dot com>
pkgname=openvsp
pkgdesc='A parametric aircraft geometry tool'
pkgver=3.41.1
pkgrel=1
arch=('i686' 'x86_64')
url='https://openvsp.org'
license=('NASA OPEN SOURCE AGREEMENT VERSION 1.3')
depends=(
'cblas'
'cminpack'
'freeglut'
'gcc'
'git'
'glew'
'libxml2'
'pandoc')
optdepends=(
'doxygen: generate documentation'
'graphviz: generate documentation'
'python: python API module'
'swig: build interface to APIs')
makedepends=('cmake' 'unzip')
#_name=OpenVSP-main
_name=OpenVSP-OpenVSP_${pkgver}
#source=("${pkgname}-${pkgver}.zip"::"https://github.com/rpxpx/OpenVSP/archive/refs/heads/main.zip")
#sha256sums=('d3bcdacb23d62f0ceb94356adb332a1512b8c8c2173f43955092b4bb2bab8601')
source=("${pkgname}-${pkgver}.tar.gz"::"https://github.com/OpenVSP/OpenVSP/archive/OpenVSP_${pkgver}.tar.gz")
sha256sums=('a9e1a9e37903ae6f15baca9d1fc89fe49b4a0306d9594552ee28a55eb4517a8e')
#sha256sums=('ba42e2bad11f086787fb06eee2300c8a2a106d410791508447a380131e576fb2')
prepare() {
cd "${srcdir}/${_name}"
}
build() {
# Create a build directory
mkdir -p "${srcdir}/build"
mkdir -p "${srcdir}/buildlibs"
cd "${srcdir}/buildlibs"
cmake ../${_name}/Libraries \
-DCMAKE_PREFIX_PATH='/usr' \
-DVSP_USE_SYSTEM_ADEPT2=false \
-DVSP_USE_SYSTEM_CLIPPER2=false \
-DVSP_USE_SYSTEM_CMINPACK=false \
-DVSP_USE_SYSTEM_CODEELI=false \
-DVSP_USE_SYSTEM_CPPTEST=false \
-DVSP_USE_SYSTEM_DELABELLA=false \
-DVSP_USE_SYSTEM_EIGEN=false \
-DVSP_USE_SYSTEM_EXPRPARSE=false \
-DVSP_USE_SYSTEM_FLTK=false \
-DVSP_USE_SYSTEM_GLEW=true \
-DVSP_USE_SYSTEM_GLM=false \
-DVSP_USE_SYSTEM_LIBIGES=false \
-DVSP_USE_SYSTEM_LIBXML2=true \
-DVSP_USE_SYSTEM_OPENABF=false \
-DVSP_USE_SYSTEM_PINOCCHIO=false \
-DVSP_USE_SYSTEM_STEPCODE=false \
-DVSP_USE_SYSTEM_TRIANGLE=false
make -j8
cd "${srcdir}/build"
cmake ../${_name}/src \
-DVSP_LIBRARY_PATH="${srcdir}/buildlibs" \
-DCMAKE_BUILD_TYPE=Release
make -j8
make package
}
package() {
cd ${srcdir}/build
unzip "OpenVSP-${pkgver}-Linux.zip"
cd "OpenVSP-${pkgver}-Linux"
mkdir -p ${pkgdir}/usr/share/${pkgname}
# binaries
cp vsp vspaero vspscript vsploads vspaero_adjoint vspaero_complex vspaero_opt vspviewer \
${pkgdir}/usr/share/${pkgname}
# misc
cp README.md ${pkgdir}/usr/share/${pkgname}
cp LICENSE ${pkgdir}/usr/share/${pkgname}
cp vspIcon.png ${pkgdir}/usr/share/${pkgname}
cp -r airfoil ${pkgdir}/usr/share/${pkgname}
cp -r CustomScripts ${pkgdir}/usr/share/${pkgname}
cp -r help ${pkgdir}/usr/share/${pkgname}
cp -r matlab ${pkgdir}/usr/share/${pkgname}
cp -r python ${pkgdir}/usr/share/${pkgname}
cp -r scripts ${pkgdir}/usr/share/${pkgname}
cp -r textures ${pkgdir}/usr/share/${pkgname}
cp -r vspaero_ex ${pkgdir}/usr/share/${pkgname}
# binary symlinks, relative
mkdir -p ${pkgdir}/usr/bin
cd ${pkgdir}/usr/share/${pkgname}
ln -sr vsp vspaero vspscript vsploads vspaero_adjoint vspaero_complex vspaero_opt vspviewer \
${pkgdir}/usr/bin/
}
|