[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Build error on Mac OS X
From: |
Ben Pfaff |
Subject: |
Re: Build error on Mac OS X |
Date: |
Mon, 20 May 2013 20:24:06 -0700 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Mon, May 20, 2013 at 07:56:43PM +0300, Teppo Jussm?ki wrote:
> On Mac OS X libtoolize is named glibtoolize and without separately set
> environment variables build command "make -f Smake" produces an error:
> libtoolize: command not found
>
> In file Smake (line 133):
> libtoolize --force --automake
>
> One possible solution, replace line 133 with:
> if [ $(shell which glibtoolize) ]; then \
> glibtoolize --force --automake; \
> else libtoolize --force --automake; fi;
>
> ...or do something like this:
> if [ $(shell which glibtoolize) ]; then LIBTOOLIZE = glibtoolize \
> else LIBTOOLIZE = libtoolize; fi;
> ...
> $(LIBTOOLIZE) --force --automake
Does this work? It may be too fancy:
diff --git a/Smake b/Smake
index d061973..4782126 100644
--- a/Smake
+++ b/Smake
@@ -130,7 +130,15 @@ prep_ph:
--source-base=gl --lib=libgl --tests-base=tests \
--doc-base=gl/doc --aux-dir=build-aux \
--libtool $(GNULIB_MODULES)
- libtoolize --force --automake
+ if (glibtoolize --version) >/dev/null 2>&1; then \
+ LIBTOOLIZE=glibtoolize; \
+ elif (libtoolize --version) >/dev/null 2>&1; then \
+ LIBTOOLIZE=libtoolize; \
+ else \
+ echo >&2 "libtoolize not found"; \
+ exit 1; \
+ fi; \
+ $$LIBTOOLIZE --force --automake
aclocal.m4:
aclocal -I m4 -I gl/m4