all::
-configMin:: $(DATABASE_DIR)/CDE-MIN.udb
- $(UDBTOANY) -toLst -ReleaseStream $(PLATFORM) \
- $(DATABASE_DIR)/CDE-MIN.udb > CDE-MIN.lst
- $(BUILD_UDB_LIST) CDE-MIN ../../../..
-
-configTT:: $(DATABASE_DIR)/CDE-TT.udb
- $(UDBTOANY) -toLst -ReleaseStream $(PLATFORM) \
- $(DATABASE_DIR)/CDE-TT.udb > CDE-TT.lst
- $(BUILD_UDB_LIST) CDE-TT ../../../..
-
-configRun:: $(DATABASE_DIR)/CDE-RUN.udb
- $(UDBTOANY) -toLst -ReleaseStream $(PLATFORM) \
- $(DATABASE_DIR)/CDE-RUN.udb > CDE-RUN.lst
- $(BUILD_UDB_LIST) CDE-RUN ../../../..
-
-configShlibs:: $(DATABASE_DIR)/CDE-SHLIBS.udb
- $(UDBTOANY) -toLst -ReleaseStream $(PLATFORM) \
- $(DATABASE_DIR)/CDE-SHLIBS.udb > CDE-SHLIBS.lst
- $(BUILD_UDB_LIST) CDE-SHLIBS ../../../..
+DoUDB_SCRIPT4(configMin,CDE-MIN,$(UDBTOANY),$(BUILD_UDB_LIST))
+DoUDB_SCRIPT4(configTT,CDE-TT,$(UDBTOANY),$(BUILD_UDB_LIST))
+DoUDB_SCRIPT4(configRun,CDE-RUN,$(UDBTOANY),$(BUILD_UDB_LIST))
+DoUDB_SCRIPT4(configShlibs,CDE-SHLIBS,$(UDBTOANY),$(BUILD_UDB_LIST))
+
LOCAL_CPP_DEFINES = -DCDE_INSTALLATION_TOP=$(CDE_INSTALLATION_TOP) \
-DCDE_CONFIGURATION_TOP=$(CDE_CONFIGURATION_TOP) \
#define CppCmd /usr/libexec/cpp -traditional
#endif
#define StandardCppOptions -traditional
-#define StandardCppDefines /**/
#define PreProcessCmd CppCmd
#define PreIncDir DefaultGccIncludeDir
-#ifndef CcCmd
-#define CcCmd cc
+#if OSMajorVersion > 6 || (OSMajorVersion == 6 && OSMinorVersion >= 2)
+#define CcCmd cc
+#define CplusplusCmd c++
+#define CppArgs -Wno-invalid-pp-token
+#else
+#define CcCmd gcc
+#define CplusplusCmd g++
+#define CppArgs /**/
+#endif
+
+#ifndef StandardCppDefines
+#define StandardCppDefines -traditional CppArgs
#endif
+
#ifndef AsCmd
#define AsCmd cc -c -x assembler
#endif
*/
#ifdef HasGcc2ForCplusplus
-CXXDEPENDINCLUDE != echo | `CcCmd -print-prog-name=cc1plus` -v 2>&1 | \
- sed -n 's/ \(.*[cg]++.*\)/-I\1/p'; rm -f gccdump.s
+CXXDEPENDINCLUDE != CcCmd -v -x c++ /dev/null -fsyntax-only \
+ 2>&1 | sed -n 's/^ \(\/.*[cg]++.*\)/-I\1/p'
#define CplusplusDependIncludes $(CXXDEPENDINCLUDE)
#endif
typedef enum {B_FALSE, B_TRUE} boolean_t;
#define MAXNAMELEN 256
-#if !defined(__FreeBSD__)
+#if !defined(CSRG_BASED)
#define iconv_t int
#define iconv_open(a, b) ((iconv_t) -1)
#define iconv(a, b, c, d, e) ((size_t) 0)
*/
static char *Includes[] =
{
+ "<stdint.h>",
"<unistd.h>",
"<stdlib.h>",
"<stdio.h>",
/*
* Local variables
*/
- abio_puts(codeFile, "Widget\t\ttoplevel = 0;\n");
+ abio_puts(codeFile, "Widget\t\ttoplevel = (Widget)NULL;\n");
abio_puts(codeFile, "Display\t\t*display = (Display*)NULL;\n");
abio_puts(codeFile, "XtAppContext\tapp = (XtAppContext)NULL;\n");
abio_puts(codeFile, "String\t\t*fallback_resources = (String*)NULL;\n");
{
abmfP_write_c_comment(genCodeInfo, FALSE,
"Set up the application's root window.");
- abio_printf(codeFile, "%s = toplevel;\n",
+ abio_printf(codeFile, "%s = toplevel;\n\n",
abmfP_get_c_name_global(main_window));
if (obj_get_icon(main_window) != NULL)
void srefout(M_NOPAR)
{
LOGICAL first = TRUE ;
- int *mapbysref ;
+ int *mapbysref = NULL ;
SREFSTRUCT *srefp ;
SREFDATA *data ;
int count = 0 ;
/* End.c executes end-code specified in the interface. */
+#include <stdint.h>
+
#include "userinc.h"
#include "globdec.h"
hdr,sys poll,socket,netinet/in
lib select,poll,socket
-typ fd_set sys/socket.h
+typ fd_set sys/socket.h sys/select.h
cat{
#pragma prototyped
#ifdef _lib_poll
hdr,sys poll,socket,netinet/in
lib select,poll,socket
-typ fd_set sys/socket.h
+typ fd_set sys/socket.h sys/select.h
cat{
#pragma prototyped
#ifdef _lib_poll
}
#endif
+#if defined(__OpenBSD__) && OSMAJORVERSION > 5
+ /*
+ * Use the OpenBSD getpwnam_shadow function to get the crypt()ed password
+ */
+ p = getpwnam_shadow(name);
+#endif
+
if (!p || strlen(name) == 0 ||
strcmp (crypt (passwd, p->pw_passwd), p->pw_passwd)) {
#include <stdio.h>
#include <stdarg.h>
-#if defined(sun) || defined(__FreeBSD__)
+#if defined(sun) || defined(CSRG_BASED)
#include <iconv.h>
#endif
#include <sys/stat.h>
DTMailError_t minor_code);
};
-#if defined(sun) || defined(__FreeBSD__)
+#if defined(sun) || defined(CSRG_BASED)
template <typename T>
size_t iconv (iconv_t i, const T inbuf, size_t* inleft,
char** outbuf, size_t* outleft)
/*
* Get password entry for 'name' or 'uid'.
*/
+#if defined(__OpenBSD__) && OSMAJORVERSION > 5
+ if ((pwent = (name == NULL ?
+ getpwuid_shadow(uid) : getpwnam_shadow(name))) == NULL)
+#else
if ((pwent = (name == NULL ? getpwuid(uid) : getpwnam(name))) == NULL)
+#endif
{
/*
* Can't get entry.