[patch] in pluign mode, send gengtype output to a user specified file
Basile STARYNKEVITCH
basile@starynkevitch.net
Tue Sep 29 16:57:00 GMT 2009
Diego Novillo wrote:
> On Thu, Sep 24, 2009 at 10:17, Rafael Espindola <espindola@google.com> wrote:
>> This patch changes gengtype to output all plugin information to a single file
>> specified in the command line.
>>
>> 2009-09-24 Basile Starynkevitch <basile@starynkevitch.net>
>> Rafael Avila de Espindola <espindola@google.com>
>>
>> * gengtype.c (plugin_output): New.
>> (get_output_file_with_visibility): Return plugin_output for plugins.
>> (main): Parse and use the -P option.
>> * gty.texi: Update the command line format.
>
> Looks fine. I don't think '-p' should be renamed to '-P',
> though. Basile, what's the point of that?
Well long time ago, since the original -p behavior did not work well, I
thought that giving explicitly the generated file name is better, and I
thought that since the command syntax changed (by adding that file name)
it was better to change the letter. I otherwise dont care on -p vs -P
provided we do explicitly give the generated file name.
Perhaps gengtype should be installed as gcc-gengtype somewhere and obey
the usual GNU conventions (including --help & --version).
However, I was not able to cleanly apply the patch in
http://gcc.gnu.org/ml/gcc-patches/2009-09/msg01717.html. I had to
manually correct it. And when applying the attached *nonworking* patch
to gcc trunk rev 152279 I am getting
ranlib libbackend.a
gcc -g -fkeep-inline-functions -DIN_GCC -W -Wall -Wwrite-strings
-Wcast-qual -Wstrict-prototypes -Wmissing-prototypes
-Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros
-Wno-overlength-strings -Wold-style-definition -Wc++-compat -fno-common
-DHAVE_CONFIG_H -o cc1-dummy c-lang.o stub-objc.o attribs.o
c-errors.o c-lex.o c-pragma.o c-decl.o c-typeck.o c-convert.o
c-aux-info.o c-common.o c-opts.o c-format.o c-semantics.o c-ppoutput.o
c-cppbuiltin.o c-objc-common.o c-dump.o c-pch.o c-parser.o i386-c.o
c-gimplify.o tree-mudflap.o c-pretty-print.o c-omp.o \
dummy-checksum.o main.o tree-browser.o libbackend.a
../libcpp/libcpp.a ../libdecnumber/libdecnumber.a ../libcpp/libcpp.a
../libiberty/libiberty.a ../libdecnumber/libdecnumber.a -L/usr/lib
-lcloog -L/usr/lib -lppl_c -lppl -lgmpxx -lmpc -lmpfr -lgmp -rdynamic -ldl
/usr/bin/ld: libbackend.a(ggc-common.o): in function
gt_pch_save:/usr/src/Lang/gcc-trunk-bstarynk/gcc/ggc-common.c:511:
error: undefined reference to 'gt_pch_cache_rtab'
/usr/bin/ld: libbackend.a(ggc-common.o): in function
gt_pch_save:/usr/src/Lang/gcc-trunk-bstarynk/gcc/ggc-common.c:539:
error: undefined reference to 'gt_pch_scalar_rtab'
/usr/bin/ld: libbackend.a(ggc-common.o): in function
gt_pch_save:/usr/src/Lang/gcc-trunk-bstarynk/gcc/ggc-common.c:546:
error: undefined reference to 'gt_pch_cache_rtab'
/usr/bin/ld: libbackend.a(ggc-common.o): in function
gt_pch_restore:/usr/src/Lang/gcc-trunk-bstarynk/gcc/ggc-common.c:616:
error: undefined reference to 'gt_pch_scalar_rtab'
/usr/bin/ld: libbackend.a(ggc-common.o): in function
gt_pch_restore:/usr/src/Lang/gcc-trunk-bstarynk/gcc/ggc-common.c:629:
error: undefined reference to 'gt_pch_cache_rtab'
collect2: ld returned 1 exit status
make[3]: *** [cc1-dummy] Error 1
rm gfdl.pod cpp.pod gcc.pod gcov.pod fsf-funding.pod
make[3]: Leaving directory `/usr/src/Lang/_Boot_Gcctrunk/gcc'
make[2]: *** [all-stage1-gcc] Error 2
make[2]: Leaving directory `/usr/src/Lang/_Boot_Gcctrunk'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/usr/src/Lang/_Boot_Gcctrunk'
make: *** [all] Error 2
So obviously I did something wrong.
If Rafael managed to patch the trunk to have something working (if
possible try the test case on gengtype provided by MELT & explained in
http://gcc.gnu.org/ml/gcc-patches/2009-09/msg02057.html) I would be
grateful and delighted to get the patch relative to trunk.
I don't understand what is happenning. Very probably I patched wrongly
the trunk. Sorry about that, but I don't understand what did I miss.
Regards.
--
Basile STARYNKEVITCH http://starynkevitch.net/Basile/
email: basile<at>starynkevitch<dot>net mobile: +33 6 8501 2359
8, rue de la Faiencerie, 92340 Bourg La Reine, France
*** opinions {are only mines, sont seulement les miennes} ***
-------------- next part --------------
A non-text attachment was scrubbed...
Name: bad-gengtype-patch-r152279.diff
Type: text/x-patch
Size: 3262 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20090929/c56ba64c/attachment.bin>
More information about the Gcc-patches
mailing list