Skip to content
This repository has been archived by the owner on Sep 8, 2020. It is now read-only.

Allow to override ncurses*-config path #524

Conversation

ricardo-martincoski
Copy link

This will be used when cross-compiling with ncurses*-config generated for the
target, using constructs like
htop_ncurses_config_script=/path/to/ncurses5-config

Signed-off-by: Ricardo Martincoski ricardo.martincoski@gmail.com

@@ -147,7 +147,11 @@ fi
# HTOP_CHECK_SCRIPT(LIBNAME, FUNCTION, DEFINE, CONFIG_SCRIPT, ELSE_PART)
m4_define([HTOP_CHECK_SCRIPT],
[
htop_config_script=$([$4] --libs 2> /dev/null)
if test ! -z "$htop_[$1]_config_script"; then
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please make the name of this variable all-uppercase (as in HTOP_[$1]_CONFIG_SCRIPT). the htop_* versions were meant to be "local" variables for the macro. Adding a short comment here explaining this was motivated by cross-compiling scenarios would also be welcome, for future maintenance.

This will be used when cross-compiling with ncurses*-config generated for the
target, using constructs like
HTOP_NCURSES_CONFIG_SCRIPT=/path/to/ncurses5-config

Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com>
@@ -147,7 +147,12 @@ fi
# HTOP_CHECK_SCRIPT(LIBNAME, FUNCTION, DEFINE, CONFIG_SCRIPT, ELSE_PART)
m4_define([HTOP_CHECK_SCRIPT],
[
htop_config_script=$([$4] --libs 2> /dev/null)
if test ! -z "m4_toupper($HTOP_[$1]_CONFIG_SCRIPT)"; then

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I used
m4_toupper($HTOP_[$1]CONFIG_SCRIPT)
because I think it is more readable, but I can change to
$HTOP
[]m4_toupper($1)_CONFIG_SCRIPT
if you want

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks fine!

@hishamhm hishamhm merged commit 265d048 into hishamhm:master Jul 12, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants