Skip to content

Commit

Permalink
Update Alpine build
Browse files Browse the repository at this point in the history
  • Loading branch information
ronaldtse committed Mar 22, 2022
1 parent f86126c commit b48ea5b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/alpine-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ jobs:
libxml2-utils libpng-dev freetype-dev fontconfig-dev git valgrind
- name: Configure CMake
# env:
# CC: clang
# CXX: clang++
env:
CC: gcc
CXX: g++
run: |
cmake -B ${{github.workspace}} \
-DVCPKG_TARGET_TRIPLET=x86_64-alpine-linux-musl
Expand Down
7 changes: 4 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -138,15 +138,15 @@ if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
add_definitions(-DDARWIN)
endif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")

# Locate fontconfig
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/FindFontconfig.cmake)

# Find/build external dependencies if it is Microsoft Visual Studio build
if(MSVC)
find_package(Iconv REQUIRED)
set(EXTERNAL_ICONV ${Iconv_LIBRARY})
endif(MSVC)

# Locate fontconfig, somehow the find_package call can't find it?
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/FindFontconfig.cmake)

if(MSVC OR ALPINE)
set(ARGP_NAME argp${EXTERNAL_LIB_DIR_SUFFIX})
ExternalProject_Add(${ARGP_NAME}
Expand All @@ -157,6 +157,7 @@ if(MSVC OR ALPINE)
PATCH_COMMAND cd ${DEPS}/src/${ARGP_NAME} && git restore CMakeLists.txt && git apply ${PATCHES}/argp/CMakeLists.txt.patch
)
set(EXTERNAL_ARGP "argp-standalone")
add_compile_options(-fPIC)
endif(MSVC OR ALPINE)

# headers & library directories
Expand Down

0 comments on commit b48ea5b

Please sign in to comment.