From 442f8ce70ed232c3add49adf810a404f55dea955 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Minisini?= Date: Sat, 9 Jun 2012 02:44:17 +0000 Subject: [PATCH] [CONFIGURATION] * NEW: Switch version to 3.2.0. [GB.XML] * BUG: Fix a 64-bits compilation warning. git-svn-id: svn://localhost/gambas/trunk@4815 867c0c6c-44f3-4631-809d-bfa615b0a4ec --- acinclude.m4 | 42 ++++++++++++++------------ comp/src/gb.form/.project | 2 +- comp/src/gb.form/.src/Test/FMain.class | 6 ++++ comp/src/gb.web/.project | 2 +- gb.gtk/configure.ac | 2 +- gb.xml/src/utils.cpp | 2 +- main/lib/debug/profile.c | 8 +++++ 7 files changed, 41 insertions(+), 23 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index 96b1917de..57c72eeed 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -64,13 +64,23 @@ AC_DEFUN([GB_PRINT_MESSAGES], AC_DEFUN([GB_INIT_AUTOMAKE], [ - AM_INIT_AUTOMAKE($1, 3.1.90) + AM_INIT_AUTOMAKE($1, 3.2.0) ##AM_SILENT_RULES([yes]) AM_CONFIG_HEADER([config.h]) - ########## DO NOT FORGET TO MODIFY GB_INIT_SHORT ! ########## - AC_DEFINE(GAMBAS_FULL_VERSION, 0x03010090, [Full Gambas version]) - AC_DEFINE(GAMBAS_PCODE_VERSION, 0x03010000, [Gambas bytecode version]) + GAMBAS_VERSION=3 + GAMBAS_MINOR_VERSION=2 + + AC_SUBST(GAMBAS_VERSION) + AC_SUBST(GAMBAS_MINOR_VERSION) + + AC_DEFINE(GAMBAS_VERSION, 3, Gambas version) + AC_DEFINE(GAMBAS_MINOR_VERSION, 2, Gambas minor version) + AC_DEFINE(GAMBAS_VERSION_STRING, "3", Gambas version string) + AC_DEFINE(GAMBAS_FULL_VERSION_STRING, "3.2", Gambas full version string) + + AC_DEFINE(GAMBAS_FULL_VERSION, 0x03020000, [Full Gambas version]) + AC_DEFINE(GAMBAS_PCODE_VERSION, 0x03020000, [Gambas bytecode version]) AC_DEFINE(GAMBAS_PCODE_VERSION_MIN, 0x03000000, [Minimum Gambas bytecode version]) GB_CLEAR_MESSAGES @@ -120,11 +130,6 @@ AC_DEFUN([GB_INIT_SHORT], AC_CANONICAL_HOST - GAMBAS_VERSION=3 - AC_SUBST(GAMBAS_VERSION) - GAMBAS_MINOR_VERSION=1 - AC_SUBST(GAMBAS_MINOR_VERSION) - gbbindir=$bindir/gambas$GAMBAS_VERSION AC_SUBST(gbbindir) gblibdir=$libdir/gambas$GAMBAS_VERSION @@ -159,11 +164,6 @@ AC_DEFUN([GB_INIT], GB_SYSTEM GB_LIBTOOL - AC_DEFINE(GAMBAS_VERSION, 3, Gambas version) - AC_DEFINE(GAMBAS_MINOR_VERSION, 0, Gambas minor version) - AC_DEFINE(GAMBAS_VERSION_STRING, "3", Gambas version string) - AC_DEFINE(GAMBAS_FULL_VERSION_STRING, "3.0", Gambas full version string) - dnl ---- Checks for programs AC_PROG_CPP @@ -726,7 +726,7 @@ AC_DEFUN([GB_COMPONENT_PKG_CONFIG], have_$1=no - if test "$gb_enable_$1"="yes" && test ! -e DISABLED.$3; then + if test "$gb_enable_$1"="yes" && test ! -e DISABLED && test ! -e DISABLED.$3; then AC_MSG_CHECKING(for $3 component with pkg-config) @@ -775,6 +775,7 @@ AC_DEFUN([GB_COMPONENT_PKG_CONFIG], fi done + else AC_DEFINE(HAVE_$2_COMPONENT, 1, [Have $3 component]) @@ -783,7 +784,7 @@ AC_DEFUN([GB_COMPONENT_PKG_CONFIG], fi - if test "$have_$1" = "no" || test -e DISABLED.$3; then + if test "$have_$1" = "no"; then $2_INC="" $2_LIB="" @@ -836,7 +837,7 @@ AC_DEFUN([GB_COMPONENT], gb_inc_$1=no gb_lib_$1=no - if test "$gb_enable_$1" = "yes" && test ! -e DISABLED.$3; then + if test "$gb_enable_$1" = "yes" && test ! -e DISABLED && test ! -e DISABLED.$3; then ## Checking for headers @@ -950,7 +951,7 @@ AC_DEFUN([GB_COMPONENT], fi - if test "$have_$1" = "no" || test -e DISABLED.$3; then + if test "$have_$1" = "no"; then $2_INC="" $2_LIB="" @@ -1026,6 +1027,7 @@ gb_in_component_search=no ## Find QT moc compiler ## ## $1 = QT version +## $2 = components to disable ## ## Returns a path list in $gb_val ## --------------------------------------------------------------------------- @@ -1074,7 +1076,7 @@ AC_DEFUN([GB_FIND_QT_MOC], if test x"$gb_cv_path_qt_moc" = x; then GB_WARNING([QT moc compiler not found. Try --with-moc option.]) MOC="" - touch DISABLED + touch DISABLED else MOC=$gb_cv_path_qt_moc fi @@ -1085,6 +1087,8 @@ AC_DEFUN([GB_FIND_QT_MOC], ## --------------------------------------------------------------------------- ## GB_CHECK_XWINDOW ## Check the X-Window system installation +## +## $1 = components to disable ## --------------------------------------------------------------------------- AC_DEFUN([GB_CHECK_XWINDOW], diff --git a/comp/src/gb.form/.project b/comp/src/gb.form/.project index 148e97e25..bdc4f86b1 100644 --- a/comp/src/gb.form/.project +++ b/comp/src/gb.form/.project @@ -1,7 +1,7 @@ # Gambas Project File 3.0 # Compiled with Gambas 3.1.90 Title=More controls for graphical components -Startup=Form1 +Startup=FMain Version=3.1.90 VersionFile=1 Component=gb.image diff --git a/comp/src/gb.form/.src/Test/FMain.class b/comp/src/gb.form/.src/Test/FMain.class index 6383a0ac6..2d8dad51d 100644 --- a/comp/src/gb.form/.src/Test/FMain.class +++ b/comp/src/gb.form/.src/Test/FMain.class @@ -166,3 +166,9 @@ Public Sub gvwView_MouseDown() Debug Mouse.X;; Mouse.Y End + +Public Sub gvwView_KeyPress() + + Debug Key.Code + +End diff --git a/comp/src/gb.web/.project b/comp/src/gb.web/.project index 61cdfc12e..5ffd50404 100644 --- a/comp/src/gb.web/.project +++ b/comp/src/gb.web/.project @@ -1,5 +1,5 @@ # Gambas Project File 3.0 -# Compiled with Gambas 3.1.90 +# Compiled with Gambas 3.2.0 Title=Web applications tools Startup=Webpage1 Version=3.1.90 diff --git a/gb.gtk/configure.ac b/gb.gtk/configure.ac index 9f1739599..73d941477 100644 --- a/gb.gtk/configure.ac +++ b/gb.gtk/configure.ac @@ -5,7 +5,7 @@ AC_CONFIG_MACRO_DIR([m4]) GB_INIT(gb.gtk) AC_PROG_LIBTOOL -GB_CHECK_XWINDOW +GB_CHECK_XWINDOW() GB_COMPONENT_PKG_CONFIG( gtk, GTK, gb.gtk, [src], diff --git a/gb.xml/src/utils.cpp b/gb.xml/src/utils.cpp index fea8a934c..8c87d8bdc 100644 --- a/gb.xml/src/utils.cpp +++ b/gb.xml/src/utils.cpp @@ -175,7 +175,7 @@ XMLParseException::XMLParseException(const char *nerror, const char *data, const //Parse error : (errorText) !\n Line 123456789 , Column 123456789 : \n (near) errorWhat = (char*)malloc(61 + lenError + lenNear); memset(errorWhat, 0, 61 + lenError + lenNear); - sprintf(errorWhat, "Parse error : %s !\n Line %u , Column %u : \n %s", error, line, column, near); + sprintf(errorWhat, "Parse error : %s !\n Line %lu , Column %lu : \n %s", error, line, column, near); errorWhat[60 + lenError + lenNear] = 0; } diff --git a/main/lib/debug/profile.c b/main/lib/debug/profile.c index 858673626..8acffa122 100644 --- a/main/lib/debug/profile.c +++ b/main/lib/debug/profile.c @@ -39,6 +39,7 @@ static FILE *_file; static int _last_line = 0; static bool _new_line = TRUE; static int _count = 0; +static size_t _max_profile_size = MAX_PROFILE_SIZE; //static long _ticks_per_sec; static uint64_t get_time(void) @@ -63,6 +64,8 @@ static uint64_t get_time(void) void PROFILE_init(void) { char path[PATH_MAX + 1]; + char *env; + size_t max; if (_init) return; @@ -81,6 +84,11 @@ void PROFILE_init(void) //_ticks_per_sec = sysconf(_SC_CLK_TCK); //fprintf(stderr, "_ticks_per_sec = %ld\n", _ticks_per_sec); + //env = getenv("GB_PROFILE + + max = 1; + + _init = TRUE; get_time(); }