Commit 75bd1103 authored by Jeremy Bicha's avatar Jeremy Bicha

New upstream version 0.1.2

parents 89a938ff 66834d40
This diff is collapsed.
== gnome-js-common 0.1.1 (2009.07.10) ==
* Contains tweener, which provides transitions with advanced easing modes
* Only build test components if seed/gjs are installed
This diff is collapsed.
SUBDIRS = po modules tests
gnome_js_commondocdir = ${prefix}/share/doc/gnome_js_common
gnome_js_commondoc_DATA = \
README \
COPYING \
AUTHORS \
ChangeLog \
INSTALL \
NEWS
INTLTOOL_FILES = intltool-extract.in \
intltool-merge.in \
intltool-update.in
EXTRA_DIST = $(gnome_js_commondoc_DATA) \
$(INTLTOOL_FILES)
DISTCLEANFILES = intltool-extract \
intltool-merge \
intltool-update \
po/.intltool-merge-cache
pkgconfig_DATA = gnome-js-common.pc
pkgconfigdir = $(libdir)/pkgconfig
# Remove doc directory on uninstall
uninstall-local:
-rm -r $(gnome_js_commondocdir)
This diff is collapsed.
This diff is collapsed.
#! /bin/sh
# Wrapper for compilers which do not understand `-c -o'.
scriptversion=2009-04-28.21; # UTC
# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2009 Free Software
# Foundation, Inc.
# Written by Tom Tromey <tromey@cygnus.com>.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# This file is maintained in Automake, please report
# bugs to <bug-automake@gnu.org> or send patches to
# <automake-patches@gnu.org>.
case $1 in
'')
echo "$0: No command. Try \`$0 --help' for more information." 1>&2
exit 1;
;;
-h | --h*)
cat <<\EOF
Usage: compile [--help] [--version] PROGRAM [ARGS]
Wrapper for compilers which do not understand `-c -o'.
Remove `-o dest.o' from ARGS, run PROGRAM with the remaining
arguments, and rename the output as expected.
If you are trying to build a whole package this is not the
right script to run: please start by reading the file `INSTALL'.
Report bugs to <bug-automake@gnu.org>.
EOF
exit $?
;;
-v | --v*)
echo "compile $scriptversion"
exit $?
;;
esac
ofile=
cfile=
eat=
for arg
do
if test -n "$eat"; then
eat=
else
case $1 in
-o)
# configure might choose to run compile as `compile cc -o foo foo.c'.
# So we strip `-o arg' only if arg is an object.
eat=1
case $2 in
*.o | *.obj)
ofile=$2
;;
*)
set x "$@" -o "$2"
shift
;;
esac
;;
*.c)
cfile=$1
set x "$@" "$1"
shift
;;
*)
set x "$@" "$1"
shift
;;
esac
fi
shift
done
if test -z "$ofile" || test -z "$cfile"; then
# If no `-o' option was seen then we might have been invoked from a
# pattern rule where we don't need one. That is ok -- this is a
# normal compilation that the losing compiler can handle. If no
# `.c' file was seen then we are probably linking. That is also
# ok.
exec "$@"
fi
# Name of file we expect compiler to create.
cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'`
# Create the lock directory.
# Note: use `[/\\:.-]' here to ensure that we don't use the same name
# that we are using for the .o file. Also, base the name on the expected
# object file name, since that is what matters with a parallel build.
lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d
while true; do
if mkdir "$lockdir" >/dev/null 2>&1; then
break
fi
sleep 1
done
# FIXME: race condition here if user kills between mkdir and trap.
trap "rmdir '$lockdir'; exit 1" 1 2 15
# Run the compile.
"$@"
ret=$?
if test -f "$cofile"; then
mv "$cofile" "$ofile"
elif test -f "${cofile}bj"; then
mv "${cofile}bj" "$ofile"
fi
rmdir "$lockdir"
exit $ret
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-end: "; # UTC"
# End:
This diff is collapsed.
/* config.h.in. Generated from configure.ac by autoheader. */
/* always defined to indicate that i18n is enabled */
#undef ENABLE_NLS
/* GETTEXT package name */
#undef GETTEXT_PACKAGE
/* Define to 1 if you have the `bind_textdomain_codeset' function. */
#undef HAVE_BIND_TEXTDOMAIN_CODESET
/* Define to 1 if you have the `dcgettext' function. */
#undef HAVE_DCGETTEXT
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define if the GNU gettext() function is already present or preinstalled. */
#undef HAVE_GETTEXT
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define if your <locale.h> file defines LC_MESSAGES. */
#undef HAVE_LC_MESSAGES
/* Define to 1 if you have the <locale.h> header file. */
#undef HAVE_LOCALE_H
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define to the sub-directory in which libtool stores uninstalled libraries.
*/
#undef LT_OBJDIR
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
#undef NO_MINUS_C_MINUS_O
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the home page for this package. */
#undef PACKAGE_URL
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION
This diff is collapsed.
This diff is collapsed.
AC_INIT(gnome-js-common, 0.1.2)
AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
AC_CONFIG_HEADERS([config.h])
AM_MAINTAINER_MODE
AC_ISC_POSIX
AC_PROG_CC
AM_PROG_CC_STDC
AC_HEADER_STDC
AM_PROG_CC_C_O
dnl ***************************************************************************
dnl Internationalization
dnl ***************************************************************************
GETTEXT_PACKAGE=gnome_js_common
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [GETTEXT package name])
AM_GLIB_GNU_GETTEXT
IT_PROG_INTLTOOL([0.35.0])
AM_PROG_LIBTOOL
AC_ARG_ENABLE(seed,
AC_HELP_STRING([--enable-seed],
[enable building and testing of Seed. [default=yes]]),
[want_seed=$enableval],[want_seed="yes"])
if test x"$want_seed" == x"yes" ; then
PKG_CHECK_EXISTS(seed, have_seed=yes, have_seed=no)
if test x"$have_seed" == x"yes" ; then
PKG_CHECK_MODULES(SEED, seed)
AC_SUBST(SEED_CFLAGS)
AC_SUBST(SEED_LDFLAGS)
fi
else
have_seed=no
fi
AC_ARG_ENABLE(gjs,
AC_HELP_STRING([--enable-gjs],
[enable building and testing of gjs. [default=yes]]),
[want_gjs=$enableval],[want_gjs="yes"])
if test x"$want_gjs" == x"yes" ; then
PKG_CHECK_EXISTS(gjs-gi-1.0, have_gjs=yes, have_gjs=no)
if test x"$have_gjs" == x"yes" ; then
PKG_CHECK_MODULES(GJS, gjs-1.0 gjs-gi-1.0)
AC_SUBST(GJS_CFLAGS)
AC_SUBST(GJS_LDFLAGS)
fi
else
have_gjs=no
fi
AM_CONDITIONAL(HAVE_SEED, test "x$have_seed" = "xyes")
AM_CONDITIONAL(HAVE_GJS, test "x$have_gjs" = "xyes")
AC_SUBST(HAVE_SEED)
AC_SUBST(HAVE_GJS)
AC_OUTPUT([
Makefile
po/Makefile.in
modules/Makefile
modules/tweener/Makefile
tests/Makefile
gnome-js-common.pc
])
echo "
Tests:
Seed.........$have_seed
gjs..........$have_gjs
"
This diff is collapsed.
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
bindir=@bindir@
includedir=@includedir@
moduledir=@libdir@/gnome-js
Name: GNOME JS Common
Description: Common modules for GNOME JavaScript bindings.
Version: @VERSION@
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
SUBDIRS=tweener
moduledir=$(libdir)/gnome-js
module_DATA= \
lang.js \
signals.js \
JSON.js \
ArrayUtils.js
EXTRA_DIST= ArrayUtils.js JSON.js signals.js lang.js
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
tweenerdir=$(libdir)/gnome-js/tweener
tweener_DATA= \
equations.js \
tweener.js \
tweenList.js
EXTRA_DIST= equations.js tweener.js tweenList.js
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
# please keep this list sorted alphabetically
#
This diff is collapsed.
# List of source files containing translatable strings.
## Process this file with automake to produce Makefile.in
check_PROGRAMS =
TESTS =
if HAVE_SEED
check_PROGRAMS += run-tests-seed
TESTS += run-tests-seed
run_tests_seed_SOURCES = run-tests-seed.c run-tests.c
run_tests_seed_CFLAGS = \
-Wall \
$(SEED_CFLAGS)
run_tests_seed_LDFLAGS = \
$(SEED_LIBS)
endif
This diff is collapsed.
/*
* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*-
*/
#include <glib.h>
#include <seed.h>
#include <stdlib.h>
#include <stdio.h>
SeedEngine * eng = NULL;
extern gboolean failure_flag;
gboolean test_exec(gchar * filename)
{
SeedObject global;
SeedScript * script;
SeedException e;
gchar * buffer;
if(!eng)
eng = seed_init(NULL, NULL);
g_file_get_contents(filename, &buffer, 0, 0);
if(!buffer)
{
g_critical("File %s not found!", filename);
exit(1);
}
if(*buffer == '#')
{
while(*buffer != '\n')
buffer++;
buffer++;
}
script = seed_make_script(eng->context, buffer, filename, 1);
global = seed_context_get_global_object(eng->context);
seed_importer_add_global(global, filename);
seed_evaluate(eng->context, script, 0);
if((e = seed_script_exception(script)))
{
printf("%s... FAIL (%s: line %d)\n",
filename,
seed_exception_get_name(eng->context, e),
seed_exception_get_line(eng->context, e));
failure_flag = TRUE;
return FALSE;
}
g_free(script);
return TRUE;
}
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment