···1-From 7e75779eaeacdbb46a387a59d9aaf1481a1da3e5 Mon Sep 17 00:00:00 2001
2-From: Adrian Gierakowski <agierakowski@gmail.com>
3-Date: Sun, 19 Jul 2020 08:38:05 +0100
4-Subject: [PATCH] fix dirent64 et al on darwin
5-6----
7- configure.ac | 11 +++++++++++
8- 1 file changed, 11 insertions(+)
9-10-diff --git a/configure.ac b/configure.ac
11-index b8faca9..cee1e4d 100644
12---- a/configure.ac
13-+++ b/configure.ac
14-@@ -139,6 +139,7 @@ if test "$ac_cv_func_signal" != yes; then
15- [klibc has bsd_signal instead of signal])])
16- fi
17-18-+dnl TODO: stat64 is deprecated since macOS 10.6
19- dnl Check for stat64 (dietlibc/klibc).
20- AC_CHECK_FUNC(stat64,, [
21- AC_DEFINE(fstat64, fstat, [64-bit operations are the same as 32-bit])
22-@@ -155,6 +156,16 @@ AC_CHECK_FUNC(open64,, [
23- AC_DEFINE(open64, open, [64-bit operations are the same as 32-bit])
24- ])
25-26-+dnl OS X apparently has stat64 but not readdir64.
27-+AC_CHECK_FUNC(readdir64,, [
28-+ AC_DEFINE(readdir64, readdir, [64-bit operations are the same as 32-bit])
29-+])
30-+
31-+dnl OS X apparently has stat64 but not dirent64.
32-+AC_CHECK_TYPE(struct dirent64,, [
33-+ AC_DEFINE(dirent64, dirent, [64-bit operations are the same as 32-bit])
34-+],[#include <dirent.h>])
35-+
36- dnl Check if struct stat has st_mtim.
37- AC_MSG_CHECKING(for stat::st_mtim)
38- AC_COMPILE_IFELSE(
39---
40-2.15.1
41-
···1819 makeFlags = [ "AR=${stdenv.cc.bintools.targetPrefix}ar" ];
200000021 meta = {
22 description = "A client for the WHOIS protocol allowing you to query the owner of a domain name";
23 homepage = "https://www.gnu.org/software/jwhois/";
···1819 makeFlags = [ "AR=${stdenv.cc.bintools.targetPrefix}ar" ];
2021+ # Work around error from <stdio.h> on aarch64-darwin:
22+ # error: 'TARGET_OS_IPHONE' is not defined, evaluates to 0 [-Werror,-Wundef-prefix=TARGET_OS_]
23+ # TODO: this should probably be fixed at a lower level than this?
24+ NIX_CFLAGS_COMPILE = lib.optional stdenv.isDarwin "-Wno-undef-prefix";
25+26 meta = {
27 description = "A client for the WHOIS protocol allowing you to query the owner of a domain name";
28 homepage = "https://www.gnu.org/software/jwhois/";
+8-2
pkgs/tools/package-management/rpm/default.nix
···36 "--sharedstatedir=/com"
37 ];
3839- # Small fixes for ndb on darwin
40- # https://github.com/rpm-software-management/rpm/pull/1465
41 patches = [
0042 (fetchpatch {
43 name = "darwin-support.patch";
44 url = "https://github.com/rpm-software-management/rpm/commit/2d20e371d5e38f4171235e5c64068cad30bda557.patch";
45 sha256 = "0p3j5q5a4hl357maf7018k3826jhcpqg6wfrnccrkv30g0ayk171";
00000046 })
47 ];
48