Skip to content
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

Simple install script using Homebrew #111

Open
noyannus opened this issue Jun 2, 2020 · 6 comments
Open

Simple install script using Homebrew #111

noyannus opened this issue Jun 2, 2020 · 6 comments

Comments

@noyannus
Copy link

noyannus commented Jun 2, 2020

Here is a skript to minimize hassle for Homebrew users. It is based on the fork by gpz500 (no issues accepted there).

Maybe it can be included in the Readme?

#!/bin/sh

brew install e2fsprogs m4 automake autoconf libtool pkg-config

if [ ! -d fuse-ext2 ]; then
  git clone https://github.com/alperakcan/fuse-ext2.git
fi

# When creating a package in a system where GNU cp shadows BSD cp, the -X option in make-pkg.sh must be deleted or the script fails.
if [ $(which cp) == /usr/local/opt/coreutils/libexec/gnubin/cp ]; then 
  sed -i 's/cp -pRX /cp -pR /' ./fuse-ext2/tools/macosx/make-pkg.sh 
fi

cd fuse-ext2
./autogen.sh
./configure \
    PKG_CONFIG_PATH="$(brew --prefix e2fsprogs)/lib/pkgconfig" \
    CFLAGS="-idirafter/$(brew --prefix e2fsprogs)/include -idirafter/usr/local/include/osxfuse" \
    LDFLAGS="-L$(brew --prefix e2fsprogs)/lib"
make

# To install on the current system
# sudo make install

# To create an install package in the current directory
make package             
mv fuse-ext2*.dmg ../fuse-ext2.dmg
@chaptsand
Copy link

thanks for your script ,But something wrong in Mac OS Catalina(10.15.5)

cp: ../../tools/macosx/prefpane/build/Release/fuse-ext2.prefPane: No such file or directory
make[4]: *** [install-exec-local] Error 1
make[3]: *** [install-am] Error 2
make[2]: *** [install-recursive] Error 1
make[1]: *** [install-recursive] Error 1
make: *** [package] Error 2

@noyannus
Copy link
Author

If it is really a Catalina issue, I can't help you there, I'll be on Mojave for a while longer. The script completes successfully here, both with make package and make install.

Some ideas:

The script itself does not call cp, that is from one of the scripts it calls. You can try to call them each manually to find out more.

Check if /fuse-ext2/tools/macosx/prefpane/Build/Release/fuse-ext2.prefPane really doesn't exist. If not, the build has failed silently before the cp. If you are the only one to have this issue, there must be something specific to your system.

Try running the script with sudo, maybe you have a permissions issue?

@Ek1nox
Copy link

Ek1nox commented Jun 24, 2020

@liqianimage I have had the same issue and fixed it (macOS Catalina 10.15.5)! May be it can solve your problem too.

Before the error:

cp: ../../tools/macosx/prefpane/build/Release/fuse-ext2.prefPane: No such file or directory

another error was reported:

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

I used the fix from this thread and restart the install script:

  1. Install Xcode (get it from https://appstore.com/mac/apple/xcode) if you don't have it yet.
  2. Accept the Terms and Conditions.
  3. Ensure Xcode app is in the /Applications directory (NOT /Users/{user}/Applications).
  4. Point xcode-select to the Xcode app Developer directory using the following command:

sudo xcode-select -s /Applications/Xcode.app/Contents/Developer

@ThetaGamma
Copy link

confirm the script by @noyannus works like a charm. Fixing compile errors as I only had "xcode command line tools" installed like mentioned by @Ek1nox

@RaphaelDDL
Copy link

RaphaelDDL commented Apr 6, 2021

I fixed the xcode error with @Ek1nox tip, greatly appreciated.

But died again during make on the step after, because of the following error:

note: Constructing build description
error: The i386 architecture is deprecated. You should update your ARCHS build setting to remove the i386 architecture. (in target 'fuse-ext2' from project 'fuse-ext2')
warning: Traditional headermap style is no longer supported; please migrate to using separate headermaps and set 'ALWAYS_SEARCH_USER_PATHS' to NO. (in target 'fuse-ext2' from project 'fuse-ext2')

** BUILD FAILED **

make[3]: *** [prefpane] Error 65
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

This on OSX Catalina, which drops 32bit support. Any thing that can be done to make it run as 64 bit?

@drewwells
Copy link
Contributor

Can you open a PR to update the instructions with this? The build from source install script does not work on my apple m1. I get a similar issue with this one configure: error: Can't find libfuse, please install it. I think it is related to the odd way that homebrew supported big sur.

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

No branches or pull requests

6 participants