ID:               22077
 Updated by:       [EMAIL PROTECTED]
 Reported By:      slash at peereboom dot us
-Status:           Open
+Status:           Feedback
 Bug Type:         Compile Failure
 Operating System: OpenBSD 3.2 sparc64
 PHP Version:      4.3.0
 New Comment:

Maybe the alterations are the problem...


Previous Comments:
------------------------------------------------------------------------

[2003-02-25 13:43:31] slash at peereboom dot us

That what ships with it. Don't pay too much attention to it though; the
compiler is higly altered by the OpenBSD developers. It is as good as
any other gcc sparc64 compiler (that's the problem!)

------------------------------------------------------------------------

[2003-02-25 04:33:12] [EMAIL PROTECTED]

>> gcc version 2.95.3 20010125 (prerelease)

prerelease? Is there any better available for that OS?




------------------------------------------------------------------------

[2003-02-11 19:22:56] slash at peereboom dot us

[EMAIL PROTECTED] root]# gcc -v
Reading specs from
/usr/lib/gcc-lib/sparc64-unknown-openbsd3.2/2.95.3/specs
gcc version 2.95.3 20010125 (prerelease)

------------------------------------------------------------------------

[2003-02-11 17:14:25] [EMAIL PROTECTED]

Looks like a compiler bug to me since the very same code compiles fine
with other compilers. What compiler are you using?

------------------------------------------------------------------------

[2003-02-05 11:42:01] slash at peereboom dot us

Fix: use -O0 on sha1.c during compilation.

Error:
I was trying to compile php-4.3.0 on an Ultra-5 & an Ultra-10 (dmesg at
the
bottom). Both boxes run OpenBSD 3.2-sparc64. What happens is that the
compiler hangs on sha1.c. It seems as if there are way too many macro's
in
there. I removed the macro's and the file did compile. The macro's that
hang
the compiler are (php-4.3.0/ext/standard/sha1.c line 144):

/* FF, GG, HH, and II transformations for rounds 1, 2, 3, and 4.
 */
#define FF(a, b, c, d, e, w) { \
 (e) += F ((b), (c), (d)) + (w) + (php_uint32)(0x5A827999); \
 (e) += ROTATE_LEFT ((a), 5); \
 (b) = ROTATE_LEFT((b), 30); \
  }
#define GG(a, b, c, d, e, w) { \
 (e) += G ((b), (c), (d)) + (w) + (php_uint32)(0x6ED9EBA1); \
 (e) += ROTATE_LEFT ((a), 5); \
 (b) = ROTATE_LEFT((b), 30); \
  }
#define HH(a, b, c, d, e, w) { \
 (e) += H ((b), (c), (d)) + (w) + (php_uint32)(0x8F1BBCDC); \
 (e) += ROTATE_LEFT ((a), 5); \
 (b) = ROTATE_LEFT((b), 30); \
  }
#define II(a, b, c, d, e, w) { \
 (e) += I ((b), (c), (d)) + (w) + (php_uint32)(0xCA62C1D6); \
 (e) += ROTATE_LEFT ((a), 5); \
 (b) = ROTATE_LEFT((b), 30); \
  }

Note all the embedded macro's (F, G, H, I, ROTATE_LEFT). Anyway, has
anyone
run into this and figured out a fix?
I will try to compile the same code on Intel and see what happens.

I searched the web, mail archives and the php archives.

More details:
PHP requires quite a bit of lib's so I installed the following from
the
ports:
curl-7.9.8.tgz
gdbm-1.8.0.tgz
libiconv-1.8.tgz
pkgconfig-0.12.0.tgz
libxml-2.4.24.tgz
jpeg-6b.tgz
png-1.2.4.tgz
gettext-0.10.40.tgz
gmake-3.79.1.tgz
expat-1.95.4.tgz
sablotron-0.96.tgz
libxslt-1.0.20.tgz

I compiled the following ones from source:
freetype2.1.3
imap-wu-2002 (coppied the headers manually to /usr/local/include)
libmcal-0.6 (coppied the headers manually to /usr/local/include)

I configured PHP as follows:
./configure --prefix=/usr/local/php --with-openssl --with-zlib
--enable-bcma
th --enable-calendar --with-curl --with-gdbm --with-dom --with-gd
--with-jpe
g-dir --with-png-dir=/usr/local --with-freetype-dir
--enable-gd-native-ttf -
-with-imap --with-mcal --with-mysql=/usr/local/mysql --enable-xslt
--with-ex
pat-dir=/usr/local --with-iconv=/usr/local --with-dom-xslt
--with-xslt-sablo
t=/usr/local --with-expat-dir=/usr/local --with-iconv-dir=/usr/local

Top after running overnight:
load averages:  1.15,  1.17,  1.16
09:41:52
15 processes:  2 running, 13 idle
CPU states: 98.8% user,  0.0% nice,  1.2% system,  0.0% interrupt, 
0.0%
idle
Memory: Real: 15M/38M act/tot  Free: 207M  Swap: 3896K/256M used/tot
 Command not understood
  PID USERNAME PRI NICE  SIZE   RES STATE WAIT     TIME    CPU COMMAND
32291 root      64    0 8312K 8696K run   -      730:13 98.39% cc1
15610 root      28    0  240K 1520K run   -        0:00  0.29% top
32651 root       2    0  792K  896K sleep select   0:07  0.00% sshd
23396 root       2    0  832K  864K idle  select   0:11  0.00% sshd
24835 root       2    0 1760K 1912K sleep select   0:00  0.00%
sendmail
 2362 root       2    0  736K    0K idle  select   0:02  0.00% sshd
