[BACK]Return to patch-src_fcstat.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / fonts / fontconfig / patches

File: [cvs.NetBSD.org] / pkgsrc / fonts / fontconfig / patches / patch-src_fcstat.c (download)

Revision 1.5, Sun Jun 19 20:48:55 2016 UTC (5 years, 5 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2021Q3-base, pkgsrc-2021Q3, pkgsrc-2021Q2-base, pkgsrc-2021Q2, pkgsrc-2021Q1-base, pkgsrc-2021Q1, pkgsrc-2020Q4-base, pkgsrc-2020Q4, pkgsrc-2020Q3-base, pkgsrc-2020Q3, pkgsrc-2020Q2-base, pkgsrc-2020Q2, pkgsrc-2020Q1-base, pkgsrc-2020Q1, pkgsrc-2019Q4-base, pkgsrc-2019Q4, pkgsrc-2019Q3-base, pkgsrc-2019Q3, pkgsrc-2019Q2-base, pkgsrc-2019Q2, pkgsrc-2019Q1-base, pkgsrc-2019Q1, pkgsrc-2018Q4-base, pkgsrc-2018Q4, pkgsrc-2018Q3-base, pkgsrc-2018Q3, pkgsrc-2018Q2-base, pkgsrc-2018Q2, pkgsrc-2018Q1-base, pkgsrc-2018Q1, pkgsrc-2017Q4-base, pkgsrc-2017Q4, pkgsrc-2017Q3-base, pkgsrc-2017Q3, pkgsrc-2017Q2-base, pkgsrc-2017Q2, pkgsrc-2017Q1-base, pkgsrc-2017Q1, pkgsrc-2016Q4-base, pkgsrc-2016Q4, pkgsrc-2016Q3-base, pkgsrc-2016Q3, pkgsrc-2016Q2-base, pkgsrc-2016Q2, HEAD
Changes since 1.4: +9 -9 lines

Updated fontconfig to 2.12.0.

Here is the announcement for the stable release after 2 years, which
many features and bug fixes contains.

Summary of the changes since last stable release is:
- - Support the size specific design selection in OS/2 table version 5
- - Allow the modification on 'lang' and 'charset' objects
- - Increase the refcount in FcConfigSetCurrent()
- - some updates in orth files
- - Add --error-on-no-fonts option to fc-cache
- - Use lang=und instead of lang=xx for "undetermined"
- - Add FC_WEIGHT_DEMILIGHT and change from 65 to 55
- - Add FC_COLOR
- - Treat color fonts as scalable
- - no FC_LANG added with FcConfigSubstitute() when it has "und"
- - Hardcode blanks in library
- - Support symbol fonts
- - Unicode 8.0 support
- - Add hintstyle templates and default hintslight
- - GX font support
- - Improve the footprint issue on updating caches
- - Bump the cache version to 6
- - more bug fixes
- - and more...

$NetBSD: patch-src_fcstat.c,v 1.5 2016/06/19 20:48:55 wiz Exp $

The argument types to scandir(3) differ between different OSes.
OpenBSD seems to be still different. I used the provided alphasort
instead of rewriting the equivalent sorter function.
statvfs and fstatvfs need another include file, at least on MirBSD.

--- src/fcstat.c.orig	2016-04-06 03:22:55.000000000 +0000
+++ src/fcstat.c
@@ -52,6 +52,12 @@ typedef long long INT64;
 #define EPOCH_OFFSET 11644473600i64
 typedef __int64 INT64;
 #endif
+#ifdef __MirBSD__
+#include <sys/statvfs.h>
+#endif
+#if defined(_SCO_DS)
+#include "../scandir.c"
+#endif
 
 /* Workaround for problems in the stat() in the Microsoft C library:
  *
@@ -159,7 +165,11 @@ Adler32Finish (struct Adler32 *ctx)
 #ifdef HAVE_STRUCT_DIRENT_D_TYPE
 /* dirent.d_type can be relied upon on FAT filesystem */
 static FcBool
+# ifdef __MirBSD__
+FcDirChecksumScandirFilter(struct dirent *entry)
+# else
 FcDirChecksumScandirFilter(const struct dirent *entry)
+# endif
 {
     return entry->d_type != DT_DIR;
 }
@@ -263,7 +273,11 @@ FcDirChecksum (const FcChar8 *dir, time_
 #else
 		 NULL,
 #endif
+#ifdef __MirBSD__
+		 &alphasort);
+#else
 		 &FcDirChecksumScandirSorter);
+#endif
     if (n == -1)
 	return -1;