On Sun, 2020-07-26 at 08:20 -0700, [email protected] wrote: > A few days ago, I tried to compile a gcc plugin with the toolchain from poky > sdk. > It failed with errors about missing header files such as backend.h etc. > > After investigation, I found that the problem was brought by a gcc patch: > 0012-gcc-Fix-argument-list-too-long-error.patch (which is considered derived > from the original patch) > > - headers=`echo $(PLUGIN_HEADERS) $$(cd $(srcdir); echo *.h *.def) | tr ' ' > '\012' | sort -u`; \ > + headers="$(sort $(PLUGIN_HEADERS) $$(cd $(srcdir); echo *.h *.def))"; \ > > It changes the commands of install-plugin, making the sorting taken effect > before the shell globs. > Thus results in the header files under gcc $(srcdir) being not installed. > > By checking log.do_install, we can find that the `headers=' statement to run > is incorrect and will not work as expected: > headers="$(cd *.def) *.h > ../../../../../../../work-shared/gcc-10.1.0-r0/gcc-10.1.0/gcc/../include/ansidecl.h > ... > > As the patch says, > "The PLUGIN_HEADERS is too long before sort, so the "echo" can't handle it, > ..." > my suggestion is that we can simply take care of PLUGIN_HEADERS: > > - headers=`echo $(PLUGIN_HEADERS) $$(cd $(srcdir); echo *.h *.def) | tr ' ' > '\012' | sort -u`; \ > + headers=`echo $(sort $(PLUGIN_HEADERS)) $$(cd $(srcdir); echo *.h *.def) | > tr ' ' '\012' | sort -u`; \
Thanks for the report, I've submitted and later merged a patch to fix it. Cheers, Richard
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#141085): https://lists.openembedded.org/g/openembedded-core/message/141085 Mute This Topic: https://lists.openembedded.org/mt/75804103/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
