You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Allan Edwards <ak...@us.ibm.com> on 2004/09/11 20:59:58 UTC
Windows IA64 builds
Here are a couple of scripts that set up the
Windows project files for IA64 builds. They
need to go in the build\win32 directory then
run setupIA64.cmd.
The awk script will update .dsp files to
build for IA64. It also provides prebuilt
chartables.c uri_delims.h and test_char.h
files since we cannot build these dynamically
in a cross compile environment(the executables
used to generate these files would be 64 bit).
It seems to me that this is a better solution
than adding a separate set of IA64 targets
to the existing project files, or maintaining
a separate set of .dsp's since either of those
routes incur quite a maintenance headache.
Allan
---------------------------------------------
#
# This performs fixups on Win32 .dsp and .dsw files to enable IA64 or AMD64 cross compiles
#
BEGIN {
buffer_cnt = 0
buffer_data = 0
delete_project = 0
delete_dependency = 0
root = escape_path(server_root)
ThisFile = root "build\\win32\\setup64.awk"
TempFile = root "setup64.tmp"
chartables_file = root "srclib\\pcre\\chartables.c"
uri_delims_file = root "srclib\\apr-util\\uri\\uri_delims.h"
test_char_file = root "server\\test_char.h"
if (!machine) {
print "Syntax: \n\t dir *.dsp /b/s/o:n | awk -f path_to_this_file -v machine=IA64|AMD64 -v server_root=path_to_server_root"
exit
}
}
{
# read the list of files piped in from the command line
# then invoke this same awk script for each .dsp or .dsw file
if (!child) {
cmd = "awk -f " ThisFile " -v machine=" machine " -v child=true -v server_root=" server_root " " $0
system(cmd)
next
}
}
########################################
# Fix up the .dsp file LINK statements #
########################################
/^# ADD LINK32/ {
if ($(NF) != "/machine:" machine ){
$(NF+1) = " /machine:" machine
}
}
/^# ADD BASE LINK32/ {
if ($(NF) != "/machine:" machine ){
$(NF+1) = " /machine:" machine
}
}
############################################################################
# Fix up .dsp and .dsw files to exclude unwanted projects and dependencies #
############################################################################
{
# detect block start and buffer until we know whether it should be excluded
if (FILENAME ~ /dsw$/) {
if (/^ Begin Project Dependency/ ||
(/^###########/ && (buffer_cnt == 0)) ){
# Dont restart block count if project is tagged to be deleted
if (delete_project != 1) {
flush_buffers()
}
buffer_data = 1
}
}
if (FILENAME ~ /dsp$/) {
if (/^# Begin Source File/) {
if (delete_project != 1) {
flush_buffers()
}
buffer_data = 1
}
}
}
{
if (FILENAME ~ /dsw$/) {
# detect projects to be excluded
if (/^Project: \"gen_uri_delims/ ||
/^Project: \"gen_test_char/ ||
/^Project: \"dftables/ ){
delete_project = 1
}
# detect dependencies to be excluded
else
if (/gen_uri_delims/ ||
/gen_test_char/ ||
/dftables/ ){
delete_dependency = 1
}
}
if (FILENAME ~ /.dsp$/) {
if (/gen_test_char.exe/ ||
/gen_uri_delims.exe/ ||
/dftables.exe/ ){
delete_dependency = 1
}
}
}
{
# detect end of buffered block
if (FILENAME ~ /dsw$/) {
if (/^ End Project Dependency/) {
if (delete_project != 1) {
buffer[++buffer_cnt] = $0
flush_buffers()
buffer_data = 0
delete_dependency = 0
next
}
}
if (/^##########/ && (buffer_cnt != 0)) {
# since this is both a start & end delimeter
# buffer the line and restart the block count
flush_buffers()
buffer[++buffer_cnt] = $0
buffer_data = 1
delete_project = 0
delete_dependency = 0
next
}
}
if (FILENAME ~ /dsp$/) {
if (/^# End Source File/) {
flush_buffers()
if (!delete_dependency)
print $0 > TempFile
buffer_data = 0
delete_dependency = 0
next
}
}
}
{
# Decide whether to print, buffer or delete the current line
if ((delete_dependency == 1) || (delete_project == 1)){
next
}
if (buffer_data == 1) {
buffer[++buffer_cnt] = $0
}
else {
print $0 > TempFile
}
}
END {
flush_buffers()
if (!child) {
printf "%d files converted for %s build \n", NR, machine
gen_chartables()
gen_test_char()
gen_uri_delims()
system("erase " TempFile);
}
else if (NR) {
close(TempFile)
close(FILENAME)
system("erase " FILENAME)
system("copy " TempFile " " FILENAME ">nul")
print FILENAME
}
}
function escape_path(inpath){
new_path = ""
if (!inpath)
return new_path
for(i=1; i<length(inpath) + 1; i++) {
char = substr(inpath, i, 1)
if (char == "/")
new_path = new_path "\\"
else
new_path = new_path char
}
return new_path
}
function flush_buffers() {
if ((delete_dependency == 0) && (delete_project == 0)) {
for (i=1; i<=buffer_cnt; i++) {
print buffer[i] > TempFile
}
}
for (i=1; i<=buffer_cnt; i++) {
delete buffer[i]
}
buffer_cnt = 0
}
function gen_chartables() {
print "/*************************************************" > chartables_file
print "* Perl-Compatible Regular Expressions *" > chartables_file
print "*************************************************/" > chartables_file
print "" > chartables_file
print "/* This file is automatically written by the dftables auxiliary " > chartables_file
print "program. If you edit it by hand, you might like to edit the Makefile to " > chartables_file
print "prevent its ever being regenerated." > chartables_file
print "" > chartables_file
print "This file is #included in the compilation of pcre.c to build the default" > chartables_file
print "character tables which are used when no tables are passed to the compile" > chartables_file
print "function. */" > chartables_file
print "" > chartables_file
print "static unsigned char pcre_default_tables[] = {" > chartables_file
print "" > chartables_file
print "/* This table is a lower casing table. */" > chartables_file
print "" > chartables_file
print " 0, 1, 2, 3, 4, 5, 6, 7," > chartables_file
print " 8, 9, 10, 11, 12, 13, 14, 15," > chartables_file
print " 16, 17, 18, 19, 20, 21, 22, 23," > chartables_file
print " 24, 25, 26, 27, 28, 29, 30, 31," > chartables_file
print " 32, 33, 34, 35, 36, 37, 38, 39," > chartables_file
print " 40, 41, 42, 43, 44, 45, 46, 47," > chartables_file
print " 48, 49, 50, 51, 52, 53, 54, 55," > chartables_file
print " 56, 57, 58, 59, 60, 61, 62, 63," > chartables_file
print " 64, 97, 98, 99,100,101,102,103," > chartables_file
print " 104,105,106,107,108,109,110,111," > chartables_file
print " 112,113,114,115,116,117,118,119," > chartables_file
print " 120,121,122, 91, 92, 93, 94, 95," > chartables_file
print " 96, 97, 98, 99,100,101,102,103," > chartables_file
print " 104,105,106,107,108,109,110,111," > chartables_file
print " 112,113,114,115,116,117,118,119," > chartables_file
print " 120,121,122,123,124,125,126,127," > chartables_file
print " 128,129,130,131,132,133,134,135," > chartables_file
print " 136,137,138,139,140,141,142,143," > chartables_file
print " 144,145,146,147,148,149,150,151," > chartables_file
print " 152,153,154,155,156,157,158,159," > chartables_file
print " 160,161,162,163,164,165,166,167," > chartables_file
print " 168,169,170,171,172,173,174,175," > chartables_file
print " 176,177,178,179,180,181,182,183," > chartables_file
print " 184,185,186,187,188,189,190,191," > chartables_file
print " 192,193,194,195,196,197,198,199," > chartables_file
print " 200,201,202,203,204,205,206,207," > chartables_file
print " 208,209,210,211,212,213,214,215," > chartables_file
print " 216,217,218,219,220,221,222,223," > chartables_file
print " 224,225,226,227,228,229,230,231," > chartables_file
print " 232,233,234,235,236,237,238,239," > chartables_file
print " 240,241,242,243,244,245,246,247," > chartables_file
print " 248,249,250,251,252,253,254,255," > chartables_file
print "" > chartables_file
print "/* This table is a case flipping table. */" > chartables_file
print "" > chartables_file
print " 0, 1, 2, 3, 4, 5, 6, 7," > chartables_file
print " 8, 9, 10, 11, 12, 13, 14, 15," > chartables_file
print " 16, 17, 18, 19, 20, 21, 22, 23," > chartables_file
print " 24, 25, 26, 27, 28, 29, 30, 31," > chartables_file
print " 32, 33, 34, 35, 36, 37, 38, 39," > chartables_file
print " 40, 41, 42, 43, 44, 45, 46, 47," > chartables_file
print " 48, 49, 50, 51, 52, 53, 54, 55," > chartables_file
print " 56, 57, 58, 59, 60, 61, 62, 63," > chartables_file
print " 64, 97, 98, 99,100,101,102,103," > chartables_file
print " 104,105,106,107,108,109,110,111," > chartables_file
print " 112,113,114,115,116,117,118,119," > chartables_file
print " 120,121,122, 91, 92, 93, 94, 95," > chartables_file
print " 96, 65, 66, 67, 68, 69, 70, 71," > chartables_file
print " 72, 73, 74, 75, 76, 77, 78, 79," > chartables_file
print " 80, 81, 82, 83, 84, 85, 86, 87," > chartables_file
print " 88, 89, 90,123,124,125,126,127," > chartables_file
print " 128,129,130,131,132,133,134,135," > chartables_file
print " 136,137,138,139,140,141,142,143," > chartables_file
print " 144,145,146,147,148,149,150,151," > chartables_file
print " 152,153,154,155,156,157,158,159," > chartables_file
print " 160,161,162,163,164,165,166,167," > chartables_file
print " 168,169,170,171,172,173,174,175," > chartables_file
print " 176,177,178,179,180,181,182,183," > chartables_file
print " 184,185,186,187,188,189,190,191," > chartables_file
print " 192,193,194,195,196,197,198,199," > chartables_file
print " 200,201,202,203,204,205,206,207," > chartables_file
print " 208,209,210,211,212,213,214,215," > chartables_file
print " 216,217,218,219,220,221,222,223," > chartables_file
print " 224,225,226,227,228,229,230,231," > chartables_file
print " 232,233,234,235,236,237,238,239," > chartables_file
print " 240,241,242,243,244,245,246,247," > chartables_file
print " 248,249,250,251,252,253,254,255," > chartables_file
print "" > chartables_file
print "/* This table contains bit maps for various character classes." > chartables_file
print "Each map is 32 bytes long and the bits run from the least" > chartables_file
print "significant end of each byte. The classes that have their own" > chartables_file
print "maps are: space, xdigit, digit, upper, lower, word, graph" > chartables_file
print "print, punct, and cntrl. Other classes are built from combinations. */" > chartables_file
print "" > chartables_file
print " 0x00,0x3e,0x00,0x00,0x01,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x03," > chartables_file
print " 0x7e,0x00,0x00,0x00,0x7e,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x03," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0xfe,0xff,0xff,0x07,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x07," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x03," > chartables_file
print " 0xfe,0xff,0xff,0x87,0xfe,0xff,0xff,0x07," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff," > chartables_file
print " 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff," > chartables_file
print " 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0x00,0x00,0x00,0x00,0xfe,0xff,0x00,0xfc," > chartables_file
print " 0x01,0x00,0x00,0xf8,0x01,0x00,0x00,0x78," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print " 0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00," > chartables_file
print "" > chartables_file
print "/* This table identifies various classes of character by individual bits:" > chartables_file
print " 0x01 white space character" > chartables_file
print " 0x02 letter" > chartables_file
print " 0x04 decimal digit" > chartables_file
print " 0x08 hexadecimal digit" > chartables_file
print " 0x10 alphanumeric or '_'" > chartables_file
print " 0x80 regular expression metacharacter or binary zero" > chartables_file
print "*/" > chartables_file
print "" > chartables_file
print " 0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 0- 7 */" > chartables_file
print " 0x00,0x01,0x01,0x01,0x01,0x01,0x00,0x00, /* 8- 15 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 16- 23 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 24- 31 */" > chartables_file
print " 0x01,0x00,0x00,0x00,0x80,0x00,0x00,0x00, /* - ' */" > chartables_file
print " 0x80,0x80,0x80,0x80,0x00,0x00,0x80,0x00, /* ( - / */" > chartables_file
print " 0x1c,0x1c,0x1c,0x1c,0x1c,0x1c,0x1c,0x1c, /* 0 - 7 */" > chartables_file
print " 0x1c,0x1c,0x00,0x00,0x00,0x00,0x00,0x80, /* 8 - ? */" > chartables_file
print " 0x00,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x12, /* @ - G */" > chartables_file
print " 0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /* H - O */" > chartables_file
print " 0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /* P - W */" > chartables_file
print " 0x12,0x12,0x12,0x80,0x00,0x00,0x80,0x10, /* X - _ */" > chartables_file
print " 0x00,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x12, /* ` - g */" > chartables_file
print " 0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /* h - o */" > chartables_file
print " 0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /* p - w */" > chartables_file
print " 0x12,0x12,0x12,0x80,0x80,0x00,0x00,0x00, /* x -127 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 128-135 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 136-143 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 144-151 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 152-159 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 160-167 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 168-175 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 176-183 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 184-191 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 192-199 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 200-207 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 208-215 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 216-223 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 224-231 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 232-239 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 240-247 */" > chartables_file
print " 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};/* 248-255 */" > chartables_file
print "" > chartables_file
print "/* End of chartables.c */" > chartables_file
}
function gen_test_char() {
print "/* this file is automatically generated by gen_test_char, do not edit */" > test_char_file
print "#define T_ESCAPE_SHELL_CMD (1)" > test_char_file
print "#define T_ESCAPE_PATH_SEGMENT (2)" > test_char_file
print "#define T_OS_ESCAPE_PATH (4)" > test_char_file
print "#define T_HTTP_TOKEN_STOP (8)" > test_char_file
print "#define T_ESCAPE_LOGITEM (16)" > test_char_file
print "#define T_ESCAPE_FORENSIC (32)" > test_char_file
print "" > test_char_file
print "static const unsigned char test_char_table[256] = {" > test_char_file
print " 32,62,62,62,62,62,62,62,62,62,63,62,62,63,62,62,62,62,62,62," > test_char_file
print " 62,62,62,62,62,62,62,62,62,62,62,62,14,0,23,6,1,39,1,1," > test_char_file
print " 9,9,1,0,8,0,0,10,0,0,0,0,0,0,0,0,0,0,40,15," > test_char_file
print " 15,8,15,15,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > test_char_file
print " 0,0,0,0,0,0,0,0,0,0,0,15,31,15,7,0,7,0,0,0," > test_char_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > test_char_file
print " 0,0,0,15,39,15,1,62,54,54,54,54,54,54,54,54,54,54,54,54," > test_char_file
print " 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54," > test_char_file
print " 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54," > test_char_file
print " 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54," > test_char_file
print " 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54," > test_char_file
print " 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54," > test_char_file
print " 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54 " > test_char_file
print "};" > test_char_file
}
function gen_uri_delims() {
print "/* this file is automatically generated by gen_uri_delims, do not edit */" > uri_delims_file
print "static const unsigned char uri_delims[256] = {" > uri_delims_file
print " T_NUL,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,T_HASH,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,T_SLASH,0,0,0,0,0,0,0,0,0,0,T_COLON,0," > uri_delims_file
print " 0,0,0,T_QUESTION,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0," > uri_delims_file
print " 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 " > uri_delims_file
print "};" > uri_delims_file
}
Re: Windows IA64 builds
Posted by Glenn Strauss <gs...@gluelogic.com>.
On Mon, Sep 13, 2004 at 12:09:20AM -0500, William A. Rowe, Jr. wrote:
> At 05:05 PM 9/12/2004, you wrote:
> >-AP_DECLARE(long) ap_get_client_block(request_rec *r, char *buffer, apr_size_t bufsiz);
> >+AP_DECLARE(apr_ssize_t) ap_get_client_block(request_rec *r, char *buffer, apr_size_t bufsiz);
> >
> >Don't know why long was used here, but it causes a warning
> >for Windows IA64 build since long is 32 bits. I'm wondering
> >however if there are any other 64 bit platforms that also have
> >32 bit longs that have ignored this warning. Hopefully not
> >and therefore this would be safe for backport to 2.0. Anyone
> >have information to the contrary?
>
> On (most/all?) unixes - sizeof(long) == sizeof(void*).
Yes, AFAIK all contemporary unices are LP32, ILP32 (most common),
or LP64 ABIs. Standard and very predictable and largely compatible
(with the exception of (long double) which is implemented by some
vendors as IEEE Quad and others as IEEE Double-Extended.)
The Open Group has a nice paper out on the subject:
http://www.opengroup.org/public/tech/aspen/lp64_wp.htm
and compares LP64 to other 64-bit models, including ILP64
and LLP64, the one which Win64 follows.
> On Win64, we have sizeof(long) < sizeof(void*). That's the
> discrepancy you are observing, and why it wasn't recognized.
The WINE dev list had this to contribute, including some GCC compiler
switches to help ease the pain:
http://www.mail-archive.com/wine-devel@winehq.com/msg14882.html
Thread begins here:
http://www.mail-archive.com/wine-devel@winehq.com/msg14810.html
Cheers,
Glenn
Re: Windows IA64 builds
Posted by "William A. Rowe, Jr." <wr...@rowe-clan.net>.
At 05:05 PM 9/12/2004, you wrote:
>-AP_DECLARE(long) ap_get_client_block(request_rec *r, char *buffer, apr_size_t bufsiz);
>+AP_DECLARE(apr_ssize_t) ap_get_client_block(request_rec *r, char *buffer, apr_size_t bufsiz);
>
>Don't know why long was used here, but it causes a warning
>for Windows IA64 build since long is 32 bits. I'm wondering
>however if there are any other 64 bit platforms that also have
>32 bit longs that have ignored this warning. Hopefully not
>and therefore this would be safe for backport to 2.0. Anyone
>have information to the contrary?
On (most/all?) unixes - sizeof(long) == sizeof(void*).
On Win64, we have sizeof(long) < sizeof(void*). That's the
discrepancy you are observing, and why it wasn't recognized.
Re: Windows IA64 builds
Posted by Allan Edwards <ak...@us.ibm.com>.
-AP_DECLARE(long) ap_get_client_block(request_rec *r, char *buffer, apr_size_t bufsiz);
+AP_DECLARE(apr_ssize_t) ap_get_client_block(request_rec *r, char *buffer, apr_size_t bufsiz);
Don't know why long was used here, but it causes a warning
for Windows IA64 build since long is 32 bits. I'm wondering
however if there are any other 64 bit platforms that also have
32 bit longs that have ignored this warning. Hopefully not
and therefore this would be safe for backport to 2.0. Anyone
have information to the contrary?
Allan