18904 root      10    0 1992K  672K idle  wait     0:01  0.00% bash
 2455 root      10    0 1992K  816K sleep wait     0:01  0.00% bash
 1758 root       2    0  328K  688K idle  select   0:00  0.00% cron
17119 root       2    0  176K  640K sleep select   0:00  0.00% syslogd
17210 root       2    0  144K  624K idle  select   0:00  0.00% inetd
    1 root      10    0  656K  104K idle  wait     0:00  0.00% init
19709 root       2    0  800K  424K idle  poll     0:00  0.00%
dhclient
31498 root      10    0  264K 1088K idle  wait     0:00  0.00% gcc
 1579 root       3    0   72K    0K idle  ttyin    0:00  0.00% getty

Dmesg of ultra-5
Copyright (c) 1982, 1986, 1989, 1991, 1993
        The Regents of the University of California.  All rights
reserved.
Copyright (c) 1995-2002 OpenBSD. All rights reserved.
http://www.OpenBSD.org

OpenBSD 3.2 (GENERIC) #8: Thu Oct  3 20:00:17 MDT 2002
   
[EMAIL PROTECTED]:/usr/src/sys/arch/sparc64/compile/GENERIC
total memory = 268435456
avail memory = 240558080
using 1638 buffers containing 13418496 of memory
bootpath: /[EMAIL PROTECTED],0/[EMAIL PROTECTED],1/[EMAIL PROTECTED],0/[EMAIL 
PROTECTED],0
mainbus0 (root): SUNW,Ultra-5_10
cpu0 at mainbus0: SUNW,UltraSPARC-IIi @ 333 MHz, version 0 FPU
cpu0: physical 32K instruction (32 b/l), 16K data (32 b/l), 2048K
external
(64 b/l)
psycho0 at mainbus0 addr 0xfffc4000
SUNW,sabre: impl 0, version 0: ign 7c0 bus range 0 to 2; PCI bus 0
IOTDB: f66000 to fe6000
pci0 at psycho0
ppb0 at pci0 dev 1 function 1 "Sun Simba PCI-PCI" rev 0x13
pci1 at ppb0 bus 1
ebus0 at pci1 dev 1 function 0 "Sun PCIO Ebus2" rev 0x01
auxio0 at ebus0 addr 726000-726003, 728000-728003, 72a000-72a003,
72c000-72c003, 72f000-72f003
power at ebus0 addr 724000-724003 ipl 37 not configured
SUNW,pll at ebus0 addr 504000-504002 not configured
sab0 at ebus0 addr 400000-40007f ipl 43: rev 3.2
sabtty0 at sab0 port 0: console i/o
sabtty1 at sab0 port 1
comkbd0 at ebus0 addr 3083f8-3083ff ipl 41
wskbd0 at comkbd0
com0 at ebus0 addr 3062f8-3062ff ipl 42, mouse: ns16550a, 16 byte fifo
lpt0 at ebus0 addr 3043bc-3043cb, 30015c-30015d, 700000-70000f ipl 34:
polled
fdthree at ebus0 addr 3023f0-3023f7, 706000-70600f, 720000-720003 ipl
39 not
configured
clock0 at ebus0 addr 0-1fff: mk48t59: hostid 80a73606
flashprom at ebus0 addr 0-fffff not configured
audioce0 at ebus0 addr 200000-2000ff, 702000-70200f, 704000-70400f,
722000-722003 ipl 35 ipl 36: nvaddrs 0
audio0 at audioce0
hme0 at pci1 dev 1 function 1 "Sun HME" rev 0x01: address
08:00:20:a7:36:06
nsphy0 at hme0 phy 1: DP83840 10/100 media interface, rev. 1
hme0: using ivec 3021 for interrupt
vgafb0 at pci1 dev 2 function 0 "ATI Mach64 GP" rev 0x5c
wsdisplay0 at vgafb0
wsdisplay0: screen 0 added (sun, sun emulation)
pciide0 at pci1 dev 3 function 0 "CMD Technology PCI0646" rev 0x03:
DMA,
channel 0 configured to native-PCI, channel 1 configured to native-PCI
pciide0: using ivec 1820 for native-PCI interrupt
wd0 at pciide0 channel 0 drive 0: <ST39140A>
wd0: 16-sector PIO, LBA, 8693MB, 17662 cyl, 16 head, 63 sec, 17803440
sectors
wd0(pciide0:0:0): using PIO mode 4, DMA mode 2
atapiscsi0 at pciide0 channel 1 drive 0
scsibus0 at atapiscsi0: 2 targets
cd0 at scsibus0 targ 0 lun 0: <LG, CD-ROM CRD-8322B, 1.03> SCSI0
5/cdrom
removable
cd0(pciide0:1:0): using PIO mode 4, DMA mode 2
ppb1 at pci0 dev 1 function 0 "Sun Simba PCI-PCI" rev 0x13
pci2 at ppb1 bus 2
gem0 at pci2 dev 1 function 0 "Sun GEM" rev 0x01
gem0: address 08:00:20:9e:a6:bb
gem0: using ivec 3010 for interrupt
pcons at mainbus0 not configured
No counter-timer -- using %tick at 333MHz as system clock.
root on wd0a
rootdev=0xc00 rrootdev=0x1a00 rawdev=0x1a02

------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=22077&edit=1

Reply via email to