Skip to content

Commit

Permalink
Fix error compiling pkg-config using latest clang.
Browse files Browse the repository at this point in the history
  • Loading branch information
saurik committed Jul 12, 2024
1 parent 88f3268 commit e76964a
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion env/output.mk
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,14 @@ $(output)/%.rc.o: $$(specific) $$(folder).rc $$(code)
@echo [RC] $(target)/$(arch) $<
$(job)@$(prefix) $(windres/$(arch)) -o $@ $< $(filter -I%,$(flags) $(xflags))

# XXX: pkg-config has an old embedded version of glib which no longer compiles
# https://gitlab.freedesktop.org/pkg-config/pkg-config/-/issues/81
# https://github.com/bazelbuild/rules_foreign_cc/issues/1065
# thttps://github.com/bazelbuild/rules_foreign_cc/issues/1200
# https://lists.freedesktop.org/archives/pkg-config/2024-May/001122.html
$(output)/%/pkg-config/Makefile: env/pkg-config/configure
@mkdir -p $(dir $@)
cd $(dir $@) && $(CURDIR)/$< --enable-static --prefix=$(CURDIR)/$(output)/$*/usr --with-internal-glib
cd $(dir $@) && CFLAGS="-Wno-int-conversion" $(CURDIR)/$< --enable-static --prefix=$(CURDIR)/$(output)/$*/usr --with-internal-glib

$(output)/%/usr/bin/pkg-config: $(output)/%/pkg-config/Makefile
$(MAKE) -C $(dir $<) install
Expand Down

0 comments on commit e76964a

Please sign in to comment.