Add libmxml1.dll target and support for mingw cross-compilation (Issue #188)

This commit is contained in:
Michael Sweet 2017-04-23 12:21:38 -04:00
parent 5b4a398c01
commit 3700ebd2c3
3 changed files with 24 additions and 0 deletions

View File

@ -251,6 +251,15 @@ $(LIBOBJS): mxml.h
mxml-entity.o mxml-file.o mxml-private.o: mxml-private.h
#
# libmxml1.dll
#
libmxml1.dll: $(LIBOBJS)
echo Creating $@...
$(DSO) $(DSOFLAGS) -o $@ $(LIBOBJS)
#
# libmxml.so.1.5
#

8
configure vendored
View File

@ -4560,6 +4560,14 @@ $as_echo "yes" >&6; }
DSOFLAGS="$DSOFLAGS \$(RC_CFLAGS) -dynamiclib -lc"
;;
mingw)
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
LIBMXML="libmxml1.dll"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -shared -Wl,--out-implib,libmxml1.a,--no-undefined,--enable-runtime-pseudo-reloc"
;;
*)
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }

View File

@ -226,6 +226,13 @@ if test x$enable_shared != xno; then
DSOFLAGS="$DSOFLAGS \$(RC_CFLAGS) -dynamiclib -lc"
;;
mingw)
AC_MSG_RESULT(yes)
LIBMXML="libmxml1.dll"
DSO="\$(CC)"
DSOFLAGS="$DSOFLAGS -shared -Wl,--out-implib,libmxml1.a,--no-undefined,--enable-runtime-pseudo-reloc"
;;
*)
AC_MSG_RESULT(no)
AC_MSG_WARN(shared libraries not supported on this platform.)