diff options
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 58 |
1 files changed, 29 insertions, 29 deletions
@@ -1,42 +1,42 @@ -# Maintainer: Max Beikirch <max.beikirch (at) unitybox (dot) de> +# Maintainer: necklace <ns@nsz.no> +# Contributor: Max Beikirch <max.beikirch (at) unitybox (dot) de> + pkgname=tor-shadow -pkgver=1.11.2 +pkgver=2.2.0 pkgrel=1 -pkgdesc="an open-source network simulator/emulator hybrid (e.g. for Tor and Bitcoin)" -arch=('i686' 'x86_64') +pkgdesc="An open-source network simulator/emulator hybrid (e.g. for Tor and Bitcoin)" +arch=('any') url="https://shadow.github.io/" license=('custom') -depends=('igraph>=0.5.4' 'glib2>=2.32.0') -makedepends=('llvm>=3.2' 'cmake>=2.8.8') -source=("https://github.com/shadow/shadow/archive/v$pkgver.tar.gz" - "patch_addLLVM.patch" - "patch_fix_build_dir.patch") -md5sums=('72a65ce92c311117fa80f9309824dfe3' - 'ad343433a279cc78a54f6eecffb92b36' - 'bc3c5e1e79c0fcf8600a30e2cb8e0fe0') +depends=('glib2>=2.32.0' 'python>=3.6') +makedepends=('gcc' 'cmake>=3.2' 'make' 'cargo' 'pkgconf' 'xz' 'util-linux' ) +optdepends=('python-numpy' 'python-lxml' 'python-matplotlib' 'python-networkx' 'python-scipy' 'python-yaml') +source=("https://github.com/shadow/shadow/archive/v$pkgver.tar.gz") +sha256sums=("707e27c4b1181849ebaa0ab052de0932713d0af26a1f3c682e47d5abfeffaf25") -prepare() { - cd "shadow-$pkgver" - patch -p1 -i "$srcdir/patch_addLLVM.patch" - patch -p1 -i "$srcdir/patch_fix_build_dir.patch" - mkdir -p build -} +# TODO +# Maybe there should be a prepare() that checks various system variables to make sure they are in accordance with: +# https://github.com/shadow/shadow/blob/0171ea8282e19bc439add4ad952bf75a98444627/docs/system_configuration.md build() { - cd "shadow-$pkgver" - python2 setup build --include /usr/lib/cmake/llvm --prefix "/usr" - cd build - cmake -DCMAKE_SKIP_INSTALL_RPATH=ON .. + mkdir -p "shadow-$pkgver/build" + cd "shadow-$pkgver/build" + cmake \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_BUILD_TYPE=Release \ + -DSHADOW_TEST=ON \ + .. make } -package() { - cd "shadow-$pkgver/build" - make DESTDIR="${pkgdir}" install +check() { + cd "shadow-$pkgver/build" + ctest +} - mv "$pkgdir/usr/plugins/libshadow-plugin-tgen.so" "$pkgdir/usr/lib" - rm -rf "$pkgdir/usr/plugins" +package() { + install -Dm644 "${srcdir}/shadow-${pkgver}/LICENSE" ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE - mkdir -p $pkgdir/usr/share/licenses/$pkgname - install -Dm644 ../LICENSE $pkgdir/usr/share/licenses/$pkgname/ + cd "shadow-$pkgver/build" + make DESTDIR="${pkgdir}" install } |