fi
fi
-AC_LANG_RESTORE
+dnl AC_LANG_RESTORE
AC_MSG_RESULT(for omniORBpy: $omniORBpy_ok)
AC_MSG_RESULT(for omniORB: $omniORB_ok)
# Save cache
AC_CACHE_SAVE
+dnl AC_LANG_CPLUSPLUS
+
+CXXFLAGS_old=$CXXFLAGS
+CXXFLAGS="$CXXFLAGS $OMNIORB_CXXFLAGS $OMNIORB_INCLUDES"
+LIBS_old=$LIBS
+LIBS="$LIBS $OMNIORB_LDFLAGS -lomnithread"
+AC_MSG_CHECKING(whether we have double and CORBA::Double compatibility)
+AC_TRY_RUN(
+#include <stdlib.h>
+#include <CORBA.h>
+int main ()
+{
+ CORBA::Double *a=new CORBA::Double(2.5);
+ double c=2.5;
+ double *b;
+ b=(double *)a;
+
+ if( (c==*b) && (sizeof(double)==sizeof(CORBA::Double)) )
+ exit(0);
+ else
+ exit(1);
+}
+,DOUBLECOMP="yes",DOUBLECOMP="no")
+if test "$DOUBLECOMP" = yes; then
+ OMNIORB_CXXFLAGS="$OMNIORB_CXXFLAGS -DCOMP_CORBA_DOUBLE"
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_RESULT(no)
+fi
+AC_MSG_CHECKING(whether we have int and CORBA::Long compatibility)
+AC_TRY_RUN(
+#include <stdlib.h>
+#include <CORBA.h>
+int main ()
+{
+ CORBA::Long *a=new CORBA::Long(2);
+ int c=2;
+ int *b;
+ b=(int *)a;
+
+ if( (c==*b) && (sizeof(int)==sizeof(CORBA::Long)) )
+ exit(0);
+ else
+ exit(1);
+}
+,LONGCOMP="yes",LONGCOMP="no")
+if test "$LONGCOMP" = yes; then
+ OMNIORB_CXXFLAGS="$OMNIORB_CXXFLAGS -DCOMP_CORBA_LONG"
+ AC_MSG_RESULT(yes)
+else
+ AC_MSG_RESULT(no)
+fi
+CXXFLAGS=$CXXFLAGS_old
+LIBS=$LIBS_old
+
+AC_LANG_RESTORE
+
+AC_SUBST(OMNIORB_CXXFLAGS)
+
])dnl
dnl