Skip to content

Commit

Permalink
pkg/fontconfig: move defines to fix x86_64-windows targets
Browse files Browse the repository at this point in the history
Some targets were duplicated in the all-targets definition list that
will not build for a Windows target. They're all moved to the
non-Windows configuration. The target now builds against a mingw64
prefix with the appropriate dependencies installed.

Updates #437
  • Loading branch information
raggi committed Oct 18, 2023
1 parent 0eea5f0 commit 5007e90
Showing 1 changed file with 12 additions and 22 deletions.
34 changes: 12 additions & 22 deletions pkg/fontconfig/build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -40,29 +40,13 @@ pub fn build(b: *std.Build) !void {
"-DHAVE_STDLIB_H",
"-DHAVE_STRING_H",
"-DHAVE_UNISTD_H",
"-DHAVE_SYS_STATVFS_H",
"-DHAVE_SYS_PARAM_H",
"-DHAVE_SYS_MOUNT_H",

"-DHAVE_LINK",
"-DHAVE_MKSTEMP",
"-DHAVE_MKOSTEMP",
"-DHAVE__MKTEMP_S",
"-DHAVE_MKDTEMP",
"-DHAVE_GETOPT",
"-DHAVE_GETOPT_LONG",
//"-DHAVE_GETPROGNAME",
//"-DHAVE_GETEXECNAME",
"-DHAVE_RAND",
"-DHAVE_RANDOM",
"-DHAVE_LRAND48",
//"-DHAVE_RANDOM_R",
"-DHAVE_RAND_R",
"-DHAVE_READLINK",
"-DHAVE_FSTATVFS",
"-DHAVE_FSTATFS",
"-DHAVE_LSTAT",
"-DHAVE_MMAP",
"-DHAVE_VPRINTF",

"-DHAVE_FT_GET_BDF_PROPERTY",
Expand Down Expand Up @@ -116,17 +100,23 @@ pub fn build(b: *std.Build) !void {
});
} else {
try flags.appendSlice(&.{
"-DHAVE_SYS_STATVFS_H",
"-DHAVE_SYS_MOUNT_H",
"-DHAVE_FSTATFS",
"-DHAVE_FSTATVFS",
"-DHAVE_GETOPT",
"-DHAVE_GETOPT_LONG",
"-DHAVE_LINK",
"-DHAVE_MKOSTEMP",
"-DHAVE_RANDOM",
"-DHAVE_LRAND48",
"-DHAVE_RAND_R",
"-DHAVE_READLINK",
"-DHAVE_LSTAT",
"-DHAVE_MKDTEMP",
"-DHAVE_MKOSTEMP",
"-DHAVE__MKTEMP_S",
"-DHAVE_MMAP",
"-DHAVE_PTHREAD",
"-DHAVE_RANDOM",
"-DHAVE_RAND_R",
"-DHAVE_READLINK",
"-DHAVE_SYS_MOUNT_H",
"-DHAVE_SYS_STATVFS_H",

"-DFC_CACHEDIR=\"/var/cache/fontconfig\"",
"-DFC_TEMPLATEDIR=\"/usr/share/fontconfig/conf.avail\"",
Expand Down

0 comments on commit 5007e90

Please sign in to comment.