Bläddra i källkod

* Autotoolified the Ruby bindings. Use --enable-ruby.

tags/v0.99.beta14
Sam Hocevar sam 17 år sedan
förälder
incheckning
1714312f07
5 ändrade filer med 51 tillägg och 16 borttagningar
  1. +1
    -1
      Makefile.am
  2. +19
    -0
      configure.ac
  3. +2
    -0
      ruby/.gitignore
  4. +0
    -15
      ruby/Makefile
  5. +29
    -0
      ruby/Makefile.am

+ 1
- 1
Makefile.am Visa fil

@@ -1,6 +1,6 @@
# $Id$

SUBDIRS = kernel cucul caca src test tools cxx doc
SUBDIRS = kernel cucul caca src test tools cxx ruby doc
DIST_SUBDIRS = $(SUBDIRS) msvc

EXTRA_DIST = NOTES COPYING.GPL COPYING.LGPL bootstrap build-dos build-kernel build-win32 caca-config.in common.h libcaca.spec


+ 19
- 0
configure.ac Visa fil

@@ -62,6 +62,8 @@ AC_ARG_ENABLE(vga,
dnl language bindings
AC_ARG_ENABLE(cxx,
[ --enable-cxx C++ bindings (default disabled)])
AC_ARG_ENABLE(ruby,
[ --enable-ruby Ruby bindings (default disabled)])

dnl example programs features
AC_ARG_ENABLE(imlib2,
@@ -317,6 +319,22 @@ if test "${enable_cxx}" = "yes"; then
fi
AM_CONDITIONAL(USE_CXX, test "${ac_cv_my_have_cxx}" = "yes")

# Build the Ruby bindings?
ac_cv_my_have_ruby="no"
if test "${enable_ruby}" = "yes"; then
AC_PATH_PROG(RUBY, ruby, no)
if test "${RUBY}" != "no"; then
AC_MSG_CHECKING(for mkmf.rb)
if "${RUBY}" -e 'require "mkmf"' >/dev/null 2>&1; then
AC_MSG_RESULT(yes)
ac_cv_my_have_ruby="yes"
else
AC_MSG_RESULT(no)
fi
fi
fi
AM_CONDITIONAL(USE_RUBY, test "${ac_cv_my_have_ruby}" = "yes")

# Build cacaserver?
ac_cv_my_have_network="no"
AC_CHECK_HEADERS(sys/socket.h,
@@ -378,6 +396,7 @@ AC_CONFIG_FILES([
test/Makefile
tools/Makefile
cxx/Makefile
ruby/Makefile
doc/Makefile
msvc/Makefile
])


+ 2
- 0
ruby/.gitignore Visa fil

@@ -0,0 +1,2 @@
*/mkmf.log
*/*.so

+ 0
- 15
ruby/Makefile Visa fil

@@ -1,15 +0,0 @@
all: cucul/cucul.so caca/caca.so

caca/caca.so: cucul/cucul.so
cd caca && \
ruby extconf.rb && \
make

cucul/cucul.so:
cd cucul && \
ruby extconf.rb && \
make

clean:
make -C caca clean
make -C cucul clean

+ 29
- 0
ruby/Makefile.am Visa fil

@@ -0,0 +1,29 @@
# $Id: $

if USE_RUBY
noinst_DATA = cucul/cucul.so caca/caca.so
endif

EXTRA_DIST = cucul/extconf.rb \
cucul/cucul.c \
cucul/cucul-canvas.c \
cucul/test.rb \
cucul/t/tc_frame.rb \
caca/extconf.rb

DISTCLEANFILES = cucul/Makefile caca/Makefile

cucul/cucul.so:
ruby -C cucul extconf.rb
make -C cucul

caca/caca.so: cucul/cucul.so
ruby -C caca extconf.rb
make -C caca

clean-local:
make -C cucul clean
make -C caca clean

distclean-local:
rm -f cucul/Makefile caca/Makefile

Laddar…
Avbryt
Spara