summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--INSTALL15
-rw-r--r--Makefile40
-rwxr-xr-xconfigure7
-rw-r--r--doc/index.html10
-rw-r--r--doc/upgrade.html7
-rw-r--r--package/info2
-rwxr-xr-xtools/gen-deps.sh4
7 files changed, 56 insertions, 29 deletions
diff --git a/INSTALL b/INSTALL
index a7f05d2..bc11077 100644
--- a/INSTALL
+++ b/INSTALL
@@ -6,11 +6,11 @@ Build Instructions
- A Linux-based system with a standard C development environment
- GNU make version 4.0 or later
- - skalibs version 2.3.5.1 or later: http://skarnet.org/software/skalibs/
- - execline version 2.1.2.2 or later: http://skarnet.org/software/execline/
- - s6-portable-utils version 2.0.5.0 or later: http://skarnet.org/software/s6-portable-utils/
- - s6-linux-utils version 2.0.2.1 or later: http://skarnet.org/software/s6-linux-utils/
- - s6 version 2.1.6.0 or later: http://skarnet.org/software/s6/
+ - skalibs version 2.3.6.1 or later: http://skarnet.org/software/skalibs/
+ - execline version 2.1.3.1 or later: http://skarnet.org/software/execline/
+ - s6-portable-utils version 2.0.5.1 or later: http://skarnet.org/software/s6-portable-utils/
+ - s6-linux-utils version 2.0.2.2 or later: http://skarnet.org/software/s6-linux-utils/
+ - s6 version 2.2.0.1 or later: http://skarnet.org/software/s6/
Note that all those are build-time dependencies, and they are
*also* run-time dependencies when you use the init binary created
@@ -20,6 +20,11 @@ by s6-linux-init-maker.
version 2.6.32 or later. However, it should not be too hard to port to
other Unix-like operating systems.
+ The s6-linux-init-maker binary will actually build *and run* on
+another operating system; however, the scripts it produces depend on
+s6-linux-utils binaries, which are really Linux-specific - so those
+scripts will not run properly on another OS.
+
* Standard usage
--------------
diff --git a/Makefile b/Makefile
index 7ff52e7..29a1875 100644
--- a/Makefile
+++ b/Makefile
@@ -18,9 +18,24 @@ STATIC_LIBS :=
SHARED_LIBS :=
INTERNAL_LIBS :=
EXTRA_TARGETS :=
+LIB_DEFS :=
-include config.mak
+
+define library_definition =
+LIB$(firstword $(subst =, ,$(1))) := lib$(lastword $(subst =, ,$(1))).$(if $(DO_ALLSTATIC),a,so).xyzzy
+ifdef DO_SHARED
+SHARED_LIBS += lib$(lastword $(subst =, ,$(1))).so.xyzzy
+endif
+ifdef DO_STATIC
+STATIC_LIBS += lib$(lastword $(subst =, ,$(1))).a.xyzzy
+endif
+endef
+
include package/targets.mak
+
+$(foreach var,$(LIB_DEFS),$(eval $(call library_definition,$(var))))
+
include package/deps.mak
version_m := $(basename $(version))
@@ -67,11 +82,11 @@ ifneq ($(strip $(ALL_BINS)),)
endif
install: install-dynlib install-libexec install-bin install-sbin install-lib install-include
-install-dynlib: $(SHARED_LIBS:lib%.so=$(DESTDIR)$(dynlibdir)/lib%.so)
+install-dynlib: $(SHARED_LIBS:lib%.so.xyzzy=$(DESTDIR)$(dynlibdir)/lib%.so)
install-libexec: $(LIBEXEC_TARGETS:%=$(DESTDIR)$(libexecdir)/%)
install-bin: $(BIN_TARGETS:%=$(DESTDIR)$(bindir)/%)
install-sbin: $(SBIN_TARGETS:%=$(DESTDIR)$(sbindir)/%)
-install-lib: $(STATIC_LIBS:lib%.a=$(DESTDIR)$(libdir)/lib%.a)
+install-lib: $(STATIC_LIBS:lib%.a.xyzzy=$(DESTDIR)$(libdir)/lib%.a)
install-include: $(ALL_INCLUDES:src/include/$(package)/%.h=$(DESTDIR)$(includedir)/$(package)/%.h)
install-data: $(ALL_DATA:src/etc/%=$(DESTDIR)$(datadir)/%)
@@ -80,7 +95,7 @@ ifneq ($(exthome),)
update:
exec $(INSTALL) -l $(notdir $(home)) $(DESTDIR)$(exthome)
-global-links: $(DESTDIR)$(exthome) $(SHARED_LIBS:lib%.so=$(DESTDIR)$(sproot)/library.so/lib%.so) $(BIN_TARGETS:%=$(DESTDIR)$(sproot)/command/%) $(SBIN_TARGETS:%=$(DESTDIR)$(sproot)/command/%)
+global-links: $(DESTDIR)$(exthome) $(SHARED_LIBS:lib%.so.xyzzy=$(DESTDIR)$(sproot)/library.so/lib%.so) $(BIN_TARGETS:%=$(DESTDIR)$(sproot)/command/%) $(SBIN_TARGETS:%=$(DESTDIR)$(sproot)/command/%)
$(DESTDIR)$(sproot)/command/%: $(DESTDIR)$(home)/command/%
exec $(INSTALL) -D -l ..$(subst $(sproot),,$(exthome))/command/$(<F) $@
@@ -95,13 +110,12 @@ endif
$(DESTDIR)$(datadir)/%: src/etc/%
exec $(INSTALL) -D -m 644 $< $@
-
-$(DESTDIR)$(dynlibdir)/lib%.so: lib%.so
+$(DESTDIR)$(dynlibdir)/lib%.so: lib%.so.xyzzy
$(INSTALL) -D -m 755 $< $@.$(version) && \
- $(INSTALL) -l $<.$(version) $@.$(version_m) && \
- $(INSTALL) -l $<.$(version_m) $@.$(version_M) && \
- $(INSTALL) -l $<.$(version_M) $@.$(version_l) && \
- exec $(INSTALL) -l $<.$(version_l) $@
+ $(INSTALL) -l $(@F).$(version) $@.$(version_m) && \
+ $(INSTALL) -l $(@F).$(version_m) $@.$(version_M) && \
+ $(INSTALL) -l $(@F).$(version_M) $@.$(version_l) && \
+ exec $(INSTALL) -l $(@F).$(version_l) $@
$(DESTDIR)$(libexecdir)/% $(DESTDIR)$(bindir)/% $(DESTDIR)$(sbindir)/%: % package/modes
exec $(INSTALL) -D -m 600 $< $@
@@ -109,7 +123,7 @@ $(DESTDIR)$(libexecdir)/% $(DESTDIR)$(bindir)/% $(DESTDIR)$(sbindir)/%: % packag
if [ x$$owner != x ] ; then chown -- $$owner $@ ; fi && \
chmod $$mode $@ ; }
-$(DESTDIR)$(libdir)/lib%.a: lib%.a
+$(DESTDIR)$(libdir)/lib%.a: lib%.a.xyzzy
exec $(INSTALL) -D -m 644 $< $@
$(DESTDIR)$(includedir)/$(package)/%.h: src/include/$(package)/%.h
@@ -124,12 +138,12 @@ $(DESTDIR)$(includedir)/$(package)/%.h: src/include/$(package)/%.h
$(ALL_BINS):
exec $(REALCC) -o $@ $(CFLAGS_ALL) $(LDFLAGS_ALL) $(LDFLAGS_NOSHARED) $^ $(EXTRA_LIBS) $(LDLIBS_ALL)
-lib%.a:
+lib%.a.xyzzy:
exec $(AR) rc $@ $^
exec $(RANLIB) $@
-lib%.so:
- exec $(REALCC) -o $@ $(CFLAGS_ALL) $(CFLAGS_SHARED) $(LDFLAGS_ALL) $(LDFLAGS_SHARED) -Wl,-soname,$@.$(version_l) $^
+lib%.so.xyzzy:
+ exec $(REALCC) -o $@ $(CFLAGS_ALL) $(CFLAGS_SHARED) $(LDFLAGS_ALL) $(LDFLAGS_SHARED) -Wl,-soname,$(patsubst lib%.so.xyzzy,lib%.so.$(version_l),$@) $^
.PHONY: it all clean distclean tgz strip install install-dynlib install-bin install-sbin install-lib install-include install-data
diff --git a/configure b/configure
index 5244a37..23bef2c 100755
--- a/configure
+++ b/configure
@@ -358,14 +358,15 @@ LDFLAGS := $LDFLAGS_AUTO
LDFLAGS_NOSHARED := $LDFLAGS_NOSHARED
CROSS_COMPILE := $cross
-vpath lib%a$vpaths
+vpath lib%.a$vpaths
+vpath lib%.so$vpathd
EOF
if $allstatic ; then
echo ".LIBPATTERNS := lib%.a"
echo "DO_ALLSTATIC := 1"
- vpathd=
+else
+ echo ".LIBPATTERNS := lib%.so"
fi
- echo "vpath lib%.so$vpathd"
if $static ; then
echo "DO_STATIC := 1"
else
diff --git a/doc/index.html b/doc/index.html
index c47d47a..ed31f82 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -50,15 +50,15 @@ a small FAQ.
<li> A Linux-based system with a standard C development environment </li>
<li> GNU make, version 4.0 or later </li>
<li> <a href="http://skarnet.org/software/skalibs/">skalibs</a> version
-2.3.5.1 or later </li>
+2.3.6.1 or later </li>
<li> <a href="http://skarnet.org/software/execline/">execline</a> version
-2.1.2.2 or later </li>
+2.1.3.1 or later </li>
<li> <a href="http://skarnet.org/software/s6-portable-utils/">s6-portable-utils</a> version
-2.0.5.0 or later </li>
+2.0.5.1 or later </li>
<li> <a href="http://skarnet.org/software/s6-linux-utils/">s6-linux-utils</a> version
-2.0.2.1 or later </li>
+2.0.2.2 or later </li>
<li> <a href="http://skarnet.org/software/s6/">s6</a> version
-2.1.6.0 or later </li>
+2.2.0.1 or later </li>
</ul>
<p>
diff --git a/doc/upgrade.html b/doc/upgrade.html
index b50899a..a39b7b4 100644
--- a/doc/upgrade.html
+++ b/doc/upgrade.html
@@ -18,6 +18,13 @@
<h1> What has changed in s6-linux-init </h1>
+<h2> in 0.0.1.3 </h2>
+
+<ul>
+ <li> <a href="http://skarnet.org/software/s6/">s6</a> dependency
+bumped to 2.3.6.1. </li>
+</ul>
+
<h2> in 0.0.1.2 </h2>
<ul>
diff --git a/package/info b/package/info
index 64f6dd1..08b0feb 100644
--- a/package/info
+++ b/package/info
@@ -1,4 +1,4 @@
package=s6-linux-init
-version=0.0.1.2
+version=0.0.1.3
category=admin
package_macro_name=S6_LINUX_INIT
diff --git a/tools/gen-deps.sh b/tools/gen-deps.sh
index 4615f28..1ca66ea 100755
--- a/tools/gen-deps.sh
+++ b/tools/gen-deps.sh
@@ -60,8 +60,8 @@ for dir in $(ls -1 src | grep -v ^include) ; do
while read dep ; do
deps="$deps src/$dir/$dep"
done < src/$dir/deps-lib/$file
- echo "lib$file.a:$deps"
- echo "lib${file}.so:$(echo "$deps" | sed 's/\.o/.lo/g')"
+ echo "lib$file.a.xyzzy: $deps"
+ echo "lib${file}.so.xyzzy: $(echo "$deps" | sed 's/\.o/.lo/g')"
done
for file in $(ls -1 src/$dir/deps-exe) ; do