1.8+ (1.9) SunOS/Soalaris install problem
John Arbash Meinel
john at arbash-meinel.com
Tue Dec 2 14:42:53 GMT 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Jari Aalto wrote:
> $ uname -a
>
> SunOS host 5.9 Generic_122300-32 sun4u sparc
>
> $ gcc --version
> gcc (GCC) 3.4.5
>
> The 1.7 installed ok, but the 1.8 and 1.9 gives following errors. Could
> someone know what is needed?
>
> Jari
...
> gcc -fno-strict-aliasing -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -I/usr/local/include/python2.5 -c bzrlib/_dirstate_helpers_c.c -o build/temp.solaris-2.9-sun4u-2.5/bzrlib/_dirstate_helpers_c.o
> In file included from bzrlib/_dirstate_helpers_c.c:31:
> bzrlib/_dirstate_helpers_c.h:8:20: stdint.h: No such file or directory
> bzrlib/_dirstate_helpers_c.c: In function `__pyx_f_19_dirstate_helpers_c_13ProcessEntryC__process_entry':
> bzrlib/_dirstate_helpers_c.c:3712: warning: '__pyx_exc_lineno' might be used uninitialized in this function
>
> Failed to build "bzrlib._dirstate_helpers_c".
> Use --allow-python-fallback to use slower python implementations instead.
>
> error: command 'gcc' failed with exit status 1
We are expecting to find 'stdint.h' because we are looking for the
"intptr_t" type.
Do you know where it is supposed to be found on Sun OS?
At the moment we have this code block:
#ifndef _DIRSTATE_HELPERS_C_H
#define _DIRSTATE_HELPERS_C_H
/* for intptr_t */
#ifdef _MSC_VER
#include <io.h>
#else
#include <stdint.h>
#endif
#endif
We can certainly extend that for Sun, even if it is only "ifdef SUN:
typedef int intptr_t
"
We use that as part of this code:
cdef int _is_aligned(void *ptr):
"""Is this pointer aligned to an integer size offset?
:return: 1 if this pointer is aligned, 0 otherwise.
"""
return ((<intptr_t>ptr) & ((sizeof(int))-1)) == 0
I believe "intptr_t" is an integer large enough to hold a pointer, and
is necessary because some things really don't like it when you do
integer math on a "void *".
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkk1SW0ACgkQJdeBCYSNAAMCEACfSmF6FVh2FEdJPgNVWfCIcUkj
D0MAn0RUvcKPhUxfkyy48sh5tbVjhPA8
=mcho
-----END PGP SIGNATURE-----
More information about the bazaar
mailing list