From 823026b58211a4166de06ac243d978dcb9930271 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Mon, 22 Jan 2024 15:58:08 +0300 Subject: Turn odb repository into muti-package repository Also remove the autoconf/make-based build system. --- m4/disable-rpath.m4 | 24 ---------- m4/gcc-plugin.m4 | 133 ---------------------------------------------------- m4/libcutl.m4 | 81 -------------------------------- m4/libtool-link.m4 | 45 ------------------ 4 files changed, 283 deletions(-) delete mode 100644 m4/disable-rpath.m4 delete mode 100644 m4/gcc-plugin.m4 delete mode 100644 m4/libcutl.m4 delete mode 100644 m4/libtool-link.m4 (limited to 'm4') diff --git a/m4/disable-rpath.m4 b/m4/disable-rpath.m4 deleted file mode 100644 index 388f685..0000000 --- a/m4/disable-rpath.m4 +++ /dev/null @@ -1,24 +0,0 @@ -dnl file : m4/disable-rpath.m4 -dnl license : GNU GPL v3; see accompanying LICENSE file -dnl -AC_DEFUN([DISABLE_RPATH],[ - -AC_MSG_CHECKING([whether to use rpath]) -AC_ARG_ENABLE( - [rpath], - [AC_HELP_STRING([--disable-rpath], [patch libtool to not use rpath])], - [libtool_rpath="$enable_rpath"], - [libtool_rpath="yes"]) -AC_MSG_RESULT($libtool_rpath) - -# Patch libtool to not use rpath if requested. -# -AC_CONFIG_COMMANDS( - [libtool-rpath-patch], - [if test "$libtool_use_rpath" = "no"; then - sed < libtool > libtool-2 's/^hardcode_libdir_flag_spec.*$'/'hardcode_libdir_flag_spec=" -D__LIBTOOL_NO_RPATH__ "/' - mv libtool-2 libtool - chmod 755 libtool - fi], - [libtool_use_rpath=$libtool_rpath]) -])dnl diff --git a/m4/gcc-plugin.m4 b/m4/gcc-plugin.m4 deleted file mode 100644 index 20a9c75..0000000 --- a/m4/gcc-plugin.m4 +++ /dev/null @@ -1,133 +0,0 @@ -dnl file : m4/gcc-plugin.m4 -dnl license : GNU GPL v3; see accompanying LICENSE file -dnl -dnl GCC_PLUGIN -dnl -AC_DEFUN([GCC_PLUGIN], [ -static_plugin=$enable_static - -AC_ARG_WITH( - [gcc-plugin-dir], - [AC_HELP_STRING([--with-gcc-plugin-dir=DIR], [install ODB plugin into the GCC plugin directory])], - [gcc_plugin_dir=$withval], - [gcc_plugin_dir=test]) - -if test x"$static_plugin" = xyes; then - gcc_plugin_dir=no -else - if test x"$cross_compiling" = xyes; then - AC_MSG_CHECKING([whether to install into default GCC plugin dir]) - case $gcc_plugin_dir in - yes) - AC_MSG_ERROR([GCC plugin directory must be specified explicitly when cross-compiling]) - ;; - test) - # We cannot detect the plugin directory since there is no way to - # run host GCC. So assume no. - # - gcc_plugin_dir=no - ;; - no) - ;; - *) - # Add the include/ subdirectory of the plugin dir to CPPFLAGS since - # the plugin headers are normally installed there. - # - CPPFLAGS="$CPPFLAGS -I$gcc_plugin_dir/include" - ;; - esac - else - if test x"$GXX" != xyes; then - AC_MSG_ERROR([$CXX is not a GNU C++ compiler]) - fi - - AC_MSG_CHECKING([whether $CXX supports plugins]) - dir=`$CXX -print-file-name=plugin 2>/dev/null` - - if test x"$dir" = xplugin; then - AC_MSG_RESULT([no]) - AC_MSG_ERROR([$CXX does not support plugins; reconfigure GCC with --enable-plugin]) - else - AC_MSG_RESULT([yes]) - fi - - CPPFLAGS="$CPPFLAGS -I$dir/include" - - AC_MSG_CHECKING([whether to install ODB plugin into default GCC plugin directory]) - case $gcc_plugin_dir in - yes) - gcc_plugin_dir=$dir - ;; - test) - # Only install into the GCC plugin dir if both GCC and ODB are - # installed into the same prefix. Testing whether $libdir or - # $libexecdir is a prefix of the GCC plugin dir is a good - # approximation. - # - - # Get the expanded values for libdir and libexecdir. - # - if test x$exec_prefix = xNONE; then - if test x$prefix = xNONE; then - e_exec_prefix=$ac_default_prefix - else - e_exec_prefix=$prefix - fi - else - e_exec_prefix=$exec_prefix - fi - - # On some systems GCC is installed into $prefix/lib even though - # libdir is $prefix/lib64 and libexecdir is $prefix/libexec. To - # cover this special case, we will also test $prefix/lib. - # - e_libdir=`echo "$libdir" | sed "s?^\\\${exec_prefix}?$e_exec_prefix?"` - e_libexecdir=`echo "$libexecdir" | sed "s?^\\\${exec_prefix}?$e_exec_prefix?"` - e_libdir32=$e_exec_prefix/lib - - # See if either one of them is a prefix of the plugin dir. - # - ld_suffix=`echo "$dir" | sed "s?^$e_libdir/*??"` - led_suffix=`echo "$dir" | sed "s?^$e_libexecdir/*??"` - l32d_suffix=`echo "$dir" | sed "s?^$e_libdir32/*??"` - - if test x$ld_suffix != x$dir -o x$led_suffix != x$dir -o x$l32d_suffix != x$dir; then - gcc_plugin_dir=$dir - else - gcc_plugin_dir=no - fi - ;; - *) - ;; - esac - fi - - if test x"$gcc_plugin_dir" != xno; then - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - fi -fi - -AC_MSG_CHECKING([for GCC plugin headers]) - -CXX_LIBTOOL_LINK_IFELSE([ -AC_LANG_SOURCE([ -#include - -#ifndef BUILDING_GCC_MAJOR -# error no BUILDING_GCC_MAJOR in bversion.h -#endif - -int main () {} -])], -[gcc_plugin_headers=yes], -[gcc_plugin_headers=no]) - -if test x"$gcc_plugin_headers" = xyes; then - AC_MSG_RESULT([yes]) -else - AC_MSG_RESULT([no]) - AC_MSG_ERROR([GCC plugin headers not found; consider installing GCC plugin development package]) -fi -])dnl diff --git a/m4/libcutl.m4 b/m4/libcutl.m4 deleted file mode 100644 index 7275ba2..0000000 --- a/m4/libcutl.m4 +++ /dev/null @@ -1,81 +0,0 @@ -dnl file : m4/libcutl.m4 -dnl license : MIT; see accompanying LICENSE file -dnl -dnl LIBCUTL([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]) -dnl -dnl -AC_DEFUN([LIBCUTL], [ -libcutl_found=no - -AC_ARG_WITH( - [libcutl], - [AC_HELP_STRING([--with-libcutl=DIR],[location of libcutl build directory])], - [libcutl_dir=${withval}], - [libcutl_dir=]) - -AC_MSG_CHECKING([for libcutl]) - -# If libcutl_dir was given, add the necessary preprocessor and linker flags. -# -if test x"$libcutl_dir" != x; then - save_CPPFLAGS="$CPPFLAGS" - save_LDFLAGS="$LDFLAGS" - - AS_SET_CATFILE([abs_libcutl_dir], [$ac_pwd], [$libcutl_dir]) - - CPPFLAGS="$CPPFLAGS -I$abs_libcutl_dir" - LDFLAGS="$LDFLAGS -L$abs_libcutl_dir/cutl" -fi - -save_LIBS="$LIBS" -LIBS="-lcutl $LIBS" - -CXX_LIBTOOL_LINK_IFELSE([ -AC_LANG_SOURCE([ -#include - -void -f () -{ -} - -const char* -g () -{ - try - { - f (); - } - catch (const cutl::exception& e) - { - return e.what (); - } - return 0; -} - -int -main () -{ - const char* m (g ()); - return m != 0; -} -])], -[libcutl_found=yes]) - -if test x"$libcutl_found" = xno; then - LIBS="$save_LIBS" - - if test x"$libcutl_dir" != x; then - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - fi -fi - -if test x"$libcutl_found" = xyes; then - AC_MSG_RESULT([yes]) - $1 -else - AC_MSG_RESULT([no]) - $2 -fi -])dnl diff --git a/m4/libtool-link.m4 b/m4/libtool-link.m4 deleted file mode 100644 index 302639f..0000000 --- a/m4/libtool-link.m4 +++ /dev/null @@ -1,45 +0,0 @@ -dnl file : m4/libtool-link.m4 -dnl license : GNU GPL v2; see accompanying LICENSE file -dnl -dnl -dnl CXX_LIBTOOL_LINK_IFELSE (input, [action-if-true], [action-if-false]) -dnl -dnl Similar to AC_LINK_IFELSE except it uses libtool to perform the -dnl linking and it does this using the C++ compiler. -dnl -AC_DEFUN([CXX_LIBTOOL_LINK_IFELSE],[ -AC_LANG_SAVE -AC_LANG(C++) - -if test -d .libs; then - delete_libs_dir=no -else - delete_libs_dir=yes -fi - -AC_COMPILE_IFELSE([$1], -[ - ac_try='./libtool --tag=CXX --mode=link $CXX -no-install $CXXFLAGS $LDFLAGS -o conftest conftest.$OBJEXT $LIBS >&AS_MESSAGE_LOG_FD' - if _AC_DO_VAR(ac_try); then - libtool_link_ok=yes - else - libtool_link_ok=no - fi -], -[ - libtool_link_ok=no -]) - -if test x"$delete_libs_dir" = xyes; then - rm -rf .libs -fi - -if test x"$libtool_link_ok" = xyes; then -[$2] -: -else -[$3] -: -fi - -AC_LANG_RESTORE])dnl -- cgit v1.1