OpenBSD.cf: don't include xorg.cf (leftover)
[oweals/cde.git] / cde / config / cf / linux.cf
index c277ce986c9a0c518a0d102f975b82560b9aa0e4..c217dbdd9029570443c2466ec6e2f43935fd4d6b 100644 (file)
@@ -6,16 +6,16 @@ XCOMM platform:  $TOG: linux.cf /main/47 1998/04/17 11:32:51 mgreess $
 #define TopXInclude -isystem$(TOP)/imports/x11/include
 
 #ifndef OSName
-#define OSName                 DefaultOSName
+# define OSName                        DefaultOSName
 #endif
 #ifndef OSMajorVersion
-#define OSMajorVersion         DefaultOSMajorVersion
+# define OSMajorVersion                DefaultOSMajorVersion
 #endif
 #ifndef OSMinorVersion
-#define OSMinorVersion         DefaultOSMinorVersion
+# define OSMinorVersion                DefaultOSMinorVersion
 #endif
 #ifndef OSTeenyVersion
-#define OSTeenyVersion         DefaultOSTeenyVersion
+# define OSTeenyVersion                DefaultOSTeenyVersion
 #endif
 
 #ifndef LinuxDistribution 
@@ -23,7 +23,7 @@ XCOMM platform:  $TOG: linux.cf /main/47 1998/04/17 11:32:51 mgreess $
 /*
   Add "#define LinuxDistribution Linux<mumble>" to your site.def or host.def.
   Currently only LinuxSuSE will be figured out automatically.
-  Valid values are (from the list at www.linux.org in Oct. '97):
+  Valid values are (from the list at www.linux.org in Oct. 1997):
     LinuxUnknown    (0)
     LinuxSuSE       (1)
     LinuxCaldera    (2)
@@ -40,16 +40,16 @@ XCOMM platform:  $TOG: linux.cf /main/47 1998/04/17 11:32:51 mgreess $
 */
 #endif
 #ifndef LinuxCLibMajorVersion
-#define LinuxCLibMajorVersion   DefaultLinuxCLibMajorVersion
+# define LinuxCLibMajorVersion   DefaultLinuxCLibMajorVersion
 #endif
 #ifndef LinuxCLibMinorVersion
-#define LinuxCLibMinorVersion   DefaultLinuxCLibMinorVersion
+# define LinuxCLibMinorVersion   DefaultLinuxCLibMinorVersion
 #endif
 #ifndef LinuxCLibTeenyVersion
-#define LinuxCLibTeenyVersion   DefaultLinuxCLibTeenyVersion
+# define LinuxCLibTeenyVersion   DefaultLinuxCLibTeenyVersion
 #endif
 #ifndef LinuxBinUtilsMajorVersion
-#define LinuxBinUtilsMajorVersion      DefaultLinuxBinUtilsMajorVersion
+# define LinuxBinUtilsMajorVersion     DefaultLinuxBinUtilsMajorVersion
 #endif
 
 XCOMM operating system:  OSName (OSMajorVersion./**/OSMinorVersion./**/OSTeenyVersion)
