]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
Grok -U as inverse of -D in ar and ranlib.
authorRoland McGrath <roland@hack.frob.com>
Fri, 20 Jan 2012 19:43:36 +0000 (11:43 -0800)
committerRoland McGrath <roland@hack.frob.com>
Fri, 20 Jan 2012 19:43:36 +0000 (11:43 -0800)
NEWS
src/ChangeLog
src/arlib-argp.c

diff --git a/NEWS b/NEWS
index 9d62d1768bcfb3225429c32c6ab9778c40206eaa..b0fb57b94d2f0f087a0ee5f1237a44c1ea42c310 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -5,7 +5,8 @@ libdw: Support reading .zdebug_* DWARF sections compressed via zlib.
 nm: Support C++ demangling.
 
 ar: Support D modifier for "deterministic output" with no uid/gid/mtime info.
-ranlib: Support -D flag with same meaning.
+    The U modifier is the inverse.
+ranlib: Support -D and -U flags with same meaning.
 
 Version 0.152
 
index 22212f9b9a568141c0b7e7175dee31798655ed81..46c277ce50d70fa71092b5a4d0c05e068c4c93c9 100644 (file)
@@ -1,5 +1,7 @@
 2012-01-20  Roland McGrath  <roland@hack.frob.com>
 
+       * arlib-argp.c (options, parse_opt): Grok -U as inverse of -D.
+
        * ranlib.c (argp): Use arlib_argp_children.
 
        * arlib.c (arlib_init): Obey arlib_deterministic_output.
index af19a2558f647c2c15cadfe259c64c65023222f0..e143fbf1c6a350c9e02a041b3f9baba036424f66 100644 (file)
@@ -35,6 +35,8 @@ static const struct argp_option options[] =
   {
     { NULL, 'D', NULL, 0,
       N_("Use zero for uid, gid, and date in archive members."), 0 },
+    { NULL, 'U', NULL, 0,
+      N_("Use actual uid, gid, and date in archive members."), 0 },
 
     { NULL, 0, NULL, 0, NULL, 0 }
   };
@@ -49,6 +51,10 @@ parse_opt (int key, char *arg __attribute__ ((unused)),
       arlib_deterministic_output = true;
       break;
 
+    case 'U':
+      arlib_deterministic_output = false;
+      break;
+
     default:
       return ARGP_ERR_UNKNOWN;
     }