Summary: | dev-libs/libgnugetopt-1.2 ebuild for IRIX | ||
---|---|---|---|
Product: | Gentoo/Alt | Reporter: | Stuart Shelton <srcshelton> |
Component: | Prefix Support | Assignee: | Gentoo Prefix <prefix> |
Status: | RESOLVED WONTFIX | ||
Severity: | normal | ||
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | IRIX | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | libgnugetopt ebuild and source |
Description
Stuart Shelton
2009-07-08 15:25:38 UTC
Created attachment 197197 [details]
libgnugetopt ebuild and source
Extracts to usr/portage/distfiles and usr/local/portage/
(Or, looking again at the speex patch, can be convinced to use libgnugetopt at least...) IIRC, gnulib does provide both getopt and getopt_long. As we build some modules (including getopt) of gnulib as library on some platforms already, I'm wondering if this could work for IRIX too - please have a look at dev-libs/gnulib/. Hmm - I'm not sure I've quite got the hang of gnulib, but I installed it and then ran 'gnulib-tools --import getopt' during groff's configure stage (since groff is a package which fails due to getopt_long not being present)... but this failed in the same way. I guess this means that either the above isn't how gnulib is supposed to be used, or that gnulib's getopt module doesn't include getopt_long... Should this have worked? I just tried "gnulib-tool -s --import getopt" for speex, and got the following output: Module list with included dependencies: getopt gettext-h include_next link-warning unistd File list: build-aux/link-warning.h lib/dummy.c lib/getopt.c lib/getopt.in.h lib/getopt1.c lib/getopt_int.h lib/gettext.h lib/unistd.in.h m4/00gnulib.m4 m4/getopt.m4 m4/gnulib-common.m4 m4/include_next.m4 m4/onceonly.m4 m4/unistd_h.m4 Creating directory ./lib Creating directory ./m4 Copying file ./link-warning.h Copying file lib/dummy.c Copying file lib/getopt.c Copying file lib/getopt.in.h Copying file lib/getopt1.c Copying file lib/getopt_int.h Copying file lib/gettext.h Copying file lib/unistd.in.h Copying file m4/00gnulib.m4 Copying file m4/getopt.m4 Copying file m4/gnulib-common.m4 Copying file m4/gnulib-tool.m4 Copying file m4/include_next.m4 Copying file m4/onceonly.m4 Copying file m4/unistd_h.m4 Creating lib/Makefile.am Creating m4/gnulib-cache.m4 Creating m4/gnulib-comp.m4 Finished. You may need to add #include directives for the following .h files. #include <getopt.h> You may need to use the following Makefile variables when linking. Use them in <program>_LDADD when linking a program, or in <library>_a_LDFLAGS or <library>_la_LDFLAGS when linking a library. $(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise Don't forget to - add "lib/Makefile" to AC_CONFIG_FILES in ./configure.ac, - mention "lib" in SUBDIRS in Makefile.am, - mention "-I m4" in ACLOCAL_AMFLAGS in Makefile.am, - mention "m4/gnulib-cache.m4" in EXTRA_DIST in Makefile.am, - invoke gl_EARLY in ./configure.ac, right after AC_PROG_CC, - invoke gl_INIT in ./configure.ac. ... which is, I'm afraid, out of my depth :o (AC_CONFIG_FILES doesn't exist in configure.ac, ACLOCAL_AMFLAGS doesn't exist in Makefile.am, AC_PROG_CC doesn't existing in configure.ac, and I don't know where to put the last one!) (In reply to comment #4) > then ran 'gnulib-tools --import getopt' during groff's configure stage We make use of 'gnulib-tool --import' within dev-libs/gnulib.ebuild to create a libgnu.a with some subset of gnulib modules suitable for one specific platform. You might need to add another set of modules for your platform there. As 'gnulib-tools --import' usually is upstream package maintainers's job, we just link against libgnu.a instead. As long as the Makefiles know CFLAGS/CXXFLAGS, LDFLAGS, LIBS, this should be enough: inherit flag-o-matic DEPEND="mips-irix? ( dev-libs/gnulib )" src_configure() { if use mips-irix; then append-flags -I"${EPREFIX}"/usr/$(get_libdir)/gnulib/include append-ldflags -I"${EPREFIX}"/usr/$(get_libdir)/gnulib/lib append-libs -lgnu fi econf ... } Hmm - problems here, then: my installation of gnulib includes neither the includes for any library to link against :( The only files installed by gnulib outside of ${EPREFIX}/usr/share/gnulib/ are: /opt/gentoo/usr/share/doc/gnulib-2009.03.03.14.07.45-r00.1/README.bz2 /opt/gentoo/usr/share/doc/gnulib-2009.03.03.14.07.45-r00.1/ChangeLog.bz2 /opt/gentoo/usr/bin/gnulib-tool We are sorry to close this bug. We lack the man-power and devotion to support mips-irix in the tree. |