gcc on Sparc Solaris 8

Dennis Clarke dclarke@blastwave.org
Mon Sep 30 19:36:00 GMT 2019


On 9/30/19 9:32 AM, rolf perau via gcc-help wrote:
> Hi Dennis,

Put a locale on the command line or just allow POSIX :

     if ( argc > 1 ) {
         printf ("\nINFO : You suggest a locale of %s\n", argv[1]);
         buf = setlocale ( LC_ALL, argv[1] );
     } else {
         buf = setlocale ( LC_ALL, "POSIX" );
     }

     if ( buf == NULL ) {
         fprintf (stderr,"FAIL : setlocale fail\n");
         return(EXIT_FAILURE);
     }


-- 
Dennis Clarke
RISC-V/SPARC/PPC/ARM/CISC
UNIX and Linux spoken
GreyBeard and suspenders optional
https://twitch.tv/lastmiles



More information about the Gcc-help mailing list