Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
htop
Commits
aed9b9d1
Commit
aed9b9d1
authored
Feb 04, 2015
by
Hisham Muhammad
Browse files
Test if -Wextra is supported. Closes #155.
parent
83a829a2
Changes
2
Show whitespace changes
Inline
Side-by-side
Makefile.am
View file @
aed9b9d1
...
...
@@ -12,7 +12,7 @@ applications_DATA = htop.desktop
pixmapdir
=
$(datadir)
/pixmaps
pixmap_DATA
=
htop.png
htop_CFLAGS
=
-pedantic
-Wall
-W
extra
-std
=
c99
-rdynamic
-D_XOPEN_SOURCE_EXTENDED
-DSYSCONFDIR
=
\"
$(sysconfdir)
\"
-I
"
$(my_htop_platform)
"
htop_CFLAGS
=
-pedantic
-Wall
$(w
extra
_flag)
-std
=
c99
-rdynamic
-D_XOPEN_SOURCE_EXTENDED
-DSYSCONFDIR
=
\"
$(sysconfdir)
\"
-I
"
$(my_htop_platform)
"
AM_CPPFLAGS
=
-DNDEBUG
myhtopsources
=
AvailableMetersPanel.c CategoriesPanel.c CheckItem.c
\
...
...
configure.ac
View file @
aed9b9d1
...
...
@@ -68,6 +68,19 @@ AC_TRY_COMPILE(AC_INCLUDES_DEFAULT, [char *a; a = strdup("foo"); int i = 0; i++;
AC_MSG_ERROR([htop is written in C99. A newer version of gcc is required.]))
CFLAGS="$save_cflags"
save_cflags="${CFLAGS}"
CFLAGS="$CFLAGS -Wextra"
AC_MSG_CHECKING([if compiler supports -Wextra])
AC_TRY_COMPILE([], [], [
wextra_flag=-Wextra
AC_MSG_RESULT([yes])
],[
wextra_flag=
AC_MSG_RESULT([no])
])
CFLAGS="$save_cflags"
AC_SUBST(wextra_flag)
# Checks for features and flags.
# ----------------------------------------------------------------------
PROCDIR=/proc
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment