romkatv / zsh-bin

Statically-linked, hermetic, relocatable Zsh
MIT License
319 stars 18 forks source link

why do not patch bin in macos #19

Open rmGFW opened 3 months ago

rmGFW commented 3 months ago

i found it was disable patch bin in macos , i dont know why disable it

if [ "$ZSH_BIN_KERNEL" = darwin ]; then
  sed_i 's/@ZSH_BIN_DO_PATCH_BIN@/false/g' share/zsh/5.8/scripts/relocate
else
romkatv commented 3 months ago

Probably doesn't work there.

rmGFW commented 3 months ago

Probably doesn't work there.

that's right , i tried patch Mach-O 64-bit executable, it will crash after patched . but i don't known why it crash .

romkatv commented 3 months ago

Probably something to do with security.

rmGFW commented 3 months ago

Probably something to do with security.

i want to find how to fix this ,but i even dont known what's the name of this mechanic.

btw, if we not do patching in macos , that is zsh-bin binary is not relocate in macos , so the relocate feature is only working in linux , right?

romkatv commented 3 months ago

btw, if we not do patching in macos , that is zsh-bin binary is not relocate in macos , so the relocate feature is only working in linux , right?

Yes, I think so.

macOS comes with zsh 5.9 by default. What are you trying to achieve by installing zsh 5.8 via zsh-bin?