From bd8692f80bf3a49cf450abefff1c507cfc52dc9a Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 22 Mar 2013 01:59:56 +0100 Subject: [PATCH 1/9] guestbk made runnable as script, enabled -w3 warnings, fixed to build with gtcgi, fixed -w3 warnings --- ChangeLog.txt | 10 ++++++++++ extras/guestbk/{cgi.prg => _cgi.prg} | 20 +++++++++---------- extras/guestbk/{inifiles.prg => _inifile.prg} | 0 extras/guestbk/guestbk.hbp | 8 ++++++-- extras/guestbk/guestbk.prg | 4 +++- 5 files changed, 28 insertions(+), 14 deletions(-) rename extras/guestbk/{cgi.prg => _cgi.prg} (96%) rename extras/guestbk/{inifiles.prg => _inifile.prg} (100%) diff --git a/ChangeLog.txt b/ChangeLog.txt index 06bcfb4321..166f18243e 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -10,6 +10,16 @@ * Change, ! Fix, % Optimization, + Addition, - Removal, ; Comment */ +2013-03-22 01:52 UTC+0100 Viktor Szakats (harbour syenar.net) + * extras/guestbk/guestbk.hbp + * extras/guestbk/guestbk.prg + * extras/guestbk/inifiles.prg -> extras/guestbk/_inifile.prg + * extras/guestbk/cgi.prg -> extras/guestbk/_cgi.prg + + guestbk made runnable as script + + enabled -w3 warnings + ! fixed to build with gtcgi + ! fixed -w3 warnings + 2013-03-21 19:00 UTC+0100 Viktor Szakats (harbour syenar.net) * utils/hbmk2/hbmk2.prg + when running a script with hbrun/hbmk2 form cmdline, diff --git a/extras/guestbk/cgi.prg b/extras/guestbk/_cgi.prg similarity index 96% rename from extras/guestbk/cgi.prg rename to extras/guestbk/_cgi.prg index 10b7eba096..bf30a980bb 100644 --- a/extras/guestbk/cgi.prg +++ b/extras/guestbk/_cgi.prg @@ -124,7 +124,9 @@ METHOD AddPara( cPara, cAlign ) CLASS THTML METHOD Generate() CLASS THTML LOCAL cFile, i, hFile, nPos, cRes := "" +#if 0 LOCAL lFlag := .F. +#endif // Is this a meta file or hand generated script? IF Empty( ::cHTMLFile ) @@ -208,13 +210,13 @@ METHOD SaveToFile( cFile ) CLASS THTML METHOD ProcessCGI() CLASS THTML - LOCAL cQuery := "" - LOCAL cBuff := "" - LOCAL nBuff := 0 + LOCAL cQuery + LOCAL cBuff := "" + LOCAL nBuff := 0 LOCAL i IF Empty( ::aCGIContents ) - ::aCGIContents := { ; + ::aCGIContents := { ; GetEnv( "SERVER_SOFTWARE" ), ; GetEnv( "SERVER_NAME" ), ; GetEnv( "GATEWAY_INTERFACE" ), ; @@ -234,8 +236,7 @@ METHOD ProcessCGI() CLASS THTML GetEnv( "AUTH_TYPE" ), ; GetEnv( "CONTENT_TYPE" ), ; GetEnv( "CONTENT_LENGTH" ), ; - GetEnv( "ANNOTATION_SERVER" ) ; - } + GetEnv( "ANNOTATION_SERVER" ) } cQuery := ::GetCGIParam( CGI_QUERY_STRING ) @@ -247,8 +248,8 @@ METHOD ProcessCGI() CLASS THTML IF i > Len( cQuery ) .OR. SubStr( cQuery, i, 1 ) == "&" - AAdd( ::aQueryFields, ; - { SubStr( cBuff, 1, At( "=", cBuff ) - 1 ), ; + AAdd( ::aQueryFields, { ; + SubStr( cBuff, 1, At( "=", cBuff ) - 1 ), ; StrTran( SubStr( cBuff, At( "=", cBuff ) + 1, ; Len( cBuff ) - At( "=", cBuff ) + 1 ), "+", " " ) } ) cBuff := "" @@ -264,11 +265,8 @@ METHOD ProcessCGI() CLASS THTML nBuff-- ENDIF ENDIF - NEXT - ENDIF - ENDIF RETURN Self diff --git a/extras/guestbk/inifiles.prg b/extras/guestbk/_inifile.prg similarity index 100% rename from extras/guestbk/inifiles.prg rename to extras/guestbk/_inifile.prg diff --git a/extras/guestbk/guestbk.hbp b/extras/guestbk/guestbk.hbp index ee2497773c..0699658c7a 100644 --- a/extras/guestbk/guestbk.hbp +++ b/extras/guestbk/guestbk.hbp @@ -1,4 +1,8 @@ +-w3 -es2 + +-nulrdd + +-gtcgi + guestbk.prg -inifiles.prg -cgi.prg diff --git a/extras/guestbk/guestbk.prg b/extras/guestbk/guestbk.prg index be2546d4b2..94d6656ced 100644 --- a/extras/guestbk/guestbk.prg +++ b/extras/guestbk/guestbk.prg @@ -51,7 +51,6 @@ PROCEDURE Main() LOCAL oIni := TIniFile():New( "C:\inetpub\wwwroot\guestbk.ini" ) LOCAL oHTML := THtml():New() - LOCAL aEntr := {} LOCAL cOddColor, cEvenColor LOCAL cCode, i, j, l, cField, nEntry, cColor LOCAL aEntries, aLine, cLine @@ -155,3 +154,6 @@ PROCEDURE Main() ENDIF RETURN + +SET PROCEDURE TO "_cgi.prg" +SET PROCEDURE TO "_inifile.prg" From 6384cc31267c4d01902783f296521b493f2312b5 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 22 Mar 2013 02:26:50 +0100 Subject: [PATCH 2/9] hbnetio made runnable as script, minor cleanups --- ChangeLog.txt | 9 +++++++++ .../utils/hbnetio/{netiocon.prg => _console.prg} | 0 .../utils/hbnetio/{netiosvc.prg => _winsvc.prg} | 0 contrib/hbnetio/utils/hbnetio/hbnetio.hbp | 7 +++---- .../utils/hbnetio/{netiosrv.prg => hbnetio.prg} | 13 +++++++++---- contrib/hbwin/tests/dlg.prg | 2 +- 6 files changed, 22 insertions(+), 9 deletions(-) rename contrib/hbnetio/utils/hbnetio/{netiocon.prg => _console.prg} (100%) rename contrib/hbnetio/utils/hbnetio/{netiosvc.prg => _winsvc.prg} (100%) rename contrib/hbnetio/utils/hbnetio/{netiosrv.prg => hbnetio.prg} (98%) diff --git a/ChangeLog.txt b/ChangeLog.txt index 166f18243e..62bf8581be 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -10,6 +10,15 @@ * Change, ! Fix, % Optimization, + Addition, - Removal, ; Comment */ +2013-03-22 02:26 UTC+0100 Viktor Szakats (harbour syenar.net) + * contrib/hbnetio/utils/hbnetio/hbnetio.hbp + * contrib/hbwin/tests/dlg.prg + * contrib/hbnetio/utils/hbnetio/netiocon.prg -> contrib/hbnetio/utils/hbnetio/_console.prg + * contrib/hbnetio/utils/hbnetio/netiosvc.prg -> contrib/hbnetio/utils/hbnetio/_winsvc.prg + * contrib/hbnetio/utils/hbnetio/netiosrv.prg -> contrib/hbnetio/utils/hbnetio/hbnetio.prg + + hbnetio made runnable as script + * minor cleanups + 2013-03-22 01:52 UTC+0100 Viktor Szakats (harbour syenar.net) * extras/guestbk/guestbk.hbp * extras/guestbk/guestbk.prg diff --git a/contrib/hbnetio/utils/hbnetio/netiocon.prg b/contrib/hbnetio/utils/hbnetio/_console.prg similarity index 100% rename from contrib/hbnetio/utils/hbnetio/netiocon.prg rename to contrib/hbnetio/utils/hbnetio/_console.prg diff --git a/contrib/hbnetio/utils/hbnetio/netiosvc.prg b/contrib/hbnetio/utils/hbnetio/_winsvc.prg similarity index 100% rename from contrib/hbnetio/utils/hbnetio/netiosvc.prg rename to contrib/hbnetio/utils/hbnetio/_winsvc.prg diff --git a/contrib/hbnetio/utils/hbnetio/hbnetio.hbp b/contrib/hbnetio/utils/hbnetio/hbnetio.hbp index 59960043a8..12f7e867ee 100644 --- a/contrib/hbnetio/utils/hbnetio/hbnetio.hbp +++ b/contrib/hbnetio/utils/hbnetio/hbnetio.hbp @@ -2,13 +2,12 @@ hbnetio.hbc -mt --w3 -es2 -l- +-w3 -es2 -l -o${hb_name} -netiosrv.prg -netiocon.prg -netiomgm.hb +hbnetio.prg + netiosvc.prg{win} -main=WinMain{win} hbwin.hbc{win} diff --git a/contrib/hbnetio/utils/hbnetio/netiosrv.prg b/contrib/hbnetio/utils/hbnetio/hbnetio.prg similarity index 98% rename from contrib/hbnetio/utils/hbnetio/netiosrv.prg rename to contrib/hbnetio/utils/hbnetio/hbnetio.prg index 6190a0c803..188bcc314b 100644 --- a/contrib/hbnetio/utils/hbnetio/netiosrv.prg +++ b/contrib/hbnetio/utils/hbnetio/hbnetio.prg @@ -204,7 +204,9 @@ PROCEDURE netiosrv_Main( lUI, ... ) netiosrv[ _NETIOSRV_lRPC ] := .T. CASE Lower( cParam ) == "--version" RETURN - CASE Lower( cParam ) == "-help" .OR. ; + CASE Lower( cParam ) == "-?" .OR. ; + Lower( cParam ) == "-h" .OR. ; + Lower( cParam ) == "-help" .OR. ; Lower( cParam ) == "--help" HB_Usage() RETURN @@ -871,16 +873,19 @@ STATIC PROCEDURE HB_Usage() OutStd( hb_StrFormat( " Default: %1$d", _NETIOMGM_PORT_DEF ) , hb_eol() ) OutStd( " -adminiface= accept manegement connections on IPv4 interface " , hb_eol() ) OutStd( hb_StrFormat( " Default: %1$s", _NETIOMGM_IPV4_DEF ) , hb_eol() ) - OutStd( " -adminpass= set remote management password" , hb_eol() ) + OutStd( " -adminpass= set remote management password and enable management server" , hb_eol() ) OutStd( hb_eol() ) OutStd( " -noui don't open interactive console" , hb_eol() ) OutStd( hb_eol() ) - #if defined( __PLATFORM__WINDOWS ) + #if ! defined( __HBSCRIPT__HBSHELL ) .AND. defined( __PLATFORM__WINDOWS ) OutStd( " -i install as service (requires admin rights)" , hb_eol() ) OutStd( " -u uninstall service (requires admin rights)" , hb_eol() ) OutStd( hb_eol() ) #endif OutStd( " --version display version header only" , hb_eol() ) - OutStd( " -help|--help this help" , hb_eol() ) + OutStd( " -?|-h|-help|--help this help" , hb_eol() ) RETURN + +SET PROCEDURE TO "_console.prg" +SET PROCEDURE TO "netiomgm.hb" diff --git a/contrib/hbwin/tests/dlg.prg b/contrib/hbwin/tests/dlg.prg index 52477d5a6a..bbad6aa09f 100644 --- a/contrib/hbwin/tests/dlg.prg +++ b/contrib/hbwin/tests/dlg.prg @@ -1,7 +1,7 @@ /* * This example demonstrates how to work with some features of the native Win32 * API. The following function displays a dialog created with an external - * resource editor (Pelles C) + * resource editor. * 2010-06-10 - 00:16:41 - [vailtom] */ From 276258331040576e33af3972f2e75c2006d3a848 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szak=C3=A1ts=20Viktor?= Date: Fri, 22 Mar 2013 02:48:07 +0100 Subject: [PATCH 3/9] Created .travis.yml build-control --- .travis.yml | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000000..d9f250a544 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,3 @@ +language: c +compiler: gcc +script: make From 9f50a34b069149d8103deaa3936210bbece5b686 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szak=C3=A1ts=20Viktor?= Date: Fri, 22 Mar 2013 02:52:52 +0100 Subject: [PATCH 4/9] c -> clang --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index d9f250a544..992923be55 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,3 +1,3 @@ language: c -compiler: gcc +compiler: clang script: make From 056d1e1aeed669feb61658def5fdc2d0ec8aa03d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szak=C3=A1ts=20Viktor?= Date: Fri, 22 Mar 2013 03:09:18 +0100 Subject: [PATCH 5/9] travis: added clang, enabled libmagic --- .travis.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 992923be55..527b2cf823 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,3 +1,7 @@ language: c -compiler: clang +compiler: + - gcc + - clang script: make +before_install: + - sudo apt-get install -qq libmagic-dev From a10a4faf576b1590604f694a261d135b9784c5e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szak=C3=A1ts=20Viktor?= Date: Fri, 22 Mar 2013 03:42:21 +0100 Subject: [PATCH 6/9] travic: gcc only log doesn't seem to appear with dual builds --- .travis.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 527b2cf823..811974fafe 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,6 @@ language: c compiler: - gcc - - clang script: make before_install: - sudo apt-get install -qq libmagic-dev From 22710f54926602e3c1678980ce127b9e42a691c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szak=C3=A1ts=20Viktor?= Date: Fri, 22 Mar 2013 03:43:31 +0100 Subject: [PATCH 7/9] travis: minor --- .travis.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 811974fafe..3656e67972 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,5 @@ language: c -compiler: - - gcc +compiler: gcc script: make before_install: - sudo apt-get install -qq libmagic-dev From a0b7d02b9d44c5a78344a4ba031cd7c539948d55 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 22 Mar 2013 03:50:10 +0100 Subject: [PATCH 8/9] expat installation examples deleted (it's hosted locally) --- ChangeLog.txt | 4 ++++ README.txt | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index 62bf8581be..f094d1cdc2 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -10,6 +10,10 @@ * Change, ! Fix, % Optimization, + Addition, - Removal, ; Comment */ +2013-03-22 03:49 UTC+0100 Viktor Szakats (harbour syenar.net) + * README.txt + ! expat installation examples deleted (it's hosted locally) + 2013-03-22 02:26 UTC+0100 Viktor Szakats (harbour syenar.net) * contrib/hbnetio/utils/hbnetio/hbnetio.hbp * contrib/hbwin/tests/dlg.prg diff --git a/README.txt b/README.txt index 36dddb7415..b1ee78a910 100644 --- a/README.txt +++ b/README.txt @@ -470,7 +470,6 @@ TABLE OF CONTENT for contrib/hbcups lib: $ sudo apt-get install libcups2-dev for contrib/hbcurl lib: $ sudo apt-get install libcurl4-openssl-dev OR $ sudo apt-get install libcurl4-gnutls-dev - for contrib/hbexpat lib: $ sudo apt-get install libexpat1-dev for contrib/hbfbird lib: $ sudo apt-get install firebird2.1-dev OR $ sudo apt-get install libfirebird2.0-dev for contrib/hbfimage lib: $ sudo apt-get install libfreeimage-dev @@ -508,7 +507,6 @@ TABLE OF CONTENT for contrib/hbcairo lib: cairo-devel for contrib/hbcups lib: libcups2-devel for contrib/hbcurl lib: curl-devel - for contrib/hbexpat lib: libexpat-devel for contrib/hbfbird lib: firebird-devel for contrib/hbfimage lib: freeimage-devel for contrib/hbgd lib: gd-devel From 3640917ad8afbe357bc138aa463bdf7456a5cdf9 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 22 Mar 2013 11:12:49 +0100 Subject: [PATCH 9/9] added link to automated build service page --- ChangeLog.txt | 4 ++++ README.txt | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/ChangeLog.txt b/ChangeLog.txt index f094d1cdc2..6348d7654c 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -10,6 +10,10 @@ * Change, ! Fix, % Optimization, + Addition, - Removal, ; Comment */ +2013-03-22 11:12 UTC+0100 Viktor Szakats (harbour syenar.net) + * README.txt + + added link to automated build service page + 2013-03-22 03:49 UTC+0100 Viktor Szakats (harbour syenar.net) * README.txt ! expat installation examples deleted (it's hosted locally) diff --git a/README.txt b/README.txt index b1ee78a910..cdc6e37f49 100644 --- a/README.txt +++ b/README.txt @@ -1309,6 +1309,11 @@ TABLE OF CONTENT Mac app: https://itunes.apple.com/us/app/committed/id560767719 Mac tool: https://github.com/marcocampana/git-notifier + 5.) Build status and details + + https://travis-ci.org/harbour/core + + 10. TROUBLESHOOTING ===================