On Sun, Mar 17, 2002 at 05:06:35PM -0800, Brent Dax wrote:
> # Checking some things by compiling and running another small C
> # program (this
> # could take a while):
> #
> # Building ./testparrotsizes.c from testparrotsizes_c.in...
> #
> #
> # #include "parrot/parrot.h"
> # #include "parrot/parrot.h"
> # ..^
> # ..^
> # %CC-F-NOINCLFILEF, Cannot find file "parrot/parrot.h"
> # specified in #include directive.
> # %CC-F-NOINCLFILEF, Cannot find file "parrot/parrot.h"
> # specified in #include directive.
> # at line number 9 in file USER1:[SCHWERN.SRC.PARROT]TESTPARROTSIZES.C;1
> # at line number 9 in file USER1:[SCHWERN.SRC.PARROT]TESTPARROTSIZES.C;1
> # C compiler died! at (eval 1) line 13.
> # %RMS-E-FNF, file not found
>
> Yikes. Does the C compiler recognize that sort of path? How about
> the -I switch (it may be set differently by VMS's hints file) that tells
> it to look in ./include?
main::(configure.pl:668): compiletestc("testparrotsizes");
DB<2> s
main::CODE(0x7a1c8c)((eval 4)[configure.pl:297]:10):
10: my $name;
DB<2> n
main::CODE(0x7a1c8c)((eval 4)[configure.pl:297]:11):
11: $name = shift;
DB<2>
main::CODE(0x7a1c8c)((eval 4)[configure.pl:297]:12):
12: $name = "test" unless $name;
DB<2>
main::CODE(0x7a1c8c)((eval 4)[configure.pl:297]:13):
13: system("$c{cc} $c{ccflags} $name.c") and die "C compiler
died!";
DB<2> x "$c{cc} $c{ccflags} $name.c"
0 'CC/DECC
/Standard=Relaxed_ANSI/Prefix=All/Obj=.obj/NoList/NOANSI_ALIAS/include=([.include],"/here")
testparrotsizes.c'
DB<3> use Cwd
DB<4> x cwd
0 'USER1:[SCHWERN.SRC.PARROT]'
DB<5> n
#include "parrot/parrot.h"
#include "parrot/parrot.h"
..^
..^
%CC-F-NOINCLFILEF, Cannot find file "parrot/parrot.h" specified in #include directive.
%CC-F-NOINCLFILEF, Cannot find file "parrot/parrot.h" specified in #include directive.
at line number 9 in file USER1:[SCHWERN.SRC.PARROT]TESTPARROTSIZES.C;3
at line number 9 in file USER1:[SCHWERN.SRC.PARROT]TESTPARROTSIZES.C;3
C compiler died! at (eval 4)[configure.pl:297] line 13.
main::__ANON__[(eval 4)[configure.pl:297]:15]('testparrotsizes') called
Debugged program terminated. Use q to quit or R to restart,
Poking around in the DECC manual, there's two problems.
http://www.openvms.compaq.com/commercial/c/5492p004.htm#index_x_113
First, its INCLUDE_DIRECTORY, not INCLUDE (although INCLUDE works).
Second, there seems to be some confusing rules about mixing VMS and
Unix style paths. It seems that the style used in INCLUDE_DIRECTORY
has to match the style used in the #include.
Search the places specified in the /INCLUDE_DIRECTORY qualifier, if
any. A place that can be parsed successfuly as an OpenVMS file-spec
and that does not contain an explicit file type or version
specification is edited to append the default header file type
specification (".h" or ".").
A place containing a "/" character is considered to be a UNIX-style
name. If the name in the #include directive also contains a "/"
character that is not the first character and is not preceded by a
"!" character (it is not an absolute UNIX-style pathname), then the
name in the #include directive is appended to the named place,
separated by a "/" character, before applying the decc$to_vms
pathname translation function. The result of the decc$to_vms
translation is then used as the filespec to try to open.
so this works:
CC/DECC /INCLUDE=("./include") testparrotsizes.c
but you might want to get independent confirmation from the vmsperl
folks about that.
--
Michael G. Schwern <[EMAIL PROTECTED]> http://www.pobox.com/~schwern/
Perl Quality Assurance <[EMAIL PROTECTED]> Kwalitee Is Job One
Not king yet