Implement --print-datadir.

* src/getargs.c (usage): Mention.
(PRINT_DATADIR_OPTION): New anonymous enum member.
(long_options): Add entry for it.
(getargs): Add case for it calling compute_pkgdatadir.
* src/output.c (output_skeleton): Encapsulate data directory
computation from here...
(prepare): ... and from here...
(compute_pkgdatadir): ... into this new function.
* src/output.h (compute_pkgdatadir): Prototype.
This commit is contained in:
Joel E. Denny
2007-10-05 02:54:33 +00:00
parent 34cdeddfa5
commit d4bd229569
4 changed files with 34 additions and 6 deletions

View File

@@ -1,5 +1,6 @@
/* Output the generated parsing program for bison,
Copyright (C) 2000, 2001, 2002, 2003, 2006 Free Software Foundation, Inc.
Copyright (C) 2000, 2001, 2002, 2003, 2006, 2007 Free Software Foundation,
Inc.
This file is part of Bison, the GNU Compiler Compiler.
@@ -21,5 +22,6 @@
/* Output the parsing tables and the parser code to FTABLE. */
void output (void);
char const *compute_pkgdatadir (void);
#endif /* !OUTPUT_H_ */