summaryrefslogtreecommitdiffstats
path: root/zenmap/install_scripts/windows/PKGBUILD
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 07:42:04 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 07:42:04 +0000
commit0d47952611198ef6b1163f366dc03922d20b1475 (patch)
tree3d840a3b8c0daef0754707bfb9f5e873b6b1ac13 /zenmap/install_scripts/windows/PKGBUILD
parentInitial commit. (diff)
downloadnmap-0d47952611198ef6b1163f366dc03922d20b1475.tar.xz
nmap-0d47952611198ef6b1163f366dc03922d20b1475.zip
Adding upstream version 7.94+git20230807.3be01efb1+dfsg.upstream/7.94+git20230807.3be01efb1+dfsgupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'zenmap/install_scripts/windows/PKGBUILD')
-rw-r--r--zenmap/install_scripts/windows/PKGBUILD32
1 files changed, 32 insertions, 0 deletions
diff --git a/zenmap/install_scripts/windows/PKGBUILD b/zenmap/install_scripts/windows/PKGBUILD
new file mode 100644
index 0000000..69a6eaf
--- /dev/null
+++ b/zenmap/install_scripts/windows/PKGBUILD
@@ -0,0 +1,32 @@
+# PKGBUILD for Zenmap targeting MinGW and MSYS2, for use in packaging Zenmap for Windows.
+# Expected invocation: makepkg-mingw -RdfL
+# -R: repackage, do not download source
+# -d: do not verify dependencies (Python 3 is the only build dependency)
+# -f: force, overwrite existing package.
+# -L: log progress to file
+_realname=zenmap
+pkgbase=mingw-w64-python-${_realname}
+pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
+provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
+conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
+replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
+NMAP_DIR=$(realpath "../../..")
+pkgver=$(echo NMAP_VERSION | ${CC} -E -imacros "${NMAP_DIR}/nmap.h" - | sed -n '$s/[" ]//g;$p')
+pkgrel=1
+pkgdesc="Graphical Nmap frontend and results viewer"
+url="https://nmap.org/zenmap/"
+arch=("any")
+license=("NPSL")
+source=("https://nmap.org/dist/nmap-${pkgver}.tar.bz2")
+sha256sums=("SKIP")
+mingw_arch=('mingw64')
+depends=("${MINGW_PACKAGE_PREFIX}-python" "${MINGW_PACKAGE_PREFIX}-python-gobject")
+makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools")
+
+package() {
+ cd "${NMAP_DIR}/zenmap"
+ ${MINGW_PREFIX}/bin/python setup.py build
+ MSYS2_ARG_CONV_EXCL="--prefix=" \
+ ${MINGW_PREFIX}/bin/python setup.py install vanilla --prefix=${MINGW_PREFIX} --root="${pkgdir}" --optimize=1
+ install -Dm644 install_scripts/unix/zenmap.desktop "${pkgdir}${MINGW_PREFIX}/share/applications/zenmap.desktop"
+}