Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
c89257fa
Commit
c89257fa
authored
May 01, 2011
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Gather and cleanup debug and profiling configuration
parent
13e78d81
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
66 additions
and
64 deletions
+66
-64
configure.ac
configure.ac
+66
-47
vlc-config.in.in
vlc-config.in.in
+0
-17
No files found.
configure.ac
View file @
c89257fa
...
...
@@ -980,11 +980,76 @@ AC_CACHE_CHECK([for ntohl in sys/param.h],
if test "${ac_cv_c_ntohl_sys_param_h}" != "no"; then
AC_DEFINE(NTOHL_IN_SYS_PARAM_H, 1, Define if <sys/param.h> defines ntohl.)
fi
CFLAGS="${CFLAGS_save}"
EXTEND_HELP_STRING([Optimization options:])
VLC_RESTORE_FLAGS
dnl
dnl Compiler warnings
dnl
RDC_PROG_CC_WFLAGS([all extra sign-compare undef pointer-arith bad-function-cast write-strings missing-prototypes volatile-register-var error-implicit-function-declaration])
RDC_PROG_CC_FLAGS([-pipe])
dnl
dnl Debugging mode
dnl
AC_ARG_ENABLE(debug,
[AS_HELP_STRING([--enable-debug],
[build with run-time assertions and debug symbols (default disabled)])],,
[enable_debug="no"])
AH_TEMPLATE(NDEBUG,
[Define to 1 if debug code should NOT be compiled])
AS_IF([test "${enable_debug}" != "no"], [
AC_CHECK_HEADERS([valgrind/valgrind.h])
CFLAGS="${CFLAGS} -g"
CXXFLAGS="${CXXFLAGS} -g"
OBJCFLAGS="${OBJCFLAGS} -g"
LDFLAGS="${LDFLAGS} -g"
], [
AC_DEFINE(NDEBUG)
])
dnl
dnl Profiling
dnl
AC_ARG_ENABLE(gprof,
[AS_HELP_STRING([--enable-gprof],[profile with gprof (default disabled)])],,
[enable_gprof="no"])
AS_IF([test "${enable_gprof}" != "no"], [
CFLAGS="${CFLAGS} -pg"
CXXFLAGS="${CXXFLAGS} -pg"
OBJCFLAGS="${OBJCFLAGS} -pg"
LDFLAGS="${LDFLAGS} -pg"
])
AC_ARG_ENABLE(cprof,
[AS_HELP_STRING([--enable-cprof],[profile with cprof (default disabled)])],,
[enable_cprof="no"])
AS_IF([test "${enable_gprof}" != "no"], [
CFLAGS="${CFLAGS} -finstrument-functions"
CXXFLAGS="${CXXFLAGS} -finstrument-functions"
OBJCFLAGS="${OBJCFLAGS} -finstrument-functions"
LDFLAGS="${LDFLAGS} -finstrument-functions"
])
dnl
dnl Test coverage
dnl
AC_ARG_ENABLE(coverage,
[AS_HELP_STRING([--enable-coverage],
[build for test coverage (default disabled)])],,
[enable_coverage="no"])
AS_IF([test "${enable_coverage}" != "no"], [
CFLAGS="-fprofile-arcs -ftest-coverage ${CFLAGS}"
CXXFLAGS="-fprofile-arcs -ftest-coverage ${CXXFLAGS}"
LDFLAGS="-lgcov ${LDFLAGS}"
CFLAGS_save="${CFLAGS}"
CXXFLAGS_save="${CXXFLAGS}"
LDFLAGS_save="${LDFLAGS}"
])
VLC_SAVE_FLAGS
dnl Check for various optimization flags
AC_CACHE_CHECK([if \$CC accepts -O4],
[ac_cv_c_o4],
...
...
@@ -1109,16 +1174,6 @@ dnl Check for backtrace() support
AC_CHECK_HEADERS(execinfo.h)
AC_CHECK_FUNCS(backtrace)
dnl
dnl Enable profiling
dnl
AC_ARG_ENABLE(gprof,
[AS_HELP_STRING([--enable-gprof],[profile with gprof (default disabled)])])
AC_ARG_ENABLE(cprof,
[AS_HELP_STRING([--enable-cprof],[profile with cprof (default disabled)])])
test "${enable_gprof}" != "yes" && enable_gprof="no"
test "${enable_cprof}" != "yes" && enable_cprof="no"
dnl
dnl default modules
dnl
...
...
@@ -1140,7 +1195,6 @@ fi
dnl
dnl Accelerated modules
dnl
EXTEND_HELP_STRING([Optimization options:])
dnl Check for fully working MMX intrinsics
dnl We need support for -mmmx, we need <mmintrin.h>, and we also need a
...
...
@@ -1534,21 +1588,6 @@ if test "${enable_optimizations}" != "no"; then
enable_optimizations="speed"
fi
dnl
dnl Debugging mode
dnl
AC_ARG_ENABLE(debug,
[AS_HELP_STRING([--enable-debug],
[check assertions at run-time (default disabled)])])
test "${enable_debug}" != "yes" && enable_debug="no"
AH_TEMPLATE(NDEBUG,
[Define to 1 if debug code should NOT be compiled])
AS_IF([test "x${enable_debug}" = "xno"], [
AC_DEFINE(NDEBUG)
], [
AC_CHECK_HEADERS([valgrind/valgrind.h])
])
dnl
dnl Allow running as root (useful for people running on embedded platforms)
dnl
...
...
@@ -1560,23 +1599,6 @@ AS_IF([test "${enable_run_as_root}" = "yes"],[
[Define to 1 to allow running VLC as root (uid 0).])
])
dnl
dnl Test coverage
dnl
AC_ARG_ENABLE(coverage,
[AS_HELP_STRING([--enable-coverage],
[build for test coverage (default disabled)])],,
[enable_coverage="no"])
AS_IF([test "${enable_coverage}" != "no"], [
CFLAGS="-fprofile-arcs -ftest-coverage ${CFLAGS}"
CXXFLAGS="-fprofile-arcs -ftest-coverage ${CXXFLAGS}"
LDFLAGS="-lgcov ${LDFLAGS}"
dnl ugly...
CFLAGS_save="${CFLAGS}"
CXXFLAGS_save="${CXXFLAGS}"
LDFLAGS_save="${LDFLAGS}"
])
dnl
dnl Stream output
dnl
...
...
@@ -4376,9 +4398,6 @@ version : ${VERSION}
system : ${SYS}
architecture : ${ARCH}
build flavour : "
test "${enable_debug}" = "yes" && printf "debug "
test "${enable_cprof}" = "yes" && printf "cprof "
test "${enable_gprof}" = "yes" && printf "gprof "
test "${enable_optimizations}" != "no" && printf ${enable_optimizations}
echo ""
if test "${enable_vlc}" != "no"; then
...
...
vlc-config.in.in
View file @
c89257fa
...
...
@@ -84,23 +84,6 @@ cppflags="${cppflags} -D_FILE_OFFSET_BITS=64 -D__USE_UNIX98 -D_REENTRANT -D_THRE
#
# Various additional defines
#
if [ "${debug}" = yes ]; then
cflags="${cflags} -g"
cxxflags="${cxxflags} -g"
objcflags="${objcflags} -g"
ldflags="${ldflags} -g"
fi
if [ "${cprof}" = yes ]; then
cflags="${cflags} -finstrument-functions"
cxxflags="${cxxflags} -finstrument-functions"
objcflags="${objcflags} -finstrument-functions"
fi
if [ "${gprof}" = yes ]; then
cflags="${cflags} -pg"
cxxflags="${cxxflags} -pg"
objcflags="${objcflags} -pg"
ldflags="${ldflags} -pg"
fi
if [ "${optim}" = speed ]; then
cflags="${cflags} ${cflags_optim_speed} ${cflags_tuning}"
cxxflags="${cxxflags} ${cflags_optim_speed} ${cflags_tuning}"
...
...
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