Ports: Install ncurses headers into the main include directory

This commit is contained in:
Tim Schumacher 2022-05-08 23:19:13 +02:00 committed by Andreas Kling
parent 06c6c046f3
commit 749d0eef7f
3 changed files with 6 additions and 3 deletions

View file

@ -9,5 +9,3 @@ build() {
run make \
production=true
}
export CPPFLAGS="-I${SERENITY_INSTALL_ROOT}/usr/local/include/ncurses"

View file

@ -11,5 +11,4 @@ auth_type="sig"
auth_import_key="BFD009061E535052AD0DF2150D28D4D2A0ACE884"
auth_opts=("nano-${version}.tar.xz.asc" "nano-${version}.tar.xz")
export CPPFLAGS="-I${SERENITY_INSTALL_ROOT}/usr/local/include/ncurses"
export PKG_CONFIG_PATH="${SERENITY_INSTALL_ROOT}/usr/local/lib/pkgconfig"

View file

@ -87,4 +87,10 @@ post_install() {
# Target folder has to be removed, otherwise we will get `/usr/local/include/ncurses/ncursesw`.
rm -rf "${SERENITY_INSTALL_ROOT}/usr/local/include/ncurses"
ln -svf ncursesw "${SERENITY_INSTALL_ROOT}/usr/local/include/ncurses"
# Compatibility symlink for ports that expect `/usr/local/include/curses.h` and friends.
# FIXME: Is there a logical explanation for all of this? If so, we should clean it up at some point.
for file in $(ls "${SERENITY_INSTALL_ROOT}/usr/local/include/ncursesw"); do
ln -svf ncursesw/${file} "${SERENITY_INSTALL_ROOT}/usr/local/include/${file}"
done
}