Skip to content
Merged
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
27 changes: 27 additions & 0 deletions pkgs/by-name/me/meson/007-darwin-case-sensitivity.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
From a908a574daf8bac10bb2a0ee3771052d2167a85f Mon Sep 17 00:00:00 2001
From: Randy Eckenrode <randy@largeandhighquality.com>
Date: Sun, 3 Dec 2023 15:41:20 -0500
Subject: [PATCH] Fix test failure on Darwin on a case-sensitive fs

This was encountered while looking into an issue with
https://github.com/NixOS/nixpkgs/pull/268583.

I run my Nix store on case-sensitive APFS, so the test fails due to
trying to link `-framework ldap` instead of `-framework LDAP`.
---
test cases/osx/5 extra frameworks/meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test cases/osx/5 extra frameworks/meson.build b/test cases/osx/5 extra frameworks/meson.build
index f6c01e63a1bd..96532846c632 100644
--- a/test cases/osx/5 extra frameworks/meson.build
+++ b/test cases/osx/5 extra frameworks/meson.build
@@ -7,7 +7,7 @@ dep_main = dependency('Foundation')
assert(dep_main.type_name() == 'extraframeworks', 'type_name is ' + dep_main.type_name())

# https://github.com/mesonbuild/meson/issues/10002
-ldap_dep = dependency('ldap', method : 'extraframework')
+ldap_dep = dependency('LDAP', method : 'extraframework')
assert(ldap_dep.type_name() == 'extraframeworks', 'type_name is ' + ldap_dep.type_name())

stlib = static_library('stat', 'stat.c', install : true, dependencies: [opengl_dep, ldap_dep])
21 changes: 8 additions & 13 deletions pkgs/by-name/me/meson/package.nix
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{ lib
, stdenv
, fetchFromGitHub
, fetchpatch
, installShellFiles
, coreutils
, darwin
, libxcrypt
, openldap
, ninja
, pkg-config
, python3
Expand All @@ -14,17 +14,17 @@
}:

let
inherit (darwin.apple_sdk.frameworks) AppKit Cocoa Foundation OpenGL;
inherit (darwin.apple_sdk.frameworks) AppKit Cocoa Foundation LDAP OpenGL;
in
python3.pkgs.buildPythonApplication rec {
pname = "meson";
version = "1.2.3";
version = "1.3.0";

src = fetchFromGitHub {
owner = "mesonbuild";
repo = "meson";
rev = "refs/tags/${version}";
hash = "sha256-dgYYz3tQDG6Z4eE77WO2dXdardxVzzGaFLQ5znPcTlw=";
hash = "sha256-Jt3PWnbv/8P6Rvf3E/Yli2vdtfgx3CmsW+jlc9CK5KA=";
};

patches = [
Expand Down Expand Up @@ -66,15 +66,8 @@ python3.pkgs.buildPythonApplication rec {
# Nixpkgs cctools does not have bitcode support.
./006-disable-bitcode.patch

# Fix passing multiple --define-variable arguments to pkg-config.
# https://github.com/mesonbuild/meson/pull/10670
(fetchpatch {
url = "https://github.com/mesonbuild/meson/commit/d5252c5d4cf1c1931fef0c1c98dd66c000891d21.patch";
hash = "sha256-GiUNVul1N5Fl8mfqM7vA/r1FdKqImiDYLXMVDt77gvw=";
excludes = [
"docs/yaml/objects/dep.yaml"
];
})
# https://github.com/mesonbuild/meson/pull/12587
./007-darwin-case-sensitivity.patch
];

buildInputs = lib.optionals (python3.pythonOlder "3.9") [
Expand All @@ -95,7 +88,9 @@ python3.pkgs.buildPythonApplication rec {
AppKit
Cocoa
Foundation
LDAP
OpenGL
openldap
];

checkPhase = lib.concatStringsSep "\n" ([
Expand Down