From: Mark Wielaard Date: Sun, 7 Apr 2019 21:59:54 +0000 (+0200) Subject: Install dhat viewer files in libexec. X-Git-Tag: VALGRIND_3_15_0~20 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8a97bdbb1bdeebbc68e30934ed4f5f002b434039;p=thirdparty%2Fvalgrind.git Install dhat viewer files in libexec. libexec seems a better location than libdir. libexec is for internal binaries or scripts that are not intended to be executed directly. If we want to change the location again it is now simple. Just change the dhat/Makefile.am dhatdir variable. --- diff --git a/dhat/Makefile.am b/dhat/Makefile.am index e8ddb05164..2aa4ac99e0 100644 --- a/dhat/Makefile.am +++ b/dhat/Makefile.am @@ -8,11 +8,9 @@ EXTRA_DIST = docs/dh-manual.xml dh_view.html dh_view.css dh_view.js # Headers, etc #---------------------------------------------------------------------------- -# Ensure the viewer components get copied into the install tree. Note that -# vglibdir and vglib_DATA are also defined in coregrind/Makefile.am. I don't -# know if that's a problem. Doesn't appear to be. -vglibdir = $(pkglibdir) -vglib_DATA = dh_view.html dh_view.css dh_view.js +# Ensure the viewer components get copied into the install tree. +dhatdir = $(pkglibexecdir) +dhat_DATA = dh_view.html dh_view.css dh_view.js #---------------------------------------------------------------------------- # dhat- @@ -30,6 +28,7 @@ dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_SOURCES = \ dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_CPPFLAGS = \ $(AM_CPPFLAGS_@VGCONF_PLATFORM_PRI_CAPS@) dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_CFLAGS = $(LTO_CFLAGS) \ + -DDHAT_VIEW_DIR=\"$(dhatdir)\" \ $(AM_CFLAGS_@VGCONF_PLATFORM_PRI_CAPS@) dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_DEPENDENCIES = \ $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_PRI_CAPS@) @@ -50,6 +49,7 @@ dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_SOURCES = \ dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_CPPFLAGS = \ $(AM_CPPFLAGS_@VGCONF_PLATFORM_SEC_CAPS@) dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_CFLAGS = $(LTO_CFLAGS) \ + -DDHAT_VIEW_DIR=\"$(dhatdir)\" \ $(AM_CFLAGS_@VGCONF_PLATFORM_SEC_CAPS@) dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_DEPENDENCIES = \ $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_SEC_CAPS@) diff --git a/dhat/dh_main.c b/dhat/dh_main.c index ece2eed771..47a9327bd7 100644 --- a/dhat/dh_main.c +++ b/dhat/dh_main.c @@ -1445,7 +1445,7 @@ static void dh_fini(Int exit_status) // Print a how-to-view-the-profile hint. VG_(umsg)("\n"); VG_(umsg)("To view the resulting profile, open\n"); - VG_(umsg)(" file://%s/%s\n", VG_(libdir), "dh_view.html"); + VG_(umsg)(" file://%s/%s\n", DHAT_VIEW_DIR, "dh_view.html"); VG_(umsg)("in a web browser, click on \"Load...\" " "and then select the file\n"); VG_(umsg)(" %s\n", dhat_out_file);