[PATCH] tools: zlib: fix broken compile with ccache enabled

Rosen Penev rosenp at gmail.com
Thu Dec 17 20:10:57 EST 2020


On Thu, Dec 17, 2020 at 4:13 PM <ansuelsmth at gmail.com> wrote:
>
>
>
> > -----Messaggio originale-----
> > Da: Ansuel Smith <ansuelsmth at gmail.com>
> > Inviato: venerdì 18 dicembre 2020 00:59
> > A: OpenWrt Development List <openwrt-devel at lists.openwrt.org>
> > Cc: Ansuel Smith <ansuelsmth at gmail.com>
> > Oggetto: [PATCH] tools: zlib: fix broken compile with ccache enabled
> >
> > If ccache is enabled with an empty buildroot the compilation fails. Fix
> > this by using the NOCACHE compiler as it's done by other tools package.
> >
> > Signed-off-by: Ansuel Smith <ansuelsmth at gmail.com>
> > ---
> >  tools/zlib/Makefile | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git a/tools/zlib/Makefile b/tools/zlib/Makefile
> > index 279851f..5dc311d 100644
> > --- a/tools/zlib/Makefile
> > +++ b/tools/zlib/Makefile
> > @@ -22,6 +22,7 @@ PKG_CPE_ID:=cpe:/a:gnu:zlib
> >  include $(INCLUDE_DIR)/host-build.mk
> >  include $(INCLUDE_DIR)/cmake.mk
> >
> > +CMAKE_HOST_C_COMPILER:=$(HOSTCC_NOCACHE)
> >  HOST_CFLAGS +=-fPIC
> >
> >  define Host/Install
> > --
> > 2.29.2
>
> Ignore, it seems it cause other problem with cmake?
You're missing -D and CMAKE_HOST_OPTIONS.

I submitted a patch that fixes this. Tested on Fedora 33.
>
>
>
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel at lists.openwrt.org
> https://lists.openwrt.org/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list