• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..--

autoopts/07-Feb-2025-2,010975

compat/07-Feb-2025-978597

m4/07-Feb-2025-667599

COPYING.gplv3D07-Feb-202534.3 KiB675553

COPYING.lgplv3D07-Feb-20257.5 KiB166128

COPYING.mbsdD07-Feb-20251.4 KiB2823

MakeDefs.incD13-Dec-20090

Makefile.amD07-Feb-20252.5 KiB6555

Makefile.inD07-Feb-202527.2 KiB854761

READMED07-Feb-20254.8 KiB12393

_Noreturn.hD18-Aug-2024375 1310

ag-char-map.hD07-Feb-202526.7 KiB529414

alias.cD07-Feb-20253.3 KiB11937

ao-strs.cD07-Feb-202514 KiB382338

ao-strs.hD07-Feb-202514.4 KiB341296

autoopts.cD07-Feb-202511.8 KiB394160

autoopts.hD07-Feb-202513.5 KiB503244

boolean.cD07-Feb-20252.5 KiB9836

check.cD07-Feb-20254.9 KiB18078

configfile.cD07-Feb-202534.6 KiB1,340721

cook.cD07-Feb-20259 KiB323150

enum.cD07-Feb-202517.4 KiB631352

env.cD07-Feb-20257.1 KiB264120

file.cD07-Feb-20255.7 KiB20492

find.cD07-Feb-202521.5 KiB768358

genshell.cD07-Feb-202530.7 KiB851619

genshell.hD07-Feb-20258.1 KiB227105

gettext.hD07-Feb-202510.2 KiB297217

init.cD07-Feb-20258.4 KiB292120

intprops.hD07-Feb-202520.5 KiB456213

libopts.cD07-Feb-20251.2 KiB5349

load.cD07-Feb-202515.9 KiB581281

makeshell.cD07-Feb-202523.8 KiB921530

nested.cD07-Feb-202523.4 KiB908531

numeric.cD07-Feb-20255.3 KiB18383

option-value-type.cD07-Feb-20255.6 KiB15984

option-value-type.hD31-May-20202.4 KiB6322

option-xat-attribute.cD07-Feb-20255.1 KiB15176

option-xat-attribute.hD31-May-20202.3 KiB6019

parse-duration.cD07-Feb-202512.1 KiB607431

parse-duration.hD07-Feb-20253.4 KiB936

pgusage.cD07-Feb-20255 KiB19089

proto.hD07-Feb-202513.4 KiB623366

putshell.cD07-Feb-202514.4 KiB498243

reset.cD07-Feb-20253.9 KiB14467

restore.cD07-Feb-20256.9 KiB226103

save-flags.cD18-Aug-20247.3 KiB251139

save-flags.hD18-Aug-20242.7 KiB7115

save.cD07-Feb-202525.3 KiB943525

sort.cD07-Feb-20259.5 KiB329168

stack.cD07-Feb-20257.3 KiB270119

stdnoreturn.in.hD07-Feb-20252.2 KiB637

streqvcmp.cD07-Feb-20258.2 KiB287110

text_mmap.cD07-Feb-202511.2 KiB385164

time.cD07-Feb-20253.9 KiB14863

tokenize.cD07-Feb-20258.7 KiB325161

usage.cD07-Feb-202537.1 KiB1,288712

version.cD07-Feb-20256.3 KiB243107

README

