[libxslt] Update to 1.1.34 (#16617)

* Updated to point at 1.1.34 tagged version of libxslt, merged the patch differences and added the required, additional patches to get it building.

* Added missing version info using "vcpkg x-add-version".

* Update ports/libxslt/CONTROL

Co-authored-by: NancyLi1013 <46708020+NancyLi1013@users.noreply.github.com>

* Re-added the version with the port-version fix in.

* Fix for x64-windows-static builds.

* Another re-add of the version since the git tree hash is different.

* [libxslt] Reorganize patches

Co-authored-by: NancyLi1013 <46708020+NancyLi1013@users.noreply.github.com>
Co-authored-by: Robert Schumacher <roschuma@microsoft.com>
This commit is contained in:
pastle-ptc 2021-04-07 21:41:35 +01:00 committed by GitHub
parent 827bfad29a
commit 186978b0e4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 96 additions and 47 deletions

View File

@ -1,35 +1,38 @@
---
win32/Makefile.msvc | 29 +++++++++++++++--------------
1 file changed, 15 insertions(+), 14 deletions(-)
diff --git a/win32/Makefile.msvc b/win32/Makefile.msvc
index 23a02d2..b13dd26 100644
--- a/win32/Makefile.msvc
+++ b/win32/Makefile.msvc
diff --git "a/win32/Makefile.msvc" "b/win32/Makefile.msvc"
index 2e4742bb..8bfe7d83 100644
--- "a/win32/Makefile.msvc"
+++ "b/win32/Makefile.msvc"
@@ -59,7 +59,13 @@ CFLAGS = $(CFLAGS) /D_CRT_SECURE_NO_DEPRECATE /D_CRT_NONSTDC_NO_DEPRECATE
LD = link.exe
LDFLAGS = /nologo
LDFLAGS = $(LDFLAGS) /LIBPATH:$(BINDIR) /LIBPATH:$(LIBPREFIX)
-LIBS = wsock32.lib
-LIBS =
+# The libraries are needed for static builds (the makefile builds all tools and dlls)
+LIBS = wsock32.lib iconv.lib charset.lib
+LIBS = iconv.lib charset.lib ws2_32.lib
+!if "$(DEBUG)" == "1"
+LIBS = $(LIBS) zlibd.lib
+LIBS = $(LIBS) zlibd.lib lzmad.lib
+!else
+LIBS = $(LIBS) zlib.lib
+LIBS = $(LIBS) zlib.lib lzma.lib
+!endif
# The archiver and its options.
AR = lib.exe
@@ -71,6 +77,7 @@ CFLAGS = $(CFLAGS) /D "_DEBUG" /Od /Z7
@@ -71,8 +77,14 @@ CFLAGS = $(CFLAGS) /D "_DEBUG" /Od /Z7
LDFLAGS = $(LDFLAGS) /DEBUG
!else
CFLAGS = $(CFLAGS) /D "NDEBUG" /O2
+LDFLAGS = $(LDFLAGS) /DEBUG /OPT:REF /OPT:ICF
!endif
+# append CFLAGS etc. passed on command line
+CPPFLAGS = $(CPPFLAGS) $(EXTRA_CPPFLAGS)
+CFLAGS = $(CFLAGS) $(EXTRA_CFLAGS)
+LDFLAGS = $(LDFLAGS) $(EXTRA_LDFLAGS)
+
# Libxslt object files.
@@ -309,13 +316,7 @@ $(UTILS_INTDIR) :
XSLT_OBJS = $(XSLT_INTDIR)\attributes.obj\
$(XSLT_INTDIR)\documents.obj\
@@ -309,13 +321,7 @@ $(UTILS_INTDIR) :
# An implicit rule for xsltproc and friends.
APPLIBS = $(LIBS)
!if "$(STATIC)" == "1"
@ -44,4 +47,3 @@ index 23a02d2..b13dd26 100644
{$(UTILS_SRCDIR)}.c{$(BINDIR)}.exe:
$(CC) /D "LIBXML_STATIC" /D "LIBXSLT_STATIC" /D "LIBEXSLT_STATIC" \
$(CFLAGS) /Fo$(UTILS_INTDIR)\ /c $<
--

View File

@ -1,21 +1,5 @@
diff --git a/win32/Makefile.msvc b/win32/Makefile.msvc
index 0d1953d..0e538ef 100644
--- a/win32/Makefile.msvc
+++ b/win32/Makefile.msvc
@@ -62,9 +62,9 @@ LDFLAGS = $(LDFLAGS) /LIBPATH:$(BINDIR) /LIBPATH:$(LIBPREFIX)
# The libraries are needed for static builds (the makefile builds all tools and dlls)
LIBS = wsock32.lib iconv.lib charset.lib
!if "$(DEBUG)" == "1"
-LIBS = $(LIBS) zlibd.lib
+LIBS = $(LIBS) zlibd.lib lzmad.lib
!else
-LIBS = $(LIBS) zlib.lib
+LIBS = $(LIBS) zlib.lib lzma.lib
!endif
# The archiver and its options.
diff --git a/win32/configure.js b/win32/configure.js
index 56694cc..24ccc8d 100644
index 12c99f3..0737b06 100644
--- a/win32/configure.js
+++ b/win32/configure.js
@@ -45,6 +45,7 @@ var withMemDebug = false;
@ -25,24 +9,24 @@ index 56694cc..24ccc8d 100644
+var withLzma = true;
var withCrypto = true;
var withModules = false;
/* Win32 build options. */
@@ -104,6 +105,7 @@ function usage()
var withProfiler = true;
@@ -105,6 +106,7 @@ function usage()
txt += " debugger: Enable external debugger support (" + (withDebugger? "yes" : "no") + ")\n";
txt += " iconv: Use iconv library (" + (withIconv? "yes" : "no") + ")\n";
txt += " zlib: Use zlib library (" + (withZlib? "yes" : "no") + ")\n";
+ txt += " lzma: Use lzma library (" + (withLzma? "yes" : "no") + ")\n";
txt += " crypto: Enable Crypto support (" + (withCrypto? "yes" : "no") + ")\n";
txt += " modules: Enable Module support (" + (withModules? "yes" : "no") + ")\n";
txt += "\nWin32 build options, default value given in parentheses:\n\n";
@@ -190,6 +192,7 @@ function discoverVersion()
txt += " profiler: Enable Profiler support (" + (withProfiler? "yes" : "no") + ")\n";
@@ -192,6 +194,7 @@ function discoverVersion()
vf.WriteLine("WITH_DEBUGGER=" + (withDebugger? "1" : "0"));
vf.WriteLine("WITH_ICONV=" + (withIconv? "1" : "0"));
vf.WriteLine("WITH_ZLIB=" + (withZlib? "1" : "0"));
+ vf.WriteLine("WITH_LZMA=" + (withLzma? "1" : "0"));
vf.WriteLine("WITH_CRYPTO=" + (withCrypto? "1" : "0"));
vf.WriteLine("WITH_MODULES=" + (withModules? "1" : "0"));
vf.WriteLine("DEBUG=" + (buildDebug? "1" : "0"));
@@ -339,6 +342,8 @@ for (i = 0; (i < WScript.Arguments.length) && (error == 0); i++) {
vf.WriteLine("WITH_PROFILER=" + (withProfiler? "1" : "0"));
@@ -344,6 +347,8 @@ for (i = 0; (i < WScript.Arguments.length) && (error == 0); i++) {
withIconv = strToBool(arg.substring(opt.length + 1, arg.length));
else if (opt == "zlib")
withZlib = strToBool(arg.substring(opt.length + 1, arg.length));
@ -51,11 +35,11 @@ index 56694cc..24ccc8d 100644
else if (opt == "crypto")
withCrypto = strToBool(arg.substring(opt.length + 1, arg.length));
else if (opt == "modules")
@@ -475,6 +480,7 @@ txtOut += " Memory debugging: " + boolToStr(withMemDebug) + "\n";
@@ -482,6 +487,7 @@ txtOut += " Memory debugging: " + boolToStr(withMemDebug) + "\n";
txtOut += " Debugger support: " + boolToStr(withDebugger) + "\n";
txtOut += " Use iconv: " + boolToStr(withIconv) + "\n";
txtOut += " With zlib: " + boolToStr(withZlib) + "\n";
+txtOut += " Lzma: " + boolToStr(withLzma) + "\n";
txtOut += " Crypto: " + boolToStr(withCrypto) + "\n";
txtOut += " Modules: " + boolToStr(withModules) + "\n";
txtOut += "\n";
txtOut += " Profiler: " + boolToStr(withProfiler) + "\n";

View File

@ -0,0 +1,50 @@
diff --git a/win32/configure.js b/win32/configure.js
index 0737b06..11815e4 100644
--- a/win32/configure.js
+++ b/win32/configure.js
@@ -138,7 +138,7 @@ function usage()
file included by our makefile. */
function discoverVersion()
{
- var fso, cf, vf, ln, s;
+ var fso, cf, vf, ln, s, m;
fso = new ActiveXObject("Scripting.FileSystemObject");
verCvs = "";
if (useCvsVer && fso.FileExists("..\\CVS\\Entries")) {
@@ -147,8 +147,8 @@ function discoverVersion()
ln = cf.ReadLine();
s = new String(ln);
if (s.search(/^\/ChangeLog\//) != -1) {
- iDot = s.indexOf(".");
- iSlash = s.indexOf("/", iDot);
+ var iDot = s.indexOf(".");
+ var iSlash = s.indexOf("/", iDot);
verCvs = "CVS" + s.substring(iDot + 1, iSlash);
break;
}
@@ -178,13 +178,13 @@ function discoverVersion()
verMicroXslt = m[1];
} else if (s.search(/^LIBEXSLT_MAJOR_VERSION=/) != -1) {
vf.WriteLine(s);
- verMajorExslt = s.substring(s.indexOf("=") + 1, s.length)
+ verMajorExslt = s.substring(s.indexOf("=") + 1, s.length);
} else if(s.search(/^LIBEXSLT_MINOR_VERSION=/) != -1) {
vf.WriteLine(s);
- verMinorExslt = s.substring(s.indexOf("=") + 1, s.length)
+ verMinorExslt = s.substring(s.indexOf("=") + 1, s.length);
} else if(s.search(/^LIBEXSLT_MICRO_VERSION=/) != -1) {
vf.WriteLine(s);
- verMicroExslt = s.substring(s.indexOf("=") + 1, s.length)
+ verMicroExslt = s.substring(s.indexOf("=") + 1, s.length);
}
}
cf.Close();
@@ -365,8 +365,6 @@ for (i = 0; (i < WScript.Arguments.length) && (error == 0); i++) {
buildStatic = strToBool(arg.substring(opt.length + 1, arg.length));
else if (opt == "prefix")
buildPrefix = arg.substring(opt.length + 1, arg.length);
- else if (opt == "incdir")
- buildIncPrefix = arg.substring(opt.length + 1, arg.length);
else if (opt == "bindir")
buildBinPrefix = arg.substring(opt.length + 1, arg.length);
else if (opt == "libdir")

View File

@ -1,7 +1,6 @@
Source: libxslt
Version: 1.1.33
Port-Version: 9
Version: 1.1.34
Homepage: https://github.com/GNOME/libxslt
Description: Libxslt is a XSLT library implemented in C for XSLT 1.0 and most of EXSLT
Build-Depends: libxml2, liblzma
Supports: !uwp
Supports: !uwp

View File

@ -1,12 +1,21 @@
vcpkg_download_distfile(
PATCH_e2584eed1c84c18f16e42188c30d2c3d8e3e8853
URLS "https://github.com/GNOME/libxslt/commit/e2584eed1c84c18f16e42188c30d2c3d8e3e8853.patch"
FILENAME e2584eed1c84c18f16e42188c30d2c3d8e3e8853.patch
SHA512 d08a06616d732993f2131826ca06fafc2e9f561cb1edb17eaf2adaf78e276bb03cba92a773143eb939da04781f5b5e0a09b351d8e4622a941de3cb3d11da731c
)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO GNOME/libxslt
REF v1.1.33
SHA512 2c20b2af3c19952b25b10dca0d95fe227602f7f815db352b04dd061c52c458d745f92c597ce08ac9207ba0fbe0169ea2fb78263d8590743717553f84463fe1d9
REF v1.1.34
SHA512 fc57affb236e5f7602ee53c8090a854c6b950d1e6526ae3488bca41d8d421ec70433d88eb227c71c2a61213bc364517bdad907125e36486da1754fe9e460601f
HEAD_REF master
PATCHES
"${PATCH_e2584eed1c84c18f16e42188c30d2c3d8e3e8853}"
0001-Fix-makefile.patch
0002-Fix-lzma.patch
0003-Fix-configure.patch
)
if (VCPKG_TARGET_IS_WINDOWS)

View File

@ -3633,8 +3633,8 @@
"port-version": 0
},
"libxslt": {
"baseline": "1.1.33",
"port-version": 9
"baseline": "1.1.34",
"port-version": 0
},
"libyaml": {
"baseline": "0.2.5",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "1893a874d7cc6d1bfd903ae9a341f9d1e6419b78",
"version-string": "1.1.34",
"port-version": 0
},
{
"git-tree": "210c2ecb911a6c2445806f30a98a3f2c9a9177dc",
"version-string": "1.1.33",