Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // swift-tools-version:5.0
- import PackageDescription
- let package = Package(
- name: "NcursesExample",
- products: [
- .executable(name: "NcursesExample", targets: ["NcursesExample"]),
- ],
- dependencies: [
- ],
- targets: [
- .systemLibrary(name: "Cncurses"),
- .target(name: "NcursesExample", dependencies: ["Cncurses"]),
- ]
- )
- module Cncurses {
- header "shim.h"
- link "ncurses"
- export *
- }
- #include "/usr/local/Cellar/ncurses/6.1/include/ncurses.h"
- shim.h:1:10: note: in file included from shim.h:1:
- #include "/usr/local/Cellar/ncurses/6.1/include/ncurses.h"
- ^
- /usr/local/Cellar/ncurses/6.1/include/ncurses.h:60:10: error: 'ncursesw/ncurses_dll.h' file not found with <angled> include; use "quotes" instead
- #include <ncursesw/ncurses_dll.h>
- ^
- <module-includes>:1:9: note: in file included from <module-includes>:1:
- #import "shim.h"
- ^
- shim.h:1:10: note: in file included from shim.h:1:
- #include "/usr/local/Cellar/ncurses/6.1/include/ncurses.h"
- ^
- /usr/local/Cellar/ncurses/6.1/include/ncurses.h:674:45: error: conflicting types for 'keyname'
- extern NCURSES_EXPORT(NCURSES_CONST char *) keyname (int); /* implemented */
- ^
- /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/curses.h:598:45: note: previous declaration is here
- extern NCURSES_EXPORT(NCURSES_CONST char *) keyname (int); /* implemented */
- ...
- ncurses is keg-only, which means it was not symlinked into /usr/local,
- because macOS already provides this software and installing another version in
- parallel can cause all kinds of trouble.
- If you need to have ncurses first in your PATH run:
- echo 'export PATH="/usr/local/opt/ncurses/bin:$PATH"' >> ~/.zshrc
- For compilers to find ncurses you may need to set:
- export LDFLAGS="-L/usr/local/opt/ncurses/lib"
- export CPPFLAGS="-I/usr/local/opt/ncurses/include"
- For pkg-config to find ncurses you may need to set:
- export PKG_CONFIG_PATH="/usr/local/opt/ncurses/lib/pkgconfig"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement