Thanks for the bug report.  I suspect that the sed usage is portable
but that we are running into some limitation of your 'sed'
implementation.

Here is some further information that you can send that will help us
debug this.  (I don't have access to your platform so I can't debug
the problem directly.)

Which operating system are you using?  What does the shell command
"uname -a" output?  How about the shell command "type sed" or "which
sed"?

Please try patching your config.status file as follows:

--- config.status~      2006-05-19 12:02:29.000000000 -0700
+++ config.status       2006-05-19 12:04:44.000000000 -0700
@@ -1013,6 +1013,7 @@ ${ac_dA}HAVE_DECL_STRTOUL$ac_dB${ac_dC}1
 ${ac_dA}HAVE_DECL_STRTOULL$ac_dB${ac_dC}1$ac_dD
 ${ac_dA}HAVE_DECL_TTYNAME$ac_dB${ac_dC}1$ac_dD
 CEOF
+    cp "$tmp/defines.sed" myscript.sed
     sed -f "$tmp/defines.sed" $ac_file_inputs >"$tmp/out1"
     # First, check the format of the line:
     cat >"$tmp/defines.sed" <<CEOF

Then run the command "./config.status", and then look at the contents
of myscript.sed.  Does that file look OK?  How does your myscript.sed
compare to my (attached), which does work for me?  What is the output
of this command?

sed -f myscript.sed config.hin | diff -b config.hin -

Thanks.

/^[      ]*#[    ]*undef[        ][      
]*[_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ][_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]*[
    ]*$/b def
/^[      ]*#[    ]*define[       ][      
]*[_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ][_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]*[(
   ]/b def
b
:def
s/$/ /
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*PACKAGE_NAME\)[       
(].*$,\1define\2 "GNU coreutils" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*PACKAGE_TARNAME\)[    
(].*$,\1define\2 "coreutils" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*PACKAGE_VERSION\)[    
(].*$,\1define\2 "5.95" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*PACKAGE_STRING\)[     
(].*$,\1define\2 "GNU coreutils 5.95" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*PACKAGE_BUGREPORT\)[  
(].*$,\1define\2 "bug-coreutils@gnu.org" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*PACKAGE\)[    (].*$,\1define\2 
"coreutils" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*VERSION\)[    (].*$,\1define\2 
"5.95" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*_GNU_SOURCE\)[        
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*STDC_HEADERS\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_TYPES_H\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_STAT_H\)[    
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STDLIB_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STRING_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_MEMORY_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STRINGS_H\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_INTTYPES_H\)[    
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STDINT_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UNISTD_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*__EXTENSIONS__\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*_POSIX_PTHREAD_SEMANTICS\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UNAME\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_CHROOT\)[        
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_GETHOSTID\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*_FILE_OFFSET_BITS\)[  
(].*$,\1define\2 64 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*PROTOTYPES\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*__PROTOTYPES\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STRING_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_LONG_DOUBLE_WIDER\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_LONG_DOUBLE\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_PATHS_H\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STROPTS_H\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_IOCTL_H\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_PARAM_H\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_RESOURCE_H\)[        
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_STATVFS_H\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_TIME_H\)[    
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_VFS_H\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_WAIT_H\)[    
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYSLOG_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_TERMIOS_H\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_GRP_H\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_PWD_H\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UTMP_H\)[        
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_SOCKET_H\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_NETDB_H\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_TYPES_H\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_NETINET_IN_H\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STDIO_EXT_H\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_LIBGEN_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UNISTD_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STDDEF_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STDLIB_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STRING_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_WCHAR_H\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_WCTYPE_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UTMPX_H\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_LOCALE_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UTIME_H\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_SYSMACROS_H\)[       
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_MOUNT_H\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_SYS_SYSCTL_H\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DIRENT_H\)[      
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STRUCT_STAT_ST_BLOCKS\)[        
 (].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_ST_BLOCKS\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*GETGROUPS_T\)[        
(].*$,\1define\2 gid_t ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_MBSTATE_T\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_INTTYPES_H_WITH_UINTMAX\)[      
 (].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STDINT_H_WITH_UINTMAX\)[        
 (].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UNSIGNED_LONG_LONG\)[    
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_UINTMAX_T\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HOST_OPERATING_SYSTEM\)[      
(].*$,\1define\2 "GNU/Linux" ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_STRUCT_DIRENT_D_TYPE\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*D_INO_IN_DIRENT\)[    
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*TIME_WITH_SYS_TIME\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_FREE\)[     
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_GETENV\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_GETEUID\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_GETGRGID\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_GETLOGIN\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_GETPWUID\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_GETUID\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_GETUTENT\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_LSEEK\)[    
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_MALLOC\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_MEMCHR\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_MEMRCHR\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_NANOSLEEP\)[        
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_REALLOC\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_STPCPY\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_STRNDUP\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_STRNLEN\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_STRSTR\)[   
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_STRTOUL\)[  
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_STRTOULL\)[         
(].*$,\1define\2 1 ,
s,^\([   ]*#[    ]*\)[^  ]*\([   ][      ]*HAVE_DECL_TTYNAME\)[  
(].*$,\1define\2 1 ,

Reply via email to