ngnix and Linux on UltrasparcII

Andrey Chernomyrdin andrey.ngnix-ru at sats.spb.ru
Mon Nov 21 14:10:51 MSK 2005


Igor Sysoev wrote:

> On Mon, 21 Nov 2005, Andrey Chernomyrdin wrote:
>
>> Igor Sysoev wrote:
>>
>>> On Fri, 18 Nov 2005, Andrey Chernomyrdin wrote:
>>>
>>>> Хотелось-бу узнать - кто-нибудь пытался скомпилировать ngnix под 
>>>> Linux-ом который работает на UltraSparc.
>>>> Причем хотелось-бы его собрать в 32-битном режиме, так как полезные 
>>>> библиотеки собраны в 32-битном режиме.
>>>>
>>>> Дистрибутив - debian.
>>>
>>>
>>>
>>> С большой степенью верятности должно собраться.
>>> Возможно, нужно будет указать
>>> ./configure ... --with-cc-opt="-m32" --with-ld-opt="-m32"
>>> чтобы gcc собирал 32-битный код.
>>
>>
>> Эээ... что-то не совсем получилось:
>>
>> gcc -c -Wall -g -O2 -m32 -I src/core -I src/event -I 
>> src/event/modules -I src/os/unix -I objs \
>>   -o objs/src/core/ngx_times.o \
>>   src/core/ngx_times.c
>> /tmp/ccZZ915Y.s: Assembler messages:
>> /tmp/ccZZ915Y.s:377: Error: Architecture mismatch on "casa".
>> /tmp/ccZZ915Y.s:377:  (Requires v9|v9a|v9b; requested architecture is 
>> sparclite.)
>> /tmp/ccZZ915Y.s:585: Error: Architecture mismatch on "membar".
>> /tmp/ccZZ915Y.s:585:  (Requires v9|v9a|v9b; requested architecture is 
>> sparclite.)
>> make[2]: *** [objs/src/core/ngx_times.o] Error 1
>> make[2]: Leaving directory `/home/andrey/work/debian/nginx/nginx-0.3.11'
>>
>> Там просто асемблерная вставка есть, собственно из-за этого и все 
>> проблемы.
>
>
> Тогда нужно что-то вроде
> --with-cc-opt="-m32 -mcpu=ultrasparc"

Ок, собрался, вот только проблемы с запуском:
# ./nginx.debug
Bus error (core dumped)

# gdb -c core ./nginx.debug
GNU gdb 6.3-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain 
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "sparc-linux"...Using host libthread_db 
library "/lib/libthread_db.so.1".

Core was generated by `/usr/sbin/nginx.debug'.
Program terminated with signal 10, Bus error.
Reading symbols from /lib/libcrypt.so.1...done.
Loaded symbols for /lib/libcrypt.so.1
Reading symbols from /usr/lib/libpcre.so.3...done.
Loaded symbols for /usr/lib/libpcre.so.3
Reading symbols from /usr/lib/libz.so.1...done.
Loaded symbols for /usr/lib/libz.so.1
Reading symbols from /lib/libc.so.6...done.
Loaded symbols for /lib/libc.so.6
Reading symbols from /lib/ld-linux.so.2...done.
Loaded symbols for /lib/ld-linux.so.2
#0  ngx_conf_parse (cf=0xefd8b99c, filename=0x76d1c) at 
src/core/ngx_conf_file.c:105
105            cf->conf_file->file.offset = 0;

# _

Так что вопрос остался.

>
> Игорь Сысоев
> http://sysoev.ru
>


-- 
Andrey Chernomyrdin



More information about the nginx-ru mailing list