|
From: dehe l. <deh...@gm...> - 2007-05-12 15:36:57
|
I am developping a new tool in the valgrind.but I have some problems in
making makefile.
first, I do as the Valgrind manual described:
1. Choose a name for the tool, and an abbreviation that can be used as a
short prefix. We'll use foobar and fb as
an example.
2. Make a new directory foobar/ which will hold the tool.
3. Copy none/Makefile.am into foobar/. Edit it by replacing all occurrences
of the string "none" with
"foobar" and the one occurrence of the string "nl_" with "fb_".
4. Copy none/nl_main.c into foobar/, renaming it as fb_main.c. Edit it by
changing the lines in
pre_clo_init() to something appropriate for the tool. These fields are
used in the startup message, except
for bug_reports_to which is used if a tool assertion fails.
5. Edit Makefile.am <http://makefile.am/>, adding the new directory foobar
to the SUBDIRS variable.
6. Edit configure.in, adding foobar/Makefile to the AC_OUTPUT list.
7. Run:
autogen.sh
./configure --prefix='pwd'/inst
make install
It should automake, configure and compile without errors, putting copies
of the tool in foobar/ and
inst/lib/valgrind/.
*QUESTIONS_0:*
*When autogen.sh,it says: can not find file,why?*
*and I do as follow:*
* # aclocal
# autoheader
# automake -a
# autoconf
# ./configure --prefix=$pwd/inst
# make install*
*But after #aclocal, it says: *
**
/usr/share/aclocal/xml-i18n-tools.m4:24: warning: underquoted definition of
XML_I18N_TOOLS_NEWER_THAN_0_9
run info '(automake)Extending aclocal'
or see http://sources.redhat.com/automake/automake.html#Extending-aclocal
/usr/share/aclocal/xml-i18n-tools.m4:28: warning: underquoted definition of
AC_PROG_XML_I18N_TOOLS
/usr/share/aclocal/xml-i18n-tools.m4:30: warning: underquoted definition of
X18T_PFORG1
/usr/share/aclocal/xml-i18n-tools.m4:32: warning: underquoted definition of
X18T_XML_KIND
/usr/share/aclocal/xml-i18n-tools.m4:34: warning: underquoted definition of
X18T_KEYS_KIND
/usr/share/aclocal/xml-i18n-tools.m4 :135: warning: underquoted definition
of AM_PROG_XML_I18N_TOOLS
/usr/share/aclocal/vorbis.m4:9: warning: underquoted definition of
XIPH_PATH_VORBIS
/usr/share/aclocal/pkg.m4:5: warning: underquoted definition of
PKG_CHECK_MODULES
/usr/share/aclocal/ogg.m4:8: warning: underquoted definition of
XIPH_PATH_OGG
/usr/share/aclocal/libxml.m4:10: warning: underquoted definition of
AM_PATH_XML
/usr/share/aclocal/libxml.m4:205: warning: underquoted definition of
AM_PATH_XML2
/usr/share/aclocal/libmikmod.m4:11: warning: underquoted definition of
AM_PATH_LIBMIKMOD
/usr/share/aclocal/intltool.m4:27: warning: underquoted definition of
AC_PROG_INTLTOOL
' is already registered with AC_CONFIG_FILES.
autoconf/status.m4:848: AC_CONFIG_FILES is expanded from...
configure.in:984: the top level
autom4te: /usr/bin/m4 failed with exit status: 1
aclocal: autom4te failed with exit status: 1
*QUESTIONS_1:*
*why the aclocal failed ?*
*Thanks.*
**
*dehe*
|
|
From: Nicholas N. <nj...@cs...> - 2007-05-12 23:45:56
|
On Sat, 12 May 2007, dehe liu wrote: > I am developping a new tool in the valgrind.but I have some problems in > making makefile. It might be because you don't have an up-to-date enough version of the autotools. I have aclocal 1.9.5, it works fine. Make sure you're using the docs from the repository rather than the ones on the website, which are a bit out of date. The writing-a-tool section has moved, it's at docs/xml/manual-writing-tools.xml. Nick |