On Mon, 01 Dec 2014 16:04:28 Paulo César Pereira de Andrade wrote:
>   Actually, it was partly my fault. I was using an early patch to adapt to
> use ntl6, what is no longer required as sagemath now uses ntl6.
> Just removing that patch correct the problem. But, the patch was
> working previously, basically it was a "typedef struct someZZ someZZ;"
> and update prototypes to use the typedef.
> 
>   I could not create a small reproducer. But found it interesting that
> adding an explicit:
> +#ifdef __cplusplus
> +extern "C"
> +#endif
> int ZZ_p_to_int(const ZZ_p& x )
> to not_wrap.c would cause a compilation failure telling it was not
> compatible with
> EXTERN int ZZ_p_to_int(const ZZ_p& x)
> defined in ntl_wrap.h.
> 
> The non expanded EXTERN was weird. And apparently the issue
> happens because I am trying to build with ntl-6.2.1, as with previous
> ntl it did not happen.

We use to have a patch too but a bit different. I think non expansion
is because "EXTERN" can be actually undefined somewhere in the header.
We used to have 
--- include/ntl_wrap.h.orig     2010-06-28 16:37:05.000000000 +0000
+++ include/ntl_wrap.h  2010-10-03 08:37:12.165889079 +0000
@@ -24,6 +24,10 @@
 using namespace NTL;
 #endif
 
+#ifdef EXTERN
+#undef EXTERN
+#endif
+
 #ifdef __cplusplus
 #define EXTERN extern "C"
 #else 

for sage-clib that would cause the non expansion.

Francois

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to