RJVB / afsctool

This is a version of "brkirch"'s afsctool utility that allows end-users to leverage HFS+ compression.
https://brkirch.wordpress.com/afsctool
GNU General Public License v3.0
186 stars 18 forks source link

How to install to computer with out internet? #24

Open Henrietta1989 opened 5 years ago

Henrietta1989 commented 5 years ago

I would like to install afsctool to Mac 10.7.5 which don't have internet access at all.

Is this possible?

RJVB commented 5 years ago

Not impossible, but complicated because you'll need to install a lot more things to even get the software to build. Your best bet to install a version of afsctool is to look for an installer or pre-build binary of the original afsctool version by bkirch.

There's another possibility though: target mode. As far as I know all Macs support this, and if you boot them in that mode they become (very fancy, expensive) external disks that you can connect to other Macs via a FireWire or USB cable. You can then use the afsctool command that you installed on your other Mac to compress folders on the other Mac.

Henrietta1989 commented 5 years ago

I dragged it to usr/bin/ (OS 10.7.5) folder but it don't work.

RJVB commented 5 years ago

"It" being what?

The version you built yourself will indeed not work. You could try to download from here (https://brkirch.wordpress.com/afsctool/), transfer the zip file to your 10.7 machine and unpack+install there.

dm0123 commented 2 years ago

I dragged it to usr/bin/ (OS 10.7.5) folder but it don't work.

I think the issue here is that CMake module 'FindZLIBP.cmake' doesn't handle -rpath link flag. So afsctool is linking by absolute paths to at least zlib. You may see if it is the case by running 'otool -L afsctool' in terminal. If it says something like

afscompress:
    /Users/c/homebrew/opt/zlib/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11)
    /System/Library/Frameworks/CoreServices.framework/Versions/A/CoreServices (compatibility version 1.0.0, current version 1141.1.0)
    /usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 1200.3.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1311.0.0)
    /System/

then you may change it via install_name_tool like so: install_name_tool -change /Users/c/homebrew/opt/zlib/lib/libz.1.dylib @rpath/libz.1.dylib bin/afscompress provided you have libz.1.dylib somewhere in search paths.