fix building of shared libraries on Windows-bases hosts

includes no longer forcing disabling optimization by the configure script; this
was resulting in over-linking of unused template instantions resulting in
'multiple definition of...' errors
This commit is contained in:
E. Madison Bray 2020-02-07 15:42:47 +01:00
parent a8c637e25e
commit 6cfa6914f7
2 changed files with 5 additions and 2 deletions

View File

@ -4,6 +4,9 @@ AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([foreign -Wall])
AM_PROG_AR
AC_PROG_CXX
LT_INIT
LT_INIT([shared win32-dll])
AC_CANONICAL_HOST
AS_CASE([$host_os], [*cygwin* | *mingw*], [SIROCCO_LDFLAGS=-no-undefined])
AC_SUBST(SIROCCO_LDFLAGS)
AC_CONFIG_FILES([Makefile lib/Makefile tests/Makefile])
AC_OUTPUT

View File

@ -1,5 +1,5 @@
lib_LTLIBRARIES = libsirocco.la
libsirocco_la_SOURCES = icomplex.cpp interval.cpp $(top_srcdir)/include/list.hpp $(top_srcdir)/include/mp_complex.hpp $(top_srcdir)/include/mp_icomplex.hpp $(top_srcdir)/include/mp_interval.hpp $(top_srcdir)/include/polynomial.hpp $(top_srcdir)/include/sirocco.hpp $(top_srcdir)/include/icomplex.hpp $(top_srcdir)/include/interval.hpp mp_complex.cpp mp_icomplex.cpp mp_interval.cpp polynomial.cpp sirocco.cpp
libsirocco_la_LDFLAGS = -lm -lmpfr -lgmp
libsirocco_la_LDFLAGS = $(SIROCCO_LDFLAGS) -lm -lmpfr -lgmp
AM_CPPFLAGS = -I$(top_srcdir)/include
include_HEADERS = $(top_srcdir)/include/sirocco.h