From c1183b3e497a4a691d1601e8312eed3d6ac39730 Mon Sep 17 00:00:00 2001 From: Niklas Hallqvist Date: Tue, 10 Feb 1998 08:30:51 +0000 Subject: Better -m compatibility with a.out ldconfig --- gnu/libexec/ld.so/ldconfig/ldconfig.8 | 11 ++++++++++- gnu/libexec/ld.so/ldconfig/ldconfig.c | 5 ++++- 2 files changed, 14 insertions(+), 2 deletions(-) (limited to 'gnu/libexec') diff --git a/gnu/libexec/ld.so/ldconfig/ldconfig.8 b/gnu/libexec/ld.so/ldconfig/ldconfig.8 index 34b738b6c86..ca0a23fecef 100644 --- a/gnu/libexec/ld.so/ldconfig/ldconfig.8 +++ b/gnu/libexec/ld.so/ldconfig/ldconfig.8 @@ -4,7 +4,7 @@ ldconfig \- determine run-time link bindings .SH SYNOPSIS ldconfig [ -.B \-DvnNX +.B \-DvmnNX ] .IR directory \ ... .PD 0 @@ -76,6 +76,15 @@ Unless .B \-N is also specified, the cache is still rebuilt. .TP +.B \-m +Merge specified directories into the cache, processes the same files as +.B \-n +although it does not imply +.B \-N +. This option exists +mainly for compatibility with the a.out variant of +.IR ldconfig . +.TP .B \-l Library mode. Manually link individual libraries. diff --git a/gnu/libexec/ld.so/ldconfig/ldconfig.c b/gnu/libexec/ld.so/ldconfig/ldconfig.c index ef2ce5be8ec..ca7f1dd4966 100644 --- a/gnu/libexec/ld.so/ldconfig/ldconfig.c +++ b/gnu/libexec/ld.so/ldconfig/ldconfig.c @@ -58,6 +58,7 @@ int verbose = 0; /* verbose mode */ int libmode = 0; /* library mode */ int nocache = 0; /* don't build cache */ int nolinks = 0; /* don't update links */ +int merge = 0; /* cache and link dirs on cmdline */ int Pswitch = 0; char *Ppath = ""; @@ -409,6 +410,8 @@ int main(int argc, char **argv) libmode = 1; /* library mode */ break; case 'm': /* Compatibility hack */ + merge = 1; + nodefault = 1; break; case 'p': printcache = 1; /* print cache */ @@ -478,7 +481,7 @@ int main(int argc, char **argv) /* don't cache dirs on the command line */ int nocache_save = nocache; - nocache = 1; + nocache = nocache || !merge; /* OK, which directories should we do? */ for (i = optind; i < argc; i++) -- cgit v1.2.3