-
-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
base: master
Are you sure you want to change the base?
systemd 257.2 #203531
Conversation
systemd: update build Signed-off-by: Rui Chen <[email protected]>
ae7535a
to
b622816
Compare
@@ -70,6 +69,8 @@ class Systemd < Formula | |||
end | |||
|
|||
def install | |||
ENV.prepend_path "PKG_CONFIG_PATH", Formula["libxml2"].opt_lib/"pkgconfig" |
There was a problem hiding this comment.
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?
There was a problem hiding this comment.
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.
There was a problem hiding this comment.
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:
homebrew-core/Formula/b/babl.rb
Lines 24 to 28 in 321b9dc
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
There was a problem hiding this comment.
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
There was a problem hiding this comment.
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!
There was a problem hiding this comment.
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.
Created by
brew bump
Created with
brew bump-formula-pr
.