mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-06 17:13:24 -05:00
zotero: Fix build on x86_64-darwin
When setting a non-`source` update channel, the build fails on x86_64-darwin. The build fails with: ``` source not found twice in ChannelPrefs source stringWithCString:encoding: ``` Which definitely means it is caused by the strings command here. When manually executing the strings command on the file, I can repeat getting only one `source` result on x86 mac, while getting two on arm64 or linux. After digging around, I tried with the flag `-arch all`, and both `source` values are found on x86 mac. Full command: `strings -n 3 -arch all $binary`. Also reported to upstream in https://github.com/zotero/zotero/pull/5926
This commit is contained in:
parent
e12e834060
commit
96a484e28e
2 changed files with 14 additions and 0 deletions
13
pkgs/by-name/zo/zotero/fix-x86_64-darwin.patch
Normal file
13
pkgs/by-name/zo/zotero/fix-x86_64-darwin.patch
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
diff --git a/app/mac/set-channel-prefs-channel b/app/mac/set-channel-prefs-channel
|
||||
index 2431837584..ab85d7e5c0 100755
|
||||
--- a/app/mac/set-channel-prefs-channel
|
||||
+++ b/app/mac/set-channel-prefs-channel
|
||||
@@ -19,7 +19,7 @@ binary=$1
|
||||
from_channel=$2
|
||||
to_channel=$3
|
||||
# `strings` has a 4-character minimum by default, but we need 3 for 'dev'
|
||||
-strings_cmd="strings -n 3"
|
||||
+strings_cmd="strings -n 3 -arch all"
|
||||
|
||||
if [ ${#to_channel} -gt 7 ]; then
|
||||
echo "Channel length cannot exceed 7 characters -- aborting" >&2
|
||||
|
|
@ -193,6 +193,7 @@ buildNpmPackage (finalAttrs: {
|
|||
./js-build-fixes.patch
|
||||
./avoid-xulrunner-fetch.patch
|
||||
./build-fixes.patch
|
||||
./fix-x86_64-darwin.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue