Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

systemd 257.2 #203531

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

systemd 257.2 #203531

wants to merge 1 commit into from

Conversation

BrewTestBot
Copy link
Member

Created by brew bump


Created with brew bump-formula-pr.

@github-actions github-actions bot added linux-only Formula depends on Linux bump-formula-pr PR was created using `brew bump-formula-pr` CI-skip-recursive-dependents Pass --skip-recursive-dependents to brew test-bot. labels Jan 7, 2025
systemd: update build

Signed-off-by: Rui Chen <[email protected]>
@@ -70,6 +69,8 @@ class Systemd < Formula
end

def install
ENV.prepend_path "PKG_CONFIG_PATH", Formula["libxml2"].opt_lib/"pkgconfig"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems suspicious. Is this a regression with Homebrew/brew#19023?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure, but that did not fix the issue though

still got this

    building 'lxml.etree' extension
    creating build/temp.linux-x86_64-cpython-312/src/lxml
    gcc-11 -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O3 -Wall -fPIC -DCYTHON_CLINE_IN_TRACEBACK=0 -Isrc -Isrc/lxml/includes -I/tmp/systemd-20250108-7528-g2l2wy/systemd-257.2/venv/include -I/home/linuxbrew/.linuxbrew/opt/[email protected]/include/python3.12 -c src/lxml/etree.c -o build/temp.linux-x86_64-cpython-312/src/lxml/etree.o -w
    In file included from src/lxml/etree.c:1328:
    src/lxml/includes/etree_defs.h:12:10: fatal error: libxml/xmlversion.h: No such file or directory
       12 | #include "libxml/xmlversion.h"
          |          ^~~~~~~~~~~~~~~~~~~~~
    compilation terminated.
    Compile failed: command '/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/shims/linux/super/gcc-11' failed with exit code 1
    creating tmp
    cc -I/usr/include/libxml2 -c /tmp/xmlXPathInitaoodw24a.c -o tmp/xmlXPathInitaoodw24a.o
    /tmp/xmlXPathInitaoodw24a.c:1:10: fatal error: libxml/xpath.h: No such file or directory
        1 | #include "libxml/xpath.h"
          |          ^~~~~~~~~~q~~~~~~
    compilation terminated.

Copy link
Member

@cho-m cho-m Jan 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's probably the same behavior we get on macOS now. Recursive build deps are missing from PKG_CONFIG_PATH.

I recall there were prior discussions for macOS side on this topic. Particularly seen with glib/GNOME dependency trees as glib is usually included in Requires.

Which is why we end up with stuff like:

depends_on "glib" => :build # to add to PKG_CONFIG_PATH for gobject-introspection
depends_on "gobject-introspection" => [:build, :test]
depends_on "meson" => :build
depends_on "ninja" => :build
depends_on "pcre2" => :build # to add to PKG_CONFIG_PATH for glib


EDIT: I do think that if build dependency is in PKG_CONFIG_PATH, then the runtime dependencies of the build dependency should also be included as pkg-config may be used for things like static library builds

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a depends_on "libxml2" => :build already

Copy link
Member

@cho-m cho-m Jan 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's due to Requires.private, which are used to detect --cflags for both shared and static builds. And --libs for static builds.

Not ideal workaround would be depends_on "icu4c@76" => :build and depends_on "zlib" => :build

I do think we should just add these paths to determine_pkg_config_path. Not sure what is easiest way, maybe just computing them based on (deps - run_time_deps).map(&:runtime_dependencies)

EDIT: Maybe some variation of:

(deps + (deps - run_time_deps).flat_map(&:runtime_dependencies).map(&:to_formula)).uniq!

Copy link
Member

@cho-m cho-m Jan 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another alternative is the pkg-config rewrite to convert Requires/Requires.private to absolute paths (Homebrew/brew#18229). Haven't found a way of handling whitespace though. May not be possible in current spec and I haven't found much documentation on absolute paths.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bump-formula-pr PR was created using `brew bump-formula-pr` CI-skip-recursive-dependents Pass --skip-recursive-dependents to brew test-bot. linux-only Formula depends on Linux
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants