Bug 531 - Conflicting basename() on Irix
Summary: Conflicting basename() on Irix
Status: CLOSED FIXED
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: Build system (show other bugs)
Version: -current
Hardware: All All
: P2 major
Assignee: OpenSSH Bugzilla mailing list
URL:
Keywords:
: 532 546 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-04-03 04:02 AEST by Petter Reinholdtsen
Modified: 2004-04-14 12:24 AEST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Petter Reinholdtsen 2003-04-03 04:02:42 AEST
The OpenSSH v3.6p1 source fails to compile on Irix 6.5.  I get the following
error message:

  [...]
  checking for basename... no
  [...]
  cc-wrapper -g -I. -I. -I/local/lib  -I/usr/local/include
   -DSSHDIR=\"/etc/ssh\" -D_PATH_SSH_PROGRAM=\"/local/bin/ssh\"
   -D_PATH_SSH_ASKPASS_DEFAULT=\"/local/libexec/ssh-askpass\"
   -D_PATH_SFTP_SERVER=\"/local/libexec/sftp-server\"
   -D_PATH_SSH_KEY_SIGN=\"/local/libexec/ssh-keysign\"
   -D_PATH_SSH_PIDDIR=\"/var/run\" -D_PATH_PRIVSEP_CHROOT_DIR=\"/var/empty\"
   -DSSH_RAND_HELPER=\"/local/libexec/ssh-rand-helper\" -DHAVE_CONFIG_H
   -c progressmeter.c
  cc-1143 cc: ERROR File = /usr/include/libgen.h, Line = 35
    Declaration is incompatible with "char *basename(const char *)"
    (declared at line 9 of "openbsd-compat/basename.h").

  extern char *basename(char *);
               ^

  1 error detected in the compilation of "progressmeter.c".
  make: *** [progressmeter.o] Error 2
Comment 1 Petter Reinholdtsen 2003-04-03 04:18:24 AEST
This is from 'man 3 basename':

  cc [flag ...] file ... -lgen [library ...]

  #include <libgen.h>
  char *basename (char *path);

I guess configure should insert '-lgen' before testing for basename().
Comment 2 Darren Tucker 2003-05-04 10:16:10 AEST
Fixed in 3.6.1p2.  From ChangeLog:
20030429
[snip]
 - (djm) Some systems have basename in -lgen. Fix from ayamura@ayamura.org

This also affected Solaris (and possibly other platforms).
Comment 3 Darren Tucker 2003-05-04 10:16:43 AEST
*** Bug 532 has been marked as a duplicate of this bug. ***
Comment 4 Darren Tucker 2003-05-04 10:17:18 AEST
*** Bug 546 has been marked as a duplicate of this bug. ***
Comment 5 Damien Miller 2004-04-14 12:24:18 AEST
Mass change of RESOLVED bugs to CLOSED