Changeset 55e44d4 in nscp


Ignore:
Timestamp:
10/04/09 23:40:03 (4 years ago)
Author:
Michael Medin <michael@…>
Branches:
master, 0.4.0, 0.4.1, 0.4.2, stable
Children:
2e8b33f
Parents:
1fc246c
Message:

Added new command: assert which causes program to assert (and "crash") which I will use to test the debug builds.
Also reworked the build scripts to work better and such

Files:
1 added
7 edited

Legend:

Unmodified
Added
Removed
  • AutoBuild.h

    r1fc246c r55e44d4  
    33// change the FALSE to TRUE for autoincrement of build number 
    44#define INCREMENT_VERSION TRUE 
    5 #define FILEVER        0,3,7,347 
    6 #define PRODUCTVER     0,3,7,347 
    7 #define STRFILEVER     _T("0.3.7.347") 
    8 #define STRPRODUCTVER  _T("0.3.7.347") 
    9 #define STRPRODUCTDATE  _T("2009-09-20") 
     5#define FILEVER        0,3,7,422 
     6#define PRODUCTVER     0,3,7,422 
     7#define STRFILEVER     _T("0.3.7.422") 
     8#define STRPRODUCTVER  _T("0.3.7.422") 
     9#define STRPRODUCTDATE  _T("2009-10-04") 
    1010#endif // AUTOBUILD_H 
  • Jamroot

    r1fc246c r55e44d4  
    208208    all-modules = $(result) ; 
    209209  } 
    210   for local l in $(all-modules) 
    211   { 
     210  all-modules-text = "" ; 
     211  for local l in $(all-modules) { 
    212212    alias $(l)  
    213213      : # sources 
     
    218218      <dependency>$(target) 
    219219      ; 
    220     echo "Adding module: $(l)" ; 
    221220    explicit $(l) ; 
    222   } 
    223   for local l in $(all-scripts) 
     221    all-modules-text = "$(all-modules-text) $(l)" ; 
     222  } 
     223  echo "Building modules: $(all-modules-text)" ; 
     224  for local l in $(all-scripts) { 
     225    all-scripts-lst = $(all-scripts-lst) scripts/$(l) ; 
     226  } 
     227} else { 
     228  all-installers = 
     229    [ MATCH .*helpers/(.*)/.* : [ glob helpers/*installer/Jamfile ] ] 
     230    ; 
     231  all-installers-text = "" ; 
     232  for local l in $(all-installers) 
    224233  { 
    225     #make scripts-$(l) : scripts/$(l) : common.copy ; 
    226     #explicit scripts/$(l) ; 
    227  
    228     #alias scripts-$(l) : scripts/$(l) ; 
    229     #explicit scripts-$(l) ; 
    230  
    231     all-scripts-lst = $(all-scripts-lst) scripts/$(l) ; 
    232  
    233     echo "Adding script: $(l)" ; 
    234   } 
    235 } 
    236  
    237 all-installers = 
    238     [ MATCH .*helpers/(.*)/.* : [ glob helpers/*installer/Jamfile ] ] 
    239     ; 
    240 for local l in $(all-installers) 
    241 { 
    242   alias $(l) : helpers/$(l) ; 
    243   echo "Adding installer target for: $(l)" ; 
    244   explicit $(l) ; 
     234    alias $(l) : helpers/$(l) ; 
     235    explicit $(l) ; 
     236    all-installers-text = "$(all-installers-text) $(l)" ; 
     237  } 
     238  echo "Building installers: $(all-installers-text)" ; 
    245239} 
    246240 
     
    280274rule get-root-prefix ( properties * ) 
    281275{ 
     276  tag = "UNKNOWN" ; 
    282277    if <architecture>ia64 in $(properties) {  
    283     return IA64 ;  
     278    tag = "IA64" ; 
    284279  } else {  
    285     if <address-model>64 in $(properties) { return x64 ; } 
    286     else { return Win32 ; } 
    287   } 
     280    if <address-model>64 in $(properties) {  
     281      tag = "x64" ;  
     282    } else {  
     283      tag = "Win32" ;  
     284    } 
     285  } 
     286    if <variant>debug in $(properties) { 
     287    tag = "$(tag)-debug" ; 
     288  } 
     289  return $(tag) ; 
    288290} 
    289291rule generate-binary-location ( properties * ) 
     
    327329explicit build-archives ; 
    328330 
    329  
    330331alias build-installer : all-installer-targets : <location>$(BOOST_STAGE_LOCATE)/installer ; 
    331332explicit build-installer ; 
    332333 
    333  
    334  
     334alias source-archive : helpers/build-source : <location>$(BOOST_STAGE_LOCATE)/archive ; 
     335explicit source-archive ; 
     336 
     337 
  • NSClient++.cpp

    r308b6f5 r55e44d4  
    2525#include <remote_processes.hpp> 
    2626#include <Lmcons.h> 
     27//#ifdef DEBUG 
     28#include <assert.h> 
     29//#endif 
    2730 
    2831NSClient mainClient(SZSERVICENAME); // Global core instance. 
     
    451454          std::wcout << _T("Reattaching to session 0") << std::endl; 
    452455          mainClient.startTrayIcon(0); 
     456//#ifdef DEBUG 
     457        } else if (s == _T("assert")) { 
     458          assert(false); 
     459//#endif 
    453460        } else if (std::cin.peek() < 15) { 
    454461          buff += s; 
  • bjam/zip.jam

    r1d53fe0 r55e44d4  
    55 
    66feature source-folder : : path free ; 
     7feature exclude : : free ; 
     8feature recursive : off on : propagated ; 
    79 
    810type.register ZIP : zip ; 
    911generators.register-composing bjam/zip.make-zip : : ZIP ; 
    1012flags bjam/zip.make-zip SOURCE_FOLDER <source-folder> ; 
     13flags bjam/zip.make-zip EXCLUDES <exclude> : -x ; 
     14flags bjam/zip.make-zip FLAGS <recursive>on : -r ; 
    1115 
    1216actions make-zip { 
    13   echo 7z.exe a -tzip -bd "$(<)" "$(SOURCE_FOLDER)" 
    14   7z.exe a -tzip -bd "$(<)" "$(SOURCE_FOLDER)" 
     17  echo 7z.exe a -tzip -bd "$(<)" "$(FLAGS)" "$(SOURCE_FOLDER)" "-x!$(EXCLUDES)" 
     18  7z.exe a -tzip -bd "$(<)" "$(FLAGS)" "$(SOURCE_FOLDER)" "-x!$(EXCLUDES)" 
    1519}  
  • build.bat

    r358cda1 r55e44d4  
    22@call env.bat 
    33 
    4 SET cmdline=%jam% --toolset=msvc --with-lua=%LUA_SOURCE% --with-openssl --include-path=%NSCP_INCLUDE% --with-boost --with-cryptopp=%CRYPTOPP_SOURCE% %* build-binaries 
    5 %jam% --toolset=msvc --with-lua=%LUA_SOURCE% --with-openssl --include-path=%NSCP_INCLUDE% --with-boost --with-cryptopp=%CRYPTOPP_SOURCE% warnings=off %* build-binaries 
     4echo :: %jam% --toolset=msvc --with-lua=%LUA_SOURCE% --with-openssl --include-path=%NSCP_INCLUDE% --with-boost --with-cryptopp=%CRYPTOPP_SOURCE% warnings=off --with-psdk="%PLATTFORM_SDK_INCLUDE%" %* build-binaries >> build.log 
     5%jam% --toolset=msvc --with-lua=%LUA_SOURCE% --with-openssl --include-path=%NSCP_INCLUDE% --with-boost --with-cryptopp=%CRYPTOPP_SOURCE% warnings=off --with-psdk="%PLATTFORM_SDK_INCLUDE%" %* build-binaries 
    66if %ERRORLEVEL% == 1 goto :error 
     7echo :: Result: %ERRORLEVEL% >> build.log 
    78 
    8 SET cmdline=%jam% --toolset=msvc --with-lua=%LUA_SOURCE% --with-openssl --include-path=%NSCP_INCLUDE% --with-boost --with-cryptopp=%CRYPTOPP_SOURCE% warnings=off %* build-archives 
    9 %jam% --toolset=msvc --with-lua=%LUA_SOURCE% --with-openssl --include-path=%NSCP_INCLUDE% --with-boost --with-cryptopp=%CRYPTOPP_SOURCE% warnings=off %* build-archives 
     9echo :: %jam% --toolset=msvc warnings=off %* build-archives >> build.log 
     10%jam% --toolset=msvc warnings=off %* build-archives 
    1011if %ERRORLEVEL% == 1 goto :error 
     12echo :: Result: %ERRORLEVEL% >> build.log 
    1113 
    12 SET cmdline=%jam% --toolset=wix %* build-installer 
    13 %jam% --toolset=wix %* build-installer 
     14echo :: %jam% --toolset=wix "--wix=%WIX_PATH%" %* build-installer >> build.log 
     15%jam% --toolset=wix "--wix=%WIX_PATH%" %* build-installer 
    1416if %ERRORLEVEL% == 1 goto :error 
     17echo :: Result: %ERRORLEVEL% >> build.log 
    1518 
    16 exit /b 1 
     19exit /b 0 
    1720goto :eof 
    1821 
    1922:error 
     23echo :: Error: %ERRORLEVEL% >> build.log 
    2024echo ************* 
    2125echo * E R R O R * 
    2226echo ************* 
    23 echo %cmdline% 
    24 echo ************* 
    2527 
    2628exit /b -1 
  • helpers/build-archive/Jamfile

    r1fc246c r55e44d4  
    1313{ 
    1414    local properties = [ $(property-set).raw ] ; 
    15     if <architecture>ia64 in $(properties) {  
    16     tag = IA64 ;  
    17   } else {  
    18     if <address-model>64 in $(properties) { tag = x64 ; } 
    19     else { tag = Win32 ; } 
    20   } 
     15  local tag = [ get-root-prefix $(properties) ] ; 
    2116  local date = [ SHELL "perl helpers/perl/echo_date.pl" ] ; 
    2217  local version = [ SHELL "perl helpers/perl/echo_version.pl $(TOP)/../../AutoBuild.h" ] ; 
  • release-build.bat

    re7dbac9 r55e44d4  
    11@echo off 
    2  
    32@call env.bat 
    43 
    5 SET version=crypto_hdr 
    6 SET cmdline=%jam% --toolset=msvc --with-cryptopp=%CRYPTOPP_SOURCE% --with-cryptopp-target=%NSCP_INCLUDE%\cryptopp cryptopp-headers 
     4SET _ERROR= 
     5echo Starting build > build.log 
     6 
     7echo %jam% --toolset=msvc --with-cryptopp=%CRYPTOPP_SOURCE% --with-cryptopp-target=%NSCP_INCLUDE%\cryptopp cryptopp-headers >> build.log 
    78%jam% --toolset=msvc --with-cryptopp=%CRYPTOPP_SOURCE% --with-cryptopp-target=%NSCP_INCLUDE%\cryptopp cryptopp-headers 
    89if %ERRORLEVEL% == -1 goto :error 
     10echo :: Result: %ERRORLEVEL% >> build.log 
    911 
    10 REM build x86 binary 
    11 SET version=x86 
    12 SET cmdline=build.bat runtime-link=static variant=release address-model=32 --library-path="%TARGET_LIB_x86_DIR%" --with-psdk-lib=%"PLATTFORM_SDK_LIB_x86%" --with-psdk="%PLATTFORM_SDK_INCLUDE%" --wix="%WIX_PATH%" 
    13 call build.bat runtime-link=static variant=release address-model=32 --library-path="%TARGET_LIB_x86_DIR%" --with-psdk-lib="%PLATTFORM_SDK_LIB_x86%" --with-psdk="%PLATTFORM_SDK_INCLUDE%" --wix="%WIX_PATH%" 
     12echo %jam% --toolset=msvc source-archive >> build.log 
     13%jam% --toolset=msvc source-archive 
    1414if %ERRORLEVEL% == -1 goto :error 
     15echo :: Result: %ERRORLEVEL% >> build.log 
    1516 
    16 REM build x64 (Amd64, Emt64) binary 
    17  SET version=x64 
    18  SET cmdline=build.bat runtime-link=static variant=release address-model=64 --library-path="%TARGET_LIB_x64_DIR%" --with-psdk-lib="%PLATTFORM_SDK_LIB_x64%" --with-psdk="%PLATTFORM_SDK_INCLUDE%" --wix="%WIX_PATH%" 
    19  call build.bat runtime-link=static variant=release address-model=64 --library-path="%TARGET_LIB_x64_DIR%" --with-psdk-lib="%PLATTFORM_SDK_LIB_x64%" --with-psdk="%PLATTFORM_SDK_INCLUDE%" --wix="%WIX_PATH%" 
    20  if %ERRORLEVEL% == -1 goto :error 
    21  
    22  
    23 REM TODO: Add IA64 version 
    24 rem version=IA64 
     17call :build_one variant=debug address-model=32 "--library-path=%TARGET_LIB_x86_DIR%" "--with-psdk-lib=%PLATTFORM_SDK_LIB_x86%" 
     18IF DEFINED _ERROR goto :error 
     19call :build_one variant=release address-model=32 "--library-path=%TARGET_LIB_x86_DIR%" "--with-psdk-lib=%PLATTFORM_SDK_LIB_x86%" 
     20IF DEFINED _ERROR goto :error 
     21call :build_one variant=debug address-model=64 "--library-path=%TARGET_LIB_x64_DIR%" "--with-psdk-lib=%PLATTFORM_SDK_LIB_x64%" 
     22IF DEFINED _ERROR goto :error 
     23call :build_one variant=release address-model=64 "--library-path=%TARGET_LIB_x64_DIR%" "--with-psdk-lib=%PLATTFORM_SDK_LIB_x64%" 
     24IF DEFINED _ERROR goto :error 
    2525rem call build.bat runtime-link=static variant=release architecture=ia64 --library-path=%TARGET_LIB_IA64_DIR% 
    26 rem if %ERRORLEVEL% == -1 goto :error 
    2726 
    2827echo ************* 
     
    3130echo *           * 
    3231echo ************* 
    33  
    3432goto :eof 
    3533 
    36 :error 
     34:build_one 
     35echo build.bat runtime-link=static %* >> build.log 
     36call build.bat runtime-link=static %* 
     37if %ERRORLEVEL% == -1 goto :error_one 
     38echo Result: %ERRORLEVEL% >> build.log 
     39goto :eof 
     40 
     41:error_one 
    3742echo ********************* 
    3843echo *                   * 
    3944echo *    E R R O R      * 
    4045echo *                   * 
    41 echo * When building %version% * 
     46echo ********************* 
     47set _ERROR=1 
     48exit /b -1 
     49goto :eof 
     50 
     51:error 
     52echo :: Error: %ERRORLEVEL% >> build.log 
     53echo ********************* 
     54echo *                   * 
     55echo *    E R R O R      * 
    4256echo *                   * 
    4357echo ********************* 
    44 echo %cmdline% 
     58type build.log 
Note: See TracChangeset for help on using the changeset viewer.