1        THIS TARBALL IS NOT A FULL DISTRIBUTION.
2
3The contents of this tarball is designed to be incorporated into
4software packages that utilize the AutoOpts option automation package
5and are intended to be installed on systems that may not have libopts
6installed.  It is redistributable under the terms of either the LGPL
7(see COPYING.lgpl) or under the terms of the advertising clause free BSD
8license (see COPYING.mbsd).
9
10Usage Instructions for autoconf/automake/libtoolized projects:
11
121. Install the unrolled tarball into your package source tree,
13   copying ``libopts.m4'' to your autoconf macro directory.
14
15   In your bootstrap (pre-configure) script, you can do this:
16
17      rm -rf libopts libopts-*
18      gunzip -c `autoopts-config libsrc` | tar -xvf -
19      mv -f libopts-*.*.* libopts
20      cp -fp libopts/m4/*.m4 m4/.
21
22   I tend to put my configure auxiliary files in "m4".
23   Whatever directory you choose, if it is not ".", then
24   be sure to tell autoconf about it with:
25
26      AC_CONFIG_AUX_DIR(m4)
27
28   This is one macro where you *MUST* remember to *NOT* quote
29   the argument.  If you do, automake will get lost.
30
312. Add an invocation of either LIBOPTS_CHECK or LIBOPTS_CHECK_NOBUILD
32   to your configure.ac file.  See LIBOPTS_CHECK: below for details.
33
343. Add the following to your top level ``Makefile.am'' file:
35
36      if NEED_LIBOPTS
37         SUBDIRS += $(LIBOPTS_DIR)
38      endif
39
40   where ``<...>'' can be whatever other files or directories you may
41   need.  The SUBDIRS must be properly ordered.  *PLEASE NOTE* it is
42   crucial that the SUBDIRS be set under the control of an automake
43   conditional.  To work correctly, automake has to know the range of
44   possible values of SUBDIRS.  It's a magical name with magical
45   properties.  ``NEED_LIBOPTS'' will be correctly set by the
46   ``LIBOPTS_CHECK'' macro, above.
47
484. Add ``$(LIBOPTS_CFLAGS)'' to relevant compiler flags and
49   ``$(LIBOPTS_LDADD)'' to relevant link options whereever
50   you need them in your build tree.
51
525. Make sure your object files explicitly depend upon the
53   generated options header file.  e.g.:
54
55     $(prog_OBJECTS) : prog-opts.h
56     prog-opts.h : prog-opts.c
57     prog-opts.c : prog-opts.def
58         autogen prog-opts.def
59
606. *OPTIONAL* --
61   If you are creating man pages and texi documentation from
62   the program options, you will need these rules somewhere, too:
63
64     man_MANS = prog.1
65     prog.1 : prog-opts.def
66         autogen -Tagman-cmd.tpl -bprog prog-opts.def
67
68     invoke-prog.texi : prog-opts.def
69         autogen -Tagtexi-cmd.tpl prog-opts.def
70
71If your package does not utilize the auto* tools, then you
72will need to hand craft the rules for building the library.
73
74LIBOPTS_CHECK:
75
76The arguments to both macro are a relative path to the directory with
77the libopts source code.  It is optional and defaults to "libopts".
78These macros work as follows:
79
801.  LIBOPTS_CHECK([libopts/rel/path/optional])
81
82    Adds two command-line options to the generated configure script,
83    --enable-local-libopts and --disable-libopts-install.  AC_SUBST's
84    LIBOPTS_CFLAGS, LIBOPTS_LDADD, and LIBOPTS_DIR for use in
85    Makefile.am files.  Adds Automake conditional NEED_LIBOPTS which
86    will be true when the local copy of libopts should be built.  Uses
87    AC_CONFIG_FILES([$libopts-dir/Makefile]) to cause the local libopts
88    into the package build.  If the optional relative path to libopts is
89    not provided, it defaults to simply "libopts".
90
912.  LIBOPTS_CHECK_NOBUILD([libopts/rel/path/optional])
92
93    This variant of LIBOPTS_CHECK is useful when multiple configure.ac
94    files in a package make use of a single libopts tearoff.  In that
95    case, only one of the configure.ac files should build libopts and
96    others should simply use it.  Consider this package arrangment:
97
98    all-tools/
99      configure.ac
100      common-tools/
101        configure.ac
102        libopts/
103
104    The parent package all-tools contains a subpackage common-tools
105    which can be torn off and used independently.  Programs configured
106    by both configure.ac files link against the common-tools/libopts
107    tearoff, when not using the system's libopts.  The top-level
108    configure.ac uses LIBOPTS_CHECK_NOBUILD([common-tools/libopts]),
109    while common-tools/configure.ac uses LIBOPTS_CHECK.  The difference
110    is LIBOPTS_CHECK_NOBUILD will never build the libopts tearoff,
111    leaving that to the subpackage configure.ac's LIBOPTS_CHECK.
112    Specifically, LIBOPTS_CHECK_NOBUILD always results in the
113    NEED_LIBOPTS Automake conditional being false, and does not invoke
114    AC_CONFIG_FILES(path-to-libopts/Makefile).
115
116LICENSING:
117
118This material is Copyright (C) 1992-2018 by Bruce Korb.  You are
119licensed to use this under the terms of either the GNU Lesser General
120Public License (see: COPYING.lgpl), or, at your option, the modified
121Berkeley Software Distribution License (see: COPYING.mbsd).  Both of
122these files should be included with this tarball.
123