fuse-ext2 icon indicating copy to clipboard operation
fuse-ext2 copied to clipboard

OSX: Build using script.sh failed (bad interpreter)

Open lukashoror opened this issue 7 years ago • 3 comments

Hi, I'm using script.sh from home page to build on OSX 10.13.4 and it fails when it's going to build fuse-ext2:

./script.sh: ./autogen.sh: /bin/sh^M: bad interpreter: No such file or directory
./script.sh: line 74: ./configure: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
make: *** No rule to make target install.  Stop.

When I run autogen.sh manually, it also says 'bad interpreter'. When I copy content of autogen.sh from git web (not raw) and save it, it works. Is it problem with incorrect line endings?

lukashoror avatar Jun 06 '18 11:06 lukashoror

have a bin/sh in /bin? /src/mac/utilis/fuse-ext2-20180729>ls /bin/sh -l -r-xr-xr-x 1 root wheel 618512 2017/09/21 12:35:23 /bin/sh

jming35 avatar Jul 29 '18 11:07 jming35

Of course I have. OT: The command should be ls -l /bin/sh.

lukashoror avatar Jul 30 '18 08:07 lukashoror

ha ha, I install GNU coreutils in my MAC are u see "./script.sh: ./autogen.sh: /bin/sh^M" --------> ^M it's mean end of line is ^M (CTRL-M), usually windows use it alias name CRLF but we use MAC unix like, end of line is LF so u need to sure 2 things,

  1. change EOL to LF
  2. use UTF8 encode u can use ultraedit do this open this file and save as file, chose EOL and code page format it's all

jming35 avatar Aug 03 '18 08:08 jming35