Skip to content

Fixed brew pkgconf pipeline test failure #40555

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion brew.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package:
name: brew
version: "4.4.28"
epoch: 0
epoch: 1
description: "The homebrew package manager"
copyright:
- license: BSD-2-Clause
@@ -54,6 +54,22 @@ pipeline:
set -x
mkdir -p ${{targets.destdir}}/home/linuxbrew/.linuxbrew/
cp -a ./brew/bin/ ./brew/Library/ ./brew/package/ ${{targets.destdir}}/home/linuxbrew/.linuxbrew/

# Relocate .pc files to /usr/lib/pkgconfig
mkdir -p "${{targets.destdir}}"/usr/lib/pkgconfig/

find ${{targets.destdir}}/home/linuxbrew -type f -name "*.pc" | while read -r pc_file; do
dname=$(printf "${pc_file}" | sed -e "s,${{targets.destdir}},,")
dname=$(dirname "${dname}")
# Adjust "pcfiledir" so that it reflects the right location of each .pc file.
if grep -q "pcfiledir" "${pc_file}"; then
sed -i -e "s,\${pcfiledir},${dname}," "${pc_file}"
fi
# Move the .pc file to /usr/lib/pkgconfig/
mv "${pc_file}" "${{targets.destdir}}"/usr/lib/pkgconfig/
done

# Create profile.d script
mkdir -p ${{targets.destdir}}/etc/profile.d/
echo "export PATH=\$PATH:/home/linuxbrew/.linuxbrew/bin" > ${{targets.destdir}}/etc/profile.d/brew.sh
echo "export HOMEBREW_NO_AUTO_UPDATE=1" >> ${{targets.destdir}}/etc/profile.d/brew.sh
@@ -83,3 +99,4 @@ test:
. /etc/profile.d/brew.sh
HOME=/root brew --version
- uses: test/tw/ldd-check
- uses: test/pkgconf