René Nieuwenhuizen
2002-Nov-22 11:42 UTC
[Samba] Add -D_XOPEN_SOURCE_EXTENDED definition for HP/UX 11.00 platform
Hi, I suggest to add the following definition to configure and its template configure.in to allow samba-2.2.x to be compiled on HP/UX 11.00 with some lesser warnings. Without this definition you'll get warnings on all socket operation because the socket operations are UNIX98 specific and HP/UX 11.00 will support this when _XOPEN_SOURCE_EXTENDED is defined. -- Ren? Nieuwenhuizen Afdeling Informatietechnologie Centraal Planbureau Bezoekadres: Van Stolkweg 14, 2585 JR Den Haag Postadres: Postbus 80510, 2508 GM Den Haag T (070) 3383 342 F (070) 3383 350 I http://www.cpb.nl/nl/general/org/afdelingen/it/ -- ===============================================================================Aan dit bericht kunnen geen rechten worden ontleend. Het bericht is alleen bestemd voor de geadresseerde. Indien dit bericht niet voor u is bestemd, verzoeken wij u dit onmiddellijk aan ons te melden en de inhoud van het bericht te vernietigen. This message shall not constitute any obligations. This message is intended solely for the addressee. If you have received this message in error, please inform us immediately and delete its contents. ===============================================================================-------------- next part -------------- *** configure.in.orig Mon Jun 17 20:35:09 2002 --- configure.in Thu Jun 20 14:55:21 2002 *************** *** 36,41 **** --- 36,48 ---- CFLAGS="" fi ;; + HP-UX) + if test "${GCC}" = "yes"; then + CFLAGS="$CFLAGS" + else + CFLAGS="-Ae -c +z" + fi + ;; # Linux) # CFLAGS="-Wall" # ;; *************** *** 52,57 **** --- 59,67 ---- ;; SunOS) LDFLAGS="-G" + ;; + HP-UX) + LDFLAGS="-b" ;; # Linux) # echo "Linux found" -------------- next part -------------- *** configure.orig Thu Jun 20 15:11:07 2002 --- configure Thu Jun 20 14:57:34 2002 *************** *** 811,816 **** --- 811,823 ---- CFLAGS="" fi ;; + HP-UX) + if test "${GCC}" = "yes"; then + CFLAGS="$CFLAGS" + else + CFLAGS="-Ae -c +z" + fi + ;; # Linux) # CFLAGS="-Wall" # ;; *************** *** 827,832 **** --- 834,842 ---- ;; SunOS) LDFLAGS="-G" + ;; + HP-UX) + LDFLAGS="-b" ;; # Linux) # echo "Linux found"
René Nieuwenhuizen
2002-Nov-22 11:59 UTC
[Samba] Add -D_XOPEN_SOURCE_EXTENDED definition for HP/UX 11.00 platform
Hi, Sorry the previous sending had the wrong attachments!!! I suggest to add the following definition to configure and its template configure.in to allow samba-2.2.x to be compiled on HP/UX 11.00 with some lesser warnings. Without this definition you'll get warnings on all socket operation because the socket operations are UNIX98 specific and HP/UX 11.00 will support this when _XOPEN_SOURCE_EXTENDED is defined. -- Ren? Nieuwenhuizen Afdeling Informatietechnologie Centraal Planbureau Bezoekadres: Van Stolkweg 14, 2585 JR Den Haag Postadres: Postbus 80510, 2508 GM Den Haag T (070) 3383 342 F (070) 3383 350 I http://www.cpb.nl/nl/general/org/afdelingen/it/ -- ===============================================================================Aan dit bericht kunnen geen rechten worden ontleend. Het bericht is alleen bestemd voor de geadresseerde. Indien dit bericht niet voor u is bestemd, verzoeken wij u dit onmiddellijk aan ons te melden en de inhoud van het bericht te vernietigen. This message shall not constitute any obligations. This message is intended solely for the addressee. If you have received this message in error, please inform us immediately and delete its contents. ===============================================================================-------------- next part -------------- *** configure.orig Tue Nov 19 19:44:19 2002 --- configure Fri Nov 22 12:36:17 2002 *************** *** 1474,1480 **** ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4" cat >> confdefs.h <<\EOF #define _HPUX_SOURCE 1 EOF --- 1474,1480 ---- ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4 -D_XOPEN_SOURCE_EXTENDED" cat >> confdefs.h <<\EOF #define _HPUX_SOURCE 1 EOF *************** *** 1488,1498 **** --- 1488,1506 ---- EOF cat >> confdefs.h <<\EOF + #define _FILE_OFFSET_BITS 64 + EOF + + cat >> confdefs.h <<\EOF #define _ALIGNMENT_REQUIRED 1 EOF cat >> confdefs.h <<\EOF #define _MAX_ALIGNMENT 4 + EOF + + cat >> confdefs.h <<\EOF + #define _XOPEN_SOURCE_EXTENDED 1 EOF cat >> confdefs.h <<\EOF -------------- next part -------------- *** configure.in.orig Tue Nov 19 19:44:19 2002 --- configure.in Fri Nov 22 12:37:03 2002 *************** *** 247,258 **** AC_DEFINE(_MAX_ALIGNMENT,4) ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4" AC_DEFINE(_HPUX_SOURCE) AC_DEFINE(_POSIX_SOURCE) AC_DEFINE(_LARGEFILE64_SOURCE) AC_DEFINE(_ALIGNMENT_REQUIRED,1) AC_DEFINE(_MAX_ALIGNMENT,4) AC_DEFINE(USE_BOTH_CRYPT_CALLS) ;; esac --- 247,260 ---- AC_DEFINE(_MAX_ALIGNMENT,4) ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4 -D_XOPEN_SOURCE_EXTENDED" AC_DEFINE(_HPUX_SOURCE) AC_DEFINE(_POSIX_SOURCE) AC_DEFINE(_LARGEFILE64_SOURCE) + AC_DEFINE(_FILE_OFFSET_BITS,64) AC_DEFINE(_ALIGNMENT_REQUIRED,1) AC_DEFINE(_MAX_ALIGNMENT,4) + AC_DEFINE(_XOPEN_SOURCE_EXTENDE,1) AC_DEFINE(USE_BOTH_CRYPT_CALLS) ;; esac
René Nieuwenhuizen
2002-Nov-22 12:02 UTC
[Samba] Add -D_XOPEN_SOURCE_EXTENDED definition for HP/UX 11.00 platform
Hi, Sorry the previous sending had the right attachments but in configure.in.diff there was a ending D missing!!! I suggest to add the following definition to configure and its template configure.in to allow samba-2.2.x to be compiled on HP/UX 11.00 with some lesser warnings. Without this definition you'll get warnings on all socket operation because the socket operations are UNIX98 specific and HP/UX 11.00 will support this when _XOPEN_SOURCE_EXTENDED is defined. -- Ren? Nieuwenhuizen Afdeling Informatietechnologie Centraal Planbureau Bezoekadres: Van Stolkweg 14, 2585 JR Den Haag Postadres: Postbus 80510, 2508 GM Den Haag T (070) 3383 342 F (070) 3383 350 I http://www.cpb.nl/nl/general/org/afdelingen/it/ -- ===============================================================================Aan dit bericht kunnen geen rechten worden ontleend. Het bericht is alleen bestemd voor de geadresseerde. Indien dit bericht niet voor u is bestemd, verzoeken wij u dit onmiddellijk aan ons te melden en de inhoud van het bericht te vernietigen. This message shall not constitute any obligations. This message is intended solely for the addressee. If you have received this message in error, please inform us immediately and delete its contents. ===============================================================================-------------- next part -------------- *** configure.orig Tue Nov 19 19:44:19 2002 --- configure Fri Nov 22 12:36:17 2002 *************** *** 1474,1480 **** ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4" cat >> confdefs.h <<\EOF #define _HPUX_SOURCE 1 EOF --- 1474,1480 ---- ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4 -D_XOPEN_SOURCE_EXTENDED" cat >> confdefs.h <<\EOF #define _HPUX_SOURCE 1 EOF *************** *** 1488,1498 **** --- 1488,1506 ---- EOF cat >> confdefs.h <<\EOF + #define _FILE_OFFSET_BITS 64 + EOF + + cat >> confdefs.h <<\EOF #define _ALIGNMENT_REQUIRED 1 EOF cat >> confdefs.h <<\EOF #define _MAX_ALIGNMENT 4 + EOF + + cat >> confdefs.h <<\EOF + #define _XOPEN_SOURCE_EXTENDED 1 EOF cat >> confdefs.h <<\EOF -------------- next part -------------- *** configure.in.orig Tue Nov 19 19:44:19 2002 --- configure.in Fri Nov 22 12:37:03 2002 *************** *** 247,258 **** AC_DEFINE(_MAX_ALIGNMENT,4) ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4" AC_DEFINE(_HPUX_SOURCE) AC_DEFINE(_POSIX_SOURCE) AC_DEFINE(_LARGEFILE64_SOURCE) AC_DEFINE(_ALIGNMENT_REQUIRED,1) AC_DEFINE(_MAX_ALIGNMENT,4) AC_DEFINE(USE_BOTH_CRYPT_CALLS) ;; esac --- 247,260 ---- AC_DEFINE(_MAX_ALIGNMENT,4) ;; *11*) ! CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_ALIGNMENT_REQUIRED=1 -D_MAX_ALIGNMENT=4 -D_XOPEN_SOURCE_EXTENDED" AC_DEFINE(_HPUX_SOURCE) AC_DEFINE(_POSIX_SOURCE) AC_DEFINE(_LARGEFILE64_SOURCE) + AC_DEFINE(_FILE_OFFSET_BITS,64) AC_DEFINE(_ALIGNMENT_REQUIRED,1) AC_DEFINE(_MAX_ALIGNMENT,4) + AC_DEFINE(_XOPEN_SOURCE_EXTENDED,1) AC_DEFINE(USE_BOTH_CRYPT_CALLS) ;; esac