Skip to content

Commit

Permalink
Merge pull request #43 from hmaarrfk/libxml2212
Browse files Browse the repository at this point in the history
Libxml2212
  • Loading branch information
hmaarrfk committed Dec 26, 2023
2 parents 9e3d055 + 8550aa6 commit f1e0ad0
Show file tree
Hide file tree
Showing 14 changed files with 103 additions and 21 deletions.
3 changes: 3 additions & 0 deletions .azure-pipelines/azure-pipelines-linux.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .azure-pipelines/azure-pipelines-osx.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .azure-pipelines/azure-pipelines-win.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions .ci_support/linux_64_.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ alsa_lib:
c_compiler:
- gcc
c_compiler_version:
- '11'
- '12'
cdt_name:
- cos7
channel_sources:
Expand All @@ -13,7 +13,7 @@ channel_targets:
cxx_compiler:
- gxx
cxx_compiler_version:
- '11'
- '12'
dbus:
- '1'
docker_image:
Expand Down Expand Up @@ -45,7 +45,7 @@ libwebp:
libxcb:
- '1.15'
libxml2:
- '2.11'
- '2.12'
nspr:
- '4'
nss:
Expand Down
6 changes: 3 additions & 3 deletions .ci_support/linux_aarch64_.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ alsa_lib:
c_compiler:
- gcc
c_compiler_version:
- '11'
- '12'
cdt_arch:
- aarch64
cdt_name:
Expand All @@ -17,7 +17,7 @@ channel_targets:
cxx_compiler:
- gxx
cxx_compiler_version:
- '11'
- '12'
dbus:
- '1'
docker_image:
Expand Down Expand Up @@ -49,7 +49,7 @@ libwebp:
libxcb:
- '1.15'
libxml2:
- '2.11'
- '2.12'
nspr:
- '4'
nss:
Expand Down
7 changes: 7 additions & 0 deletions .ci_support/migrations/libxml2212.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
__migrator:
build_number: 1
kind: version
migration_number: 1
libxml2:
- '2.12'
migrator_ts: 1700445986.2150207
15 changes: 12 additions & 3 deletions .scripts/build_steps.sh

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .scripts/run_docker_build.sh

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 10 additions & 3 deletions .scripts/run_osx_build.sh

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 12 additions & 2 deletions .scripts/run_win_build.bat

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 2 additions & 5 deletions recipe/conda_build_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,8 @@ MACOSX_DEPLOYMENT_TARGET: # [osx and x86_64]
- '10.13' # [osx and x86_64]
MACOSX_SDK_VERSION: # [osx and x86_64]
- '10.14' # [osx and x86_64]
c_compiler_version: # [unix]
# downgraded in #27 for reasons that aren't apparent
- 11 # [linux]
c_compiler_version: # [osx]
# clang 16 errors on incompatible function pointers
- 15 # [osx]
cxx_compiler_version: # [unix]
- 11 # [linux]
cxx_compiler_version: # [osx]
- 15 # [osx]
20 changes: 19 additions & 1 deletion recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,30 @@ source:
# https://github.com/Homebrew/homebrew-core/pull/114739/files
- patches/qt5-webengine-xcode14.diff

# hmaarrfk - 2023/12
# I generated this patch when I updated the compilers on linux from 11 to 12
# during the libxml2212 migration
# https://github.com/conda-forge/qt-webengine-feedstock/pull/43/files
#
# Due to the limited access I have to osx and windows, I decided to only
# apply this patch to linux.
#
# In searching the source for std::begin, it seemed like there were 100s
# of occurances of its usage. I thus designed a command to help in its
# replacement.
# However, after applying the patch to the first error, it seemed like it worked.
#
# This patch was generated with
# sed -i'' 's/std::begin[[:space:]]*(\([^)]*\))/(\1)/g' src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp
# sed -i'' 's/std::end[[:space:]]*(\([^)]*\))/(\1 + sizeof(\1) \/ sizeof(\1[0]))/g' src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp
- patches/cxx17_support_std_begin_std_end.patch # [linux]

- url: https://download.qt.io/development_releases/gnuwin32/gnuwin32.zip # [win]
folder: gnuwin32 # [win]
sha256: 4a9dc893cc0a1695a16102a42ef47ef2e228652891f4afea67fadd452b63656b # [win]

build:
number: 4
number: 5
detect_binary_files_with_prefix: true
run_exports:
- {{ pin_subpackage('qt-webengine', max_pin='x.x') }}
Expand Down
22 changes: 22 additions & 0 deletions recipe/patches/cxx17_support_std_begin_std_end.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
diff --git a/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp b/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp
index 7260365..98a1de5 100644
--- a/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp
+++ b/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp
@@ -297,14 +297,14 @@ static constexpr struct ColorRec {
};

const char* SkParse::FindNamedColor(const char* name, size_t len, SkColor* color) {
- const auto rec = std::lower_bound(std::begin(gColorNames),
- std::end (gColorNames),
+ const auto rec = std::lower_bound((gColorNames),
+ (gColorNames + sizeof(gColorNames) / sizeof(gColorNames[0])),
name, // key
[](const char* name, const char* key) {
return strcmp(name, key) < 0;
});

- if (rec == std::end(gColorNames) || 0 != strcmp(name, *rec)) {
+ if (rec == (gColorNames + sizeof(gColorNames) / sizeof(gColorNames[0])) || 0 != strcmp(name, *rec)) {
return nullptr;
}

0 comments on commit f1e0ad0

Please sign in to comment.