seed r651 - in trunk: . modules/Multiprocessing modules/canvas modules/example modules/readline modules/sqlite tests



Author: hortont
Date: Mon Jan  5 06:34:54 2009
New Revision: 651
URL: http://svn.gnome.org/viewvc/seed?rev=651&view=rev

Log:
Enable profiling for some modules, simple SQLite test.

When we have tests for Multiprocessing and canvas, add them to the lcov call in Makefile.am



Added:
   trunk/tests/quit2.js   (contents, props changed)
   trunk/tests/sqlite.js   (contents, props changed)
Modified:
   trunk/Makefile.am
   trunk/ltmain.sh
   trunk/modules/Multiprocessing/Makefile.am
   trunk/modules/canvas/Makefile.am
   trunk/modules/example/Makefile.am
   trunk/modules/readline/Makefile.am
   trunk/modules/sqlite/Makefile.am
   trunk/modules/sqlite/example.js

Modified: trunk/Makefile.am
==============================================================================
--- trunk/Makefile.am	(original)
+++ trunk/Makefile.am	Mon Jan  5 06:34:54 2009
@@ -43,9 +43,22 @@
 
 profile: profile-reset test
 	cp libseed/*.c libseed/.libs/
+	
+	cp modules/readline/*.c modules/readline/.libs/
+	cp modules/example/*.c modules/example/.libs/
+	cp modules/sqlite/*.c modules/sqlite/.libs/
+	cp modules/canvas/*.c modules/canvas/.libs/
+	cp modules/Multiprocessing/*.c modules/Multiprocessing/.libs/
+	
 	cd libseed/.libs ; gcov *.c
+	
+	cd modules/readline/.libs ; gcov *.c
+	cd modules/example/.libs ; gcov *.c
+	cd modules/sqlite/.libs ; gcov *.c
+	cd modules/canvas/.libs ; gcov *.c
+	cd modules/Multiprocessing/.libs ; gcov *.c
 
 profile-gui: profile
-	lcov --directory libseed/.libs --capture --output-file seed.info
+	lcov --directory libseed/.libs --directory modules/readline/.libs --directory modules/example/.libs --directory modules/sqlite/.libs --capture --output-file seed.info
 	cp seed.info /tmp/
 	cd /tmp ; genhtml seed.info ; gnome-open index.html

Modified: trunk/ltmain.sh
==============================================================================
--- trunk/ltmain.sh	(original)
+++ trunk/ltmain.sh	Mon Jan  5 06:34:54 2009
@@ -65,7 +65,7 @@
 #       compiler:		$LTCC
 #       compiler flags:		$LTCFLAGS
 #       linker:		$LD (gnu? $with_gnu_ld)
-#       $progname:		(GNU libtool) 2.2.4 Debian-2.2.4-0ubuntu5
+#       $progname:		(GNU libtool) 2.2.4 Debian-2.2.4-0ubuntu4
 #       automake:		$automake_version
 #       autoconf:		$autoconf_version
 #
@@ -73,7 +73,7 @@
 
 PROGRAM=ltmain.sh
 PACKAGE=libtool
-VERSION="2.2.4 Debian-2.2.4-0ubuntu5"
+VERSION="2.2.4 Debian-2.2.4-0ubuntu4"
 TIMESTAMP=""
 package_revision=1.2976
 

Modified: trunk/modules/Multiprocessing/Makefile.am
==============================================================================
--- trunk/modules/Multiprocessing/Makefile.am	(original)
+++ trunk/modules/Multiprocessing/Makefile.am	Mon Jan  5 06:34:54 2009
@@ -11,7 +11,10 @@
 	-I../../libseed/ \
 	`pkg-config --cflags seed` \
 	`pkg-config --cflags glib-2.0` -g \
-	`pkg-config --cflags gobject-introspection-1.0`
+	`pkg-config --cflags gobject-introspection-1.0` \
+	$(SEED_DEBUG_CFLAGS) $(SEED_PROFILE_CFLAGS)
+
+AM_LDFLAGS = $(SEED_PROFILE_LDFLAGS)
 
 EXTRA_DIST = fork.js bi.js
 

Modified: trunk/modules/canvas/Makefile.am
==============================================================================
--- trunk/modules/canvas/Makefile.am	(original)
+++ trunk/modules/canvas/Makefile.am	Mon Jan  5 06:34:54 2009
@@ -14,9 +14,12 @@
 	`pkg-config --cflags seed` \
 	`pkg-config --cflags glib-2.0` -g \
 	`pkg-config --cflags gobject-introspection-1.0` \
-	`pkg-config --cflags cairo`
+	`pkg-config --cflags cairo` \
+	$(SEED_DEBUG_CFLAGS) $(SEED_PROFILE_CFLAGS)
+
+AM_LDFLAGS = $(SEED_PROFILE_LDFLAGS)
 
 endif
 
 libdir = ${exec_prefix}/lib/seed
-EXTRA_DIST=run-tests.js
\ No newline at end of file
+EXTRA_DIST=run-tests.js

Modified: trunk/modules/example/Makefile.am
==============================================================================
--- trunk/modules/example/Makefile.am	(original)
+++ trunk/modules/example/Makefile.am	Mon Jan  5 06:34:54 2009
@@ -11,7 +11,10 @@
 	-I../../libseed/ \
 	`pkg-config --cflags seed` \
 	`pkg-config --cflags glib-2.0` -g \
-	`pkg-config --cflags gobject-introspection-1.0`
+	`pkg-config --cflags gobject-introspection-1.0` \
+	$(SEED_DEBUG_CFLAGS) $(SEED_PROFILE_CFLAGS)
+
+AM_LDFLAGS = $(SEED_PROFILE_LDFLAGS)
 
 libdir = ${exec_prefix}/lib/seed
 

Modified: trunk/modules/readline/Makefile.am
==============================================================================
--- trunk/modules/readline/Makefile.am	(original)
+++ trunk/modules/readline/Makefile.am	Mon Jan  5 06:34:54 2009
@@ -14,7 +14,10 @@
 	`pkg-config --cflags seed` \
 	`pkg-config --cflags glib-2.0` -g \
 	`pkg-config --cflags gobject-introspection-1.0` \
-	`pkg-config --cflags libffi`
+	`pkg-config --cflags libffi` \
+	$(SEED_DEBUG_CFLAGS) $(SEED_PROFILE_CFLAGS)
+
+AM_LDFLAGS = $(SEED_PROFILE_LDFLAGS)
 
 endif
 

Modified: trunk/modules/sqlite/Makefile.am
==============================================================================
--- trunk/modules/sqlite/Makefile.am	(original)
+++ trunk/modules/sqlite/Makefile.am	Mon Jan  5 06:34:54 2009
@@ -13,9 +13,12 @@
 	-I../../libseed/ \
 	`pkg-config --cflags seed` \
 	`pkg-config --cflags glib-2.0` -g \
-	`pkg-config --cflags gobject-introspection-1.0`
+	`pkg-config --cflags gobject-introspection-1.0` \
+	$(SEED_DEBUG_CFLAGS) $(SEED_PROFILE_CFLAGS)
+
+AM_LDFLAGS = $(SEED_PROFILE_LDFLAGS)
 
 endif
 
 libdir = ${exec_prefix}/lib/seed
-EXTRA_DIST = example.js
\ No newline at end of file
+EXTRA_DIST = example.js

Modified: trunk/modules/sqlite/example.js
==============================================================================
--- trunk/modules/sqlite/example.js	(original)
+++ trunk/modules/sqlite/example.js	Mon Jan  5 06:34:54 2009
@@ -1,4 +1,4 @@
-#!/usr/local/bin/seed
+#!/usr/bin/env seed
 Seed.import_namespace("sqlite");
 d = new sqlite.Database(Seed.argv[2]);
 
@@ -9,4 +9,4 @@
 
 d.exec("select * from t1", function(results){Seed.print(JSON.stringify(results))});
 
-d.close();
\ No newline at end of file
+d.close();

Added: trunk/tests/quit2.js
==============================================================================
--- (empty file)
+++ trunk/tests/quit2.js	Mon Jan  5 06:34:54 2009
@@ -0,0 +1,7 @@
+#!/usr/bin/env seed
+// Returns: 0
+// STDIN:
+// STDOUT:
+// STDERR:
+
+Seed.quit(0);

Added: trunk/tests/sqlite.js
==============================================================================
--- (empty file)
+++ trunk/tests/sqlite.js	Mon Jan  5 06:34:54 2009
@@ -0,0 +1,24 @@
+#!/usr/bin/env seed
+// Returns: 0
+// STDIN:
+// STDOUT:\{"t1key":"1","data":"This is sample data","num":"3\.0","timeEnter":""\}\n\{"t1key":"2","data":"More sample data","num":"6\.0","timeEnter":""\}\n\{"t1key":"3","data":"And a little more","num":"9\.0","timeEnter":""\}
+// STDERR:
+
+Seed.import_namespace("sqlite");
+Seed.import_namespace("Gio");
+
+try
+{
+	Gio.file_new_for_path("/tmp/.seed_test.db")["delete"]();
+} catch(e) { }
+
+d = new sqlite.Database("/tmp/.seed_test.db");
+
+d.exec("create table t1 (t1key INTEGER PRIMARY KEY,data TEXT,num double,timeEnter DATE);");
+d.exec("insert into t1 (data,num) values ('This is sample data',3);");
+d.exec("insert into t1 (data,num) values ('More sample data',6);");
+d.exec("insert into t1 (data,num) values ('And a little more',9);");
+
+d.exec("select * from t1", function(results){Seed.print(JSON.stringify(results))});
+
+d.close();



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]