Jonathan Gold wrote in post #956225:
Probably not unless you say something about the environment you're
building under: operating system, C compiler version etc.
Reasonable point. It's an Amazon Linux image which is by all accounts really
Centos (poking around on the box confirms).
What shell does your OS have? It's possible that a bash-specific syntax
is being used here, and you're using a POSIX shell, like ksh or dash.
That's the case in Ubuntu:
$ ls -l /bin/sh
lrwxrwxrwx 1 root root 4 2010-06-09 16:27 /bin/sh -> dash
I'm using bash.
Having said that, I have the source to ruby-1.9.1-p429 unpacked on my
machine, where it compiled successfully, and I can't find mkmain.sh
anywhere. Can you post the first two lines of that file?
Nor can I. I actually did a 'find / -name "mkmain.sh"' as well as searched the
centos pkg repos for the file and nothing comes up. My colleague suggested that
perhaps mkmain.sh is actually generated by the make process and cleaned up after
the error, leaving me no chance to see it. I grepped around in the ruby build
dirs for mkmain.sh and only see these references:
$ find . -type f | xargs grep 'mkmain'./Makefile:MKMAIN_CMD = mkmain.sh
./Makefile.in:MKMAIN_CMD = mkmain.sh
./win32/Makefile.sub:MKMAIN_CMD = mkmain.bat
and then searching for the MKMAIN_CMD string:
$ find . -type f | xargs grep 'MKMAIN_CMD'
./Makefile:MKMAIN_CMD = mkmain.sh
./Makefile.in:MKMAIN_CMD = mkmain.sh
./ChangeLog: * Makefile.in, win32/Makefile.sub (RUNCMD, MKMAIN_CMD):
macros to
./win32/Makefile.sub:MKMAIN_CMD = mkmain.bat
./uncommon.mk: @$(RUNCMD) $(MKMAIN_CMD) MAKE=$(MAKE)
./uncommon.mk:exts: $(MKMAIN_CMD)
./uncommon.mk:$(MKMAIN_CMD): $(MKFILES) incs $(PREP) $(RBCONFIG) $(LIBRUBY)
./common.mk: @$(RUNCMD) $(MKMAIN_CMD) MAKE=$(MAKE)
./common.mk:exts: $(MKMAIN_CMD)
./common.mk:$(MKMAIN_CMD): $(MKFILES) incs $(PREP) $(RBCONFIG) $(LIBRUBY)
but nothing that seems to generate said file that I can tell.