Well, upstream has now released version 0.2.0 of mosh, so I decided to
take another look at it. It would have to be targeted at experimental,
because it relies on the experimental version of libgc (>= 1:7.1)
Barak - I'm CC'ing you in case you want to take a look at this.
So, I tried my hand at ripping out the internal libraries just to see
how tough it would be. I actually got mosh to build pretty easily by
applying the following patch to the source and autoreconf'ing. A couple
of things to note:
First, the patch is really really dirty right now. My autotools-fu is
awful to begin with, but yes, I know /usr shouldn't be hardcoded, etc.
It is probably broken in 10 different ways. It should be broken out into
3 patches for the different libraries I ripped out.
Second, the patch doesn't mention a word about libatomic-ops-dev. It
seems to build fine without it?
In any case, with and without libatomic-ops-dev installed, I'm getting
this error in make test:
Condition components:
1. &error
2. &who who: unknown
3. &message message: "hogehoge2"
4. &irritants irritants: ()
Condition components:
1. &error
2. &who who: expander
3. &message message: "cannot locate library in
library-path"
4. &library-resolution library: (mosh test)
files: ("./mosh/test.mosh.sls"
"./mosh/test.mosh.ss" "./mosh/test.mosh.scm" "./mosh/test.sls"
"./mosh/test.ss" "./mosh/test.scm" "/lib/mosh/test.mosh.sls"
"/lib/mosh/test.mosh.ss" "/lib/mosh/test.mosh.scm" "/lib/mosh/test.sls"
"/lib/mosh/test.ss" "/lib/mosh/test.scm")
Exception:
error in raise: returned from non-continuable exception
Stack trace:
1. throw: <subr>
2. (raise c): compiler-with-library.scm:894
3. (lambda (x) ...): psyntax.scm:8
4. (lambda () ...): psyntax.scm:8
5. (dynamic-wind in body out): compiler-with-library.scm:813
6. (lambda (j21a9 j21ab) ...): psyntax.scm:10
7. apply: <subr>
make[1]: *** [test] Error 255
make[1]: Leaving directory `/build/dmr-mosh_0.2.0-1-amd64-pDC4BB/mosh-0.2.0'
dh_auto_test: make returned exit code 2
make: *** [build-stamp] Error 1
dpkg-buildpackage: error: debian/rules build gave error exit status 2
I haven't the faintest clue what it means.
Regards,
Daniel
diff --git a/Makefile.am b/Makefile.am
index 5d3c2c8..e886e02 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -4,12 +4,12 @@ AM_CXXFLAGS = $(CFLAGS)
# Boehm GC
#BOEHM_GC_DIR = ./gc-7.1alpha3
-BOEHM_GC_DIR = ./gc-7.1
-GC_LIB = $(BOEHM_GC_DIR)/.libs/libgc.a
+#BOEHM_GC_DIR = ./gc-7.1
+GC_LIB = /usr/lib/libgc.a
# Regexp library oniguruma
-ONIG_DIR = ./onig-5.7.0
-REGEXP_LIB = $(ONIG_DIR)/.libs/libonig.a
+#ONIG_DIR = ./onig-5.7.0
+REGEXP_LIB = /usr/lib/libonig.a
# for GTEST
GTEST_DIR = gtest-1.2.1
@@ -24,7 +24,7 @@ libffitest.so.1.0: ffitest.c
$(CC) -Wall -fPIC -c $<
$(CC) -Wl @SHLIB_SO_LDFLAGS@ -o $@ ffitest.o
-SUBDIRS = $(BOEHM_GC_DIR) $(ONIG_DIR) .
+SUBDIRS = .
man_MANS = mosh.1 mosh_config.1
@@ -306,7 +306,7 @@ nobase_data_DATA = ${mosh_core_libraries} #${mosh_core_fasl_libraries}
PRECOMPILE_SRC = compiler-with-library.scmc pmatch.scmc psyntax.scmc
-INCLUDES = -I $(BOEHM_GC_DIR)/include -I $(ONIG_DIR)
+INCLUDES = -I /usr/include/gc
EXTRA_DIST = instruction.scm vm.scm library.scm compiler.scm free-vars.scm scripts pmatch.scm test-data.scm doc repl.scm tools/psyntax-r6rs/rev10_to_10/psyntax.scm mosh.1 mosh_config.1 tools/psyntax-r6rs RELNOTE r6rs-test-suite example lib cprocedures.cpp labels.cpp all-tests.scm test call.inc.cpp ${GTEST_DIR} ffitest.c bench win mosh.vcproj mosh.sln logo r6rs-test-suite README-WINDOWS.txt README.MINGW misc
GENERATED = \
diff --git a/configure.ac b/configure.ac
index 3eadbd9..c985064 100644
--- a/configure.ac
+++ b/configure.ac
@@ -39,6 +39,11 @@ dnl fi
AC_CHECK_LIB(gmp, __gmpz_init, ,
[AC_MSG_ERROR([GNU MP not found, see http://gmplib.org/."For OSX, install GNU MP with "CFLAGS+=-m32 ./configure ABI=32 && make"])])
+AC_CHECK_LIB(onig, onig_init, ,
+ [AC_MSG_ERROR([Cannot find onig])])
+
+AC_CHECK_LIB(gc, GC_init, ,
+ [AC_MSG_ERROR([Cannot find gc])])
AC_ARG_ENABLE(profiler, [ --enable-profiler turn off profiler [default=yes]], ,[enable_profiler=yes])
AC_MSG_CHECKING(whether to enable profiler)
@@ -355,5 +360,4 @@ case "$target_in" in
esac
AC_CONFIG_FILES([Makefile])
-AC_CONFIG_SUBDIRS([gc-7.1 onig-5.7.0])
AC_OUTPUT(mosh_config lib/mosh/mysql.ss lib/mosh/config.ss doc/text/Download.txt)
Attachment:
signature.asc
Description: OpenPGP digital signature