2
# $Id: s_win32,v 1.14 2001/05/27 14:08:20 bostic Exp $
4
# Build Windows/32 include files.
6
msgc="/* DO NOT EDIT: automatically built by dist/s_win32. */"
14
trap 'rm -f $s $t ; exit 1' 1 2 3 13 15
17
cat <<ENDOFSEDTEXT > $s
18
s/@u_int8_decl@/typedef unsigned char u_int8_t;/
19
s/@int16_decl@/typedef short int16_t;/
20
s/@u_int16_decl@/typedef unsigned short u_int16_t;/
21
s/@int32_decl@/typedef int int32_t;/
22
s/@u_int32_decl@/typedef unsigned int u_int32_t;/
25
#if !defined(_WINSOCKAPI_)
26
s/@u_char_decl@/typedef unsigned char u_char;/
28
s/@u_short_decl@/typedef unsigned short u_short;/
29
s/@u_int_decl@/typedef unsigned int u_int;/
31
s/@u_long_decl@/typedef unsigned long u_long;/
37
#if defined(_WIN64) || defined(_M_ALPHA)\\
38
typedef __int64 ssize_t;\\
40
typedef int ssize_t;\\
44
s/@DB_VERSION_MAJOR@/$DB_VERSION_MAJOR/
45
s/@DB_VERSION_MINOR@/$DB_VERSION_MINOR/
46
s/@DB_VERSION_PATCH@/$DB_VERSION_PATCH/
47
s/@DB_VERSION_STRING@/"$DB_VERSION_STRING"/
50
sed -f $s ../include/db.in &&
51
cat ../include_auto/rpc_defs.in &&
52
cat ../include_auto/global_ext.in) > $t
53
cmp $t $f > /dev/null 2>&1 ||
54
(echo "Building $f" && rm -f $f && cp $t $f && chmod 444 $f)
56
f=../build_win32/db_int.h
57
cat <<ENDOFSEDTEXT > $s
58
s/\(PATH_SEPARATOR[^"]*"\)\/"/\1\\\\\\\\\\/:\"/
59
s/@db_align_t_decl@/typedef unsigned long db_align_t;/
60
s/@db_alignp_t_decl@/typedef unsigned long db_alignp_t;/
62
(echo "$msgc" && sed -f $s ../include/db_int.in) > $t
63
cmp $t $f > /dev/null 2>&1 ||
64
(echo "Building $f" && rm -f $f && cp $t $f && chmod 444 $f)
66
f=../build_win32/libdb.rc
67
cat <<ENDOFSEDTEXT > $s
68
s/%MAJOR%/$DB_VERSION_MAJOR/
69
s/%MINOR%/$DB_VERSION_MINOR/
70
s/%PATCH%/$DB_VERSION_PATCH/
72
sed -f $s ../build_win32/libdbrc.src > $t
73
cmp $t $f > /dev/null 2>&1 ||
74
(echo "Building $f" && rm -f $f && cp $t $f && chmod 444 $f)