Hi,
On 06/04/2024 08:25, Herbert Xu wrote:
[...]
> Thanks but this needs to be split up into smaller patches so
> that each patch fixes just one problem.
I've now split up the patch into parts. In addition to just the
splitting, the patch set contains the following changes/improvements:
- adapted it to dash 0.5.12 which has been released in the meantime,
- some cleanup,
- it now also compiles & works on Solaris 10 & 11
The patches only list the changes to the primary sources (such as
Makefile.am) Derived files, such as Makefile.in are not included, even
though they would be part of the source tarball.
For simplicity, I attached the patches as text files rather than
pasting them into the mail. Indeed, I no longer trust thunderbird not
to munge them if pasted. I hope this is ok.
Here comes the first part: 01-remove-extraneous
This simply removes declarations from dash that are not used anyways,
and that might needlessly clash with system definitions later on.
Regards,
Alain
diff -X ../exclude.txt -urN dash-0.5.12/src/bltin/bltin.h dash-0.5.12+01-remove-extraneous/src/bltin/bltin.h
--- dash-0.5.12/src/bltin/bltin.h 2020-06-03 01:19:23.000000000 +0000
+++ dash-0.5.12+01-remove-extraneous/src/bltin/bltin.h 2024-10-20 18:26:46.960598638 +0000
@@ -63,7 +63,6 @@
#define fputs outstr
#define fflush flushout
#define fileno(f) ((f)->fd)
-#define ferror outerr
#endif
#define INITARGS(argv)
#define error sh_error
diff -X ../exclude.txt -urN dash-0.5.12/src/jobs.c dash-0.5.12+01-remove-extraneous/src/jobs.c
--- dash-0.5.12/src/jobs.c 2022-01-20 05:54:13.000000000 +0000
+++ dash-0.5.12+01-remove-extraneous/src/jobs.c 2024-10-27 19:53:42.912675611 +0000
@@ -112,9 +112,6 @@
STATIC void forkchild(struct job *, union node *, int);
STATIC void forkparent(struct job *, union node *, int, pid_t);
STATIC int dowait(int, struct job *);
-#ifdef SYSV
-STATIC int onsigchild(void);
-#endif
STATIC int waitproc(int, int *);
STATIC char *commandtext(union node *);
STATIC void cmdtxt(union node *);
diff -X ../exclude.txt -urN dash-0.5.12/src/mystring.c dash-0.5.12+01-remove-extraneous/src/mystring.c
--- dash-0.5.12/src/mystring.c 2022-12-11 06:29:21.000000000 +0000
+++ dash-0.5.12+01-remove-extraneous/src/mystring.c 2024-10-20 18:27:56.634245499 +0000
@@ -46,7 +46,6 @@
#include <errno.h>
#include <inttypes.h>
#include <limits.h>
-#include <inttypes.h>
#include <stdlib.h>
#include "shell.h"
#include "syntax.h"