summaryrefslogtreecommitdiff
blob: d78317da0b3c3b217136ba1799d9e36270195323 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
From 8208f99fa1676c42bfd8d74de3e9dac5366c150c Mon Sep 17 00:00:00 2001
From: Akira TAGOH <akira@tagoh.org>
Date: Mon, 3 Sep 2018 04:56:16 +0000
Subject: [PATCH] Fix the build issue with --enable-static

Fixes https://gitlab.freedesktop.org/fontconfig/fontconfig/issues/109
--- a/fontconfig/fontconfig.h
+++ b/fontconfig/fontconfig.h
@@ -1076,6 +1076,10 @@ FcUtf16Len (const FcChar8   *string,
 	    int		    *nchar,
 	    int		    *wchar);
 
+FcPublic FcChar8 *
+FcStrBuildFilename (const FcChar8 *path,
+		    ...);
+
 FcPublic FcChar8 *
 FcStrDirname (const FcChar8 *file);
 
--- a/src/fcint.h
+++ b/src/fcint.h
@@ -1282,10 +1282,6 @@ FcStrUsesHome (const FcChar8 *s);
 FcPrivate FcBool
 FcStrIsAbsoluteFilename (const FcChar8 *s);
 
-FcPrivate FcChar8 *
-FcStrBuildFilename (const FcChar8 *path,
-		    ...);
-
 FcPrivate FcChar8 *
 FcStrLastSlash (const FcChar8  *path);
 
--- a/test/test-bz106632.c
+++ b/test/test-bz106632.c
@@ -25,25 +25,26 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
+#include <stdio.h>
 #include <stdlib.h>
+#include <string.h>
 #include <dirent.h>
+#include <unistd.h>
+#include <errno.h>
 #ifndef HAVE_STRUCT_DIRENT_D_TYPE
 #include <sys/types.h>
 #include <sys/stat.h>
-#include <unistd.h>
 #endif
-#include "fcstr.c"
-#undef FcConfigBuildFonts
-#undef FcConfigCreate
-#undef FcConfigGetCurrent
-#undef FcConfigParseAndLoadFromMemory
-#undef FcConfigUptoDate
-#undef FcFontList
-#undef FcInitReinitialize
-#undef FcPatternCreate
-#undef FcPatternDestroy
 #include <fontconfig/fontconfig.h>
 
+#ifdef _WIN32
+#  define FC_DIR_SEPARATOR         '\\'
+#  define FC_DIR_SEPARATOR_S       "\\"
+#else
+#  define FC_DIR_SEPARATOR         '/'
+#  define FC_DIR_SEPARATOR_S       "/"
+#endif
+
 #ifdef HAVE_MKDTEMP
 #define fc_mkdtemp	mkdtemp
 #else
@@ -154,18 +155,6 @@ unlink_dirs (const char *dir)
     return ret;
 }
 
-FcChar8 *
-FcLangNormalize (const FcChar8 *lang)
-{
-    return NULL;
-}
-
-FcChar8 *
-FcConfigHome (void)
-{
-    return NULL;
-}
-
 int
 main (void)
 {