Re: make problem - HP-UX 11i, amanda 2.4.2p2
On Thursday 20 June 2002 10:28, Gary Hines wrote: >Just as a reference for future HP users that might run into this > problem. > >I was able to get Amanda compiled and installed by using GCC 3.0.2. > This is available from itrc.hp.com > >http://h21007.www2.hp.com/dspp/tech/tech_TechSoftwareDetailPage_IDX/1, >1703,5 47,00.html > Humm, I've built the last 3 or 4 versions of 2.4.3b3 with gcc-3.1. No problems that I've detected on a RH7.3 system. (that weren't my own dumb fault that is) :-) -- Cheers, Gene CE @ WDTV-5, CBS for N. Central WV
RE: make problem - HP-UX 11i, amanda 2.4.2p2
Title: RE: make problem - HP-UX 11i, amanda 2.4.2p2 I went with just the first suggestion and just renamed the gcc types.h to _types.h, and made it past that sticking point. Now I'm stuck on dgram.c. Here's what I've copied that seemed relevant. gcc -DHAVE_CONFIG_H -I. -I. -I../config -I./../regex-src -D_FILE_OFFSET_BITS=64 -D__STDC_EXT__ -D_FILE_OFFSET_BITS=64 -g -O2 -c dgra m.c :1:1: warning: "__STDC_EXT__" redefined :1:1: warning: this is the location of the previous definition dgram.c: In function `dgram_send': dgram.c:222: warning: assignment makes pointer from integer without a cast dgram.c:230: dereferencing pointer to incomplete type dgram.c:230: dereferencing pointer to incomplete type *** Error exit code 1 Stop. dgram.c 222 if((hp = gethostbyname(hostname)) == 0) { 223 save_errno = errno; 224 dbprintf(("%s: dgram_send: gethostbyname(%s) failed\n", 225 get_pname(), 226 hostname)); 227 errno = save_errno; 228 return -1; 229 } 230 memcpy(&name.sin_addr, hp->h_addr, hp->h_length); I've looked everywhere I could think of for gethostbyname, and could not find the actual function for it, but it is in the man pages. In my searches, I also noticed that there were some other programs that called it (sendmail, hoststat, rpc.statd), and it kept giving failures of some type. Has anyone successfully compiled this with gcc on hp-ux 11i? Ours is a month old system, and I didn't think I would be running into these types of problems. Thanks to all for any help! Gary -Original Message- From: Jon LaBadie [mailto:[EMAIL PROTECTED]] Sent: Friday, May 31, 2002 12:16 PM To: Gary Hines Subject: Re: make problem - HP-UX 11i, amanda 2.4.2p2 On Fri, May 31, 2002 at 10:46:18AM -0500, Gary Hines wrote: > Thanks very much for the help Jon (and the refresher course in C). I've > stepped back to simple basics, and starting with a configure that just sets > up the user and group. I've also replaced the socket.h. I reran the make > after the new configure, and received the same error, so I tried it with -E > as you mentioned in the previous e-mail. This shed a new light on things. It > seems it is calling the types.h file that is included with gcc > (/usr/local/lib/gcc-lib/hppa2.0n-hp-hpux11.00/3.1/include/sys/types.h). I > checked, and this types.h file does not have the definitions in it, while > the HP one (/usr/include/sys/types.h) does. So I know what's wrong, but how > can I fix it? Interesting, my gcc installation (solaris, from Sun's extra software cd) does not have a sys/types.h. I don't know the answer. I know the first thing I would try is to rename gcc's types.h to _types.h. That will prevent it from being found and the system one will be included. The C pre-processor looks for include files in a sequence of include dirs. Kinda like a PATH variable for include files. The system dirs are the last to be looked at. I might also consider adding #include to the beginning of the gcc types.h file. This could cause an explosion of errors from duplication or redefinition, maybe not. Be careful about placement and those nasty #ifndef's at the beginning. If both sys/types.h use the same macro to prevent reincluding the header file (probably something like _sys_type_h), you may want the extra #include to replace the #define in the gcc header. Otherwise placement is not critical. Now that you have homed in on the problem, I'd suggest a revisit to the mail list. Many of them are using HP-UX, and I'll bet some the same version of gcc as you. Though I think that is pretty recent. Explain that gcc seems to be picking up its own types.h rather than the system one and that some definitions in the system one are needed. Show your configure command line, but I'd suggest putting the output into an attachment. Make sure the output is from a run AFTER a make distclean. Maybe also attach the resulting config.h file. Show a make like you did before with the sbsize error. -- Jon H. LaBadie [EMAIL PROTECTED] JG Computing 4455 Province Line Road (609) 252-0159 Princeton, NJ 08540-4322 (609) 683-7220 (fax)
Re: make problem - HP-UX 11i, amanda 2.4.2p2
Gary Hines writes: - I'm using gcc, and I just downloaded the new gcc3.1 from the hp - porting site, but I still get the same error. My experience with software from the Porting Centre doesn't instill confidence. It seems they frequently build in one directory, and then package it to install in another (which breaks things massively.) - Does gcc come with separate - includes? Part of the gcc installation process is to preprocess/reprocess some of the system include files into something gcc likes better. Odds are, the Porting Centre build didn't get that done, or the includes didn't get put into the depot. -The socket.h that came with the HP includes the header file that - defines the types that I'm getting the errors on (sbsize_t, bsize_t, - sbsize64_t, and bsize64_t), but for some reason they don't seem to be - getting include'd in the compilation. I'm wondering if gcc has a different - socket.h that would work? The problem is more likely the file. It's entirely possible that the amanda source isn't including before including and it's required on HP-UX (it certainly is on NetBSD and Solaris, but may not be required on some versions of Linux, where much of the amanda development occurs.) I have HP's commercial C compiler installed on my HP-UX 11.00 system, and would gladly build an amanda kit to your configuration. (the 11.00 binaries will run just fine on your 11i (11.11+) system -- after all, that's how HP builds them.. :-) -- Eric Schnoebelen[EMAIL PROTECTED] http://www.cirr.com "Linux in some ways is the Jerry Springer of operating systems, ..." Bruce Becker in comp.sys.sun.wanted
RE: make problem - HP-UX 11i, amanda 2.4.2p2
Title: RE: make problem - HP-UX 11i, amanda 2.4.2p2 Hi Eric, I'm using gcc, and I just downloaded the new gcc3.1 from the hp porting site, but I still get the same error. Does gcc come with separate includes? The socket.h that came with the HP includes the header file that defines the types that I'm getting the errors on (sbsize_t, bsize_t, sbsize64_t, and bsize64_t), but for some reason they don't seem to be getting include'd in the compilation. I'm wondering if gcc has a different socket.h that would work? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 30, 2002 12:11 PM To: Gary Hines Cc: 'Amanda backup' Subject: Re: make problem - HP-UX 11i, amanda 2.4.2p2 Gary Hines writes: - I'm just stuck trying to figure out why socket.h is not compiling It looks like you're attempting to use the bundled compiler on HP-UX. Unfortunately, the bundled compiler is only (barely) suited to building new kernels on HP-UX (and occasionally bootstraping gcc.) You really need either the ANSI C suite, or gcc, to build amanda.. Amanda uses a lot of ANSI C features, as do the system include files.. (You might get away with making sure that __STDC__ isn't defined during your configure and build, but I doubt it..) If you like, I can put the HP-UX amanda client up for ftp. -- Eric Schnoebelen [EMAIL PROTECTED] http://www.cirr.com "Any sufficiently advanced bureaucracy is indistinguishable from molasses." -- Unknown
Re: make problem - HP-UX 11i, amanda 2.4.2p2
Gary Hines writes: - I'm just stuck trying to figure out why socket.h is not compiling It looks like you're attempting to use the bundled compiler on HP-UX. Unfortunately, the bundled compiler is only (barely) suited to building new kernels on HP-UX (and occasionally bootstraping gcc.) You really need either the ANSI C suite, or gcc, to build amanda.. Amanda uses a lot of ANSI C features, as do the system include files.. (You might get away with making sure that __STDC__ isn't defined during your configure and build, but I doubt it..) If you like, I can put the HP-UX amanda client up for ftp. -- Eric Schnoebelen[EMAIL PROTECTED] http://www.cirr.com "Any sufficiently advanced bureaucracy is indistinguishable from molasses." -- Unknown
RE: make problem - HP-UX 11i, amanda 2.4.2p2
Title: RE: make problem - HP-UX 11i, amanda 2.4.2p2 Nope. That's supposed to be produced in the make and I'm not getting through the make. I don't think I need it due to the following quote from the SYSTEM.NOTES for hpux: "The use of `amhpfixdevs' is deprecated, since you can list mount-points or full device names in the disklist. The script may be removed in future releases of Amanda." I'm just stuck trying to figure out why socket.h is not compiling -Original Message- From: Jon LaBadie [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 30, 2002 11:14 AM To: Jon LaBadie Subject: Re: make problem - HP-UX 11i, amanda 2.4.2p2 On Thu, May 30, 2002 at 10:47:44AM -0500, Gary Hines wrote: > Hi All, > I'm having trouble with running make with Amanda. The configure appears > to run fine, then when I run make I get the following errors: > [ lots of errors I think amhpfixdevs is supposed to fix deleted ] > > As a side note: I received the following warning during configure. Is this > something that I need to be worried about? > configure: warning: *** Run amhpfixdevs on HP-UX systems using /dev/vg??. Did you? -- Jon H. LaBadie [EMAIL PROTECTED] JG Computing 4455 Province Line Road (609) 252-0159 Princeton, NJ 08540-4322 (609) 683-7220 (fax)
Re: make problem - HP-UX 11i, amanda 2.4.2p2
On Thu, May 30, 2002 at 10:47:44AM -0500, Gary Hines wrote: > Hi All, > I'm having trouble with running make with Amanda. The configure appears > to run fine, then when I run make I get the following errors: > [ lots of errors I think amhpfixdevs is supposed to fix deleted ] > > As a side note: I received the following warning during configure. Is this > something that I need to be worried about? > configure: warning: *** Run amhpfixdevs on HP-UX systems using /dev/vg??. Did you? -- Jon H. LaBadie [EMAIL PROTECTED] JG Computing 4455 Province Line Road(609) 252-0159 Princeton, NJ 08540-4322 (609) 683-7220 (fax)
make problem - HP-UX 11i, amanda 2.4.2p2
Title: make problem - HP-UX 11i, amanda 2.4.2p2 Hi All, I'm having trouble with running make with Amanda. The configure appears to run fine, then when I run make I get the following errors: : warning: "__STDC_EXT__" redefined : warning: this is the location of the previous definition In file included from amanda.h:224, from alloc.c:33: /usr/include/sys/socket.h:439: parse error before "sendfile" /usr/include/sys/socket.h:439: parse error before "bsize_t" /usr/include/sys/socket.h:441: parse error before "sendpath" /usr/include/sys/socket.h:441: parse error before "bsize_t" /usr/include/sys/socket.h:456: parse error before "__sendfile64" /usr/include/sys/socket.h:456: parse error before "bsize_t" /usr/include/sys/socket.h:457: parse error before "__sendpath64" /usr/include/sys/socket.h:457: parse error before "bsize_t" /usr/include/sys/socket.h:459: parse error before "sendfile" /usr/include/sys/socket.h: In function `sendfile': /usr/include/sys/socket.h:459: parse error before "bsize_t" /usr/include/sys/socket.h: At top level: /usr/include/sys/socket.h:460: parse error before "sendpath" /usr/include/sys/socket.h: In function `sendpath': /usr/include/sys/socket.h:460: parse error before "bsize_t" *** Error exit code 1 Stop. *** Error exit code 1 Stop. I checked the socket.h file and these are the offending lines: 439 extern sbsize_t sendfile __((int, int, off_t, bsize_t, 440 const struct iovec *, int)); 441 extern sbsize_t sendpath __((int, char *, off_t, bsize_t, 442 const struct iovec *, int)); 443 #if defined(_LARGEFILE64_SOURCE) 444 #ifdef __LP64__ 445 #define sendfile64 sendfile 446 #define sendpath64 sendpath 447 #else /* __LP64__ */ 448 extern sbsize64_t sendfile64 __((int, int, off64_t, bsize64_t, 449 const struct iovec *, int)); 450 extern sbsize64_t sendpath64 __((int, char *, off64_t, bsize64_t, 451 const struct iovec *, int)); 452 #endif /* __LP64 */ 453 #endif /* _LARGEFILE64_SOURCE */ 454 455 #ifdef _APP32_64BIT_OFF_T 456 extern sbsize64_t __sendfile64 __((int,int,off_t,bsize_t, const struct iovec *, int)); 457 extern sbsize64_t __sendpath64 __((int,char *,off_t,bsize_t,const struct iovec *,int)); 458 #ifndef __cplusplus 459 static sbsize_t sendfile(a,b,c,d,e,f) int a,b,f; off_t c; bsize_t d; const struct iovec * e; { return __sendfile64(a,b,c,d,e ,f); } 460 static sbsize_t sendpath(a,b,c,d,e,f) int a,f; char *b; off_t c; bsize_t d; const struct iovec * e; { return __sendpath64(a, b,c,d,e,f); } Any ideas on how I can fix this? My C is way rusty As a side note: I received the following warning during configure. Is this something that I need to be worried about? configure: warning: *** Run amhpfixdevs on HP-UX systems using /dev/vg??. Thanks for any and all help!! Gary Hines Systems Analyst SHC Direct, L.L.C. [EMAIL PROTECTED] Gary Hines Systems Analyst SHC Direct, L.L.C. [EMAIL PROTECTED] (630)874-2439
make problem - HP-UX 11i, amanda 2.4.2p2
Title: make problem - HP-UX 11i, amanda 2.4.2p2 Hi All, I'm having trouble with running make with Amanda. The configure occurs to run fine, then when I run make I get the following errors: : warning: "__STDC_EXT__" redefined : warning: this is the location of the previous definition In file included from amanda.h:224, from alloc.c:33: /usr/include/sys/socket.h:439: parse error before "sendfile" /usr/include/sys/socket.h:439: parse error before "bsize_t" /usr/include/sys/socket.h:441: parse error before "sendpath" /usr/include/sys/socket.h:441: parse error before "bsize_t" /usr/include/sys/socket.h:456: parse error before "__sendfile64" /usr/include/sys/socket.h:456: parse error before "bsize_t" /usr/include/sys/socket.h:457: parse error before "__sendpath64" /usr/include/sys/socket.h:457: parse error before "bsize_t" /usr/include/sys/socket.h:459: parse error before "sendfile" /usr/include/sys/socket.h: In function `sendfile': /usr/include/sys/socket.h:459: parse error before "bsize_t" /usr/include/sys/socket.h: At top level: /usr/include/sys/socket.h:460: parse error before "sendpath" /usr/include/sys/socket.h: In function `sendpath': /usr/include/sys/socket.h:460: parse error before "bsize_t" *** Error exit code 1 Stop. *** Error exit code 1 Stop. I checked the socket.h file and these are the offending lines: 439 extern sbsize_t sendfile __((int, int, off_t, bsize_t, 440 const struct iovec *, int)); 441 extern sbsize_t sendpath __((int, char *, off_t, bsize_t, 442 const struct iovec *, int)); 443 #if defined(_LARGEFILE64_SOURCE) 444 #ifdef __LP64__ 445 #define sendfile64 sendfile 446 #define sendpath64 sendpath 447 #else /* __LP64__ */ 448 extern sbsize64_t sendfile64 __((int, int, off64_t, bsize64_t, 449 const struct iovec *, int)); 450 extern sbsize64_t sendpath64 __((int, char *, off64_t, bsize64_t, 451 const struct iovec *, int)); 452 #endif /* __LP64 */ 453 #endif /* _LARGEFILE64_SOURCE */ 454 455 #ifdef _APP32_64BIT_OFF_T 456 extern sbsize64_t __sendfile64 __((int,int,off_t,bsize_t, const struct iovec *, int)); 457 extern sbsize64_t __sendpath64 __((int,char *,off_t,bsize_t,const struct iovec *,int)); 458 #ifndef __cplusplus 459 static sbsize_t sendfile(a,b,c,d,e,f) int a,b,f; off_t c; bsize_t d; const struct iovec * e; { return __sendfile64(a,b,c,d,e ,f); } 460 static sbsize_t sendpath(a,b,c,d,e,f) int a,f; char *b; off_t c; bsize_t d; const struct iovec * e; { return __sendpath64(a, b,c,d,e,f); } Any ideas on how I can fix this? My C is way rusty As a side note: I received the following warning during configure. Is this something that I need to be worried about? configure: warning: *** Run amhpfixdevs on HP-UX systems using /dev/vg??. Thanks for any and all help!! Gary Hines Systems Analyst SHC Direct, L.L.C. [EMAIL PROTECTED]