[Buildroot] [PATCH] gutenprint: fix host build when libusb found
Peter Korsgaard
peter at korsgaard.com
Fri Apr 15 22:07:59 UTC 2016
>>>>> "Waldemar" == Waldemar Brodkorb <wbx at openadk.org> writes:
> Hi Peter,
> Peter Korsgaard wrote,
>> >>>>> "Waldemar" == Waldemar Brodkorb <wbx at openadk.org> writes:
>>
>> > Allow to disable USB support, otherwise host build breaks when
>> > libusb is found as installation tries to install to /usr.
>> > Fixes following autobuild error:
>> > http://autobuild.buildroot.net/results/081b3be918ac1eaa8cfbc5919e00bc1ea267c1df/
>>
>> Hmm, but why does that end up with /usr and not $(HOST_DIR)/usr? Is it
>> picking up a libusb.pc from your host or is our host-libusb .pc file
>> wrong?
> It is picking up libusb.pc from the host and I don't think
> gutenprint-print will build host libusb at all. As cups support
> is disabled anyway for the host, I don't think installing any USB
> backends for the hosttools is strictly necessary and might be better
> avoided.
I had a closer look, and it actually isn't libusb.pc from the build host
(or directly anything to do with libusb).
The problem is really that the --without-cups option doesn't really
work. We already have a related workaround for this where we
ac_cv_path_CUPS_CONFIG='', but more is needed. When we pass
--without-cups the configure script hardcodes cups_prefix to "/usr".
host-gutenprint itself doesn't depend on host-libusb, but other packages
do so it might be built before host-gutenprint. If the configure script
detects libusb support (using pkg-config), then it will build a cups
backend using libusb (even though cups support is disabled) and intall
it into $cups_prefix/share/cups/usb, breaking the build :/
So either we fix the configure script to really disable the cups support
when configured with --without-cups, we add your patch as a workaround
or we simply add PKG_CONFIG=false to HOST_GUTENPRINT_CONF_ENV to make
sure the configure script doesn't find libusb. We can do that as
pkg-config is only used to check for libusb and gtk2, neither of which
we need for host-gutenprint.
--
Venlig hilsen,
Peter Korsgaard
More information about the buildroot
mailing list