Hi,

William Allen Simpson wrote on Wed, Aug 02, 2017 at 04:46:38AM -0400:
> I've been using -DCMAKE_C_FLAGS="-O0 -g -gdwarf-4"

I'm curious, do you notice the difference with -O0 and -gdwarf for
debugging?
(honest question, I've never felt bothered, I only have -g from Debug
build type - we might want to add -gdwarf or -ggdb to the build type if
that feels useful)
 
> There's something in our standard cmake that is already setting -Werror.

-Werror is added by CMAKE_BUILD_TYPE (defaults to Debug, which is a
superset of Maintainer with -g)
Maintainer has these:
-Werror -Wall -Wimplicit -Wformat -Wmissing-braces -Wreturn-type
-Wunused-variable -Wuninitialized -Wno-pointer-sign
-Wno-strict-aliasing

> These don't work in the ntirpc cmake:
> CMake Warning:
>   Manually-specified variables were not used by the project:
> 
>     SANITIZE_ADDRESS
>     USE_DBUS
>     USE_MAN_PAGE

Yes, DBUS and MAN_PAGE are really ganesha specific.
SANITIZE_ADDRESS could be ported for ntirpc, but just having the end
binary compiled with it will already do some of the work as it replaces
the allocator functions which will be used in libraries as well.

Compiling ntirpc with it (for example by using the internal module) will
add extra checks though, e.g. if you notice my bot fails on an invalid
read/write in ntirpc itself you might need to do that.


> And Ganesha gives these warnings (note saitizer_add_flags [sic]):

Not a very expensive fix :)

> CMake Warning at cmake/modules/sanitize-helpers.cmake:161 (message):
>   AddressSanitizer disabled for target log because there is no sanitizer
>   available for target sources.
> Call Stack (most recent call first):
>   cmake/modules/FindASan.cmake:58 (saitizer_add_flags)
>   cmake/modules/FindSanitizers.cmake:57 (add_sanitize_address)
>   log/CMakeLists.txt:26 (add_sanitizers)


You're likely missing the libasan package for rhel/fedora
(I don't think we need libasan-static for ganesha)

-- 
Dominique

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Nfs-ganesha-devel mailing list
Nfs-ganesha-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs-ganesha-devel

Reply via email to