Commit f0e57e15ef57d84c2ecd3974b89607d3fb6a3fa4
1 parent
90564f33
Exists in
master
and in
1 other branch
Fixing bugs found during test in windows with MSYS2
Showing
2 changed files
with
5 additions
and
3 deletions
Show diff stats
Makefile.in
... | ... | @@ -269,7 +269,7 @@ $(BINRLS)/$(LIBNAME)@DLLEXT@.@PACKAGE_MAJOR_VERSION@.@PACKAGE_MINOR_VERSION@: \ |
269 | 269 | @$(MKDIR) `dirname $@` |
270 | 270 | @echo $< ... |
271 | 271 | @$(LD) \ |
272 | - -shared -Wl,-soname,$(@F) \ | |
272 | + @DLL_LDFLAGS@ \ | |
273 | 273 | -o $@ \ |
274 | 274 | $(LDFLAGS) \ |
275 | 275 | $(foreach SRC, $(basename $(SOURCES)), $(OBJRLS)/$(SRC).o) \ | ... | ... |
configure.ac
... | ... | @@ -80,11 +80,12 @@ dnl --------------------------------------------------------------------------- |
80 | 80 | DLLPREFIX="lib" |
81 | 81 | |
82 | 82 | case "$host" in |
83 | - *-mingw32) | |
83 | + *-mingw32|*-pc-msys) | |
84 | 84 | app_cv_osname="windows" |
85 | 85 | CFLAGS="$CFLAGS -pthread -D_WIN32_WINNT=0x0600" |
86 | 86 | LIBS="$LIBS -lws2_32 -lwtsapi32 -lcomdlg32" |
87 | - LDFLAGS="$LDFLAGS -pthread -static-libgcc -static-libstdc++" | |
87 | + LDFLAGS="$LDFLAGS -pthread" | |
88 | + DLL_LDFLAGS="-shared -Wl,--output-def,\$(@D)/\$(LIBNAME).def" | |
88 | 89 | DLLEXT=".dll" |
89 | 90 | |
90 | 91 | app_win32_revision=$(date +%y.%m.%d.%H) |
... | ... | @@ -120,6 +121,7 @@ AC_SUBST(LIBS) |
120 | 121 | AC_SUBST(LOGDIR) |
121 | 122 | AC_SUBST(DLLEXT) |
122 | 123 | AC_SUBST(DLLPREFIX) |
124 | +AC_SUBST(DLL_LDFLAGS) | |
123 | 125 | |
124 | 126 | dnl --------------------------------------------------------------------------- |
125 | 127 | dnl Check for other programs | ... | ... |