You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@trafficserver.apache.org by Igor Galić <i....@brainsware.org> on 2011/06/26 18:36:30 UTC
ATS on Solaris in 32 bit mode
Hi folks,
recently I've done a little work on OpenCSW and have finally
started creating packages. Sadly even OpenCSW doesn't provide
all the libraries in 64 bit, a key requirement to compiling
TrafficServer in 64 bit - which is our hard-coded default.
I altered that default in configure.ac:
- common_opt="-mt -m64 -D__WORDSIZE=64" # FIXME: arch should be detected
+ common_opt="-mt" # -D__WORDSIZE=64" # -m64 " # FIXME: arch shouldn't need to be detected..?
And then started fixing the other issues that arose:
__i386__ is a GCCism, SunPRO needs __i386 -- same is true for
__x86_64__ vs __x86_64.
Now that all is fine and well: It compiles, at least.
But it doesn't link, see:
https://issues.apache.org/jira/browse/TS-856
This is where I'm stuck - I hope somebody can help me out.
So long,
i
--
Igor Galić
Tel: +43 (0) 664 886 22 883
Mail: i.galic@brainsware.org
URL: http://brainsware.org/
Re: ATS on Solaris in 32 bit mode
Posted by Igor Galić <i....@brainsware.org>.
----- Original Message -----
> 32 bit systems still exist? :-D
Sadly... :-/
> int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const
> unsigned char*,int,const unsigned char*,unsigned char*,int)
> ../iocore/dns/libinkdns.a(DNS.o)
>
> Find which file that exists in and run nm against the lib | c++filt
> to
> understand the type signature that is "really" has.
igalic@asd5inbld002:/buildr/mgar/pkg/trafficserver/trunk/work/build-isa-i386/trafficserver-3.0.0> for i in $( ggrep -r ink_res_mkquery *| awk '/Binary/{print $3}' ); do echo $i ; nm $i | c++filt | grep ' ink_res_mkquery(' ; done
iocore/dns/libinkdns.a
[519] | 0| 0|FUNC |GLOB |0 |UNDEF |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
iocore/dns/DNS.o
[519] | 0| 0|FUNC |GLOB |0 |UNDEF |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
lib/ts/ink_res_mkquery.o
[35] | 32| 650|FUNC |GLOB |0 |2 |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
lib/ts/.libs/libtsutil.so
[753] | 94716| 693|FUNC |GLOB |0 |12 |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
lib/ts/.libs/ink_res_mkquery.o
[35] | 52| 693|FUNC |GLOB |0 |2 |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
lib/ts/.libs/libtsutil.a
[35] | 32| 650|FUNC |GLOB |0 |2 |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
lib/ts/.libs/libtsutil.so.3.0.0
[753] | 94716| 693|FUNC |GLOB |0 |12 |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
lib/ts/.libs/libtsutil.so.3
[753] | 94716| 693|FUNC |GLOB |0 |12 |int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const unsigned char*,int,const unsigned char*,unsigned char*,int)
The files origin is lib/ts/ink_res_mkquery.cc
/*%
* Form all types of queries.
* Returns the size of the result or -1.
*/
int
ink_res_mkquery(ink_res_state statp,
int op, /*!< opcode of query */
const char *dname, /*!< domain name */
int _class, int type, /*!< _class and type of query */
const u_char *data, /*!< resource record data */
int datalen, /*!< length of data */
const u_char *newrr_in, /*!< new rr for modify or append */
u_char *buf, /*!< buffer to put query */
int buflen) /*!< size of buffer */
int_res_mkquery.o is compiled into libtsutil.(a|so)
The symbol is referenced by iocore/dns/libinkdns.a, in in DNS.cc
in a static function - but isn't found in that form.
Where are we going wrong?
> My _guess_ is that one of those is long int vs. long long int or
> something like that. Most likely a C++ type signature mismatch
> between what was built vs. what's expected.
All these signatures look exactly the same to me.
> --
> Theo Schlossnagle
>
> http://omniti.com/is/theo-schlossnagle
--
Igor Galić
Tel: +43 (0) 664 886 22 883
Mail: i.galic@brainsware.org
URL: http://brainsware.org/
Re: ATS on Solaris in 32 bit mode
Posted by Theo Schlossnagle <je...@omniti.com>.
32 bit systems still exist? :-D
int ink_res_mkquery(__ink_res_state*,int,const char*,int,int,const
unsigned char*,int,const unsigned char*,unsigned char*,int)
../iocore/dns/libinkdns.a(DNS.o)
Find which file that exists in and run nm against the lib | c++filt to
understand the type signature that is "really" has.
My _guess_ is that one of those is long int vs. long long int or
something like that. Most likely a C++ type signature mismatch
between what was built vs. what's expected.
2011/6/26 Igor Galić <i....@brainsware.org>:
> Hi folks,
>
> recently I've done a little work on OpenCSW and have finally
> started creating packages. Sadly even OpenCSW doesn't provide
> all the libraries in 64 bit, a key requirement to compiling
> TrafficServer in 64 bit - which is our hard-coded default.
>
> I altered that default in configure.ac:
>
> - common_opt="-mt -m64 -D__WORDSIZE=64" # FIXME: arch should be detected
> + common_opt="-mt" # -D__WORDSIZE=64" # -m64 " # FIXME: arch shouldn't need to be detected..?
>
> And then started fixing the other issues that arose:
>
> __i386__ is a GCCism, SunPRO needs __i386 -- same is true for
> __x86_64__ vs __x86_64.
>
> Now that all is fine and well: It compiles, at least.
> But it doesn't link, see:
> https://issues.apache.org/jira/browse/TS-856
>
> This is where I'm stuck - I hope somebody can help me out.
>
> So long,
>
> i
>
> --
> Igor Galić
>
> Tel: +43 (0) 664 886 22 883
> Mail: i.galic@brainsware.org
> URL: http://brainsware.org/
>
--
Theo Schlossnagle
http://omniti.com/is/theo-schlossnagle