Perl / perl5

🐪 The Perl programming language
https://dev.perl.org/perl5/
Other
1.85k stars 525 forks source link

stdarg.h / stdarg.ph Problem #106

Closed p5pRT closed 20 years ago

p5pRT commented 24 years ago

Migrated from rt.perl.org#910 (status was 'resolved')

Searchable as RT910$

p5pRT commented 24 years ago

From tcurdt@linux01.gwdg.de

After successfull installation of perl I tried to run the following script​:

#!/usr/bin/perl use Sys​::Syslog; openlog('programname'\,'ndelay'\,'root'); syslog('debug'\,'message'); closelog();

which gave me the following error

Can't locate stdarg.ph in @​INC (did you run h2ph?) (@​INC contains​: /usr/lib/perl5/5.00503/i586-linux /usr/lib/perl5/5.00503 /usr/lib/perl5/site_perl/5.005/i586-linux /usr/lib/perl5/site_perl/5.005 .) at /usr/lib/perl5/site_perl/5.005/i586-linux/sys/syslog.ph line 76. BEGIN failed--compilation aborted at test.pl line 2.

Well\, I did run h2ph!! And there was still now stdarg.ph in my filesystem (find / -xdev -name stdarg.ph)

After checking in some news groups I found the following sollution for me​:

Foo​:/root # locate stdarg.h /usr/include/g++/std/cstdarg.h /usr/lib/gcc-lib/i486-linux/2.7.2.1/include/stdarg.h Foo​:/root # cd /usr/lib/gcc-lib/i486-linux/2.7.2.1/include Foo​:/usr/lib/gcc-lib/i486-linux/2.7.2.1/include # h2ph stdarg.h

Which build me the missing stdarg.ph Then I had to make some changes in the stdarg.ph​:

unless(defined(&_STDARG_H)) {   unless(defined(&_ANSI_STDARG_H_)) { # unless(defined(&__need___va_list)) {   eval 'sub _STDARG_H () {1;}' unless defined(&_STDARG_H);   eval 'sub _ANSI_STDARG_H_ () {1;}' unless defined(&_ANSI_STDARG_H_); # } # undef(&__need___va_list) if defined(&__need___va_list);   if(defined(&__clipper__)) {

Now it work for me!!

Perl Info ``` Site configuration information for perl 5.00503: Configured by root at Mon Jun 21 20:01:45 CEST 1999. Summary of my perl5 (5.0 patchlevel 5 subversion 3) configuration: Platform: osname=linux, osvers=2.0.35, archname=i586-linux uname='linux foo 2.0.35 #1 mon oct 12 22:43:48 cest 1998 i586 unknown ' hint=recommended, useposix=true, d_sigaction=define usethreads=undef useperlio=undef d_sfio=undef Compiler: cc='cc', optimize='-O2', gccversion=2.7.2.1 cppflags='-Dbool=char -DHAS_BOOL -I/usr/local/include' ccflags ='-Dbool=char -DHAS_BOOL -I/usr/local/include' stdchar='char', d_stdstdio=define, usevfork=false intsize=4, longsize=4, ptrsize=4, doublesize=8 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12 alignbytes=4, usemymalloc=y, prototype=define Linker and Libraries: ld='cc', ldflags ='-L/usr/local/lib -L/lib -L/usr/lib' libpth=/usr/local/lib /lib /usr/lib libs=-lgdbm -ldb -ldl -lm -lc libc=/lib/libc.so.5.4.33, so=so, useshrplib=false, libperl=libperl.a Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic' cccdlflags='-fpic', lddlflags='-shared -L/usr/local/lib -L/lib -L/usr/lib' Locally applied patches: @INC for perl 5.00503: /usr/lib/perl5/5.00503/i586-linux /usr/lib/perl5/5.00503 /usr/lib/perl5/site_perl/5.005/i586-linux /usr/lib/perl5/site_perl/5.005 . Environment for perl 5.00503: HOME=/root LANG (unset) LANGUAGE (unset) LC_CTYPE=de_DE LD_LIBRARY_PATH (unset) LOGDIR (unset) PATH=/sbin:/usr/sbin:/usr/local/bin:/usr/bin:/usr/X11R6/bin:/bin:/usr/lib/java/bin:/root/bin:/usr/bin/TeX:/usr/lib/news/bin:/usr/local/mysql/bin PERL_BADLANG (unset) SHELL=/bin/bash ```