Skip to content

Commit 6ee4be5

Browse files
adamcinjamesbvaughan
authored andcommitted
changes to get macos prebuild to pass on arm64 local machine
1 parent 58f7fa1 commit 6ee4be5

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

.github/workflows/prebuild.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ jobs:
8383
npm install nan
8484
. prebuild/macOS/preinstall.sh
8585
cp prebuild/macOS/binding.gyp binding.gyp
86-
node-gyp rebuild -j 2 --arch=${{ runner.arch }}
86+
node-gyp rebuild -j 2 --arch=${{ matrix.os.arch }}
8787
. prebuild/macOS/bundle.sh
8888
8989
- name: Test binary

prebuild/macOS/binding.gyp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@
3434
'<!@(pkg-config pangocairo --libs)',
3535
'<!@(pkg-config freetype2 --libs)',
3636
'<!@(pkg-config librsvg-2.0 --libs)',
37-
'-ljpeg',
37+
'<!@(pkg-config libjpeg --libs)',
38+
'-L/opt/homebrew/lib',
3839
'-lgif'
3940
],
4041
'include_dirs': [
@@ -43,7 +44,8 @@
4344
'<!@(pkg-config libpng --cflags-only-I | sed s/-I//g)',
4445
'<!@(pkg-config pangocairo --cflags-only-I | sed s/-I//g)',
4546
'<!@(pkg-config freetype2 --cflags-only-I | sed s/-I//g)',
46-
'<!@(pkg-config librsvg-2.0 --cflags-only-I | sed s/-I//g)'
47+
'<!@(pkg-config librsvg-2.0 --cflags-only-I | sed s/-I//g)',
48+
'/opt/homebrew/include'
4749
],
4850
'cflags+': ['-fvisibility=hidden'],
4951
'xcode_settings': {

prebuild/macOS/preinstall.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ rm -f /usr/local/bin/python3-config || :
1010

1111
# two or more of these packages have python3 as a dependency, and --overwrite
1212
# doesn't work to make them ignore conflicts. For now just ignore errors, yolo.
13-
brew install --force pkg-config cairo pango librsvg giflib || :
13+
brew install --force pkg-config cairo pango jpeg libpng librsvg giflib pixman || :
1414

1515
pip3 install --user --break-system-packages macpack

0 commit comments

Comments
 (0)