System/getopt

- added
This commit is contained in:
2018-10-11 17:48:28 +02:00
parent f9a3d3b77b
commit ea37f47348
4 changed files with 70 additions and 0 deletions

43
System/getopt/build Executable file
View File

@@ -0,0 +1,43 @@
#!/usr/bin/env modbuild
pbuild::set_download_url "http://frodo.looijaard.name/system/files/software/$P/$P-${V_PKG}.tar.gz"
pbuild::compile_in_sourcetree
module use System
pbuild::pre_configure_Linux() {
pbuild::add_patch "files/Makefile.patch"
}
pbuild::configure() {
:
}
pbuild::compile() {
case ${OS} in
Linux )
declare -x LDFLAGS="-lintl"
;;
Darwin )
declare -x LDFLAGS="-lintl -liconv -framework CoreFoundation"
;;
esac
make -e all
}
pbuild::install() {
declare -x DESTDIR="${PREFIX}"
declare -x prefix=''
make -e install
}
pbuild::cleanup_build() {
make -e realclean
}
# Local Variables:
# mode: sh
# sh-basic-offset: 8
# tab-width: 8
# End:

View File

@@ -0,0 +1,15 @@
diff -u getopt-1.1.6.orig//Makefile getopt-1.1.6/Makefile
--- getopt-1.1.6.orig//Makefile 2014-11-24 04:33:39.000000000 -0800
+++ getopt-1.1.6/Makefile 2016-10-27 08:27:52.000000000 -0700
@@ -61,7 +61,7 @@
-$(RM) $(objects) $(binaries)
getopt: $(objects)
- $(CC) $(LDFLAGS) -o $@ $(objects)
+ $(CC) -o $@ $(objects) $(LDFLAGS)
install: getopt install_po
$(INSTALL) -m 755 -d $(DESTDIR)$(bindir) $(DESTDIR)$(man1dir)
Common subdirectories: getopt-1.1.6.orig//gnu and getopt-1.1.6/gnu
Common subdirectories: getopt-1.1.6.orig//po and getopt-1.1.6/po
Common subdirectories: getopt-1.1.6.orig//tests and getopt-1.1.6/tests

View File

@@ -0,0 +1 @@
getopt/1.1.6 stable b:gettext/0.19.8

11
System/getopt/modulefile Normal file
View File

@@ -0,0 +1,11 @@
#%Module1.0
module-whatis "parse command-line arguments from shell scripts"
module-url "http://frodo.looijaard.name/project/getopt"
module-license "GNU GPLv2"
module-maintainer "Achim Gsell <achim.gsell@psi.ch>"
module-help "
Getopt(1) is a program to help shell scripts parse command-line parameters.
"