|
@@ -68,38 +68,48 @@ scute_version_script_cmd =
|
|
|
endif
|
|
|
|
|
|
|
|
|
-EXEEXT = .dll
|
|
|
+lib_LTLIBRARIES = libscute.la
|
|
|
|
|
|
if HAVE_W32_SYSTEM
|
|
|
|
|
|
-bin_PROGRAMS = scute
|
|
|
+LTRCCOMPILE = $(LIBTOOL) --mode=compile $(RC) \
|
|
|
+ `echo $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) | \
|
|
|
+ sed -e 's/-I/--include-dir /g;s/-D/--define /g'`
|
|
|
|
|
|
-AM_CFLAGS = @LIBASSUAN_CFLAGS@ @GPG_ERROR_CFLAGS@ -shared
|
|
|
+SUFFIXES: .rc .lo
|
|
|
|
|
|
-scute_SOURCES = $(sources) versioninfo.rc
|
|
|
+.rc.lo:
|
|
|
+ $(LTRCCOMPILE) -i $< -o $@
|
|
|
|
|
|
-scute_DEPENDENCIES = @LTLIBOBJS@ versioninfo.o libgpg-error.a libassuan.a
|
|
|
+scute_res = versioninfo.lo
|
|
|
+scute_res_ldflag = -Wl,.libs/versioninfo.o
|
|
|
|
|
|
-libgpg-error.a:
|
|
|
- ln -s $$($(GPG_ERROR_CONFIG) --prefix)/lib/libgpg-error.a .
|
|
|
+no_undefined = -no-undefined
|
|
|
+export_symbols = -export-symbols $(srcdir)/scute.def
|
|
|
|
|
|
-libassuan.a:
|
|
|
- ln -s $$($(LIBASSUAN_CONFIG) --prefix)/lib/libassuan.a .
|
|
|
+install-def-file:
|
|
|
+ $(INSTALL) $(srcdir)/scute.def $(DESTDIR)$(libdir)/scute.def
|
|
|
|
|
|
-clean-local:
|
|
|
- rm -f libgpg-error.a libassuan.a
|
|
|
+uninstall-def-file:
|
|
|
+ -rm $(DESTDIR)$(libdir)/scute.def
|
|
|
|
|
|
+scute_deps = $(scute_res) scute.def
|
|
|
|
|
|
-scute_LDADD = @LTLIBOBJS@ $(srcdir)/scute.def -L. -lassuan -lgpg-error
|
|
|
+else
|
|
|
|
|
|
-.rc.o:
|
|
|
- $(RC) -I $(srcdir) -I . `test -f '$<' || echo '$(srcdir)/'`$< $@
|
|
|
+scute_res =
|
|
|
+scute_res_ldflag =
|
|
|
+no_undefined =
|
|
|
+export_symbols =
|
|
|
+install-def-file:
|
|
|
+uninstall-def-file:
|
|
|
|
|
|
-else
|
|
|
+scute_deps =
|
|
|
|
|
|
-lib_LTLIBRARIES = libscute.la
|
|
|
+endif
|
|
|
|
|
|
-libscute_la_LDFLAGS = $(scute_version_script_cmd) -version-info \
|
|
|
+libscute_la_LDFLAGS = $(scute_res_ldflag) $(no_undefined) $(export_symbols) \
|
|
|
+ $(scute_version_script_cmd) -version-info \
|
|
|
@LIBSCUTE_LT_CURRENT@:@LIBSCUTE_LT_REVISION@:@LIBSCUTE_LT_AGE@
|
|
|
libscute_la_DEPENDENCIES = @LTLIBOBJS@ $(srcdir)/libscute.vers $(scute_deps)
|
|
|
libscute_la_LIBADD = @LTLIBOBJS@ @LIBASSUAN_LIBS@ @GPG_ERROR_LIBS@
|
|
@@ -108,4 +118,35 @@ libscute_la_CPPFLAGS = -I$(srcdir)/../include \
|
|
|
@LIBASSUAN_CFLAGS@ @GPG_ERROR_CFLAGS@
|
|
|
libscute_la_SOURCES = $(sources)
|
|
|
|
|
|
+# The above rules only build a static library on W32. We build the
|
|
|
+# DLL below, such that it is autonomous (does not link to any other
|
|
|
+# non-standard DLL).
|
|
|
+
|
|
|
+EXEEXT = .dll
|
|
|
+
|
|
|
+if HAVE_W32_SYSTEM
|
|
|
+
|
|
|
+bin_PROGRAMS = scute
|
|
|
+
|
|
|
+AM_CFLAGS = @LIBASSUAN_CFLAGS@ @GPG_ERROR_CFLAGS@ -shared
|
|
|
+
|
|
|
+scute_SOURCES = dllmain.c $(sources) versioninfo.rc
|
|
|
+
|
|
|
+scute_DEPENDENCIES = @LTLIBOBJS@ versioninfo.o libgpg-error.a libassuan.a
|
|
|
+
|
|
|
+libgpg-error.a:
|
|
|
+ ln -s $$($(GPG_ERROR_CONFIG) --prefix)/lib/libgpg-error.a .
|
|
|
+
|
|
|
+libassuan.a:
|
|
|
+ ln -s $$($(LIBASSUAN_CONFIG) --prefix)/lib/libassuan.a .
|
|
|
+
|
|
|
+clean-local:
|
|
|
+ rm -f libgpg-error.a libassuan.a
|
|
|
+
|
|
|
+
|
|
|
+scute_LDADD = @LTLIBOBJS@ $(srcdir)/scute.def -L. -lassuan -lgpg-error -lws2_32
|
|
|
+
|
|
|
+#.rc.o:
|
|
|
+# $(RC) -I $(srcdir) -I . `test -f '$<' || echo '$(srcdir)/'`$< $@
|
|
|
+
|
|
|
endif
|