freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft-devel] FreeType DLL support


From: Alexei Podtelezhnikov
Subject: Re: [ft-devel] FreeType DLL support
Date: Thu, 18 Jan 2018 00:10:28 -0500

Ok, this is a patch that works for tagging DLL with version and copyright information.


diff --git a/builds/freetype.mk b/builds/freetype.mk
index f2e7e608e..9d05821a7 100644
--- a/builds/freetype.mk
+++ b/builds/freetype.mk
@@ -248,6 +248,22 @@ $(FTINIT_OBJ): $(FTINIT_SRC) $(FREETYPE_H)
        $(FT_COMPILE) $T$(subst /,$(COMPILER_SEP),$@ $<)


+# ftver component
+#
+#  The version resource `ftver.rc' contains version and copyright to be
+#  compiled by windres and tagged into DLL usually.
+#
+ifneq ($(RC),)
+FTVER_SRC := $(BASE_DIR)/ftver.rc
+FTVER_OBJ := $(OBJ_DIR)/ftver.$O
+
+OBJECTS_LIST += $(FTVER_OBJ)
+
+$(FTVER_OBJ): $(FTVER_SRC)
+       $(RC) -o $@ $<
+endif
+
+
 # All FreeType library objects.
 #
 OBJ_M := $(BASE_OBJ_M) $(BASE_EXT_OBJ) $(DRV_OBJS_M)
diff --git a/builds/unix/configure.raw b/builds/unix/configure.raw
index 20157b9be..d76c32452 100644
--- a/builds/unix/configure.raw
+++ b/builds/unix/configure.raw
@@ -37,6 +37,7 @@ AC_SUBST(EXEEXT)
 PKG_PROG_PKG_CONFIG([0.24])

 LT_INIT(win32-dll)
+LT_PROG_RC


 # checks for native programs to generate building tool
diff --git a/builds/unix/unix-cc.in b/builds/unix/unix-cc.in
index a06246d63..5675866ea 100644
--- a/builds/unix/unix-cc.in
+++ b/builds/unix/unix-cc.in
@@ -87,10 +87,16 @@ ANSIFLAGS := @XX_ANSIFLAGS@

 # C compiler to use -- we use libtool!
 #
-#
 CCraw := $(CC)
 CC    := $(LIBTOOL) --mode=compile $(CCraw)

+# Resource compiler to use on Cygwin/MinGW, usually windres.
+#
+RCraw := @RC@
+ifneq ($(RCraw),)
+  RC := $(LIBTOOL) --tag=RC --mode=compile $(RCraw)
+endif
+
 # Linker flags.
 #
 LDFLAGS           := @LDFLAGS@

reply via email to

[Prev in Thread] Current Thread [Next in Thread]