From 3d180f47a0f955ee52215027e7bed2f655206944 Mon Sep 17 00:00:00 2001 From: Jake Lilly Date: Sat, 5 Oct 2024 15:21:49 -0400 Subject: [PATCH] Update lflags for homebrew on Apple Silicon --- README.md | 2 +- dub.sdl | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index adcd957..553bcbb 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,7 @@ versions "NCURSES_REENTRANT" ## Building on macOS -The stock ncurses libraries on macOS don't include the wide libraries. Thus the full ncurses version needs to be installed with [Homebrew](https://brew.sh/). Homebrew installs ncurses below ```/usr/local/opt/ncurses```, where the dub configuration will pick it up. +The stock ncurses libraries on macOS don't include the wide libraries. Thus the full ncurses version needs to be installed with [Homebrew](https://brew.sh/). Homebrew installs ncurses below ```/usr/local/opt/ncurses``` (macOS Intel) or ```/opt/homebrew/opt/ncurses``` (Apple Silicon), where the dub configuration will pick it up. First install Homebrew using the instructions on the web site, then you can add the ncurses package with diff --git a/dub.sdl b/dub.sdl index 7b55644..b3b191d 100644 --- a/dub.sdl +++ b/dub.sdl @@ -11,7 +11,8 @@ targetType "sourceLibrary" # .di files only targetName "ncurses-d" # Howebrew installs libncurses here: -lflags "-L/usr/local/opt/ncurses/lib" platform="osx" +lflags "-L/usr/local/opt/ncurses/lib" platform="osx-x86_64" +lflags "-L/opt/homebrew/opt/ncurses/lib" platform="osx-aarch64" configuration "minimal" { libs "ncursesw"