diff --git a/configure.ac b/configure.ac index a21f85c..202543b 100644 --- a/configure.ac +++ b/configure.ac @@ -232,6 +232,9 @@ AM_CONDITIONAL([USE_SSL_GNUTLS], [test "$auth_lib" = gnutls -o "$auth_lib" = net AM_CONDITIONAL([USE_GNUTLS_NETTLE], [test "$auth_lib" = nettle]) AM_CONDITIONAL([USE_SSL_NSS], [test "$auth_lib" = nss]) +AC_CANONICAL_HOST +AM_CONDITIONAL([MSYS], [test "$host_os" = "msys"]) + dnl ---------------------------------------------- dnl check functions dnl ---------------------------------------------- diff --git a/src/Makefile.am b/src/Makefile.am index def210e..8a431d9 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -53,9 +53,7 @@ s3fs_SOURCES = \ addhead.cpp \ sighandlers.cpp \ autolock.cpp \ - common_auth.cpp \ - strptime.cpp \ - strcasestr.cpp + common_auth.cpp if USE_SSL_OPENSSL s3fs_SOURCES += openssl_auth.cpp endif @@ -65,6 +63,9 @@ endif if USE_SSL_NSS s3fs_SOURCES += nss_auth.cpp endif +if MSYS + s3fs_SOURCES += strptime.cpp strcasestr.cpp +endif s3fs_LDADD = $(DEPS_LIBS) @@ -73,7 +74,7 @@ noinst_PROGRAMS = \ test_page_list \ test_string_util -test_curl_util_SOURCES = common_auth.cpp curl_util.cpp string_util.cpp test_curl_util.cpp s3fs_global.cpp s3fs_logger.cpp strptime.cpp strcasestr.cpp +test_curl_util_SOURCES = common_auth.cpp curl_util.cpp string_util.cpp test_curl_util.cpp s3fs_global.cpp s3fs_logger.cpp if USE_SSL_OPENSSL test_curl_util_SOURCES += openssl_auth.cpp endif @@ -83,6 +84,9 @@ endif if USE_SSL_NSS test_curl_util_SOURCES += nss_auth.cpp endif +if MSYS + test_curl_util_SOURCES += strptime.cpp strcasestr.cpp +endif test_curl_util_LDADD = $(DEPS_LIBS) @@ -94,7 +98,10 @@ test_page_list_SOURCES = \ test_page_list.cpp \ strptime.cpp -test_string_util_SOURCES = string_util.cpp test_string_util.cpp s3fs_logger.cpp strptime.cpp +test_string_util_SOURCES = string_util.cpp test_string_util.cpp s3fs_logger.cpp +if MSYS + test_string_util_SOURCES += strptime.cpp +endif TESTS = \ test_curl_util \