diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2020-12-06 21:07:44 +0000 |
---|---|---|
committer | Laurent Bercot <ska-skaware@skarnet.org> | 2020-12-06 21:07:44 +0000 |
commit | 46b44d5f433764fb7976da47f449b35d31b04098 (patch) | |
tree | 5ad4103bc63ec63867434a2a65b355dcf27b5d87 | |
parent | 84a2d25e5995a55729b27cbd0502b5cb2745e554 (diff) | |
download | utmps-46b44d5f433764fb7976da47f449b35d31b04098.tar.gz utmps-46b44d5f433764fb7976da47f449b35d31b04098.tar.xz utmps-46b44d5f433764fb7976da47f449b35d31b04098.zip |
Prepare for 0.1.0.0; don't install utmpx.h by default
New --enable-libc-includes configure option to overwrite the system utmpx.h
-rw-r--r-- | Makefile | 6 | ||||
-rw-r--r-- | NEWS | 5 | ||||
-rwxr-xr-x | configure | 9 | ||||
-rw-r--r-- | doc/index.html | 4 | ||||
-rw-r--r-- | doc/libutmps/index.html | 25 | ||||
-rw-r--r-- | doc/upgrade.html | 6 | ||||
-rw-r--r-- | package/info | 2 | ||||
-rw-r--r-- | package/targets.mak | 4 |
8 files changed, 50 insertions, 11 deletions
diff --git a/Makefile b/Makefile index 9cb6494..9dd4ab1 100644 --- a/Makefile +++ b/Makefile @@ -57,7 +57,7 @@ ALL_BINS := $(LIBEXEC_TARGETS) $(BIN_TARGETS) ALL_LIBS := $(SHARED_LIBS) $(STATIC_LIBS) $(INTERNAL_LIBS) ALL_INCLUDES := $(wildcard src/include/$(package)/*.h) -all: $(ALL_LIBS) $(ALL_BINS) $(ALL_INCLUDES) src/include/utmpx.h +all: $(ALL_LIBS) $(ALL_BINS) $(ALL_INCLUDES) $(EXTRA_INCLUDES) clean: @exec rm -f $(ALL_LIBS) $(ALL_BINS) $(wildcard src/*/*.o src/*/*.lo) $(EXTRA_TARGETS) @@ -86,7 +86,7 @@ install-dynlib: $(SHARED_LIBS:lib%.so.xyzzy=$(DESTDIR)$(dynlibdir)/lib%.so) install-libexec: $(LIBEXEC_TARGETS:%=$(DESTDIR)$(libexecdir)/%) install-bin: $(BIN_TARGETS:%=$(DESTDIR)$(bindir)/%) install-lib: $(STATIC_LIBS:lib%.a.xyzzy=$(DESTDIR)$(libdir)/lib%.a) -install-include: $(ALL_INCLUDES:src/include/$(package)/%.h=$(DESTDIR)$(includedir)/$(package)/%.h) $(DESTDIR)$(includedir)/utmpx.h +install-include: $(ALL_INCLUDES:src/include/$(package)/%.h=$(DESTDIR)$(includedir)/$(package)/%.h) $(EXTRA_INCLUDES:src/include/%.h=$(DESTDIR)$(includedir)/%.h) install-data: $(ALL_DATA:src/etc/%=$(DESTDIR)$(datadir)/%) ifneq ($(exthome),) @@ -128,7 +128,7 @@ $(DESTDIR)$(libdir)/lib%.a: lib%.a.xyzzy $(DESTDIR)$(includedir)/$(package)/%.h: src/include/$(package)/%.h exec $(INSTALL) -D -m 644 $< $@ -$(DESTDIR)$(includedir)/utmpx.h: src/include/utmpx.h +$(DESTDIR)$(includedir)/%.h: src/include/%.h exec $(INSTALL) -D -m 644 $< $@ %.o: %.c diff --git a/NEWS b/NEWS index 131d82c..8a5f857 100644 --- a/NEWS +++ b/NEWS @@ -1,9 +1,12 @@ Changelog for utmps. -In 0.0.3.3 +In 0.1.0.0 ---------- - Bugfixes. + - utmpx.h is not installed by default anymore. +You now need to explicitly give the --enable-libc-includes +configure option. In 0.0.3.2 diff --git a/configure b/configure index 545c3c6..fcd5d2a 100755 --- a/configure +++ b/configure @@ -46,6 +46,7 @@ Optional features: --enable-absolute-paths do not rely on PATH to access this package's binaries, hardcode absolute BINDIR/foobar paths instead [disabled] --enable-nsss use the nsss library for user information [disabled] + --enable-libc-includes overwrite utmpx.h in includedir [disabled] --with-utmpd-socket=PATH assume the utmpd socket is at PATH [/run/utmps/.utmpd-socket] --with-wtmpd-socket=PATH assume the wtmpd socket is at PATH [/run/utmps/.wtmpd-socket] @@ -163,6 +164,7 @@ addlibdpath='' vpaths='' vpathd='' build= +libcincludes=false utmpdpath=/run/utmps/.utmpd-socket wtmpdpath=/run/utmps/.wtmpd-socket @@ -195,6 +197,8 @@ for arg ; do --disable-slashpackage) sproot= ; slashpackage=false ;; --enable-absolute-paths|--enable-absolute-paths=yes) abspath=true ;; --disable-absolute-paths|--enable-absolute-paths=no) abspath=false ;; + --enable-libc-includes|--enable-libc-includes=yes) libcincludes=true ;; + --disable-libc-includes|--enable-libc-includes=no) libcincludes=false ;; --enable-nsss|--enable-nsss=yes) usensss=true ;; --disable-nsss|--enable-nsss=no) usensss=false ;; --enable-*|--disable-*|--with-*|--without-*|--*dir=*) ;; @@ -448,6 +452,11 @@ if $allpic ; then else echo "STATIC_LIBS_ARE_PIC :=" fi +if $libcincludes ; then + echo "DO_LIBC_INCLUDES := 1" +else + echo "DO_LIBC_INCLUDES :=" +fi if $usensss ; then echo "LIBNSSS := -lnsss" echo "MAYBEPTHREAD_LIB := -lpthread" diff --git a/doc/index.html b/doc/index.html index 247a9a0..a911019 100644 --- a/doc/index.html +++ b/doc/index.html @@ -70,13 +70,13 @@ suitable replacement for <p> utmps is free software. It is available under the -<a href="http://opensource.org/licenses/ISC">ISC license</a>. +<a href="https://opensource.org/licenses/ISC">ISC license</a>. </p> <h3> Download </h3> <ul> - <li> The current released version of utmps is <a href="utmps-0.0.3.3.tar.gz">0.0.3.3</a>. </li> + <li> The current released version of utmps is <a href="utmps-0.1.0.0.tar.gz">0.1.0.0</a>. </li> <li> Alternatively, you can checkout a copy of the <a href="//git.skarnet.org/cgi-bin/cgit.cgi/utmps/">utmps git repository</a>: diff --git a/doc/libutmps/index.html b/doc/libutmps/index.html index f2fb86f..dc41fda 100644 --- a/doc/libutmps/index.html +++ b/doc/libutmps/index.html @@ -35,6 +35,17 @@ interface, which in utmps is implemented as a series of thin wrappers around the utmps library. </p> +<p> + A suitable <tt>utmpx.h</tt> header can be found in the <tt>utmps/</tt> +subdirectory of +the header installation directory; if the <tt>--enable-libc-includes</tt> +option has been given to configure, it can also be found directly +in that directory. (Example: <tt>/usr/include/utmps/utmpz.h</tt> is +always installed, but if the option has been given at nsss build time, +<tt>/usr/include/utmpx.h</tt> is also installed and replaces the +version provided by the libc.) +</p> + <h2> Compiling </h2> <ul> @@ -42,9 +53,17 @@ around the utmps library. are visible in your header search path. </li> <li> Use <tt>#include <utmps/utmps.h></tt> </li> <li> To use the standard <tt>utmpx.h</tt> interface, you can -just <tt>#include <utmpx.h></tt>, which will work as long -as the <tt>utmps/utmpx.h</tt> header is accessible in your header -search path. </li> +just <tt>#include <utmpx.h></tt>, which will work: + <ul> + <li> either if the <tt>--enable-libc-includes</tt> option +has been given at utmps build time </li> + <li> or if you give the <tt>-I/usr/include/utmps</tt> option +to your compiler. (Depending on your standard header location, +specify that the header search path should include the +<tt>utmps</tt> subdirectory of that location.) This is useful when +the administrator did not want to overwrite the libc-provided +<tt>utmpx.h</tt> file when they installed utmps. </li> + </ul> </li> </ul> <h2> Linking </h2> diff --git a/doc/upgrade.html b/doc/upgrade.html index d700919..a01dfc3 100644 --- a/doc/upgrade.html +++ b/doc/upgrade.html @@ -18,13 +18,17 @@ <h1> What has changed in utmps </h1> -<h2> in 0.0.3.3 </h2> +<h2> in 0.1.0.0 </h2> <ul> <li> <a href="//skarnet.org/software/skalibs/">skalibs</a> dependency bumped to 2.10.0.0. </li> <li> <a href="//skarnet.org/software/s6/">s6</a> run-time dependency bumped to 2.10.0.0. </li> + <li> The <tt>utmpx.h</tt> header files is +not installed by default anymore. You now need to explicitly give the +<tt>--enable-libc-includes</tt> configure option in order to install it. The +point of this change is to avoid overwriting libc headers accidentally. </li> </ul> <h2> in 0.0.3.2 </h2> diff --git a/package/info b/package/info index d4afb81..ea11f8e 100644 --- a/package/info +++ b/package/info @@ -1,4 +1,4 @@ package=utmps -version=0.0.3.3 +version=0.1.0.0 category=admin package_macro_name=UTMPS diff --git a/package/targets.mak b/package/targets.mak index ff763be..3ff5217 100644 --- a/package/targets.mak +++ b/package/targets.mak @@ -5,3 +5,7 @@ utmps-wtmpd LIBEXEC_TARGETS := LIB_DEFS := UTMPS=utmps + +ifneq ($(DO_LIBC_INCLUDES),) +EXTRA_INCLUDES := src/include/utmpx.h +endif |