Skip to content

macOS improvements - #4

Open
philmd wants to merge 3 commits into
p-b-o:masterfrom
philmd:macos
Open

macOS improvements#4
philmd wants to merge 3 commits into
p-b-o:masterfrom
philmd:macos

Conversation

@philmd

@philmd philmd commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

No description provided.

Comment thread build_kernel.sh
Comment thread clone.sh Outdated

for patch in $patches; do
git -C $src.tmp am $(readlink -f $patch)
patch -d $src.tmp -p1 < $(readlink -f $patch)

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Why not use git?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Applying: include/linux/compiler: add DEBUGGER attribute for functions
error: sha1 information is lacking or useless (include/linux/compiler.h).
error: could not build fake ancestor
Patch failed at 0001 include/linux/compiler: add DEBUGGER attribute for functions
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config advice.mergeConflict false"

@p-b-o p-b-o Jul 27, 2026

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Do you have a specific git config that checks for this? It does not seem to be present on my machine or in CI.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Apparently per my logs the last command tested before giving up was git -C $src.tmp am -n -3 $(readlink -f $patch).

This patch is a kludge doesn't belong to this PR; I removed it. Let's figure the issue out when you get hardware to reproduce.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Could you try with a blank .gitconfig (`mv ~/.gitconfig ~/.gitconfig.bak) to see if it's related to this?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Committer identity unknown

*** Please tell me who you are.

Run

  git config --global user.email "you@example.com"
  git config --global user.name "Your Name"

to set your account's default identity.
Omit --global to set the identity only in this repository.

fatal: unable to auto-detect email address (got 'root@36327ed1d4dd.(none)')

:)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

~/source/qemu-linux-stack (macos)$ git config --global user.email a@b.c
~/source/qemu-linux-stack (macos)$ ./build_kernel.sh 
+ '[' -z '' ']'
+ ./container.sh ./build_kernel.sh
+ '[' -z 1 ']'
+ clone
+ ./clone.sh linux https://github.com/torvalds/linux v6.17 patches/linux-include-linux-compiler-add-DEBUGGER-attribute-for-functions.patch
+ src=linux-e5fadff6f
+ rm -f linux
+ '[' '!' -d linux-e5fadff6f ']'
+ rm -rf linux-e5fadff6f.tmp
+ '[' '!' -d /Users/user/.cache/qemu-linux-stack/clone/5bb903da8 ']'
+ rsync -a /Users/user/.cache/qemu-linux-stack/clone/5bb903da8/ linux-e5fadff6f.tmp/
+ pushd linux-e5fadff6f.tmp
~/source/qemu-linux-stack/linux-e5fadff6f.tmp ~/source/qemu-linux-stack
+ git checkout v6.17
M	Documentation/Changes
M	arch/arm/boot/dts/allwinner/sun8i-a23-ippo-q8h-v1.2.dts
M	arch/arm/boot/dts/allwinner/sun8i-a23-ippo-q8h-v5.dts
M	arch/arm/boot/dts/allwinner/sun8i-a33-et-q8-v1.6.dts
M	arch/arm/boot/dts/allwinner/sun8i-a33-ippo-q8h-v1.2.dts
M	arch/arm64/boot/dts/renesas/r9a07g054l2-smarc-cru-csi-ov5645.dtso
M	arch/arm64/tools/syscall_64.tbl
M	arch/powerpc/configs/kvm_guest.config
M	include/uapi/linux/netfilter/xt_CONNMARK.h
M	include/uapi/linux/netfilter/xt_DSCP.h
M	include/uapi/linux/netfilter/xt_MARK.h
M	include/uapi/linux/netfilter/xt_RATEEST.h
M	include/uapi/linux/netfilter/xt_TCPMSS.h
M	include/uapi/linux/netfilter_ipv4/ipt_ECN.h
M	include/uapi/linux/netfilter_ipv4/ipt_TTL.h
M	include/uapi/linux/netfilter_ipv6/ip6t_HL.h
M	net/netfilter/xt_DSCP.c
M	net/netfilter/xt_HL.c
M	net/netfilter/xt_RATEEST.c
M	net/netfilter/xt_TCPMSS.c
M	tools/memory-model/litmus-tests/Z6.0+pooncelock+poonceLock+pombonce.litmus
HEAD is now at e5f0a698b Linux 6.17
+ popd
~/source/qemu-linux-stack
+ for patch in $patches
++ readlink -f patches/linux-include-linux-compiler-add-DEBUGGER-attribute-for-functions.patch
+ git -C linux-e5fadff6f.tmp am /Users/user/source/qemu-linux-stack/patches/linux-include-linux-compiler-add-DEBUGGER-attribute-for-functions.patch
Applying: include/linux/compiler: add DEBUGGER attribute for functions
error: include/linux/compiler.h: does not match index
Patch failed at 0001 include/linux/compiler: add DEBUGGER attribute for functions
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config advice.mergeConflict false"
~/source/qemu-linux-stack (macos)$ 

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Why not use git?

Maybe you missed the per-commit description (each commit have one):
ec7ab2b

@p-b-o p-b-o Jul 28, 2026

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

I'm not sure what file case sensitivity changes in current case.
Can you go in checkouted linux folder and run a git status from podman (./container.sh).
You should be able to find what is wrong with git itself.

Comment thread container.sh Outdated
Comment thread container.sh
Comment thread lldbinit
Comment thread container.sh Outdated
@philmd philmd changed the title macOS support macOS improvements Jul 28, 2026
@philmd
philmd requested a review from p-b-o July 28, 2026 07:54
philmd added 3 commits July 28, 2026 10:42
podman access the host filesystem over virtio-9p which is limited.

Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
'--network host' does not work on macOS.

Access the container hostname resolving 'host.containers.internal'.

Expose the DAP and perfetto HTTP services.

Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
Comment thread README.md

```
podman machine stop && ulimit -n unlimited && podman machine start
podman machine ssh sudo sysctl -w fs.file-max=2097152

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Without this, does it fail by defaut on MacOS?
What the default value?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants