Force automake to invoke the C (not C++) linker in kit/ when no C++ is in use.

git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@2989 7ae35d74-ebe9-4afe-98af-79ac388436b8
Hamlib-1.2.13
Kamal Mostafa, KA6MAL 2010-09-29 17:58:32 +00:00
rodzic 2567b93af7
commit 0a8b6ad41e
2 zmienionych plików z 10 dodań i 3 usunięć

Wyświetl plik

@ -373,6 +373,7 @@ if test "${cf_with_cxx}" = "yes" ; then
fi
fi
AM_CONDITIONAL(ENABLE_CXX, test x"${cf_with_cxx}" = "xyes")
AM_CONDITIONAL(HAVE_USRP, test x"${cf_with_usrp}" = "xyes")
PKG_CHECK_MODULES(LIBUSB, libusb >= 0.1, ,

Wyświetl plik

@ -1,11 +1,17 @@
AM_CFLAGS = @LIBUSB_CFLAGS@
AM_CXXFLAGS = @USRP_CFLAGS@
# FIXME: compile usrp only if CXX available
KITSRCLIST = elektor304.c drt1.c dwt.c usrp.c elektor507.c \
dds60.c miniVNA.c si570avrusb.c
if ENABLE_CXX
KITSRCLIST += usrp_impl.cc
if HAVE_USRP
AM_CXXFLAGS = @USRP_CFLAGS@
KITSRCLIST += usrp_impl.cc
else
# automake gets confused and invokes the C++ linker via libtool regardless
# of whether or not HAVE_USRP enables the .cc source. This override forces
# automake to invoke the C linker as no C++ is involved:
hamlib_kit_la_LINK = $(LINK) $(hamlib_kit_la_LDFLAGS)
endif
KITROTSRCLIST = pcrotor.c