xnd 0.2.0dev6 → 0.2.0dev7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/Rakefile +1 -1
- data/ext/ruby_xnd/GPATH +0 -0
- data/ext/ruby_xnd/GRTAGS +0 -0
- data/ext/ruby_xnd/GTAGS +0 -0
- data/ext/ruby_xnd/extconf.rb +8 -5
- data/ext/ruby_xnd/gc_guard.c +53 -2
- data/ext/ruby_xnd/gc_guard.h +8 -2
- data/ext/ruby_xnd/include/overflow.h +147 -0
- data/ext/ruby_xnd/include/ruby_xnd.h +62 -0
- data/ext/ruby_xnd/include/xnd.h +590 -0
- data/ext/ruby_xnd/lib/libxnd.a +0 -0
- data/ext/ruby_xnd/lib/libxnd.so +1 -0
- data/ext/ruby_xnd/lib/libxnd.so.0 +1 -0
- data/ext/ruby_xnd/lib/libxnd.so.0.2.0dev3 +0 -0
- data/ext/ruby_xnd/ruby_xnd.c +556 -47
- data/ext/ruby_xnd/ruby_xnd.h +2 -1
- data/ext/ruby_xnd/xnd/Makefile +80 -0
- data/ext/ruby_xnd/xnd/config.h +26 -0
- data/ext/ruby_xnd/xnd/config.h.in +3 -0
- data/ext/ruby_xnd/xnd/config.log +421 -0
- data/ext/ruby_xnd/xnd/config.status +1023 -0
- data/ext/ruby_xnd/xnd/configure +376 -8
- data/ext/ruby_xnd/xnd/configure.ac +48 -7
- data/ext/ruby_xnd/xnd/doc/xnd/index.rst +3 -1
- data/ext/ruby_xnd/xnd/doc/xnd/{types.rst → xnd.rst} +3 -18
- data/ext/ruby_xnd/xnd/libxnd/Makefile +142 -0
- data/ext/ruby_xnd/xnd/libxnd/Makefile.in +43 -3
- data/ext/ruby_xnd/xnd/libxnd/Makefile.vc +19 -3
- data/ext/ruby_xnd/xnd/libxnd/bitmaps.c +42 -3
- data/ext/ruby_xnd/xnd/libxnd/bitmaps.o +0 -0
- data/ext/ruby_xnd/xnd/libxnd/bounds.c +366 -0
- data/ext/ruby_xnd/xnd/libxnd/bounds.o +0 -0
- data/ext/ruby_xnd/xnd/libxnd/contrib.h +98 -0
- data/ext/ruby_xnd/xnd/libxnd/contrib/bfloat16.h +213 -0
- data/ext/ruby_xnd/xnd/libxnd/copy.c +155 -4
- data/ext/ruby_xnd/xnd/libxnd/copy.o +0 -0
- data/ext/ruby_xnd/xnd/libxnd/cuda/cuda_memory.cu +121 -0
- data/ext/ruby_xnd/xnd/libxnd/cuda/cuda_memory.h +58 -0
- data/ext/ruby_xnd/xnd/libxnd/equal.c +195 -7
- data/ext/ruby_xnd/xnd/libxnd/equal.o +0 -0
- data/ext/ruby_xnd/xnd/libxnd/inline.h +32 -0
- data/ext/ruby_xnd/xnd/libxnd/libxnd.a +0 -0
- data/ext/ruby_xnd/xnd/libxnd/libxnd.so +1 -0
- data/ext/ruby_xnd/xnd/libxnd/libxnd.so.0 +1 -0
- data/ext/ruby_xnd/xnd/libxnd/libxnd.so.0.2.0dev3 +0 -0
- data/ext/ruby_xnd/xnd/libxnd/shape.c +207 -0
- data/ext/ruby_xnd/xnd/libxnd/shape.o +0 -0
- data/ext/ruby_xnd/xnd/libxnd/split.c +2 -2
- data/ext/ruby_xnd/xnd/libxnd/split.o +0 -0
- data/ext/ruby_xnd/xnd/libxnd/tests/Makefile +39 -0
- data/ext/ruby_xnd/xnd/libxnd/xnd.c +613 -91
- data/ext/ruby_xnd/xnd/libxnd/xnd.h +145 -4
- data/ext/ruby_xnd/xnd/libxnd/xnd.o +0 -0
- data/ext/ruby_xnd/xnd/python/test_xnd.py +1125 -50
- data/ext/ruby_xnd/xnd/python/xnd/__init__.py +609 -124
- data/ext/ruby_xnd/xnd/python/xnd/_version.py +1 -0
- data/ext/ruby_xnd/xnd/python/xnd/_xnd.c +1652 -101
- data/ext/ruby_xnd/xnd/python/xnd/libxnd.a +0 -0
- data/ext/ruby_xnd/xnd/python/xnd/libxnd.so +1 -0
- data/ext/ruby_xnd/xnd/python/xnd/libxnd.so.0 +1 -0
- data/ext/ruby_xnd/xnd/python/xnd/libxnd.so.0.2.0dev3 +0 -0
- data/ext/ruby_xnd/xnd/python/xnd/pyxnd.h +1 -1
- data/ext/ruby_xnd/xnd/python/xnd/util.h +25 -0
- data/ext/ruby_xnd/xnd/python/xnd/xnd.h +590 -0
- data/ext/ruby_xnd/xnd/python/xnd_randvalue.py +106 -6
- data/ext/ruby_xnd/xnd/python/xnd_support.py +4 -0
- data/ext/ruby_xnd/xnd/setup.py +46 -4
- data/lib/ruby_xnd.so +0 -0
- data/lib/xnd.rb +39 -3
- data/lib/xnd/version.rb +2 -2
- data/xnd.gemspec +2 -1
- metadata +58 -5
data/ext/ruby_xnd/xnd/configure
CHANGED
@@ -588,6 +588,7 @@ PACKAGE_URL='https://github.com/plures/'
|
|
588
588
|
ac_subst_vars='LTLIBOBJS
|
589
589
|
LIBOBJS
|
590
590
|
CONFIGURE_LDFLAGS
|
591
|
+
CONFIGURE_CXXFLAGS
|
591
592
|
CONFIGURE_CFLAGS
|
592
593
|
XND_OPT
|
593
594
|
XND_WARN
|
@@ -597,6 +598,8 @@ CONFIGURE_LIBS_TEST
|
|
597
598
|
CONFIGURE_LIBS
|
598
599
|
CONFIGURE_INCLUDES_TEST
|
599
600
|
CONFIGURE_INCLUDES
|
601
|
+
CONFIGURE_CUDA_CXXFLAGS
|
602
|
+
CUDA_CXX
|
600
603
|
INSTALL
|
601
604
|
INSTALL_DATA
|
602
605
|
INSTALL_SCRIPT
|
@@ -606,6 +609,9 @@ GREP
|
|
606
609
|
CPP
|
607
610
|
RANLIB
|
608
611
|
AR
|
612
|
+
ac_ct_CXX
|
613
|
+
CXXFLAGS
|
614
|
+
CXX
|
609
615
|
OBJEXT
|
610
616
|
EXEEXT
|
611
617
|
ac_ct_CC
|
@@ -645,6 +651,7 @@ infodir
|
|
645
651
|
docdir
|
646
652
|
oldincludedir
|
647
653
|
includedir
|
654
|
+
runstatedir
|
648
655
|
localstatedir
|
649
656
|
sharedstatedir
|
650
657
|
sysconfdir
|
@@ -679,6 +686,9 @@ CFLAGS
|
|
679
686
|
LDFLAGS
|
680
687
|
LIBS
|
681
688
|
CPPFLAGS
|
689
|
+
CXX
|
690
|
+
CXXFLAGS
|
691
|
+
CCC
|
682
692
|
CPP'
|
683
693
|
|
684
694
|
|
@@ -718,6 +728,7 @@ datadir='${datarootdir}'
|
|
718
728
|
sysconfdir='${prefix}/etc'
|
719
729
|
sharedstatedir='${prefix}/com'
|
720
730
|
localstatedir='${prefix}/var'
|
731
|
+
runstatedir='${localstatedir}/run'
|
721
732
|
includedir='${prefix}/include'
|
722
733
|
oldincludedir='/usr/include'
|
723
734
|
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
|
@@ -970,6 +981,15 @@ do
|
|
970
981
|
| -silent | --silent | --silen | --sile | --sil)
|
971
982
|
silent=yes ;;
|
972
983
|
|
984
|
+
-runstatedir | --runstatedir | --runstatedi | --runstated \
|
985
|
+
| --runstate | --runstat | --runsta | --runst | --runs \
|
986
|
+
| --run | --ru | --r)
|
987
|
+
ac_prev=runstatedir ;;
|
988
|
+
-runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
|
989
|
+
| --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
|
990
|
+
| --run=* | --ru=* | --r=*)
|
991
|
+
runstatedir=$ac_optarg ;;
|
992
|
+
|
973
993
|
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
|
974
994
|
ac_prev=sbindir ;;
|
975
995
|
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
|
@@ -1107,7 +1127,7 @@ fi
|
|
1107
1127
|
for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
|
1108
1128
|
datadir sysconfdir sharedstatedir localstatedir includedir \
|
1109
1129
|
oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
|
1110
|
-
libdir localedir mandir
|
1130
|
+
libdir localedir mandir runstatedir
|
1111
1131
|
do
|
1112
1132
|
eval ac_val=\$$ac_var
|
1113
1133
|
# Remove trailing slashes.
|
@@ -1260,6 +1280,7 @@ Fine tuning of the installation directories:
|
|
1260
1280
|
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
|
1261
1281
|
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
|
1262
1282
|
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
|
1283
|
+
--runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
|
1263
1284
|
--libdir=DIR object code libraries [EPREFIX/lib]
|
1264
1285
|
--includedir=DIR C header files [PREFIX/include]
|
1265
1286
|
--oldincludedir=DIR C header files for non-gcc [/usr/include]
|
@@ -1306,6 +1327,8 @@ Some influential environment variables:
|
|
1306
1327
|
LIBS libraries to pass to the linker, e.g. -l<library>
|
1307
1328
|
CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
|
1308
1329
|
you have headers in a nonstandard directory <include dir>
|
1330
|
+
CXX C++ compiler command
|
1331
|
+
CXXFLAGS C++ compiler flags
|
1309
1332
|
CPP C preprocessor
|
1310
1333
|
|
1311
1334
|
Use these variables to override the choices made by `configure' or to help
|
@@ -1427,6 +1450,44 @@ fi
|
|
1427
1450
|
|
1428
1451
|
} # ac_fn_c_try_compile
|
1429
1452
|
|
1453
|
+
# ac_fn_cxx_try_compile LINENO
|
1454
|
+
# ----------------------------
|
1455
|
+
# Try to compile conftest.$ac_ext, and return whether this succeeded.
|
1456
|
+
ac_fn_cxx_try_compile ()
|
1457
|
+
{
|
1458
|
+
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
|
1459
|
+
rm -f conftest.$ac_objext
|
1460
|
+
if { { ac_try="$ac_compile"
|
1461
|
+
case "(($ac_try" in
|
1462
|
+
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
|
1463
|
+
*) ac_try_echo=$ac_try;;
|
1464
|
+
esac
|
1465
|
+
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
|
1466
|
+
$as_echo "$ac_try_echo"; } >&5
|
1467
|
+
(eval "$ac_compile") 2>conftest.err
|
1468
|
+
ac_status=$?
|
1469
|
+
if test -s conftest.err; then
|
1470
|
+
grep -v '^ *+' conftest.err >conftest.er1
|
1471
|
+
cat conftest.er1 >&5
|
1472
|
+
mv -f conftest.er1 conftest.err
|
1473
|
+
fi
|
1474
|
+
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
1475
|
+
test $ac_status = 0; } && {
|
1476
|
+
test -z "$ac_cxx_werror_flag" ||
|
1477
|
+
test ! -s conftest.err
|
1478
|
+
} && test -s conftest.$ac_objext; then :
|
1479
|
+
ac_retval=0
|
1480
|
+
else
|
1481
|
+
$as_echo "$as_me: failed program was:" >&5
|
1482
|
+
sed 's/^/| /' conftest.$ac_ext >&5
|
1483
|
+
|
1484
|
+
ac_retval=1
|
1485
|
+
fi
|
1486
|
+
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
|
1487
|
+
as_fn_set_status $ac_retval
|
1488
|
+
|
1489
|
+
} # ac_fn_cxx_try_compile
|
1490
|
+
|
1430
1491
|
# ac_fn_c_try_cpp LINENO
|
1431
1492
|
# ----------------------
|
1432
1493
|
# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
|
@@ -2005,7 +2066,8 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
|
|
2005
2066
|
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
|
2006
2067
|
ac_compiler_gnu=$ac_cv_c_compiler_gnu
|
2007
2068
|
|
2008
|
-
saved_cflags
|
2069
|
+
saved_cflags="$CFLAGS"
|
2070
|
+
saved_cxxflags="$CXXFLAGS"
|
2009
2071
|
ac_ext=c
|
2010
2072
|
ac_cpp='$CPP $CPPFLAGS'
|
2011
2073
|
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
|
@@ -2795,7 +2857,265 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
|
|
2795
2857
|
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
|
2796
2858
|
ac_compiler_gnu=$ac_cv_c_compiler_gnu
|
2797
2859
|
|
2798
|
-
|
2860
|
+
ac_ext=cpp
|
2861
|
+
ac_cpp='$CXXCPP $CPPFLAGS'
|
2862
|
+
ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
|
2863
|
+
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
|
2864
|
+
ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
|
2865
|
+
if test -z "$CXX"; then
|
2866
|
+
if test -n "$CCC"; then
|
2867
|
+
CXX=$CCC
|
2868
|
+
else
|
2869
|
+
if test -n "$ac_tool_prefix"; then
|
2870
|
+
for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
|
2871
|
+
do
|
2872
|
+
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
|
2873
|
+
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
|
2874
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
2875
|
+
$as_echo_n "checking for $ac_word... " >&6; }
|
2876
|
+
if ${ac_cv_prog_CXX+:} false; then :
|
2877
|
+
$as_echo_n "(cached) " >&6
|
2878
|
+
else
|
2879
|
+
if test -n "$CXX"; then
|
2880
|
+
ac_cv_prog_CXX="$CXX" # Let the user override the test.
|
2881
|
+
else
|
2882
|
+
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
2883
|
+
for as_dir in $PATH
|
2884
|
+
do
|
2885
|
+
IFS=$as_save_IFS
|
2886
|
+
test -z "$as_dir" && as_dir=.
|
2887
|
+
for ac_exec_ext in '' $ac_executable_extensions; do
|
2888
|
+
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
2889
|
+
ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
|
2890
|
+
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
2891
|
+
break 2
|
2892
|
+
fi
|
2893
|
+
done
|
2894
|
+
done
|
2895
|
+
IFS=$as_save_IFS
|
2896
|
+
|
2897
|
+
fi
|
2898
|
+
fi
|
2899
|
+
CXX=$ac_cv_prog_CXX
|
2900
|
+
if test -n "$CXX"; then
|
2901
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
|
2902
|
+
$as_echo "$CXX" >&6; }
|
2903
|
+
else
|
2904
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
2905
|
+
$as_echo "no" >&6; }
|
2906
|
+
fi
|
2907
|
+
|
2908
|
+
|
2909
|
+
test -n "$CXX" && break
|
2910
|
+
done
|
2911
|
+
fi
|
2912
|
+
if test -z "$CXX"; then
|
2913
|
+
ac_ct_CXX=$CXX
|
2914
|
+
for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
|
2915
|
+
do
|
2916
|
+
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
2917
|
+
set dummy $ac_prog; ac_word=$2
|
2918
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
2919
|
+
$as_echo_n "checking for $ac_word... " >&6; }
|
2920
|
+
if ${ac_cv_prog_ac_ct_CXX+:} false; then :
|
2921
|
+
$as_echo_n "(cached) " >&6
|
2922
|
+
else
|
2923
|
+
if test -n "$ac_ct_CXX"; then
|
2924
|
+
ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
|
2925
|
+
else
|
2926
|
+
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
2927
|
+
for as_dir in $PATH
|
2928
|
+
do
|
2929
|
+
IFS=$as_save_IFS
|
2930
|
+
test -z "$as_dir" && as_dir=.
|
2931
|
+
for ac_exec_ext in '' $ac_executable_extensions; do
|
2932
|
+
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
2933
|
+
ac_cv_prog_ac_ct_CXX="$ac_prog"
|
2934
|
+
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
2935
|
+
break 2
|
2936
|
+
fi
|
2937
|
+
done
|
2938
|
+
done
|
2939
|
+
IFS=$as_save_IFS
|
2940
|
+
|
2941
|
+
fi
|
2942
|
+
fi
|
2943
|
+
ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
|
2944
|
+
if test -n "$ac_ct_CXX"; then
|
2945
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
|
2946
|
+
$as_echo "$ac_ct_CXX" >&6; }
|
2947
|
+
else
|
2948
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
2949
|
+
$as_echo "no" >&6; }
|
2950
|
+
fi
|
2951
|
+
|
2952
|
+
|
2953
|
+
test -n "$ac_ct_CXX" && break
|
2954
|
+
done
|
2955
|
+
|
2956
|
+
if test "x$ac_ct_CXX" = x; then
|
2957
|
+
CXX="g++"
|
2958
|
+
else
|
2959
|
+
case $cross_compiling:$ac_tool_warned in
|
2960
|
+
yes:)
|
2961
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
|
2962
|
+
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
|
2963
|
+
ac_tool_warned=yes ;;
|
2964
|
+
esac
|
2965
|
+
CXX=$ac_ct_CXX
|
2966
|
+
fi
|
2967
|
+
fi
|
2968
|
+
|
2969
|
+
fi
|
2970
|
+
fi
|
2971
|
+
# Provide some information about the compiler.
|
2972
|
+
$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
|
2973
|
+
set X $ac_compile
|
2974
|
+
ac_compiler=$2
|
2975
|
+
for ac_option in --version -v -V -qversion; do
|
2976
|
+
{ { ac_try="$ac_compiler $ac_option >&5"
|
2977
|
+
case "(($ac_try" in
|
2978
|
+
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
|
2979
|
+
*) ac_try_echo=$ac_try;;
|
2980
|
+
esac
|
2981
|
+
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
|
2982
|
+
$as_echo "$ac_try_echo"; } >&5
|
2983
|
+
(eval "$ac_compiler $ac_option >&5") 2>conftest.err
|
2984
|
+
ac_status=$?
|
2985
|
+
if test -s conftest.err; then
|
2986
|
+
sed '10a\
|
2987
|
+
... rest of stderr output deleted ...
|
2988
|
+
10q' conftest.err >conftest.er1
|
2989
|
+
cat conftest.er1 >&5
|
2990
|
+
fi
|
2991
|
+
rm -f conftest.er1 conftest.err
|
2992
|
+
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
2993
|
+
test $ac_status = 0; }
|
2994
|
+
done
|
2995
|
+
|
2996
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
|
2997
|
+
$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
|
2998
|
+
if ${ac_cv_cxx_compiler_gnu+:} false; then :
|
2999
|
+
$as_echo_n "(cached) " >&6
|
3000
|
+
else
|
3001
|
+
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
3002
|
+
/* end confdefs.h. */
|
3003
|
+
|
3004
|
+
int
|
3005
|
+
main ()
|
3006
|
+
{
|
3007
|
+
#ifndef __GNUC__
|
3008
|
+
choke me
|
3009
|
+
#endif
|
3010
|
+
|
3011
|
+
;
|
3012
|
+
return 0;
|
3013
|
+
}
|
3014
|
+
_ACEOF
|
3015
|
+
if ac_fn_cxx_try_compile "$LINENO"; then :
|
3016
|
+
ac_compiler_gnu=yes
|
3017
|
+
else
|
3018
|
+
ac_compiler_gnu=no
|
3019
|
+
fi
|
3020
|
+
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
3021
|
+
ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
|
3022
|
+
|
3023
|
+
fi
|
3024
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
|
3025
|
+
$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
|
3026
|
+
if test $ac_compiler_gnu = yes; then
|
3027
|
+
GXX=yes
|
3028
|
+
else
|
3029
|
+
GXX=
|
3030
|
+
fi
|
3031
|
+
ac_test_CXXFLAGS=${CXXFLAGS+set}
|
3032
|
+
ac_save_CXXFLAGS=$CXXFLAGS
|
3033
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
|
3034
|
+
$as_echo_n "checking whether $CXX accepts -g... " >&6; }
|
3035
|
+
if ${ac_cv_prog_cxx_g+:} false; then :
|
3036
|
+
$as_echo_n "(cached) " >&6
|
3037
|
+
else
|
3038
|
+
ac_save_cxx_werror_flag=$ac_cxx_werror_flag
|
3039
|
+
ac_cxx_werror_flag=yes
|
3040
|
+
ac_cv_prog_cxx_g=no
|
3041
|
+
CXXFLAGS="-g"
|
3042
|
+
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
3043
|
+
/* end confdefs.h. */
|
3044
|
+
|
3045
|
+
int
|
3046
|
+
main ()
|
3047
|
+
{
|
3048
|
+
|
3049
|
+
;
|
3050
|
+
return 0;
|
3051
|
+
}
|
3052
|
+
_ACEOF
|
3053
|
+
if ac_fn_cxx_try_compile "$LINENO"; then :
|
3054
|
+
ac_cv_prog_cxx_g=yes
|
3055
|
+
else
|
3056
|
+
CXXFLAGS=""
|
3057
|
+
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
3058
|
+
/* end confdefs.h. */
|
3059
|
+
|
3060
|
+
int
|
3061
|
+
main ()
|
3062
|
+
{
|
3063
|
+
|
3064
|
+
;
|
3065
|
+
return 0;
|
3066
|
+
}
|
3067
|
+
_ACEOF
|
3068
|
+
if ac_fn_cxx_try_compile "$LINENO"; then :
|
3069
|
+
|
3070
|
+
else
|
3071
|
+
ac_cxx_werror_flag=$ac_save_cxx_werror_flag
|
3072
|
+
CXXFLAGS="-g"
|
3073
|
+
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
3074
|
+
/* end confdefs.h. */
|
3075
|
+
|
3076
|
+
int
|
3077
|
+
main ()
|
3078
|
+
{
|
3079
|
+
|
3080
|
+
;
|
3081
|
+
return 0;
|
3082
|
+
}
|
3083
|
+
_ACEOF
|
3084
|
+
if ac_fn_cxx_try_compile "$LINENO"; then :
|
3085
|
+
ac_cv_prog_cxx_g=yes
|
3086
|
+
fi
|
3087
|
+
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
3088
|
+
fi
|
3089
|
+
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
3090
|
+
fi
|
3091
|
+
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
3092
|
+
ac_cxx_werror_flag=$ac_save_cxx_werror_flag
|
3093
|
+
fi
|
3094
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
|
3095
|
+
$as_echo "$ac_cv_prog_cxx_g" >&6; }
|
3096
|
+
if test "$ac_test_CXXFLAGS" = set; then
|
3097
|
+
CXXFLAGS=$ac_save_CXXFLAGS
|
3098
|
+
elif test $ac_cv_prog_cxx_g = yes; then
|
3099
|
+
if test "$GXX" = yes; then
|
3100
|
+
CXXFLAGS="-g -O2"
|
3101
|
+
else
|
3102
|
+
CXXFLAGS="-g"
|
3103
|
+
fi
|
3104
|
+
else
|
3105
|
+
if test "$GXX" = yes; then
|
3106
|
+
CXXFLAGS="-O2"
|
3107
|
+
else
|
3108
|
+
CXXFLAGS=
|
3109
|
+
fi
|
3110
|
+
fi
|
3111
|
+
ac_ext=c
|
3112
|
+
ac_cpp='$CPP $CPPFLAGS'
|
3113
|
+
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
|
3114
|
+
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
|
3115
|
+
ac_compiler_gnu=$ac_cv_c_compiler_gnu
|
3116
|
+
|
3117
|
+
CFLAGS="$saved_cflags"
|
3118
|
+
CXXFLAGS="$saved_cxxflags"
|
2799
3119
|
|
2800
3120
|
# ar and ranlib:
|
2801
3121
|
if test -n "$ac_tool_prefix"; then
|
@@ -3464,6 +3784,47 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
|
|
3464
3784
|
|
3465
3785
|
|
3466
3786
|
|
3787
|
+
# Cuda compiler:
|
3788
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for nvcc" >&5
|
3789
|
+
$as_echo_n "checking for nvcc... " >&6; }
|
3790
|
+
saved_cc="$CC"
|
3791
|
+
saved_cflags="$CFLAGS"
|
3792
|
+
saved_cxxflags="$CXXFLAGS"
|
3793
|
+
CC=nvcc
|
3794
|
+
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
3795
|
+
/* end confdefs.h. */
|
3796
|
+
|
3797
|
+
void
|
3798
|
+
f(void)
|
3799
|
+
{
|
3800
|
+
return;
|
3801
|
+
}
|
3802
|
+
|
3803
|
+
_ACEOF
|
3804
|
+
if ac_fn_c_try_compile "$LINENO"; then :
|
3805
|
+
have_nvcc=yes
|
3806
|
+
else
|
3807
|
+
have_nvcc=no
|
3808
|
+
fi
|
3809
|
+
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
3810
|
+
CC="$saved_cc"
|
3811
|
+
CFLAGS="$saved_cflags"
|
3812
|
+
CXXFLAGS="$saved_cxxflags"
|
3813
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_nvcc" >&5
|
3814
|
+
$as_echo "$have_nvcc" >&6; }
|
3815
|
+
|
3816
|
+
CUDA_CXX=
|
3817
|
+
CONFIGURE_CUDA_CXXFLAGS=
|
3818
|
+
if test "$have_nvcc" = yes; then
|
3819
|
+
CUDA_CXX="nvcc"
|
3820
|
+
CONFIGURE_CUDA_CXXFLAGS="-std=c++11"
|
3821
|
+
|
3822
|
+
$as_echo "#define HAVE_CUDA 1" >>confdefs.h
|
3823
|
+
|
3824
|
+
fi
|
3825
|
+
|
3826
|
+
|
3827
|
+
|
3467
3828
|
# Add an explicit include directory.
|
3468
3829
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-includes" >&5
|
3469
3830
|
$as_echo_n "checking for --with-includes... " >&6; }
|
@@ -3539,20 +3900,20 @@ fi
|
|
3539
3900
|
|
3540
3901
|
# Compiler dependent settings:
|
3541
3902
|
XND_WARN=
|
3542
|
-
XND_OPT="-O2"
|
3903
|
+
XND_OPT="-O2 -g"
|
3543
3904
|
case $CC in
|
3544
3905
|
*gcc*)
|
3545
3906
|
XND_WARN="-Wall -Wextra -std=c11 -pedantic"
|
3546
|
-
XND_OPT="-O2"
|
3907
|
+
XND_OPT="-O2 -g"
|
3547
3908
|
;;
|
3548
3909
|
*icc*)
|
3549
3910
|
AR=xiar
|
3550
3911
|
XND_WARN="-Wall"
|
3551
|
-
XND_OPT="-O2"
|
3912
|
+
XND_OPT="-O2 -g"
|
3552
3913
|
;;
|
3553
3914
|
*clang*)
|
3554
3915
|
XND_WARN="-Wall -Wextra -std=c11 -pedantic"
|
3555
|
-
XND_OPT="-O2"
|
3916
|
+
XND_OPT="-O2 -g"
|
3556
3917
|
;;
|
3557
3918
|
esac
|
3558
3919
|
|
@@ -3560,7 +3921,7 @@ esac
|
|
3560
3921
|
|
3561
3922
|
# Substitute variables and generate output:
|
3562
3923
|
if test -z "$LD"; then
|
3563
|
-
LD="$
|
3924
|
+
LD="$CXX"
|
3564
3925
|
fi
|
3565
3926
|
|
3566
3927
|
|
@@ -3574,6 +3935,12 @@ else
|
|
3574
3935
|
CONFIGURE_CFLAGS="$XND_INCLUDE $XND_WARN $XND_CONFIG $XND_OPT $CFLAGS"
|
3575
3936
|
fi
|
3576
3937
|
|
3938
|
+
if test -z "$CXXFLAGS"; then
|
3939
|
+
CONFIGURE_CXXFLAGS="$XND_INCLUDE -Wall -Wextra -O2 -g"
|
3940
|
+
else
|
3941
|
+
CONFIGURE_CXXFLAGS="$XND_INCLUDE -Wall -Wextra -O2 -g $CXXFLAGS"
|
3942
|
+
fi
|
3943
|
+
|
3577
3944
|
if test -z "$LDFLAGS"; then
|
3578
3945
|
CONFIGURE_LDFLAGS="$XND_LINK $CONFIGURE_LDFLAGS"
|
3579
3946
|
else
|
@@ -3583,6 +3950,7 @@ fi
|
|
3583
3950
|
|
3584
3951
|
|
3585
3952
|
|
3953
|
+
|
3586
3954
|
cat >confcache <<\_ACEOF
|
3587
3955
|
# This file is a shell script that caches the results of configure
|
3588
3956
|
# tests run on this system so they can be shared between configure
|