From: "James K. Lowden" <jklowden@schemamania.org>
To: gcc@gcc.gnu.org
Subject: passing command-line arguments, still
Date: Wed, 16 Mar 2022 14:34:09 -0400 [thread overview]
Message-ID: <20220316143409.24cb3e7fd17c6b73acaee586@schemamania.org> (raw)
[I sent this to gcc-help by mistake. I'm reposting it here in case
anyone has a suggestion. I did take dje's advice, and deleted the build
directory, except that I preserved config.status and regenerated
Makefile. The observed behavior remains unchanged. TIA.]
https://git.symas.net:443/cobolworx/gcc-cobol/
My first question regards command-line options. I've had no trouble
defining switches (-f-foo), but no luck defining an option that takes
an argument. The latter are accepted by gcobol and not passed to
cobol1.
In cobol/lang.opt, I have:
indicator-column
Cobol Joined Separate UInteger Var(indicator_column) Init(0)
IntegerRange(0, 8) -indicator-column=<n> Column after which
Region B begins
strace(1) shows the problem:
[pid 683008] execve("../../../build/gcc/gcobol",
["../../../build/gcc/gcobol", "-main", "-o", "obj/SG105A", "-B",
"../../../build/gcc/", "-f-flex-debug", "-f-yacc-debug",
"-indicator-column", "1", "cbl/SG105A.cbl", "-lgcobol", "-lm", "-ldl"],
0x55a19b487940 /* 36 vars */ <unfinished ...>
gcobol is being invoked with 3 options used by cobol1:
"-f-flex-debug", "-f-yacc-debug", "-indicator-column", "1"
where -indicator-column takes an argument, "1". But it's not passed to
cobol1:
[pid 683008] <... execve resumed>) = 0
[pid 683009] execve("../../../build/gcc/cobol1",
["../../../build/gcc/cobol1", "cbl/SG105A.cbl", "-quiet", "-dumpbase",
"SG105A.cbl", "-main", "-mtune=generic", "-march=x86-64", "-auxbase",
"SG105A", "-f-flex-debug", "-f-yacc-debug", "-o", "/tmp/ccIBQZv1.s"],
0x1578290 /* 40 vars */ <unfinished ...>
The stanza in cobol/lang.opt looks similar to others in
fortran/lang.opt. The gcc internals don't mention anything else that I
could find that needs to be done. I've done a complete rebuild after
"make distclean". And still no joy.
We are working with a gcc fork of 10.2. Our log message says (in part):
The "tiny" branch was started with the 10.2.1
origin/releases/gcc-10 branch> c806314b32987096d79de21e72dc0cf783e51d57)
What am I missing, please?
--jkl
next reply other threads:[~2022-03-16 18:34 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-16 18:34 James K. Lowden [this message]
2022-03-16 18:45 ` Marek Polacek
2022-03-17 16:21 ` James K. Lowden
2022-03-17 17:39 ` Jonathan Wakely
2022-03-19 17:10 ` James K. Lowden
2022-03-19 17:53 ` David Edelsohn
2022-03-21 10:19 ` Jonathan Wakely
2022-03-21 10:21 ` Jonathan Wakely
2022-03-17 18:37 ` Joseph Myers
2022-03-17 19:16 ` Marek Polacek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220316143409.24cb3e7fd17c6b73acaee586@schemamania.org \
--to=jklowden@schemamania.org \
--cc=gcc@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).