diff --git a/harbour/COPYING b/harbour/COPYING index 02938db7cc..1ea2f56bd8 100644 --- a/harbour/COPYING +++ b/harbour/COPYING @@ -2,7 +2,7 @@ THE HARBOUR PROJECT COMPILER LICENSE ==================================== Note: This license applies to most of the files in the src/compiler - and utils/hbmk2 directories. + and utils/hbmk2 directories and certain .hbs Harbour scripts. 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 @@ -546,7 +546,7 @@ Creative Commons may be contacted at http://creativecommons.org/. GNU GENERAL PUBLIC LICENSE VERSION 2 ==================================== -Binary tools included in Harbour source repository +Binary tools included in Harbour source repository all use GNU GPL 2. Find it below: ------------------------------------------------------------------------ diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 2cbb8e1e80..662c99a0ac 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -16,6 +16,17 @@ The license applies to all entries newer than 2009-04-28. */ +2010-07-04 15:46 UTC+0200 Viktor Szakats (harbour.01 syenar.hu) + * COPYING + * utils/hbmk2/examples/plug_tpl.hbs + * contrib/hbqt/hbmk2_plugin_qt.hbs + + Changed to use same license as hbmk2 (pure GPL) + also for hbmk2 plugin scripts. + + * utils/hbmk2/hbmk2.prg + ! Corrected to display any type of return value coming from + plugins. (all non-empty return value is considered an error) + 2010-07-04 15:27 UTC+0200 Viktor Szakats (harbour.01 syenar.hu) * bin/patchup.hbs * contrib/hbqt/hbmk2_plugin_qt.hbs diff --git a/harbour/contrib/hbqt/hbmk2_plugin_qt.hbs b/harbour/contrib/hbqt/hbmk2_plugin_qt.hbs index 2717af9636..9f26c1d1b0 100644 --- a/harbour/contrib/hbqt/hbmk2_plugin_qt.hbs +++ b/harbour/contrib/hbqt/hbmk2_plugin_qt.hbs @@ -11,8 +11,8 @@ * * 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. + * the Free Software Foundation; either version 2 of the License, 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 @@ -20,33 +20,9 @@ * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License - * along with this software; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place, Suite 330, - * Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/). - * - * As a special exception, the Harbour Project gives permission for - * additional uses of the text contained in its release of Harbour. - * - * The exception is that, if you link the Harbour libraries with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the Harbour library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by the Harbour - * Project under the name Harbour. If you copy code from other - * Harbour Project or Free Software Foundation releases into a copy of - * Harbour, as the General Public License permits, the exception does - * not apply to the code that you add in this way. To avoid misleading - * anyone as to the status of such modified files, you must delete - * this exception notice from them. - * - * If you write modifications of your own for Harbour, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). * */ diff --git a/harbour/utils/hbmk2/examples/plug_tpl.hbs b/harbour/utils/hbmk2/examples/plug_tpl.hbs index 2fb2175280..166d105f2e 100644 --- a/harbour/utils/hbmk2/examples/plug_tpl.hbs +++ b/harbour/utils/hbmk2/examples/plug_tpl.hbs @@ -3,69 +3,53 @@ */ /* - * hbmk2 plugin sample + * hbmk2 plugin example * * Copyright 2010 Viktor Szakats (harbour.01 syenar.hu) - * See COPYING for licensing terms. + * www - http://harbour-project.org + * + * 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 of the License, 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, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). + * */ -FUNCTION hbmk2_plugin_tpl( hbmk2 ) - LOCAL cMOC_BIN +#pragma warninglevel=3 +FUNCTION hbmk2_plugin_tpl( hbmk2 ) LOCAL tmp + IF hbmk2[ "lTRACE" ] + hbmk2_OutStd( hbmk2, "@@ Entered plugin: " + hbmk2[ "cSTATE" ] ) + ENDIF + SWITCH hbmk2[ "cSTATE" ] CASE "pre_all" FOR EACH tmp IN hbmk2[ "params" ] hbmk2_OutStd( hbmk2, hb_StrFormat( "Parameter #%1$s: '%2$s'", hb_ntos( tmp:__enumIndex() ), tmp ) ) NEXT - - hbmk2_AddInput_C( hbmk2, "hello.c" ) EXIT CASE "pre_c" - - cMOC_BIN := GetEnv( "MOC_BIN" ) - IF Empty( cMOC_BIN ) - IF Empty( GetEnv( "HB_QT_MOC_BIN" ) ) - IF hbmk2[ "cPLAT" ] == "win" - cMOC_BIN := GetEnv( "HB_WITH_QT" ) + "\..\bin\moc.exe" - IF ! hb_FileExists( cMOC_BIN ) - hbmk2_OutErr( hbmk2, "HB_WITH_QT points to incomplete QT installation. moc executable not found." ) - RETURN NIL - ENDIF - ELSE - cMOC_BIN := hbmk2_FindInPath( "moc", "/opt/qtsdk/qt/bin" ) - IF Empty( cMOC_BIN ) - cMOC_BIN := hbmk2_FindInPath( "moc", "/opt/qtsdk/qt/bin" ) - IF Empty( cMOC_BIN ) - hbmk2_OutErr( hbmk2, "HB_QT_MOC_BIN not set, could not autodetect" ) - RETURN NIL - ENDIF - ENDIF - ENDIF - hbmk2_OutStd( hbmk2, "Using QT 'moc' executable: " + cMOC_BIN + " (autodetected)" ) - ELSE - IF hb_FileExists( GetEnv( "HB_QT_MOC_BIN" ) ) - cMOC_BIN := GetEnv( "HB_QT_MOC_BIN" ) - hbmk2_OutStd( hbmk2, "Using QT 'moc' executable: " + cMOC_BIN ) - ELSE - hbmk2_OutErr( hbmk2, "HB_QT_MOC_BIN points to non-existent file. Make sure to set it to full path and filename of moc executable." ) - RETURN NIL - ENDIF - ENDIF - ENDIF - - hbmk2[ "vars" ][ "MOC_BIN" ] := cMOC_BIN - + hbmk2[ "vars" ][ "MyVar" ] := "Hello world!" EXIT + CASE "post_all" - hbmk2_OutStd( hbmk2, "POST_ALL: " + hbmk2[ "vars" ][ "MOC_BIN" ] ) - OTHERWISE - IF hbmk2[ "lTRACE" ] - hbmk2_OutStd( hbmk2, "@@ Entered plugin: " + hbmk2[ "cSTATE" ] ) - ENDIF + hbmk2_OutStd( hbmk2, "POST_ALL: " + hbmk2[ "vars" ][ "MyVar" ] ) + EXIT + ENDSWITCH RETURN NIL diff --git a/harbour/utils/hbmk2/hbmk2.prg b/harbour/utils/hbmk2/hbmk2.prg index 27137f8a3f..33da3b8ef8 100644 --- a/harbour/utils/hbmk2/hbmk2.prg +++ b/harbour/utils/hbmk2/hbmk2.prg @@ -6620,7 +6620,7 @@ STATIC PROCEDURE PlugIn_call_low( hbmk, cName, hrb, ctx ) xResult := hb_hrbDo( hrb, ctx ) IF ! Empty( xResult ) IF hbmk[ _HBMK_lInfo ] - hbmk_OutStd( hbmk, hb_StrFormat( I_( "Plugin %1$s returned: '%2$s'" ), cName, xResult ) ) + hbmk_OutStd( hbmk, hb_StrFormat( I_( "Plugin %1$s returned: '%2$s'" ), cName, hb_cstr( xResult ) ) ) ENDIF ENDIF RECOVER USING oError