Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions ports/fontconfig/CONTROL

This file was deleted.

2 changes: 1 addition & 1 deletion ports/fontconfig/build2.patch
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ index f0fa0ec50..24e5afd16 100644

$(TOOL): $(TSRC) $(ALIAS_FILES)
- $(AM_V_GEN) $(CC_FOR_BUILD) -o $(TOOL) $< $(AM_CPPFLAGS)
+ $(AM_V_GEN) $(CC_FOR_BUILD) -o $(TOOL) $< $(AM_CPPFLAGS) $(LIBINTL) $(CFLAGS)
+ $(AM_V_GEN) $(CC_FOR_BUILD) -o $(TOOL) $< $(AM_CPPFLAGS) $(LIBINTL) $(CFLAGS_FOR_BUILD)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where does CFLAGS_FOR_BUILD come from, before #15605?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Lucius-Q-User, I didn't find the CFLAGS_FOR_BUILD in fontconfig, so why do you change it?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CFLAGS refers to target system cflags, which can break the build, (e.g -arch flag for clang, or -march/-mcpu flags)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CFLAGS_FOR_BUILD might be set for cross builds after #15605, but for now you miss CFLAGS for native builds.
In addition, $(LIBINTL) can go wrong as well for cross builds.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alternatively, we can update the version of fontconfig that is currently in the tree. Newer versions made fc-case, which is the source of cross-compile problems into a python script.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would it be ok to conditionally include cflags depending on whether we are cross-compiling or not?


$(TARG): $(TMPL) $(TSRC) $(DEPS)
$(AM_V_GEN) $(MAKE) $(TOOL) && \
Expand Down
9 changes: 7 additions & 2 deletions ports/fontconfig/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -98,13 +98,18 @@ file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share
if(NOT VCPKG_TARGET_IS_WINDOWS)
set(ENV{FONTCONFIG_PATH} "${CURRENT_PACKAGES_DIR}/etc/fonts")
set(ENV{FONTCONFIG_FILE} "${CURRENT_PACKAGES_DIR}/etc/fonts/fonts.conf")
vcpkg_execute_required_process(COMMAND "${CURRENT_PACKAGES_DIR}/tools/${PORT}/bin/fc-cache${VCPKG_TARGET_EXECUTABLE_SUFFIX}" --verbose
if("${TARGET_TRIPLET}" STREQUAL "${HOST_TRIPLET}")
set(FC_CACHE_BASE "${CURRENT_PACKAGES_DIR}")
else()
set(FC_CACHE_BASE "${_VCPKG_INSTALLED_DIR}/${HOST_TRIPLET}")
endif()
vcpkg_execute_required_process(COMMAND "${FC_CACHE_BASE}/tools/${PORT}/bin/fc-cache${VCPKG_TARGET_EXECUTABLE_SUFFIX}" --verbose
WORKING_DIRECTORY "${CURRENT_PACKAGES_DIR}/tools/${PORT}/bin"
LOGNAME fc-cache-${TARGET_TRIPLET})
endif()

if(VCPKG_TARGET_IS_WINDOWS)
# Unnecessary make rule creating the fontconfig cache dir on windows.
# Unnecessary make rule creating the fontconfig cache dir on windows.
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}LOCAL_APPDATA_FONTCONFIG_CACHE")
endif()

Expand Down
23 changes: 23 additions & 0 deletions ports/fontconfig/vcpkg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"name": "fontconfig",
"version-string": "2.13.1",
"port-version": 8,
"description": "Library for configuring and customizing font access.",
"homepage": "https://www.freedesktop.org/software/fontconfig/front.html",
"dependencies": [
"dirent",
"expat",
{
"name": "fontconfig",
"host": true
},
"freetype",
"json-c",
"libiconv",
{
"name": "libuuid",
"platform": "!windows & !osx & !mingw"
},
"pthread"
]
}
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -2098,7 +2098,7 @@
},
"fontconfig": {
"baseline": "2.13.1",
"port-version": 7
"port-version": 8
},
"foonathan-memory": {
"baseline": "2019-07-21-1",
Expand Down
5 changes: 5 additions & 0 deletions versions/f-/fontconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "7b8de891f5ef8e60bb971e2d7af4b7687537d3d3",
"version-string": "2.13.1",
"port-version": 8
},
{
"git-tree": "e28c20718e723ea702e408f52f76343950b1a3f2",
"version-string": "2.13.1",
Expand Down