@@ -57,13 +57,14 @@ XCOMM libc:  (LinuxCLibMajorVersion./**/LinuxCLibMinorVersion./**/LinuxCLibTeeny
 XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 
 #ifndef UseElfFormat
-#if OSMajorVersion > 1 || (OSMajorVersion == 1 && OSMinorVersion > 1)
-#define UseElfFormat           YES
-#else
-#define UseElfFormat           NO
-#error "Only ELF format is supported on linux"
-#endif
+# if OSMajorVersion > 1 || (OSMajorVersion == 1 && OSMinorVersion > 1)
+#  define UseElfFormat         YES
+# else
+#  define UseElfFormat         NO
+#  error "Only ELF format is supported on linux"
+# endif
 #endif
+
 #define BuildLibPathVar        LD_LIBRARY_PATH
 #define HasGcc                 YES
 #define HasGcc2                        YES
@@ -76,7 +77,7 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 #define HasShm                 YES
 #define HasSockets             YES
 #if (LinuxDistribution == LinuxRedHat)
-#define HasZlib                        YES
+# define HasZlib               YES
 #endif
 
 #define AvoidNullMakeCommand   YES
@@ -101,9 +102,9 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 #define MkdirHierCmd           mkdir -p
 #define CppCmd                 /lib/cpp
 #if OSMajorVersion >= 2
-#define YaccCmd                 yacc
+# define YaccCmd                yacc
 #else
-#define YaccCmd                 bison -y
+# define YaccCmd                bison -y
 #endif
 #define LexCmd                 flex -l
 #define LexLib                 -lfl
@@ -117,6 +118,26 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 
 #define LinuxLocaleDefines     /**/
 
+XCOMM If you have the tirpc library on your system, and you have the
+XCOMM libtirpc-dev installed, then define HasTIRPCLib to YES in either
+XCOMM your host.def or site.def file.  Using the tirpc lib should
+XCOMM allow running rpcbind in secure mode (ie: without the -i option).
+XCOMM The default is NO.
+
+#ifndef HasTIRPCLib
+# define HasTIRPCLib NO
+#endif
+
+#if HasTIRPCLib
+TIRPCLIB = -ltirpc
+#else
+TIRPCLIB = 
+#endif
+
+#if !defined(DefaultGcc2i386Opt)
+# define DefaultGcc2i386Opt -O2 -fno-strict-aliasing
+#endif
+
 #if LinuxCLibMajorVersion < 6
 # define LinuxSourceDefines    -D_POSIX_SOURCE \
                                -D_BSD_SOURCE -D_SVID_SOURCE LinuxLocaleDefines
@@ -128,8 +149,8 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 # define LinuxSourceDefines    -D_POSIX_C_SOURCE=199309L \
                                -D_POSIX_SOURCE \
                                -D_BSD_SOURCE -D_SVID_SOURCE -D_XOPEN_SOURCE \
-                                -D__NO_STRING_INLINES -D__NO_MATH_INLINES \
-                                LinuxLocaleDefines
+                               -D__NO_STRING_INLINES -D__NO_MATH_INLINES \
+                               LinuxLocaleDefines
 # define HasPosixThreads       YES
 # define ThreadedX             YES
 # define HasThreadSafeAPI      YES
@@ -141,68 +162,75 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 #endif
 
 #ifdef SparcArchitecture
-#define LinuxMachineDefines -Dsparc
+# define LinuxMachineDefines -Dsparc
 
-#if UseElfFormat
-#define HasPlugin               YES
-#define VendorHasX11R6_3libXext YES     /* XC or XFree86 3.3.1 */
-#endif
+# if UseElfFormat
+#  define HasPlugin             YES
+#  define VendorHasX11R6_3libXext YES     /* XC or XFree86 3.3.1 */
+# endif
 #endif /* SparcArchitecture */
 
 #ifdef ARMArchitecture
-#define LinuxMachineDefines -D__arm__
-#define LSBBitOrder             YES
+# define LinuxMachineDefines -D__arm__
+# define LSBBitOrder             YES
 
-#if UseElfFormat
-#define HasPlugin               YES
-#define VendorHasX11R6_3libXext YES     /* XC or XFree86 3.3.1 */
-#endif 
+# if UseElfFormat
+#  define HasPlugin              YES
+#  define VendorHasX11R6_3libXext YES     /* XC or XFree86 3.3.1 */
+# endif 
 #endif /* ARMArchitecture */
 
 #ifdef i386Architecture
-#define OptimizedCDebugFlags   DefaultGcc2i386Opt
-#define LinuxMachineDefines    -D__i386__
+# define OptimizedCDebugFlags  DefaultGcc2i386Opt
+# define LinuxMachineDefines   -D__i386__
 /* For DtHelp TIFF processing routines. */
-#define LSBBitOrder             YES
+# define LSBBitOrder             YES
 
-#if UseElfFormat
-#define HasPlugin              YES
-#define VendorHasX11R6_3libXext        YES     /* XC or XFree86 3.3.1 */
-#endif
+# if UseElfFormat
+#  define HasPlugin            YES
+#  define VendorHasX11R6_3libXext      YES     /* XC or XFree86 3.3.1 */
+# endif
 /* add this to void screenfuls of warnings from makedepend */
-#define DependFlags -I/usr/include/i386-linux-gnu
+# define DependFlags -I/usr/include/i386-linux-gnu
 #endif /* i386Architecture */
 
 #ifdef AMD64Architecture
-#define OptimizedCDebugFlags   DefaultGcc2i386Opt
-#define LinuxMachineDefines    -D__x86_64__ 
+# define OptimizedCDebugFlags  DefaultGcc2i386Opt
+# define LinuxMachineDefines   -D__x86_64__ 
 /* For DtHelp TIFF processing routines. */
-#define LSBBitOrder             YES
+# define LSBBitOrder            YES
 
-#if UseElfFormat
-#define HasPlugin              YES
-#define VendorHasX11R6_3libXext        YES     /* XC or XFree86 3.3.1 */
-#endif
+# if UseElfFormat
+#  define HasPlugin            YES
+#  define VendorHasX11R6_3libXext      YES     /* XC or XFree86 3.3.1 */
+# endif
 /* add this to void screenfuls of warnings from makedepend */
-#define DependFlags -I/usr/include/x86_64-linux-gnu
+# define DependFlags -I/usr/include/x86_64-linux-gnu
 #endif /* AMD64Architecture */
 
 #ifdef PpcArchitecture
-#define OptimizedCDebugFlags    -O2
-#define LinuxMachineDefines     -D__powerpc__
+# define OptimizedCDebugFlags    DefaultGcc2i386Opt
+# define LinuxMachineDefines     -D__powerpc__
 #endif /* PpcArchitecture */
 
 #ifdef AlphaArchitecture
-#define OptimizedCDebugFlags   -O2
-#define LinuxMachineDefines    -D__alpha__
+# define OptimizedCDebugFlags  DefaultGcc2i386Opt
+# define LinuxMachineDefines   -D__alpha__
 #endif /* AlphaArchitecture */
 
 #ifdef Mc68020Architecture
-#define OptimizedCDebugFlags   -O2
-#define LinuxMachineDefines    -D__mc68000__
-#define StandardCppDefines      -traditional 
+# define OptimizedCDebugFlags  DefaultGcc2i386Opt
+# define LinuxMachineDefines   -D__mc68000__
+# define StandardCppDefines      -traditional 
 #endif /* Mc68020Architecture */
 
+#ifdef HasGcc2
+CXXDEPENDINCLUDE = $(shell CppCmd -x c++ -Wp,-v < /dev/null \
+                  2>&1 | sed -n 's/ \(.*[cg]++.*\)/-I\1/p')
+#define CplusplusDependIncludes        $(CXXDEPENDINCLUDE)
+#endif
+#define DependDefines          -D_SYS_RESOURCE_H -D_SYS_UTSNAME_H
+
 #define StandardDefines                -Dlinux LinuxMachineDefines LinuxSourceDefines
 
 #define ConnectionFlags                -DUNIXCONN -DTCPCONN
@@ -232,7 +260,7 @@ XCOMM This is needed for CDE currently
 
 #define ArchitectureDefines    -DLINUX_ARCHITECTURE
 
-#define TtClientLibs $(TTLIB) $(XTOOLLIB) $(XLIB)
+#define TtClientLibs $(TTLIB) $(TIRPCLIB) $(XTOOLLIB) $(XLIB)
 #define TtClientDepLibs $(DEPTTLIB) $(DEPXTOOLLIB) $(DEPXLIB)
 
 #include <lnxLib.rules>