[arch-commits] Commit in (4 files)
Levente Polyak
anthraxx at archlinux.org
Wed Sep 28 20:46:33 UTC 2016
Date: Wednesday, September 28, 2016 @ 20:46:33
Author: anthraxx
Revision: 190752
addpkg: metasploit 4.12.28-1
Added:
metasploit/
metasploit/repos/
metasploit/trunk/
metasploit/trunk/PKGBUILD
----------+
PKGBUILD | 49 +++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 49 insertions(+)
Added: metasploit/trunk/PKGBUILD
===================================================================
--- metasploit/trunk/PKGBUILD (rev 0)
+++ metasploit/trunk/PKGBUILD 2016-09-28 20:46:33 UTC (rev 190752)
@@ -0,0 +1,49 @@
+# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
+# Contributor: Sabart Otto - Seberm <seberm[at]seberm[dot]com>
+# Contributor: Tobias Veit - nIcE <m.on.key.tobi[at]gmail[dot]com>
+
+pkgname=metasploit
+pkgver=4.12.28
+pkgrel=1
+pkgdesc='Advanced open-source platform for developing, testing, and using exploit code'
+url='https://www.metasploit.com/'
+arch=('i686' 'x86_64')
+license=('BSD')
+depends=('ruby' 'libpcap' 'postgresql-libs' 'ruby-bundler' 'sqlite' 'libxslt' 'git')
+optdepends=('ruby-pg: database support')
+options=('!strip' '!emptydirs')
+source=(${pkgname}-${pkgver}.tar.gz::https://github.com/rapid7/metasploit-framework/archive/${pkgver}.tar.gz)
+sha512sums=('582b002e78744eb6c5dd70297b30b0f354eb918c3bd837d7b76ff7d99cb3e2b658da750be1c959ba03cb5c621ec3d29be05d8e4f263a7b2601653e3f7e44c7bd')
+
+prepare() {
+ cd ${pkgname}-framework-${pkgver}
+ bundle config build.nokogiri --use-system-libraries
+ sed 's|git ls-files|find -type f|' -i metasploit-framework.gemspec
+}
+
+build() {
+ cd ${pkgname}-framework-${pkgver}
+ bundle install -j"$(nproc)" --no-cache --deployment
+ find vendor/bundle/ruby -exec chmod o+r '{}' \;
+}
+
+package() {
+ cd ${pkgname}-framework-${pkgver}
+
+ install -d "${pkgdir}/opt/${pkgname}" "${pkgdir}/usr/bin"
+ cp -r . "${pkgdir}/opt/${pkgname}"
+
+ for f in "${pkgdir}"/opt/${pkgname}/msf*; do
+ local _msffile="${pkgdir}/usr/bin/`basename "${f}"`"
+ echo -e "#!/bin/sh\nBUNDLE_GEMFILE=/opt/${pkgname}/Gemfile bundle exec ruby /opt/${pkgname}/`basename "${f}"` \"\$@\"" > ${_msffile}
+ chmod 755 ${_msffile}
+ done
+
+ install -Dm 644 external/zsh/_* -t "${pkgdir}/usr/share/zsh/site-functions"
+ install -Dm 644 LICENSE COPYING -t "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -d "${pkgdir}/usr/share/doc"
+ mv "${pkgdir}/opt/${pkgname}/documentation" "${pkgdir}/usr/share/doc/${pkgname}"
+ rm "${pkgdir}/usr/bin/msfupdate"
+}
+
+# vim: ts=2 sw=2 et:
More information about the arch-commits
mailing list