Be able to compile on Linux [Patch]

Nicolas Pelletier nicolas.pelletier3 at free.fr
Sun May 1 06:10:01 PDT 2005


Pupeno <pupeno at pupeno.com> writes:

> Je Dimanĉo Majo 1 2005 08:25, Pupeno skribis:
> > Hello,
> > I had to change configure.in to be able to compile the main branch on
> > Linux. I am attaching the patch, I hope it's in the right format.
> > Note: this patch may make Slate not compile in other architectures than
> > Linux. Thanks.

How about something like:

COPTFLAGS=-O2 -fomit-frame-pointer -DNDEBUG=1 -s
ifeq ($(shell uname -s),Linux)
  COPTFLAGS += -ldl
endif

> That was a quick and dirty way out, investigating further I've found that
> configure.in was totally mistaking my OS.

The code to see in configure.in  is not executed, but just included as
is into src/mobius/vm/platform/unix/Makefile.

> It uses OS = $(shell uname -s), so, I've tried running:

$(shell uname -s) is transformed  by make into ${SHELL} -c 'uname -s'.

> $ bash uname -s
> and I've got:
> uname: /bin/uname: cannot execute binary file

So do other people. You  are calling the shell script interpreter bash
to  load  the  file /bin/uname  and  try  to  execute  it as  a  shell
script. Bash  tells you that /bin/uname  is not a shell  script, but a
binary file.

> I don't know why it can't run it, I can run uname -s by itself just fine.
> If someone has a clue about this situation, it's welcome.

Do  not  underestimate the  wisdom  and  knowledge  found in  the  man
pages... ;-P

-- 
Nicolas




More information about the Slate mailing list