#645: [PATCH]  remove "." from architecture names
-----------------------+----------------------------------------------------
  Reporter:  rrauenza  |        Type:  bug      
    Status:  closed    |    Priority:  normal   
 Milestone:            |   Component:  configure
   Version:  1.1.0     |    Severity:  medium   
Resolution:  fixed     |    Keywords:           
      Lang:            |       Patch:  applied  
  Platform:  unix      |  
-----------------------+----------------------------------------------------
Changes (by NotFound):

  * status:  new => closed
  * resolution:  => fixed
  * patch:  => applied


Old description:

> This fixes arch.pm on hpux, which is built with the following
> architecture id's:
>
> @INC:
>     /usr/local/lib/perl5/5.10.0/IA64.ARCHREV_0
>     /usr/local/lib/perl5/5.10.0
>     /usr/local/lib/perl5/site_perl/5.10.0/IA64.ARCHREV_0
>     /usr/local/lib/perl5/site_perl/5.10.0
>
> The "." gets propagated into config.h as part of a #define identifier,
> which is illegal.  So I turn the "." into "_".  A more robust solution
> would be to check for any characters not allowed in a #define, but I'm
> reluctant to make that large of a change.
>

> --- config/auto/arch.pm (revision 38492)
> +++ config/auto/arch.pm (working copy)
> @@ -39,6 +39,7 @@
>      $verbose and print "\n";
>
>      my $archname = $conf->data->get('archname');
> +    $archname =~ s|\.|_|g;
>      my ( $cpuarch, $osname ) = split( /-/, $archname );
>
>      if ($verbose) {

New description:

 This fixes arch.pm on hpux, which is built with the following architecture
 id's:

 @INC:
     /usr/local/lib/perl5/5.10.0/IA64.ARCHREV_0
     /usr/local/lib/perl5/5.10.0
     /usr/local/lib/perl5/site_perl/5.10.0/IA64.ARCHREV_0
     /usr/local/lib/perl5/site_perl/5.10.0

 The "." gets propagated into config.h as part of a #define identifier,
 which is illegal.  So I turn the "." into "_".  A more robust solution
 would be to check for any characters not allowed in a #define, but I'm
 reluctant to make that large of a change.


 --- config/auto/arch.pm (revision 38492)
 +++ config/auto/arch.pm (working copy)
 @@ -39,6 +39,7 @@
      $verbose and print "\n";

      my $archname = $conf->data->get('archname');
 +    $archname =~ s|\.|_|g;
      my ( $cpuarch, $osname ) = split( /-/, $archname );

      if ($verbose) {

--

Comment:

 Thanks! Applied with the addition of a comment in r38512, other change
 commited with this by mistake reverted in r38513.

-- 
Ticket URL: <https://trac.parrot.org/parrot/ticket/645#comment:1>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets

Reply via email to