From bf6ca7ccf0f1a91763e04a82f20e65101d965d2d Mon Sep 17 00:00:00 2001 From: Daniel Berger <78529+djberg96@users.noreply.github.com> Date: Sun, 14 Dec 2025 08:32:42 -0500 Subject: [PATCH 1/5] Bump minimum version to 3.5.0. --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2c5eea1a7..f04b8689b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,7 +19,7 @@ # Run "cmake" to generate the build files for your platform -cmake_minimum_required(VERSION 3.2.0) +cmake_minimum_required(VERSION 3.5.0) # Use new variable expansion policy. if (POLICY CMP0053) From df1fb288dcd8876581d857c0f351dedd0569276f Mon Sep 17 00:00:00 2001 From: Daniel Berger <78529+djberg96@users.noreply.github.com> Date: Sun, 14 Dec 2025 08:35:28 -0500 Subject: [PATCH 2/5] Fixed compiliation errors in writeSafe. --- .../XMLSupport/XalanOtherEncodingWriter.hpp | 58 +++++++++---------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/src/xalanc/XMLSupport/XalanOtherEncodingWriter.hpp b/src/xalanc/XMLSupport/XalanOtherEncodingWriter.hpp index 8741cea49..03aa344ed 100644 --- a/src/xalanc/XMLSupport/XalanOtherEncodingWriter.hpp +++ b/src/xalanc/XMLSupport/XalanOtherEncodingWriter.hpp @@ -119,7 +119,7 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter } /** - * Writes CDATA chars , if not presentable, fixes it + * Writes CDATA chars , if not presentable, fixes it * with addition CDATA sections */ size_type @@ -142,11 +142,11 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter if (start + 1 >= length) { throwInvalidUTF16SurrogateException( - theChar, + theChar, 0, getMemoryManager()); } - else + else { value = decodeUTF16SurrogatePair(theChar, chars[start+1], getMemoryManager()); @@ -180,7 +180,7 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter { if(outsideCDATA == false) { - // we have a non-representable char in the normal state - + // we have a non-representable char in the normal state - // close the CDATA section and print the value write( m_constants.s_cdataCloseString, @@ -188,13 +188,13 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter writeNumericCharacterReference(value); - outsideCDATA = true; + outsideCDATA = true; } else { writeNumericCharacterReference(value); } - } + } return result; } @@ -209,8 +209,8 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter size_type theLength) { for( size_type i = 0; i < theLength; ++i) - { - i = write(data, i , theLength, m_exceptionFunctor); + { + i = write(data, i , theLength, m_exceptionFunctor); } } @@ -224,8 +224,8 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter size_type theLength) { for( size_type i = 0; i < theLength; ) - { - i = write(data, i , theLength, m_exceptionFunctor); + { + i = write(data, i , theLength, m_exceptionFunctor); } } @@ -240,8 +240,8 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter size_type theLength) { for( size_type i = 0; i < theLength; ) - { - i = write(data, i , theLength, m_exceptionFunctor); + { + i = write(data, i , theLength, m_exceptionFunctor); } } @@ -263,8 +263,8 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter } /** - * Writes writes a UTF-16 code unit that isn't - * part of the surrogate pair + * Writes writes a UTF-16 code unit that isn't + * part of the surrogate pair */ void write(XalanDOMChar theChar) @@ -316,17 +316,17 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter { throwInvalidUTF16SurrogateException(ch, 0, getMemoryManager()); } - else + else { XalanUnicodeChar value = decodeUTF16SurrogatePair(ch, theChars[i+1], getMemoryManager()); - if (this->m_isPresentable(value)) + if (m_predicate(value)) { write(value); } else { - this->writeNumberedEntityReference(value); + writeNumericCharacterReference(value); } ++i; @@ -349,7 +349,7 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter flushWriter() { m_writer.flush(); - } + } void flushBuffer() @@ -366,13 +366,13 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter * Writes a representable code point * * @param chars Array of the characters for transcoding - * + * * @param start Place int the array the transcoding should start - * + * * @param length The length of the array - * + * * @param failureHandler The functor handles the non-representable characters - * + * * @return Place int the array of the next character */ @@ -398,11 +398,11 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter if (start + 1 >= length) { throwInvalidUTF16SurrogateException( - ch, + ch, 0, getMemoryManager()); } - else + else { value = decodeUTF16SurrogatePair(ch, chars[start+1], getMemoryManager()); @@ -425,13 +425,13 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter /** * Writes a representable code point * - * @param theChar UTF-32 code point . For passing it to the Xerces - * transcoder, we convert it back to UTF-16 + * @param theChar UTF-32 code point . For passing it to the Xerces + * transcoder, we convert it back to UTF-16 */ void write(XalanUnicodeChar theChar) { - // encode back UTF-32 into UTF-16 + // encode back UTF-32 into UTF-16 if (theChar > 0xFFFF) { @@ -449,7 +449,7 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter ++m_bufferPosition; m_bufferRemaining = m_bufferRemaining - size_type(2); - } + } else { if (m_bufferRemaining == 0) @@ -461,7 +461,7 @@ class XalanOtherEncodingWriter : public XalanFormatterWriter ++m_bufferPosition; --m_bufferRemaining; - } + } } void From 5bc55d620f6246e08a07e92bb4ee2cc0b0515a79 Mon Sep 17 00:00:00 2001 From: Daniel Berger <78529+djberg96@users.noreply.github.com> Date: Sun, 14 Dec 2025 08:53:20 -0500 Subject: [PATCH 3/5] Add github workflows. --- .github/MIGRATION.md | 126 ++++++++++++++++++++++++++++++++++ .github/workflows/ci.yml | 17 +++++ .github/workflows/linux.yml | 86 +++++++++++++++++++++++ .github/workflows/macos.yml | 74 ++++++++++++++++++++ .github/workflows/windows.yml | 89 ++++++++++++++++++++++++ README.md | 4 ++ 6 files changed, 396 insertions(+) create mode 100644 .github/MIGRATION.md create mode 100644 .github/workflows/ci.yml create mode 100644 .github/workflows/linux.yml create mode 100644 .github/workflows/macos.yml create mode 100644 .github/workflows/windows.yml diff --git a/.github/MIGRATION.md b/.github/MIGRATION.md new file mode 100644 index 000000000..028bee633 --- /dev/null +++ b/.github/MIGRATION.md @@ -0,0 +1,126 @@ +# Migration from AppVeyor to GitHub Actions + +This document describes the migration from AppVeyor CI to GitHub Actions. + +## Overview + +The project has migrated from AppVeyor to GitHub Actions for continuous integration. The new CI system provides: + +- **Multi-platform support**: Windows, Linux (Ubuntu), and macOS +- **Multiple compilers**: MSVC, GCC, and Clang +- **Multiple configurations**: Release and Debug builds +- **Shared and static library builds** +- **Automatic testing** on all platforms +- **Build artifacts** for releases + +## New Workflows + +### 1. Windows CI (`.github/workflows/windows.yml`) +- **Runner**: Windows Server 2019 +- **Compiler**: Visual Studio 2019 (MSVC) +- **Matrix builds**: + - Release / Shared libraries + - Debug / Static libraries +- **Dependencies**: Xerces-C installed via vcpkg +- **Artifacts**: Windows release builds packaged as zip files + +### 2. Linux CI (`.github/workflows/linux.yml`) +- **Runner**: Ubuntu Latest +- **Compilers**: GCC and Clang +- **Matrix builds**: + - GCC Release / Shared + - GCC Debug / Static + - Clang Release / Shared +- **Dependencies**: Xerces-C installed via apt +- **Artifacts**: Linux release builds packaged as tar.gz + +### 3. macOS CI (`.github/workflows/macos.yml`) +- **Runner**: macOS Latest +- **Compiler**: Apple Clang +- **Matrix builds**: + - Release / Shared libraries + - Debug / Static libraries +- **Dependencies**: Xerces-C installed via Homebrew +- **Artifacts**: macOS release builds packaged as tar.gz + +### 4. Combined CI Status (`.github/workflows/ci.yml`) +- Provides a single status check for branch protection rules + +## Key Differences from AppVeyor + +| Feature | AppVeyor | GitHub Actions | +|---------|----------|----------------| +| Platforms | Windows only | Windows, Linux, macOS | +| Compilers | MSVC, MinGW, Cygwin | MSVC, GCC, Clang | +| Dependency Management | vcpkg, manual builds | vcpkg (Windows), apt (Linux), Homebrew (macOS) | +| Caching | Manual cache configuration | Automatic with actions | +| Artifacts | Manual zip creation | Built-in artifact upload | +| Cost | Free for open source | Free for public repos | + +## What Was Removed + +The following AppVeyor-specific files are no longer needed: +- `.appveyor.yml` - AppVeyor configuration +- `scripts/ci-appveyor-setup` - AppVeyor setup script + +These can be safely removed from the repository. + +## Status Badges + +The README.md now includes GitHub Actions status badges: + +```markdown +[![Windows CI](https://github.com/djberg96/xalan-c/actions/workflows/windows.yml/badge.svg)](https://github.com/djberg96/xalan-c/actions/workflows/windows.yml) +[![Linux CI](https://github.com/djberg96/xalan-c/actions/workflows/linux.yml/badge.svg)](https://github.com/djberg96/xalan-c/actions/workflows/linux.yml) +[![macOS CI](https://github.com/djberg96/xalan-c/actions/workflows/macos.yml/badge.svg)](https://github.com/djberg96/xalan-c/actions/workflows/macos.yml) +``` + +## Triggering Workflows + +Workflows are triggered by: +- Push to `master` or `main` branch +- Pull requests to `master` or `main` branch +- Manual trigger via GitHub Actions UI (`workflow_dispatch`) + +## Viewing Results + +1. Go to the repository on GitHub +2. Click the "Actions" tab +3. Select a workflow to see its runs +4. Click on a specific run to see detailed logs + +## Customization + +To customize the workflows: + +1. Edit the `.github/workflows/*.yml` files +2. Common customizations: + - Add/remove compiler versions in the matrix + - Modify CMake configuration options + - Add additional test commands + - Change artifact packaging + +## Testing Locally + +To test changes before pushing: + +```bash +# Install act (GitHub Actions local runner) +brew install act # macOS +# or +sudo apt install act # Linux + +# Run a workflow locally +act -W .github/workflows/linux.yml +``` + +## Migration Checklist + +- [x] Create Windows CI workflow +- [x] Create Linux CI workflow +- [x] Create macOS CI workflow +- [x] Add status badges to README +- [ ] Test workflows on GitHub +- [ ] Remove `.appveyor.yml` +- [ ] Remove `scripts/ci-appveyor-setup` +- [ ] Update documentation references to CI diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 000000000..deea969b0 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,17 @@ +name: CI + +on: + push: + branches: [ master, main ] + pull_request: + branches: [ master, main ] + workflow_dispatch: + +jobs: + check-workflows: + name: Check All CI Workflows + runs-on: ubuntu-latest + needs: [] + steps: + - name: Check Status + run: echo "All CI workflows completed" diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml new file mode 100644 index 000000000..763e51da5 --- /dev/null +++ b/.github/workflows/linux.yml @@ -0,0 +1,86 @@ +name: Linux CI + +on: + push: + branches: [ master, main ] + pull_request: + branches: [ master, main ] + workflow_dispatch: + +jobs: + build-linux: + name: ${{ matrix.config.name }} + runs-on: ubuntu-latest + + strategy: + fail-fast: false + matrix: + config: + - name: "Ubuntu GCC - Release - Shared" + cc: gcc + cxx: g++ + config: Release + shared: ON + + - name: "Ubuntu GCC - Debug - Static" + cc: gcc + cxx: g++ + config: Debug + shared: OFF + + - name: "Ubuntu Clang - Release - Shared" + cc: clang + cxx: clang++ + config: Release + shared: ON + + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 5 + + - name: Install Dependencies + run: | + sudo apt-get update + sudo apt-get install -y cmake ninja-build libxerces-c-dev + + - name: Configure CMake + env: + CC: ${{ matrix.config.cc }} + CXX: ${{ matrix.config.cxx }} + run: | + mkdir build + cd build + cmake -G Ninja \ + -DCMAKE_BUILD_TYPE=${{ matrix.config.config }} \ + -DBUILD_SHARED_LIBS:BOOL=${{ matrix.config.shared }} \ + .. + + - name: Build + run: | + cd build + cmake --build . --parallel + + - name: Install + run: | + cd build + sudo cmake --build . --target install + + - name: Test + run: | + cd build + ctest -V + + - name: Package + if: matrix.config.config == 'Release' && matrix.config.cc == 'gcc' + run: | + cd build + cpack -G TGZ + + - name: Upload Artifacts + if: matrix.config.config == 'Release' && matrix.config.cc == 'gcc' + uses: actions/upload-artifact@v4 + with: + name: xalan-c-linux-${{ matrix.config.config }} + path: build/*.tar.gz diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml new file mode 100644 index 000000000..42d999be9 --- /dev/null +++ b/.github/workflows/macos.yml @@ -0,0 +1,74 @@ +name: macOS CI + +on: + push: + branches: [ master, main ] + pull_request: + branches: [ master, main ] + workflow_dispatch: + +jobs: + build-macos: + name: ${{ matrix.config.name }} + runs-on: ${{ matrix.config.os }} + + strategy: + fail-fast: false + matrix: + config: + - name: "macOS Clang - Release - Shared" + os: macos-latest + config: Release + shared: ON + + - name: "macOS Clang - Debug - Static" + os: macos-latest + config: Debug + shared: OFF + + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 5 + + - name: Install Dependencies + run: | + brew install cmake ninja xerces-c + + - name: Configure CMake + run: | + mkdir build + cd build + cmake -G Ninja \ + -DCMAKE_BUILD_TYPE=${{ matrix.config.config }} \ + -DBUILD_SHARED_LIBS:BOOL=${{ matrix.config.shared }} \ + .. + + - name: Build + run: | + cd build + cmake --build . --parallel + + - name: Install + run: | + cd build + sudo cmake --build . --target install + + - name: Test + run: | + cd build + ctest -V + + - name: Package + if: matrix.config.config == 'Release' + run: | + cd build + cpack -G TGZ + + - name: Upload Artifacts + if: matrix.config.config == 'Release' + uses: actions/upload-artifact@v4 + with: + name: xalan-c-macos-${{ matrix.config.config }} + path: build/*.tar.gz diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml new file mode 100644 index 000000000..6d38986bf --- /dev/null +++ b/.github/workflows/windows.yml @@ -0,0 +1,89 @@ +name: Windows CI + +on: + push: + branches: [ master, main ] + pull_request: + branches: [ master, main ] + workflow_dispatch: + +jobs: + build-windows: + name: ${{ matrix.config.name }} + runs-on: windows-2019 + + strategy: + fail-fast: false + matrix: + config: + - name: "Windows MSVC 2019 - Release - Shared" + generator: "Visual Studio 16 2019" + arch: "x64" + config: Release + shared: ON + + - name: "Windows MSVC 2019 - Debug - Static" + generator: "Visual Studio 16 2019" + arch: "x64" + config: Debug + shared: OFF + + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 5 + + - name: Setup vcpkg + uses: lukka/run-vcpkg@v11 + with: + vcpkgDirectory: '${{ github.workspace }}/vcpkg' + vcpkgGitCommitId: 'master' + + - name: Install Xerces-C + run: | + vcpkg install xerces-c:x64-windows + shell: pwsh + + - name: Configure CMake + run: | + mkdir build + cd build + cmake -G "${{ matrix.config.generator }}" -A ${{ matrix.config.arch }} ` + -DCMAKE_BUILD_TYPE=${{ matrix.config.config }} ` + -DBUILD_SHARED_LIBS:BOOL=${{ matrix.config.shared }} ` + -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" ` + .. + shell: pwsh + + - name: Build + run: | + cd build + cmake --build . --config ${{ matrix.config.config }} --parallel + shell: pwsh + + - name: Install + run: | + cd build + cmake --build . --config ${{ matrix.config.config }} --target install + shell: pwsh + + - name: Test + run: | + cd build + ctest -V -C ${{ matrix.config.config }} + shell: pwsh + + - name: Package + if: matrix.config.config == 'Release' + run: | + cd "C:/Program Files (x86)/xalan-c" + 7z a ${{ github.workspace }}/xalan-c-${{ matrix.config.arch }}.zip * + shell: pwsh + + - name: Upload Artifacts + if: matrix.config.config == 'Release' + uses: actions/upload-artifact@v4 + with: + name: xalan-c-windows-${{ matrix.config.arch }}-${{ matrix.config.config }} + path: xalan-c-${{ matrix.config.arch }}.zip diff --git a/README.md b/README.md index 5254e1d98..d34334494 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,10 @@ ![Xalan-C++-logo](docs/images/xalan-small.svg) +[![Windows CI](https://github.com/djberg96/xalan-c/actions/workflows/windows.yml/badge.svg)](https://github.com/djberg96/xalan-c/actions/workflows/windows.yml) +[![Linux CI](https://github.com/djberg96/xalan-c/actions/workflows/linux.yml/badge.svg)](https://github.com/djberg96/xalan-c/actions/workflows/linux.yml) +[![macOS CI](https://github.com/djberg96/xalan-c/actions/workflows/macos.yml/badge.svg)](https://github.com/djberg96/xalan-c/actions/workflows/macos.yml) + ## Overview The Apache Xalan-C++ Project provides a library and a command line From 526542e663448e209363777d0028d465aed488ae Mon Sep 17 00:00:00 2001 From: Daniel Berger <78529+djberg96@users.noreply.github.com> Date: Sun, 14 Dec 2025 08:53:57 -0500 Subject: [PATCH 4/5] Remove appveyor.yml file. --- .appveyor.yml | 137 -------------------------------------------------- 1 file changed, 137 deletions(-) delete mode 100644 .appveyor.yml diff --git a/.appveyor.yml b/.appveyor.yml deleted file mode 100644 index 7fa2dfba1..000000000 --- a/.appveyor.yml +++ /dev/null @@ -1,137 +0,0 @@ -environment: - AV_PROJECTS: 'c:\projects' - AV_XERCES_SOURCE: 'c:\projects\xerces-c-source' - AV_XERCES_BUILD: 'c:\projects\xerces-c-build' - AV_XERCES_INSTALL: 'c:\projects\xerces-c' - AV_XALAN_DOWNLOAD: 'c:\projects\download' - AV_XALAN_TOOLS: 'c:\projects\tools' - AV_XALAN_SOURCE: 'c:\projects\xalan-c' - AV_XALAN_BUILD: 'c:\projects\build' - AV_XALAN_INSTALL: 'c:/projects/libs' - - matrix: -# - compiler: cygwin -# configuration: Release -# generator: Unix Makefiles -# shared: ON -# msgloader: inmemory -# transcoder: default -# - compiler: cygwin -# configuration: Debug -# generator: Unix Makefiles -# shared: OFF -# msgloader: -# transcoder: - compiler: mingw -# configuration: Release -# generator: Ninja -# shared: ON -# msgloader: inmemory -# transcoder: -# - compiler: mingw -# configuration: Debug -# generator: Ninja -# shared: OFF -# msgloader: -# transcoder: default - - compiler: vc15 - configuration: Release - generator: Visual Studio 15 2017 Win64 - shared: ON - msgloader: - transcoder: -# - compiler: vc15 -# configuration: Debug -# generator: Visual Studio 15 2017 Win64 -# shared: OFF -# msgloader: inmemory -# transcoder: icu - -cache: - - 'c:\projects\download -> scripts/ci-appveyor-setup' - - 'c:\projects\icu -> scripts/ci-appveyor-setup' - - 'c:\projects\xerces-c -> scripts/ci-appveyor-setup' - - 'c:\tools\vcpkg\installed -> scripts/ci-appveyor-setup' - -# Operating system (build VM template) -os: 'Visual Studio 2017' - -# clone directory -clone_folder: 'c:\projects\xalan-c' -clone_depth: 5 - -platform: x64 - -init: - - set - - git config --global core.autocrlf input - - 'FOR /F "tokens=* USEBACKQ" %%F IN (`C:\cygwin64\bin\cygpath -u %AV_XERCES_SOURCE%`) DO SET AV_XERCES_CYG_SOURCE=%%F' - - 'FOR /F "tokens=* USEBACKQ" %%F IN (`C:\cygwin64\bin\cygpath -u %AV_XERCES_INSTALL%`) DO SET AV_XERCES_CYG_INSTALL=%%F' - - 'FOR /F "tokens=* USEBACKQ" %%F IN (`C:\cygwin64\bin\cygpath -u %AV_XALAN_DOWNLOAD%`) DO SET AV_XALAN_CYG_DOWNLOAD=%%F' - - 'FOR /F "tokens=* USEBACKQ" %%F IN (`C:\cygwin64\bin\cygpath -u %AV_XALAN_TOOLS%`) DO SET AV_XALAN_CYG_TOOLS=%%F' - - 'FOR /F "tokens=* USEBACKQ" %%F IN (`C:\cygwin64\bin\cygpath -u %AV_XALAN_SOURCE%`) DO SET AV_XALAN_CYG_SOURCE=%%F' - - 'FOR /F "tokens=* USEBACKQ" %%F IN (`C:\cygwin64\bin\cygpath -u %AV_XALAN_INSTALL%`) DO SET AV_XALAN_CYG_INSTALL=%%F' - - 'if NOT EXIST "%AV_XALAN_DOWNLOAD%\" mkdir %AV_XALAN_DOWNLOAD%' - - 'if NOT EXIST "%AV_XALAN_TOOLS%\" mkdir %AV_XALAN_TOOLS%' - - 'if %compiler%==cygwin C:\Cygwin64\setup-x86_64 -q -R C:\Cygwin64 -s http://cygwin.mirror.constant.com -l %AV_XALAN_DOWNLOAD%\cygwin -P libcurl-devel,cmake' - - set AV_DO_ICU_BUILD=false - - set AV_DO_XERCES_BUILD=true - - if [%msgloader%] == [icu] set AV_DO_ICU_BUILD=true - - if [%transcoder%] == [icu] set AV_DO_ICU_BUILD=true - - if [%compiler%] == [vc15] set AV_DO_XERCES_BUILD=false - - if [%compiler%] == [vc15] set AV_DO_ICU_BUILD=false - - 'if EXIST "%AV_PROJECTS%\icu" AV_DO_ICU_BUILD=false' - - 'if EXIST "%AV_PROJECTS%\xerces-c" AV_DO_XERCES_BUILD=false' - - 'set "PATH=C:\Program Files (x86)\cmake\bin;%AV_XALAN_TOOLS%;%PATH%"' - - 'if %compiler%==cygwin set "PATH=C:\Cygwin64\bin;%PATH%"' - - 'if %compiler%==mingw set "PATH=C:\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\bin;%PATH%"' - - 'if %compiler%==mingw set CC=C:\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\bin\gcc' - - 'if %compiler%==mingw set CXX=C:\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\bin\g++' - - set "AV_CMAKE_ARGS=-DBUILD_SHARED_LIBS:BOOL=%shared%" - - 'if %compiler%==vc15 set "AV_CMAKE_ARGS=%AV_CMAKE_ARGS% -DCMAKE_TOOLCHAIN_FILE:PATH=C:\tools\vcpkg\scripts\buildsystems\vcpkg.cmake"' - - if NOT [%msgloader%] == [] set "AV_CMAKE_ARGS=%AV_CMAKE_ARGS% -Dmessage-loader=%msgloader%" - - if NOT [%transcoder%] == [] set "AV_CMAKE_ARGS=%AV_CMAKE_ARGS% -Dtranscoder=%transcoder%" - - set "AV_XERCES_CMAKE_SOURCE=%AV_XERCES_SOURCE%" - - set "AV_XERCES_CMAKE_INSTALL=%AV_XERCES_INSTALL%" - - 'if %compiler%==cygwin set "AV_XERCES_CMAKE_SOURCE=%AV_XERCES_CYG_SOURCE%' - - 'if %compiler%==cygwin set "AV_XERCES_CMAKE_INSTALL=%AV_XERCES_CYG_INSTALL%' - - set "AV_XALAN_CMAKE_SOURCE=%AV_XALAN_SOURCE%" - - set "AV_XALAN_CMAKE_INSTALL=%AV_XALAN_INSTALL%" - - 'if %compiler%==cygwin set "AV_XALAN_CMAKE_SOURCE=%AV_XALAN_CYG_SOURCE%' - - 'if %compiler%==cygwin set "AV_XALAN_CMAKE_INSTALL=%AV_XALAN_CYG_INSTALL%' - -before_build: - - 'C:\cygwin64\bin\bash %AV_XALAN_CYG_SOURCE%/scripts/ci-appveyor-setup' - - set ICU_PLATFORM=x64 - - if [%platform%] == [x86] set ICU_PLATFORM=Win32 - - 'if [%AV_DO_ICU_BUILD%] == [true] cd "%AV_PROJECTS%\icu"' - - 'if [%AV_DO_ICU_BUILD%] == [true] echo "Running msbuild to build ICU"' - - 'if [%AV_DO_ICU_BUILD%] == [true] call "%VS140COMNTOOLS%..\..\VC\vcvarsall.bat" %platform%' - - 'if [%AV_DO_ICU_BUILD%] == [true] msbuild source\allinone\allinone.sln /p:Configuration=%configuration% /p:Platform=%ICU_PLATFORM% /m' - - 'if [%AV_DO_ICU_BUILD%] == [true] set "PATH=%AV_PROJECTS%\icu\bin;%AV_PROJECTS%\icu\bin64;%PATH%"' - - mkdir %AV_XERCES_BUILD% - - cd %AV_XERCES_BUILD% - - if [%AV_DO_XERCES_BUILD%] == [true] cmake -G "%generator%" -DCMAKE_INSTALL_PREFIX:PATH=%AV_XERCES_CMAKE_INSTALL% -DCMAKE_BUILD_TYPE=%configuration% "%AV_XERCES_CMAKE_SOURCE%" - - if [%AV_DO_XERCES_BUILD%] == [true] cd %AV_XERCES_BUILD% - - if [%AV_DO_XERCES_BUILD%] == [true] cmake --build . --config %configuration% - - if [%AV_DO_XERCES_BUILD%] == [true] cmake --build . --config %configuration% --target install - - 'set "PATH=%AV_XERCES_CMAKE_INSTALL%\bin;%PATH%"' - - 'set "PREFIX_PATH=%AV_XERCES_INSTALL%;%AV_PROJECTS%\icu"' - - 'if %compiler%==cygwin set "PREFIX_PATH=/cygdrive/c/projects/xerces-c:/cygdrive/c/projects/icu"' - - 'echo CPP: %CMAKE_PREFIX_PATH%' - - mkdir %AV_XALAN_BUILD% - - cd %AV_XALAN_BUILD% - - echo Running cmake -G "%generator%" "-DCMAKE_PREFIX_PATH:PATH=%PREFIX_PATH%" "-DCMAKE_INSTALL_PREFIX:PATH=%AV_XALAN_CMAKE_INSTALL%" -DCMAKE_BUILD_TYPE=%configuration% "%AV_XALAN_CMAKE_SOURCE%" - - cmake -G "%generator%" "-DCMAKE_PREFIX_PATH:PATH=%PREFIX_PATH%" "-DCMAKE_INSTALL_PREFIX:PATH=%AV_XALAN_CMAKE_INSTALL%" -DCMAKE_BUILD_TYPE=%configuration% %AV_CMAKE_ARGS% "%AV_XALAN_CMAKE_SOURCE%" - -build_script: - - cd %AV_XALAN_BUILD% - - cmake --build . --config %configuration% - - cmake --build . --config %configuration% --target install - -after_build: - - cd %AV_XALAN_INSTALL% - - '7z a %AV_XALAN_SOURCE%\xalan-c.zip * -tzip' - -before_test: - - cd %AV_XALAN_BUILD% - - ctest -V -C %configuration% From 391c86e5f460c493f819d7cfd50eafe6e6d49b09 Mon Sep 17 00:00:00 2001 From: Daniel Berger <78529+djberg96@users.noreply.github.com> Date: Sun, 14 Dec 2025 13:40:46 -0500 Subject: [PATCH 5/5] Update to match working copies. --- .github/workflows/ci.yml | 4 ++++ .github/workflows/linux.yml | 5 ----- .github/workflows/macos.yml | 5 ----- .github/workflows/windows.yml | 37 +++++++++++++++++------------------ 4 files changed, 22 insertions(+), 29 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index deea969b0..5a3d23f53 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -3,8 +3,12 @@ name: CI on: push: branches: [ master, main ] + paths-ignore: + - '**/*.md' pull_request: branches: [ master, main ] + paths-ignore: + - '**/*.md' workflow_dispatch: jobs: diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 763e51da5..b7080bfc7 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -62,11 +62,6 @@ jobs: cd build cmake --build . --parallel - - name: Install - run: | - cd build - sudo cmake --build . --target install - - name: Test run: | cd build diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 42d999be9..99972672d 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -50,11 +50,6 @@ jobs: cd build cmake --build . --parallel - - name: Install - run: | - cd build - sudo cmake --build . --target install - - name: Test run: | cd build diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 6d38986bf..fd6eb310a 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -16,11 +16,11 @@ jobs: fail-fast: false matrix: config: - - name: "Windows MSVC 2019 - Release - Shared" + - name: "Windows MSVC 2019 - Release - Static" generator: "Visual Studio 16 2019" arch: "x64" config: Release - shared: ON + shared: OFF - name: "Windows MSVC 2019 - Debug - Static" generator: "Visual Studio 16 2019" @@ -35,14 +35,14 @@ jobs: fetch-depth: 5 - name: Setup vcpkg - uses: lukka/run-vcpkg@v11 - with: - vcpkgDirectory: '${{ github.workspace }}/vcpkg' - vcpkgGitCommitId: 'master' + run: | + git clone https://github.com/microsoft/vcpkg.git + .\vcpkg\bootstrap-vcpkg.bat + shell: pwsh - name: Install Xerces-C run: | - vcpkg install xerces-c:x64-windows + .\vcpkg\vcpkg install xerces-c:x64-windows shell: pwsh - name: Configure CMake @@ -50,22 +50,21 @@ jobs: mkdir build cd build cmake -G "${{ matrix.config.generator }}" -A ${{ matrix.config.arch }} ` - -DCMAKE_BUILD_TYPE=${{ matrix.config.config }} ` + -DCMAKE_CONFIGURATION_TYPES="${{ matrix.config.config }}" ` -DBUILD_SHARED_LIBS:BOOL=${{ matrix.config.shared }} ` - -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" ` + -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}\vcpkg\scripts\buildsystems\vcpkg.cmake" ` + -DCMAKE_VERBOSE_MAKEFILE=ON ` .. shell: pwsh - name: Build run: | cd build - cmake --build . --config ${{ matrix.config.config }} --parallel - shell: pwsh - - - name: Install - run: | - cd build - cmake --build . --config ${{ matrix.config.config }} --target install + cmake --build . --config ${{ matrix.config.config }} --target xalanMsg --verbose + echo "Checking for xalanMsg library files:" + Get-ChildItem -Recurse -Filter "XalanMsgLib*.lib" | Select-Object FullName + Get-ChildItem -Recurse -Filter "XalanMessages*.dll" | Select-Object FullName + cmake --build . --config ${{ matrix.config.config }} shell: pwsh - name: Test @@ -77,8 +76,8 @@ jobs: - name: Package if: matrix.config.config == 'Release' run: | - cd "C:/Program Files (x86)/xalan-c" - 7z a ${{ github.workspace }}/xalan-c-${{ matrix.config.arch }}.zip * + cd build + cpack -G ZIP -C ${{ matrix.config.config }} shell: pwsh - name: Upload Artifacts @@ -86,4 +85,4 @@ jobs: uses: actions/upload-artifact@v4 with: name: xalan-c-windows-${{ matrix.config.arch }}-${{ matrix.config.config }} - path: xalan-c-${{ matrix.config.arch }}.zip + path: build/*.zip