summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2021-08-10 18:24:46 +0000
committerLaurent Bercot <ska@appnovation.com>2021-08-10 18:24:46 +0000
commit6696cee3bd309f61fc6c945ef747262a845e9267 (patch)
tree6bb1a8f54ff0a590d375aece2af01009c94d9206
parent4a773dc6d9d36844501994720aca31a4f50d7d52 (diff)
downloads6-linux-init-6696cee3bd309f61fc6c945ef747262a845e9267.tar.xz
Prepare for 1.0.6.4, adapt to skalibs-2.11.0.0
Signed-off-by: Laurent Bercot <ska@appnovation.com>
-rw-r--r--CONTRIBUTING5
-rw-r--r--DCO37
-rw-r--r--INSTALL10
-rw-r--r--NEWS6
-rw-r--r--doc/index.html16
-rw-r--r--doc/upgrade.html15
-rw-r--r--package/info2
-rw-r--r--src/init/s6-linux-init-maker.c8
-rw-r--r--src/init/s6-linux-init-telinit.c2
-rw-r--r--src/init/s6-linux-init.c2
-rw-r--r--src/misc/s6-linux-init-echo.c2
-rw-r--r--src/shutdown/hpr.h2
-rw-r--r--src/shutdown/hpr_shutdown.c2
-rw-r--r--src/shutdown/s6-linux-init-hpr.c2
-rw-r--r--src/shutdown/s6-linux-init-shutdown.c16
-rw-r--r--src/shutdown/s6-linux-init-shutdownd.c14
16 files changed, 102 insertions, 39 deletions
diff --git a/CONTRIBUTING b/CONTRIBUTING
new file mode 100644
index 0000000..6279422
--- /dev/null
+++ b/CONTRIBUTING
@@ -0,0 +1,5 @@
+ Please add a Signed-Off-By: line at the end of your commit,
+which certifies that you have the right and authority to pass
+it on as an open-source patch, as explicited in the Developer's
+Certificate of Origin available in this project's DCO file,
+or at https://developercertificate.org/
diff --git a/DCO b/DCO
new file mode 100644
index 0000000..8201f99
--- /dev/null
+++ b/DCO
@@ -0,0 +1,37 @@
+Developer Certificate of Origin
+Version 1.1
+
+Copyright (C) 2004, 2006 The Linux Foundation and its contributors.
+1 Letterman Drive
+Suite D4700
+San Francisco, CA, 94129
+
+Everyone is permitted to copy and distribute verbatim copies of this
+license document, but changing it is not allowed.
+
+
+Developer's Certificate of Origin 1.1
+
+By making a contribution to this project, I certify that:
+
+(a) The contribution was created in whole or in part by me and I
+ have the right to submit it under the open source license
+ indicated in the file; or
+
+(b) The contribution is based upon previous work that, to the best
+ of my knowledge, is covered under an appropriate open source
+ license and I have the right under that license to submit that
+ work with modifications, whether created in whole or in part
+ by me, under the same open source license (unless I am
+ permitted to submit under a different license), as indicated
+ in the file; or
+
+(c) The contribution was provided directly to me by some other
+ person who certified (a), (b) or (c) and I have not modified
+ it.
+
+(d) I understand and agree that this project and the contribution
+ are public and that a record of the contribution (including all
+ personal information I submit with it, including my sign-off) is
+ maintained indefinitely and may be redistributed consistent with
+ this project or the open source license(s) involved.
diff --git a/INSTALL b/INSTALL
index ec61830..f78c0d1 100644
--- a/INSTALL
+++ b/INSTALL
@@ -6,11 +6,11 @@ Build Instructions
- A Linux-based system with a standard C development environment
- GNU make version 3.81 or later
- - skalibs version 2.10.0.3 or later: https://skarnet.org/software/skalibs/
- - Optional: nsss version 0.1.0.1 or later: https://skarnet.org/software/nsss/
- - Optional: utmps version 0.1.0.2 or later: https://skarnet.org/software/utmps/
- - execline version 2.8.0.1 or later: https://skarnet.org/software/execline/
- - s6 version 2.10.0.3 or later: https://skarnet.org/software/s6/
+ - skalibs version 2.11.0.0 or later: https://skarnet.org/software/skalibs/
+ - Optional: nsss version 0.1.0.2 or later: https://skarnet.org/software/nsss/
+ - Optional: utmps version 0.1.0.3 or later: https://skarnet.org/software/utmps/
+ - execline version 2.8.1.0 or later: https://skarnet.org/software/execline/
+ - s6 version 2.11.0.0 or later: https://skarnet.org/software/s6/
This software is Linux-specific. It will run on a Linux kernel,
version 2.6.32 or later. However, it should not be too hard to port to
diff --git a/NEWS b/NEWS
index 6648bc9..5fc2a6a 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,11 @@
Changelog for s6-linux-init.
+In 1.0.6.4
+----------
+
+ - Adapt to skalibs-2.11.0.0.
+
+
In 1.0.6.3
----------
diff --git a/doc/index.html b/doc/index.html
index f5e78c4..b6ee197 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -73,16 +73,16 @@ kernel command line </li>
<li> A Linux-based system with a standard C development environment </li>
<li> GNU make, version 3.81 or later </li>
<li> <a href="//skarnet.org/software/skalibs/">skalibs</a> version
-2.10.0.3 or later. It's a build-time requirement. It's also a run-time
+2.11.0.0 or later. It's a build-time requirement. It's also a run-time
requirement (for <a href="s6-linux-init-maker.html">s6-linux-init-maker</a>)
as well as a boot-time requirement (i.e. a run-time requirement for the
programs used when you boot a system created with
<a href="s6-linux-init-maker.html">s6-linux-init-maker</a>) if you link
against the shared version of the skalibs library. </li>
<li> <a href="//skarnet.org/software/execline/">execline</a> version
-2.8.0.1 or later. It is a build-time and boot-time requirement. </li>
+2.8.1.0 or later. It is a build-time and boot-time requirement. </li>
<li> <a href="//skarnet.org/software/s6/">s6</a> version
-2.10.0.3 or later. It is a build-time and boot-time requirement. </li>
+2.11.0.0 or later. It is a build-time and boot-time requirement. </li>
</ul>
<p>
@@ -93,10 +93,10 @@ against the shared version of the skalibs library. </li>
<li> If you're using <a href="https://www.musl-libc.org/">musl</a> and
want nsswitch-like functionality:
<a href="//skarnet.org/software/nsss/">nsss</a> version
-0.1.0.1 or later (build-time and boot-time) </li>
+0.1.0.2 or later (build-time and boot-time) </li>
<li> If you want secure utmp functionality:
<a href="//skarnet.org/software/utmps/">utmps</a> version
-0.1.0.2 or later (build-time and boot-time) </li>
+0.1.0.3 or later (build-time and boot-time) </li>
</ul>
<p>
@@ -116,7 +116,7 @@ all the other packages against the <em>static</em> version of libskarnet.
<ul>
<li> The current released version of s6-linux-init is
-<a href="s6-linux-init-1.0.6.3.tar.gz">1.0.6.3</a>. </li>
+<a href="s6-linux-init-1.0.6.4.tar.gz">1.0.6.4</a>. </li>
<li> Alternatively, you can checkout a copy of the
<a href="//git.skarnet.org/cgi-bin/cgit.cgi/s6-linux-init/">s6-linux-init
git repository</a>:
@@ -177,8 +177,8 @@ permanent error (such as a misuse).
<ul>
<li> <tt>s6-linux-init</tt> is discussed on the
-<a href="//skarnet.org/lists.html#skaware">skaware</a> and
-<a href="//skarnet.org/lists.html#supervision">supervision</a>
+<a href="//skarnet.org/lists/#skaware">skaware</a> and
+<a href="//skarnet.org/lists/#supervision">supervision</a>
mailing-lists. </li>
<li> There is a <tt>#s6</tt> IRC channel on OFTC. Sometimes people
are there and even answer questions. </li>
diff --git a/doc/upgrade.html b/doc/upgrade.html
index df02152..8cd21a9 100644
--- a/doc/upgrade.html
+++ b/doc/upgrade.html
@@ -18,6 +18,21 @@
<h1> What has changed in s6-linux-init </h1>
+<h2> in 1.0.6.4 </h2>
+
+<ul>
+ <li> <a href="//skarnet.org/software/skalibs/">skalibs</a>
+dependency bumped to 2.11.0.0. </li>
+ <li> <a href="//skarnet.org/software/nsss/">nsss</a>
+optional dependency bumped to 0.1.0.2. </li>
+ <li> <a href="//skarnet.org/software/utmps/">utmps</a>
+optional dependency bumped to 0.1.0.3. </li>
+ <li> <a href="//skarnet.org/software/execline/">execline</a>
+dependency bumped to 2.8.1.0. </li>
+ <li> <a href="//skarnet.org/software/s6/">s6</a>
+dependency bumped to 2.11.0.0. </li>
+</ul>
+
<h2> in 1.0.6.3 </h2>
<ul>
diff --git a/package/info b/package/info
index df01859..ecf36f3 100644
--- a/package/info
+++ b/package/info
@@ -1,4 +1,4 @@
package=s6-linux-init
-version=1.0.6.3
+version=1.0.6.4
category=admin
package_macro_name=S6_LINUX_INIT
diff --git a/src/init/s6-linux-init-maker.c b/src/init/s6-linux-init-maker.c
index bc06836..2cfb35e 100644
--- a/src/init/s6-linux-init-maker.c
+++ b/src/init/s6-linux-init-maker.c
@@ -64,8 +64,8 @@ static gid_t mygid = -1 ;
static char const *utmp_user = 0 ;
#endif
-typedef int writetobuf_func_t (buffer *, char const *) ;
-typedef writetobuf_func_t *writetobuf_func_t_ref ;
+typedef int writetobuf_func (buffer *, char const *) ;
+typedef writetobuf_func *writetobuf_func_ref ;
#define put_shebang(b) put_shebang_options((b), 0)
@@ -383,7 +383,7 @@ static void auto_fifo (char const *base, char const *fifo)
}
}
-static void auto_script (char const *base, char const *file, writetobuf_func_t_ref scriptf, char const *data)
+static void auto_script (char const *base, char const *file, writetobuf_func_ref scriptf, char const *data)
{
char buf[4096] ;
buffer b ;
@@ -639,7 +639,7 @@ int main (int argc, char const *const *argv, char const *const *envp)
{
PROG = "s6-linux-init-maker" ;
{
- subgetopt_t l = SUBGETOPT_ZERO ;
+ subgetopt l = SUBGETOPT_ZERO ;
for (;;)
{
int opt = subgetopt_r(argc, argv, OPTION_STRING, &l) ;
diff --git a/src/init/s6-linux-init-telinit.c b/src/init/s6-linux-init-telinit.c
index 2baa6c2..65fb491 100644
--- a/src/init/s6-linux-init-telinit.c
+++ b/src/init/s6-linux-init-telinit.c
@@ -22,7 +22,7 @@ int main (int argc, char const *const *argv, char const *const *envp)
char const *newargv[8] = { S6_EXTBINPREFIX "s6-sudo", "-e", "-T", "3600000", "--", RUNLEVELD_PATH, 0, 0 } ;
PROG = "s6-linux-init-telinit" ;
{
- subgetopt_t l = SUBGETOPT_ZERO ;
+ subgetopt l = SUBGETOPT_ZERO ;
for (;;)
{
int opt = subgetopt_r(argc, argv, "c:p:s:m:d:D:nNCB", &l) ;
diff --git a/src/init/s6-linux-init.c b/src/init/s6-linux-init.c
index 9e2d86e..6bf22b8 100644
--- a/src/init/s6-linux-init.c
+++ b/src/init/s6-linux-init.c
@@ -136,7 +136,7 @@ int main (int argc, char const **argv, char const *const *envp)
}
{
- subgetopt_t l = SUBGETOPT_ZERO ;
+ subgetopt l = SUBGETOPT_ZERO ;
for (;;)
{
int opt = subgetopt_r(argc, argv, "c:p:s:m:d:D:nNCB", &l) ;
diff --git a/src/misc/s6-linux-init-echo.c b/src/misc/s6-linux-init-echo.c
index 483efe2..a59eae7 100644
--- a/src/misc/s6-linux-init-echo.c
+++ b/src/misc/s6-linux-init-echo.c
@@ -12,7 +12,7 @@ int main (int argc, char const *const *argv)
char donl = 1 ;
PROG = "s6-linux-init-echo" ;
{
- subgetopt_t l = SUBGETOPT_ZERO ;
+ subgetopt l = SUBGETOPT_ZERO ;
for (;;)
{
int opt = subgetopt_r(argc, argv, "ns:", &l) ;
diff --git a/src/shutdown/hpr.h b/src/shutdown/hpr.h
index 2c545a5..fd268e8 100644
--- a/src/shutdown/hpr.h
+++ b/src/shutdown/hpr.h
@@ -17,7 +17,7 @@
#define hpr_send(s, n) openwritenclose_unsafe(INITCTL, (s), n)
#define hpr_cancel() hpr_send("c", 1)
-extern int hpr_shutdown (unsigned int, tain_t const *, unsigned int) ;
+extern int hpr_shutdown (unsigned int, tain const *, unsigned int) ;
extern void hpr_wall (char const *) ;
extern void hpr_wallv (struct iovec const *, unsigned int) ;
extern void hpr_confirm_hostname (void) ;
diff --git a/src/shutdown/hpr_shutdown.c b/src/shutdown/hpr_shutdown.c
index 3ede92d..c5e98b1 100644
--- a/src/shutdown/hpr_shutdown.c
+++ b/src/shutdown/hpr_shutdown.c
@@ -7,7 +7,7 @@
#include "hpr.h"
-int hpr_shutdown (unsigned int what, tain_t const *when, unsigned int grace)
+int hpr_shutdown (unsigned int what, tain const *when, unsigned int grace)
{
char pack[5 + TAIN_PACK] = { "Shpr"[what] } ;
tain_pack(pack+1, when) ;
diff --git a/src/shutdown/s6-linux-init-hpr.c b/src/shutdown/s6-linux-init-hpr.c
index a874ac3..fe8a77d 100644
--- a/src/shutdown/s6-linux-init-hpr.c
+++ b/src/shutdown/s6-linux-init-hpr.c
@@ -46,7 +46,7 @@ int main (int argc, char const *const *argv)
PROG = "s6-linux-init-hpr" ;
{
- subgetopt_t l = SUBGETOPT_ZERO ;
+ subgetopt l = SUBGETOPT_ZERO ;
for (;;)
{
int opt = subgetopt_r(argc, argv, "hprfdwWni", &l) ;
diff --git a/src/shutdown/s6-linux-init-shutdown.c b/src/shutdown/s6-linux-init-shutdown.c
index ce7f01f..2e81c3b 100644
--- a/src/shutdown/s6-linux-init-shutdown.c
+++ b/src/shutdown/s6-linux-init-shutdown.c
@@ -49,9 +49,9 @@ static inline void add_one_day (struct tm *tm)
tm->tm_year++ ;
}
-static inline void parse_hourmin (tain_t *when, char const *s)
+static inline void parse_hourmin (tain *when, char const *s)
{
- tai_t taithen ;
+ tai taithen ;
struct tm tmthen ;
unsigned int hour, minute ;
size_t len = uint_scan(s, &hour) ;
@@ -67,25 +67,25 @@ static inline void parse_hourmin (tain_t *when, char const *s)
tmthen.tm_min = minute ;
tmthen.tm_sec = 0 ;
if (!tai_from_localtm(&taithen, &tmthen))
- strerr_diefu1sys(111, "assemble broken-down time into tain_t") ;
+ strerr_diefu1sys(111, "assemble broken-down time into tain") ;
if (tai_less(&taithen, tain_secp(&STAMP)))
{
add_one_day(&tmthen) ;
if (!tai_from_localtm(&taithen, &tmthen))
- strerr_diefu1sys(111, "assemble broken-down time into tain_t") ;
+ strerr_diefu1sys(111, "assemble broken-down time into tain") ;
}
when->sec = taithen ;
when->nano = 0 ;
}
-static void parse_mins (tain_t *when, char const *s)
+static void parse_mins (tain *when, char const *s)
{
unsigned int mins ;
if (!uint0_scan(s, &mins)) dieusage() ;
tain_addsec_g(when, mins * 60) ;
}
-static inline void parse_time (tain_t *when, char const *s)
+static inline void parse_time (tain *when, char const *s)
{
if (!strcmp(s, "now")) tain_copynow(when) ;
else if (s[0] == '+') parse_mins(when, s+1) ;
@@ -257,11 +257,11 @@ int main (int argc, char const *const *argv)
int doactl = 0 ;
int docancel = 0 ;
int doconfirm = 0 ;
- tain_t when ;
+ tain when ;
PROG = "s6-linux-init-shutdown" ;
{
- subgetopt_t l = SUBGETOPT_ZERO ;
+ subgetopt l = SUBGETOPT_ZERO ;
for (;;)
{
int opt = subgetopt_r(argc, argv, "HPhprkafFcit:", &l) ;
diff --git a/src/shutdown/s6-linux-init-shutdownd.c b/src/shutdown/s6-linux-init-shutdownd.c
index 16e0780..e448b92 100644
--- a/src/shutdown/s6-linux-init-shutdownd.c
+++ b/src/shutdown/s6-linux-init-shutdownd.c
@@ -100,7 +100,7 @@ static inline void run_stage3 (char const *basedir)
else strerr_warnwu2sys("spawn ", stage3) ;
}
-static inline void prepare_shutdown (buffer *b, tain_t *deadline, unsigned int *grace_time)
+static inline void prepare_shutdown (buffer *b, tain *deadline, unsigned int *grace_time)
{
uint32_t u ;
char pack[TAIN_PACK + 4] ;
@@ -113,7 +113,7 @@ static inline void prepare_shutdown (buffer *b, tain_t *deadline, unsigned int *
if (u && u <= 300000) *grace_time = u ;
}
-static inline void handle_fifo (buffer *b, char *what, tain_t *deadline, unsigned int *grace_time)
+static inline void handle_fifo (buffer *b, char *what, tain *deadline, unsigned int *grace_time)
{
for (;;)
{
@@ -255,7 +255,7 @@ static inline void unsupervise_tree (void)
int main (int argc, char const *const *argv)
{
unsigned int grace_time = 3000 ;
- tain_t deadline ;
+ tain deadline ;
int fdr, fdw ;
buffer b ;
char what = 'S' ;
@@ -263,7 +263,7 @@ int main (int argc, char const *const *argv)
PROG = "s6-linux-init-shutdownd" ;
{
- subgetopt_t l = SUBGETOPT_ZERO ;
+ subgetopt l = SUBGETOPT_ZERO ;
for (;;)
{
int opt = subgetopt_r(argc, argv, "c:g:CB", &l) ;
@@ -312,8 +312,8 @@ int main (int argc, char const *const *argv)
fdw = open_write(SHUTDOWND_FIFO) ;
if (fdw == -1 || coe(fdw) == -1)
strerr_diefu3sys(111, "open ", SHUTDOWND_FIFO, " for writing") ;
- if (sig_ignore(SIGPIPE) == -1)
- strerr_diefu1sys(111, "sig_ignore SIGPIPE") ;
+ if (!sig_altignore(SIGPIPE))
+ strerr_diefu1sys(111, "ignore SIGPIPE") ;
buffer_init(&b, &buffer_read, fdr, buf, 64) ;
tain_now_set_stopwatch_g() ;
tain_add_g(&deadline, &tain_infinite_relative) ;
@@ -344,7 +344,7 @@ int main (int argc, char const *const *argv)
prepare_stage4(basedir, what) ;
unsupervise_tree() ;
- if (sig_ignore(SIGTERM) == -1) strerr_warnwu1sys("sig_ignore SIGTERM") ;
+ if (!sig_ignore(SIGTERM)) strerr_warnwu1sys("ignore SIGTERM") ;
if (!inns)
{
sync() ;