diff -ruNp gpsbabel-1.6.0.orig/Makefile.in gpsbabel-1.6.0/Makefile.in --- gpsbabel-1.6.0.orig/Makefile.in 2019-05-02 10:26:47.000000000 +0200 +++ gpsbabel-1.6.0/Makefile.in 2019-08-06 03:31:17.476367571 +0200 @@ -121,7 +121,7 @@ LIBOBJS = route.o waypt.o filter_vecs.o src/core/textstream.o \ src/core/usasciicodec.o \ src/core/xmlstreamwriter.o \ - $(GARMIN) $(JEEPS) $(FMTS) $(FILTERS) $(SHAPE) @ZLIB@ + $(GARMIN) $(JEEPS) $(FMTS) $(FILTERS) $(SHAPE) @ZLIB@ @MINIZIP@ OBJS = main.o globals.o $(LIBOBJS) @FILEINFO@ DEPFILES = $(OBJS:.o=.d) diff -ruNp gpsbabel-1.6.0.orig/config.h.in gpsbabel-1.6.0/config.h.in --- gpsbabel-1.6.0.orig/config.h.in 2019-05-02 10:26:47.000000000 +0200 +++ gpsbabel-1.6.0/config.h.in 2019-08-06 03:32:15.346105354 +0200 @@ -21,6 +21,9 @@ /* Define to 1 if you have the `m' library (-lm). */ #undef HAVE_LIBM +/* Define to 1 if you have the `minizip' library (-lminizip). */ +#undef HAVE_LIBMINIZIP + /* Defined if you have libusb */ #undef HAVE_LIBUSB @@ -66,6 +69,9 @@ /* 1 to enable as many formats as possible */ #undef MAXIMAL_ENABLED +/* 1 to inhibit our use of libminizip. */ +#undef MINIZIP_INHIBITED + /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT diff -ruNp gpsbabel-1.6.0.orig/configure.ac gpsbabel-1.6.0/configure.ac --- gpsbabel-1.6.0.orig/configure.ac 2019-05-02 10:26:47.000000000 +0200 +++ gpsbabel-1.6.0/configure.ac 2019-08-06 03:34:20.233539240 +0200 @@ -128,6 +128,22 @@ AS_CASE([$with_zlib], ["system"], [ AC_SUBST(ZLIB_CPP) AC_SUBST(ZLIB) +AC_MSG_CHECKING([whether to support zlib's minizip]) +AC_ARG_WITH([libminizip], + [AS_HELP_STRING( + [--with-libminizip=(included)|system|no], + [])]) +AS_CASE([$with_libminizip], ["system"], [ + AC_CHECK_LIB([minizip], [zipOpen64]) +], ["no"], [ + AC_DEFINE(MINIZIP_INHIBITED, 1, [1 to inhibit our use of libminizip.]) + AC_MSG_RESULT([no]) +], [ + MINIZIP="\$(MINIZIP)" + AC_MSG_RESULT([using included version]) +]) +AC_SUBST(MINIZIP) + AS_CASE(["$target"], [*-*-mingw32*], [ FILEINFO=fileinfo.o AS_IF([test "$CC" = "gcc"], [