At 3:53 PM -0700 7/14/05, Michael G Schwern wrote: > I see this sort of thing >repeated a lot. > >> +if ($Is_VMS) { >> + my $unix_report; >> + my $unix_only; >> + >> + $unix_report = $ENV{'DECC$FILENAME_UNIX_REPORT'}; >> + if (defined $unix_report) { >> + if (($unix_report lt '1') && ($unix_report ne 'ENABLE')) { >> + $unix_report = undef; >> + } >> + } >> + $unix_only = $ENV{'DECC$FILENAME_UNIX_ONLY'}; >> + if (defined $unix_only) { >> + if (($unix_only lt '1') && ($unix_only ne 'ENABLE')) { >> + $unix_only = undef; >> + } >> + } >> + $unix_report = 1 if (defined $unix_only); > >Not only in this patch but in many of the other patches you've submitted. >I think step one of your porting effort should be to encapsulate this >"what sort of VMS am I on?" logic into a module. Perhaps something as simple >as a bunch of new File::Spec::VMS methods.
These aren't the only reasons we need a different way to test CRTL features from Perl. The assumption in the code as written is that the %ENV hash maps to logical names, which may or may not be the case. We probably need some XS to really do this right, something comparable to VMS::Filespec that is wired into the core and available everywhere, even in miniperl. I'm thinking of something like VMS::CRTL->feature_get() and VMS::CRTL->feature_set() as wrappers around the C calls that query and set the C run-time features. >I doubt your patches will be accepted in their current state and I'd hate >to see all that effort wasted. The hard link and symlink support are probably close to ready for prime time. But a VMS mutant that expects, requires and reports file names in Unix syntax is really quite a different beast than anything the VMS port of Perl has dealt with in the past, and may call for more of a paradigm shift than patching the tests one at a time. If Configure could be made to run within GNV, and if $^O could report something other than 'VMS', we might be closer to what is really needed. Nevertheless, I think John's work is an important proof of concept and may turn out to be the direction we ultimately follow. I do wish I had more time to delve into all of this as I think it will need some kicking about before we can say we are ready to get it checked in to the repository. -- ________________________________________ Craig A. Berry mailto:[EMAIL PROTECTED] "... getting out of a sonnet is much more difficult than getting in." Brad Leithauser