chiark
/
gitweb
/
~mdw
/
runlisp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
README.org: Clarify `free software' with a link to the FSF.
[runlisp]
/
dump-runlisp-image.c
diff --git
a/dump-runlisp-image.c
b/dump-runlisp-image.c
index 7d1d88f68b95aa41c382fba5ac7a9f893e57de83..72ce97de1ddffb0696326bbeb9b2c1a77c732615 100644
(file)
--- a/
dump-runlisp-image.c
+++ b/
dump-runlisp-image.c
@@
-547,6
+547,7
@@
static void notice_filename(const char *p, size_t sz)
if (!node) {
node = xmalloc(sizeof(*node));
treap_insert(&good, &path, node, p, sz);
if (!node) {
node = xmalloc(sizeof(*node));
treap_insert(&good, &path, node, p, sz);
+ if (verbose >= 3) moan("noticed non-junk file `%.*s'", (int)sz, p);
}
}
}
}
@@
-702,7
+703,10
@@
static void add_job(unsigned f, struct config_section *sect)
config_subst_split_var(&config, sect, runvar, &av_version);
if (!av_version.n)
lose("empty `run-script' command for Lisp implementation `%s'", name);
config_subst_split_var(&config, sect, runvar, &av_version);
if (!av_version.n)
lose("empty `run-script' command for Lisp implementation `%s'", name);
- argv_append(&av_version, xstrdup("?(lisp-implementation-version)"));
+ argv_append(&av_version,
+ config_subst_string_alloc
+ (&config, sect, "<internal>",
+ "?${lisp-version?(lisp-implementation-version)}"));
config_subst_split_var(&config, sect, dumpvar, &av_dump);
if (!av_dump.n)
lose("empty `dump-image' command for Lisp implementation `%s'", name);
config_subst_split_var(&config, sect, dumpvar, &av_dump);
if (!av_dump.n)
lose("empty `dump-image' command for Lisp implementation `%s'", name);
@@
-915,7
+919,7
@@
static void finish_job(struct job *job)
job->exit);
/* What happens next depends on the state of the job. This is the main
job->exit);
/* What happens next depends on the state of the job. This is the main
- * place which advance
d
the job state machine.
+ * place which advance
s
the job state machine.
*/
if (ok) switch (job->st) {
*/
if (ok) switch (job->st) {
@@
-993,6
+997,12
@@
static void finish_job(struct job *job)
ok = 0; break;
}
ok = 0; break;
}
+ /* Notice the image so that it doesn't get junked. */
+ if (flags&AF_JUNK) {
+ p = strrchr(job->imghash, '/'); if (p) p++; else p = job->imghash;
+ notice_filename(p, strlen(p));
+ }
+
/* Determine the basename of the final image. */
p = strrchr(job->imghash, '/'); if (p) p++; else p = job->imghash;
/* Determine the basename of the final image. */
p = strrchr(job->imghash, '/'); if (p) p++; else p = job->imghash;
@@
-1337,20
+1347,20
@@
static void help(FILE *fp)
{
version(fp); fputc('\n', fp); usage(fp);
fputs("\n\
{
version(fp); fputc('\n', fp); usage(fp);
fputs("\n\
-Help options
:
\n\
+Help options\n\
-h, --help Show this help text and exit successfully.\n\
-V, --version Show version number and exit successfully.\n\
\n\
-h, --help Show this help text and exit successfully.\n\
-V, --version Show version number and exit successfully.\n\
\n\
-Diagnostics
:
\n\
+Diagnostics\n\
-n, --dry-run Don't run run anything (useful with `-v').\n\
-q, --quiet Don't print warning messages.\n\
-v, --verbose Print informational messages (repeatable).\n\
\n\
-n, --dry-run Don't run run anything (useful with `-v').\n\
-q, --quiet Don't print warning messages.\n\
-v, --verbose Print informational messages (repeatable).\n\
\n\
-Configuration
:
\n\
+Configuration\n\
-c, --config-file=CONF Read configuration from CONF (repeatable).\n\
-o, --set-option=[SECT:]VAR=VAL Set configuration variable (repeatable).\n\
\n\
-c, --config-file=CONF Read configuration from CONF (repeatable).\n\
-o, --set-option=[SECT:]VAR=VAL Set configuration variable (repeatable).\n\
\n\
-Image dumping
:
\n\
+Image dumping\n\
-O, --output=FILE|DIR Store image(s) in FILE or DIR.\n\
-R, --remove-other Delete image files for other Lisp systems.\n\
-U, --remove-unknown Delete unrecognized files in image dir.\n\
-O, --output=FILE|DIR Store image(s) in FILE or DIR.\n\
-R, --remove-other Delete image files for other Lisp systems.\n\
-U, --remove-unknown Delete unrecognized files in image dir.\n\