r8450: more configure tests for solaris. It now builds some binaries, but
authorAndrew Tridgell <tridge@samba.org>
Thu, 14 Jul 2005 06:36:19 +0000 (06:36 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:23:04 +0000 (13:23 -0500)
fails in the ejs floating point code.
(This used to be commit 30e1b6140e9f6246cb66eef7cf108d1ccf62bd40)

source4/heimdal_build/config.h
source4/heimdal_build/config.m4
source4/heimdal_build/config.mk
source4/heimdal_build/replace.c
source4/lib/replace/replace.h

index 02b3705ba108a8913e5cf91cadb6ae46ce7578cf..6bbe94715556e8bb74a2c9f4ca5d0bfd9dea047f 100644 (file)
@@ -3,6 +3,9 @@
   Samba source tree
 */
 
+#ifndef HAVE_HEIMDAL_CONFIG_H
+#define HAVE_HEIMDAL_CONFIG_H 1
+
 /* bring in the samba4 config.h */
 #include "include/config.h"
 
@@ -42,3 +45,5 @@ static /**/const char *const rcsid[] = { (const char *)rcsid, "\100(#)" msg }
 #include <stdarg.h>
 #include "lib/replace/replace.h"
 #endif
+
+#endif
index 90fb7a930d38aed11c443e5c997e62b352004553..342ab6901fa45d6153db5c3d0bc6e6feb1f17e5a 100644 (file)
@@ -87,6 +87,8 @@ AC_CHECK_FUNCS([                              \
        hstrerror                               \
        err                                     \
        errx                                    \
+       warnx                                   \
+       flock                                   \
        writev
 ])
 
@@ -174,6 +176,10 @@ SMB_BINARY_ENABLE(compile_et, NO)
 AC_PROG_LEX
 AC_PROG_YACC
 
+AC_CHECK_TYPES(u_int32_t)
+AC_CHECK_TYPES(u_int16_t)
+AC_CHECK_TYPES(u_int8_t)
+
 # to enable kerberos, unpack a heimdal source tree in the heimdal directory
 # of the samba source tree
 if test -d heimdal; then
index 9b1ee96edf971014b6a3851d5bbaaf67d3bb3bf6..25abfa9542d87d6e59fc108a06ae9a4989b672b8 100644 (file)
@@ -179,7 +179,6 @@ ADD_OBJ_FILES = \
        heimdal/lib/asn1/der_length.o \
        heimdal/lib/asn1/der_copy.o \
        heimdal/lib/asn1/der_cmp.o \
-       heimdal/lib/asn1/timegm.o \
        heimdal/lib/asn1/asn1_AD_IF_RELEVANT.o \
        heimdal/lib/asn1/asn1_APOptions.o \
        heimdal/lib/asn1/asn1_AP_REP.o \
@@ -282,7 +281,8 @@ ADD_OBJ_FILES = \
        heimdal/lib/roken/strlwr.o \
        heimdal/lib/roken/strsep_copy.o \
        heimdal/lib/roken/strupr.o \
-       heimdal/lib/roken/strpool.o
+       heimdal/lib/roken/strpool.o \
+       heimdal_build/replace.o
 NOPROTO = YES
 # End SUBSYSTEM HEIMDAL_ROKEN
 #######################
index 0b7e1943f86a247e8308e8769b7e65ee5f72e7c1..46019d7bb52d0256750ce138e2b1c9d1269b9c38 100644 (file)
@@ -24,6 +24,7 @@
 #include "config.h"
 #include <stdio.h>
 #include "err.h"
+#include "roken.h"
 
 #ifndef HAVE_ERR
  void err(int eval, const char *format, ...)
        exit(eval);
 }
 #endif
+
+#ifndef HAVE_WARNX
+ void warnx(const char *format, ...)
+{
+       va_list ap;
+       va_start(ap, format);
+       vfprintf(stderr, format, ap);
+       va_end(ap);
+}
+#endif
+
+#ifndef HAVE_FLOCK
+ int flock(int fd, int op)
+{
+       switch (op & (LOCK_UN|LOCK_SH|LOCK_EX)) {
+       case LOCK_UN:
+               return fcntl_lock(fd, F_SETLK, 0, 0, F_UNLCK);
+       case LOCK_SH:
+               return fcntl_lock(fd, (op&LOCK_NB)?F_SETLK:F_SETLKW, 
+                                 0, 0, F_RDLCK);
+       case LOCK_EX:
+               return fcntl_lock(fd, (op&LOCK_NB)?F_SETLK:F_SETLKW, 
+                                 0, 0, F_WRLCK);
+       }
+       errno = EINVAL;
+       return -1;
+}
+#endif
index 89225d3d65184bf6d966c3076977695925b24079..48e46ba18e9769b690462c07cb6bfce9a5ddedd9 100644 (file)
@@ -119,4 +119,16 @@ int asprintf(char **,const char *, ...) PRINTF_ATTRIBUTE(2,3);
 typedef int (*comparison_fn_t)(const void *, const void *);
 #endif
 
+#ifndef HAVE_U_INT32_T
+typedef unsigned u_int32_t;
+#endif
+
+#ifndef HAVE_U_INT16_T
+typedef unsigned short u_int16_t;
+#endif
+
+#ifndef HAVE_U_INT8_T
+typedef unsigned char u_int8_t;
+#endif
+
 #endif