site.def: Only build C/en_US locales by default for Linux
[oweals/cde.git] / cde / config / cf / linux.cf
index fbd4d09dd127a4eecb341c060397fab625c881ea..a5d5c93721625f22bcf09c19c470c71317c77732 100644 (file)
@@ -1,16 +1,16 @@
 XCOMM platform:  $TOG: linux.cf /main/47 1998/04/17 11:32:51 mgreess $
 
 #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 
@@ -18,7 +18,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)
@@ -34,17 +34,29 @@ XCOMM platform:  $TOG: linux.cf /main/47 1998/04/17 11:32:51 mgreess $
     LinuxYggdrasil  (12)
 */
 #endif
+
+#ifndef DefaultLinuxCLibMajorVersion
+# define DefaultLinuxCLibMajorVersion    6
+#endif
+#ifndef DefaultLinuxCLibMinorVersion
+# define DefaultLinuxCLibMinorVersion    0
+#endif
+#ifndef DefaultLinuxCLibTeenyVersion
+# define DefaultLinuxCLibTeenyVersion    0
+#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)
@@ -52,12 +64,16 @@ XCOMM libc:  (LinuxCLibMajorVersion./**/LinuxCLibMinorVersion./**/LinuxCLibTeeny
 XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 
 #ifndef UseElfFormat
-#if OSMajorVersion > 1 || (OSMajorVersion == 1 && OSMinorVersion > 1)
-#define UseElfFormat           YES
-#else
-#define UseElfFormat           NO
-#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 UseInstalledX11         YES
+
 #define BuildLibPathVar        LD_LIBRARY_PATH
 #define HasGcc                 YES
 #define HasGcc2                        YES
@@ -69,12 +85,23 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 #define HasPutenv              YES
 #define HasShm                 YES
 #define HasSockets             YES
+
+#define HasMakefileSafeInclude  YES
+#define DependFileName          .depend
+#define DependCmd               $(CC) -E -MM -MG
+
+#ifdef IncludeMakefile
+# undef IncludeMakefile
+#endif
+
+#define IncludeMakefile(file)   -include file
+
 #if (LinuxDistribution == LinuxRedHat)
-#define HasZlib                        YES
+# define HasZlib               YES
 #endif
 
 #define AvoidNullMakeCommand   YES
-#define StripInstalledPrograms YES
+#define StripInstalledPrograms NO
 #define CompressAllFonts       YES
 #define Malloc0ReturnsNull     YES
 #define NeedConstPrototypes    YES
@@ -84,36 +111,20 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 #define NeedWidePrototypes     NO
 #define SetTtyGroup            YES
 
-#if UseElfFormat
-#if OSMajorVersion == 1 && OSMinorVersion < 2
-#define CcCmd                  gcc -b i486-linuxelf
-#define CplusplusCmd           g++ -b i486-linuxelf
-#define AsCmd                  /usr/i486-linuxelf/bin/as
-#define LdCmd                  ld -m elf_i386
-#else
-#define CcCmd                  gcc
-#define CplusplusCmd           g++ 
+#define CcCmd                  gcc -g -pipe
+#define CplusplusCmd           g++ -g -pipe -fpermissive
 #define AsCmd                  as
 #define LdCmd                  ld
-#endif
+
+#define CplusplusLibC           -lstdc++
 #define AsmDefines             -D__ELF__
-#else
-#define CcCmd                  gcc
-#if OSMajorVersion == 1 && OSMinorVersion > 1
-#define AsCmd                  /usr/i486-linuxaout/bin/as
-#define LdCmd                  ld -m i386linux
-#else
-#define AsCmd                  as
-#define LdCmd                  ld
-#endif
-#define AsmDefines             -DUSE_GAS -U__ELF__
-#endif
+
 #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
@@ -122,62 +133,141 @@ XCOMM binutils:  (LinuxBinUtilsMajorVersion)
 #define LdCombineFlags         -r
 #define XawI18nDefines         -DUSE_XWCHAR_STRING -DUSE_XMBTOWC
 #define HasWChar32             YES
-#define StandardCppDefines     -traditional StandardDefines
+#define StandardCppDefines     -traditional -nostdinc StandardDefines
 #define ExtensionOSDefines     -DXTESTEXT1
 
-#if (LinuxDistribution == LinuxSuSE)
 #define LinuxLocaleDefines     /**/
+
+#define DefaultCCOptions        -ansi
+
+XCOMM Lets try XdmAuth instead of the ancient MIT/DES auth
+#define HasXdmAuth  YES
+
+XCOMM TIRPC is enabled by default now on Linux.  The libtirpc-dev package is
+XCOMM required for this support.  If you cannot use tirpc for some reason,
+XCOMM can disable it by defining HasTIRPCLib to NO in either
+XCOMM your host.def or site.def file.  Not using the TIRPC lib will require
+XCOMM that you run rpcbind in insecure mode (ie: with the -i option).
+XCOMM The default is YES.
+
+#ifndef HasTIRPCLib
+# define HasTIRPCLib YES
+#endif
+
+#if HasTIRPCLib
+TIRPCLIB = -ltirpc
+TIRPCINC = -I/usr/include/tirpc
 #else
-#define LinuxLocaleDefines     -DX_LOCALE
+TIRPCLIB =
+TIRPCINC =
+#endif
+
+#if !defined(DefaultGcc2i386Opt)
+# define DefaultGcc2i386Opt -O2 -fno-strict-aliasing -Wno-write-strings \
+       -Wno-unused-result
 #endif
 
 #if LinuxCLibMajorVersion < 6
-#define LinuxSourceDefines     -D_POSIX_SOURCE \
+# define LinuxSourceDefines    -D_POSIX_SOURCE -D_DEFAULT_SOURCE \
                                -D_BSD_SOURCE -D_SVID_SOURCE LinuxLocaleDefines
-#ifndef HasLibCrypt
-# define HasLibCrypt           NO
-#endif
+# ifndef HasLibCrypt
+#  define HasLibCrypt          NO
+# endif
+
 #else
-#define LinuxSourceDefines     -D_POSIX_C_SOURCE=199309L \
-                               -D_POSIX_SOURCE \
-                               -D_BSD_SOURCE -D_SVID_SOURCE
-#define HasPosixThreads                YES
-#define ThreadedX              YES
-#define HasThreadSafeAPI       YES
-#define ThreadsLibraries       -lpthread
-#define SystemMTDefines                -D_REENTRANT
-#ifndef HasLibCrypt
-# define HasLibCrypt           YES
-#endif
+# define LinuxSourceDefines    -D_POSIX_SOURCE -D_DEFAULT_SOURCE \
+                               -D_BSD_SOURCE -D_SVID_SOURCE \
+                               -D__NO_STRING_INLINES -D__NO_MATH_INLINES \
+                               LinuxLocaleDefines
+# define HasPosixThreads       YES
+# define ThreadedX             YES
+# define HasThreadSafeAPI      YES
+# define ThreadsLibraries      -lpthread
+# define SystemMTDefines       -D_REENTRANT
+# ifndef HasLibCrypt
+#  define HasLibCrypt          YES
+# endif
 #endif
 
-XCOMM This is needed for CDE currently
-#define CplusplusStandardDefines StandardDefines -fpermissive
+#ifdef SparcArchitecture
+# define LinuxMachineDefines -Dsparc
+
+# if UseElfFormat
+#  define HasPlugin             YES
+#  define VendorHasX11R6_3libXext YES     /* XC or XFree86 3.3.1 */
+# endif
+#endif /* SparcArchitecture */
+
+#ifdef ARMArchitecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags DefaultGcc2i386Opt
+# endif
+# define LinuxMachineDefines -D__arm__
+# define LSBBitOrder             YES
+
+# 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__
-#if UseElfFormat
-#define HasPlugin              YES
-#define VendorHasX11R6_3libXext        YES     /* XC or XFree86 3.3.1 */
-#endif
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags DefaultGcc2i386Opt
+# endif
+# define LinuxMachineDefines   -D__i386__
+/* For DtHelp TIFF processing routines. */
+# define LSBBitOrder             YES
+
+# if UseElfFormat
+#  define HasPlugin            YES
+#  define VendorHasX11R6_3libXext      YES     /* XC or XFree86 3.3.1 */
+# endif
 #endif /* i386Architecture */
 
+#ifdef AMD64Architecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags DefaultGcc2i386Opt
+# endif
+# define LinuxMachineDefines   -D__x86_64__ 
+/* For DtHelp TIFF processing routines. */
+# define LSBBitOrder            YES
+
+# if UseElfFormat
+#  define HasPlugin            YES
+#  define VendorHasX11R6_3libXext      YES     /* XC or XFree86 3.3.1 */
+# endif
+#endif /* AMD64Architecture */
+
+#ifdef PpcArchitecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags    DefaultGcc2i386Opt
+# endif
+# define LinuxMachineDefines     -D__powerpc__
+#endif /* PpcArchitecture */
+
 #ifdef AlphaArchitecture
-#define OptimizedCDebugFlags   -O2
-#define LinuxMachineDefines    -D__alpha__
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags DefaultGcc2i386Opt
+# endif
+# define LinuxMachineDefines   -D__alpha__
 #endif /* AlphaArchitecture */
 
 #ifdef Mc68020Architecture
-#define OptimizedCDebugFlags   -O2
-#define LinuxMachineDefines    -D__mc68000__
-#define StandardCppDefines      -traditional StandardDefines
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags DefaultGcc2i386Opt
+# endif
+# define LinuxMachineDefines   -D__mc68000__
+# define StandardCppDefines      -traditional 
 #endif /* Mc68020Architecture */
 
-#define StandardDefines                -Dlinux LinuxMachineDefines LinuxSourceDefines
+#define StandardDefines                -D__linux__ LinuxMachineDefines LinuxSourceDefines
 
 #define ConnectionFlags                -DUNIXCONN -DTCPCONN
 
+XCOMM This is needed for CDE currently
+#define CplusplusStandardDefines StandardDefines 
+
 /* Some of these man page defaults are overriden in the above OS sections */
 #ifndef ManSuffix
 # define ManSuffix     1x
@@ -200,8 +290,9 @@ XCOMM This is needed for CDE currently
 
 #define ArchitectureDefines    -DLINUX_ARCHITECTURE
 
-#define TtClientLibs $(TTLIB) $(XTOOLLIB) $(XLIB)
-#define TtClientDepLibs $(DEPTTLIB) $(DEPXTOOLLIB) $(DEPXLIB)
+#define TtClientLibs $(TTLIB) $(TIRPCLIB) $(XTOOLLIB) $(XLIB)
+
+#define SharedTtReqs $(TIRPCLIB) $(LDPRELIBS) SharedXReqs $(CXXLIB)
 
+#include <lnxDep.rules>
 #include <lnxLib.rules>
-#include <xfree86.cf>