Re: access to include path in front end

2022-12-05 Thread Michael Matz via Gcc
Hey, On Fri, 2 Dec 2022, James K. Lowden wrote: > > > 3. Correct the entries in the default_compilers array. Currently I > > > have in cobol/lang-specs.h: > > > > > > {".cob", "@cobol", 0, 0, 0}, > > > {".COB", "@cobol", 0, 0, 0}, > > > {".cbl", "@cobol", 0, 0, 0}, > > >

Re: access to include path in front end

2022-12-02 Thread James K. Lowden
On Thu, 1 Dec 2022 17:14:31 + (UTC) Michael Matz wrote: > > 3. Correct the entries in the default_compilers array. Currently I > > have in cobol/lang-specs.h: > > > > {".cob", "@cobol", 0, 0, 0}, > > {".COB", "@cobol", 0, 0, 0}, > > {".cbl", "@cobol", 0, 0, 0}, > >

Re: access to include path in front end

2022-12-01 Thread Michael Matz via Gcc
Hey, On Thu, 1 Dec 2022, James K. Lowden wrote: > > E.g. look in gcc.cc for '@c' (matching the file extension) how that > > entry uses '%(cpp_unique_options)', and how cpp_unique_options is > > defined for the specs language: > > > > INIT_STATIC_SPEC ("cpp_unique_options",

Re: access to include path in front end

2022-12-01 Thread James K. Lowden
On Wed, 30 Nov 2022 15:58:40 + (UTC) Michael Matz wrote: Hi Michael, First, thanks for a great answer, and to Jonathan for reminding me of what documentation we do have for this. I'm now using -I in cobol1, but I'm not getting it from gcobol. I guess I need to extend the spec options, but

Re: access to include path in front end

2022-11-30 Thread Jonathan Wakely via Gcc
On Wed, 30 Nov 2022 at 15:59, Michael Matz wrote: > If you're looking at the C frontends for inspiration, then: > > c-family/c.opt defines which options are recognized and several specifics > about them, e.g. for -I it has: > > > I > C ObjC C++ ObjC++ Joined Separate MissingArgError(missing

Re: access to include path in front end

2022-11-30 Thread James K. Lowden
On Wed, 30 Nov 2022 08:49:35 +0100 Richard Biener wrote: > > I would like to use the -I option to pass the names of copybook > > directories to the cobol front end. A bit of exploration yesterday > > left me with the sense that the -I argument, in C at least, is not > > passed to the compiler,

Re: access to include path in front end

2022-11-30 Thread Michael Matz via Gcc
Hello, On Tue, 29 Nov 2022, James K. Lowden wrote: > I don't understand how to access in a front end the arguments to the -I > option on the command line. > > Cobol has a feature similar to the C preprecessor, known as the > Compiler Directing Facility (CDF). The CDF has a COPY statement

Re: access to include path in front end

2022-11-29 Thread Richard Biener via Gcc
On Tue, Nov 29, 2022 at 4:41 PM James K. Lowden wrote: > > I don't understand how to access in a front end the arguments to the -I > option on the command line. > > Cobol has a feature similar to the C preprecessor, known as the > Compiler Directing Facility (CDF). The CDF has a COPY statement

access to include path in front end

2022-11-29 Thread James K. Lowden
I don't understand how to access in a front end the arguments to the -I option on the command line. Cobol has a feature similar to the C preprecessor, known as the Compiler Directing Facility (CDF). The CDF has a COPY statement that resembles an #include directive in C, and shares the property