diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2014-12-24 00:20:48 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2014-12-24 00:20:48 (GMT) |
commit | 9cab778bfaaca2589a383445e8569d99d73374d5 (patch) | |
tree | 29371502a4a816a2c0a42a55dfdcd8b7fde4ffa2 /tools/d2c/d2c_gram.y | |
parent | 04dfbc68e7cd5036017f097a67ba5f0288ddace0 (diff) |
Improved the generation of source code: there are now templates and one file per instruction.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@443 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'tools/d2c/d2c_gram.y')
-rw-r--r-- | tools/d2c/d2c_gram.y | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/d2c/d2c_gram.y b/tools/d2c/d2c_gram.y index 5ae93c8..b1519a1 100644 --- a/tools/d2c/d2c_gram.y +++ b/tools/d2c/d2c_gram.y @@ -354,6 +354,7 @@ int main(int argc, char **argv) static struct option long_options[] = { { "help", no_argument, NULL, 'h' }, + { "input", required_argument, NULL, 'i' }, { "dir", required_argument, NULL, 'd' }, { "arch", required_argument, NULL, 'a' }, { "header", required_argument, NULL, 'H' }, @@ -374,7 +375,7 @@ int main(int argc, char **argv) while (!has_error) { - ret = getopt_long(argc, argv, "hd:a:H:e:M:", long_options, &index); + ret = getopt_long(argc, argv, "hi:d:a:H:e:M:", long_options, &index); if (ret == -1) break; switch (ret) @@ -383,6 +384,10 @@ int main(int argc, char **argv) need_help = true; break; + case 'i': + set_coder_input_file(coder, optarg); + break; + case 'd': set_coder_output_directory(coder, optarg); break; |