From: <ah...@us...> - 2008-11-11 18:15:27
|
Revision: 12044 http://jvcl.svn.sourceforge.net/jvcl/?rev=12044&view=rev Author: ahuser Date: 2008-11-11 18:15:17 +0000 (Tue, 11 Nov 2008) Log Message: ----------- - Removed CLX from the jvcl.inc - Removed special Installer jvcl.inc, installer now defines DEFAULT_JVCL_INC - JvGIF no longer registered for .gif under Delphi 2009 by default - Installer is statically compiled against RTL, VCL - Added missing JVCLInstallStarter source code Modified Paths: -------------- trunk/jvcl/common/jvcl.inc trunk/jvcl/common/jvcld12.inc trunk/jvcl/install/JVCLInstall/Main.pas trunk/jvcl/install.bat Added Paths: ----------- trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dpr trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dproj Removed Paths: ------------- trunk/jvcl/install/JVCLInstall/jvcl.inc Modified: trunk/jvcl/common/jvcl.inc =================================================================== --- trunk/jvcl/common/jvcl.inc 2008-11-11 17:54:45 UTC (rev 12043) +++ trunk/jvcl/common/jvcl.inc 2008-11-11 18:15:17 UTC (rev 12044) @@ -10,26 +10,19 @@ The Original Code is: JVCL.INC, released on 2002-07-04. -Last Modified: 2004-12-22 +Last Modified: 2008-11-11 You may retrieve the latest version of this file at the Project JEDI's JVCL home page, located at http://jvcl.sourceforge.net Known Issues: -----------------------------------------------------------------------------} +{$A+,B-,C+,D+,E-,F-,G+,H+,I+,J-,K-,L+,M-,N+,O+,P+,Q-,R-,S-,T-,U-,V+,W-,X+,Y+,Z1} + {$IFDEF JVCL_NO_DEBUGINFO} // set by the Installer {$D-} -{$ELSE} - // default - {$D+} {$ENDIF JVCL_NO_DEBUGINFO} -{$IFDEF JVCLINSTALLER} -{$I ..\install\JVCLInstall\jvcl.inc} -{$ELSE} - -{$A+,B-,C+,E-,F-,G+,H+,I+,J-,K-,L+,M-,N+,O+,P+,Q-,R-,S-,T-,U-,V+,W-,X+,Y+,Z1} - {$I jedi.inc} {$IFNDEF JEDI_INC} @@ -48,30 +41,17 @@ {$ObjExportAll ON} {$ENDIF BCB} -{$IFDEF QUnit} - {$UNDEF VCL} - {$DEFINE VisualCLX} -{$ENDIF} -// jedi.inc does not define VCL nor VisualCLX if the application is a console -// But the JVCL code requires that VCL or VisualCLX be defined (but not both, -// of course). So we define those symbols ourselves as it is not a matter -// for all JEDI projects. -{$IFDEF CONSOLE} - {$IFNDEF VCL} - {$IFNDEF VisualCLX} - {$IFDEF LINUX} - {$DEFINE VisualCLX} - {$ENDIF LINUX} - {$IFNDEF VisualCLX} - {$DEFINE VCL} - {$ENDIF !VisualCLX} - {$ENDIF !VisualCLX} - {$ENDIF !VCL} -{$ENDIF CONSOLE} +{$UNDEF JVCL_CONFIGURED} -{$IFNDEF DEFAULT_JVCL_INC} +{$IFDEF DEFAULT_JVCL_INC} {-----------------------------------------------------------------------------} +{ Default configuration } +{-----------------------------------------------------------------------------} + {$I jvclbase.inc} + {$DEFINE JVCL_CONFIGURED} +{$ELSE} +{-----------------------------------------------------------------------------} { Delphi } {-----------------------------------------------------------------------------} {$IFDEF DELPHI5} @@ -135,18 +115,11 @@ {$I jvcld12.inc} // same include file for BDS based C++ {$DEFINE JVCL_CONFIGURED} {$ENDIF BCB12} -{-----------------------------------------------------------------------------} -{ Default configuration } -{-----------------------------------------------------------------------------} -{$ELSE} - {$I jvclbase.inc} - {$DEFINE JVCL_CONFIGURED} + {$ENDIF DEFAULT_JVCL_INC} {-----------------------------------------------------------------------------} -// check configuration - {$IFNDEF JVCL_CONFIGURED} {$IFDEF SUPPORTS_COMPILETIME_MESSAGES} {$MESSAGE FATAL 'Your Delphi/BCB version is not supported by this JVCL version!'} @@ -156,6 +129,8 @@ {$ENDIF !JVCL_CONFIGURED} +// check configuration dependencies + {$IFNDEF JVCL_UseQuickReport} {$UNDEF QREPORT4} {$ENDIF !JVCL_UseQuickReport} @@ -194,4 +169,3 @@ {$DEFINE MSWINDOWS} {$ENDIF CLR} -{$ENDIF INSTALLER} Modified: trunk/jvcl/common/jvcld12.inc =================================================================== --- trunk/jvcl/common/jvcld12.inc 2008-11-11 17:54:45 UTC (rev 12043) +++ trunk/jvcl/common/jvcld12.inc 2008-11-11 18:15:17 UTC (rev 12044) @@ -61,7 +61,7 @@ { This define enables GIF image support. Deactivate this define if you are using another GIF image support library. } -{$DEFINE USE_JV_GIF} +{.$DEFINE USE_JV_GIF} { Activate this define if you do not want to use TGauge Borland sample component in TDBProgress component and FileUtil routines. In this case Added: trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dpr =================================================================== --- trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dpr (rev 0) +++ trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dpr 2008-11-11 18:15:17 UTC (rev 12044) @@ -0,0 +1,124 @@ +{----------------------------------------------------------------------------- +The contents of this file are subject to the Mozilla Public License +Version 1.1 (the "License"); you may not use this file except in compliance +with the License. You may obtain a copy of the License at +http://www.mozilla.org/MPL/MPL-1.1.html + +Software distributed under the License is distributed on an "AS IS" basis, +WITHOUT WARRANTY OF ANY KIND, either expressed or implied. See the License for +the specific language governing rights and limitations under the License. + +The Original Code is: JVCLInstallStarter.dpr, released on 2008-11-03. + +The Initial Developer of the Original Code is Andreas Hausladen +Portions created by Andreas Hausladen are Copyright (C) 2008 Andreas Hausladen +All Rights Reserved. + +Contributor(s): + +You may retrieve the latest version of this file at the Project JEDI's JVCL home page, +located at http://jvcl.sourceforge.net + +Known Issues: +-----------------------------------------------------------------------------} +// $Id$ + +program JVCLInstallStarter; + +{$APPTYPE CONSOLE} + +{ JVCLInstallStarter is used to get the JVCLInstaller into the forground under Windows Vista. + Under Vista a GUI application will be send to the back if it is started from a console window + that is closing after triggering the start of the GUI application. + + JVCLInstallStarter waits until the GUI application is idle and then terminates. It is also + a replacement for Windows's "start" command. } + +uses + Windows; + +{$R CommCtrlAsInvoker.res} + +function SysErrorMessage(ErrorCode: Cardinal): string; +var + Buffer: array[0..1024] of Char; +var + Len: Integer; +begin + Len := FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM or FORMAT_MESSAGE_IGNORE_INSERTS or + FORMAT_MESSAGE_ARGUMENT_ARRAY, nil, ErrorCode, 0, Buffer, Length(Buffer), nil); + while (Len > 0) and ((Buffer[Len - 1] <= #32) or (Buffer[Len - 1] = '.')) do + Dec(Len); + SetString(Result, Buffer, Len); +end; + +var + P: PChar; + InStr: Boolean; + ProcessInfo: TProcessInformation; + StartupInfo: TStartupInfo; + S: string; + SecAttr: TSecurityAttributes; + LastError: Cardinal; +begin + P := GetCommandLine; + if P = nil then + begin + WriteLn(ErrOutput, 'GetCommandLine returned NULL'); + Halt(1); + end; + + InStr := False; + while P[0] <> #0 do + begin + if P[0] = '"' then + begin + if InStr and (P[1] = '"') then + Inc(P) + else + InStr := not InStr; + end + else if (P[0] <= ' ') and not InStr then + Break; + Inc(P); + end; + + if P[0] <> #0 then + begin + while (P[0] <> #0) and (P[0] <= #32) do + Inc(P); + end; + + if P[0] <> #0 then + begin + S := P; + + FillChar(SecAttr, SizeOf(SecAttr), 0); + SecAttr.nLength := SizeOf(SecAttr); + SecAttr.bInheritHandle := False; + + FillChar(StartupInfo, SizeOf(StartupInfo), 0); + if CreateProcess(nil, PChar(S), @SecAttr, nil, False, 0, nil, nil, StartupInfo, ProcessInfo) then + begin + CloseHandle(ProcessInfo.hThread); + WaitForInputIdle(ProcessInfo.hProcess, INFINITE); + CloseHandle(ProcessInfo.hProcess); + end + else + begin + LastError := GetLastError; + + SetLength(S, 1024); + SetLength(S, FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM or FORMAT_MESSAGE_IGNORE_INSERTS or + FORMAT_MESSAGE_ARGUMENT_ARRAY, nil, LastError, 0, PChar(S), Length(S), nil)); + WriteLn(ErrOutput, S); + end; + + ExitCode := 0; + end + else + begin + WriteLn(ErrOutput, 'No executable specified'); + ExitCode := 1; + end; +end. Added: trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dproj =================================================================== --- trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dproj (rev 0) +++ trunk/jvcl/install/JVCLInstall/JVCLInstallStarter.dproj 2008-11-11 18:15:17 UTC (rev 12044) @@ -0,0 +1,104 @@ + <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <PropertyGroup> + <ProjectGuid>{02676ECE-0BB1-4801-8014-5E99A122F5B1}</ProjectGuid> + <MainSource>JVCLInstallStarter.dpr</MainSource> + <Config Condition="'$(Config)'==''">Debug</Config> + <DCC_DCCCompiler>DCC32</DCC_DCCCompiler> + <ProjectVersion>12.0</ProjectVersion> + </PropertyGroup> + <PropertyGroup Condition="'$(Config)'=='Basis' or '$(Base)'!=''"> + <Base>true</Base> + </PropertyGroup> + <PropertyGroup Condition="'$(Config)'=='Release' or '$(Cfg_1)'!=''"> + <Cfg_1>true</Cfg_1> + <CfgParent>Base</CfgParent> + <Base>true</Base> + </PropertyGroup> + <PropertyGroup Condition="'$(Config)'=='Debug' or '$(Cfg_2)'!=''"> + <Cfg_2>true</Cfg_2> + <CfgParent>Base</CfgParent> + <Base>true</Base> + </PropertyGroup> + <PropertyGroup Condition="'$(Base)'!=''"> + <DCC_ImageBase>00400000</DCC_ImageBase> + <DCC_E>false</DCC_E> + <DCC_Platform>x86</DCC_Platform> + <DCC_DependencyCheckOutputName>JVCLInstallStarter.exe</DCC_DependencyCheckOutputName> + <DCC_N>false</DCC_N> + <DCC_S>false</DCC_S> + <DCC_F>false</DCC_F> + <DCC_K>false</DCC_K> + </PropertyGroup> + <PropertyGroup Condition="'$(Cfg_1)'!=''"> + <DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols> + <DCC_Define>RELEASE;$(DCC_Define)</DCC_Define> + <DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo> + <DCC_DebugInformation>false</DCC_DebugInformation> + </PropertyGroup> + <PropertyGroup Condition="'$(Cfg_2)'!=''"> + <DCC_Define>DEBUG;$(DCC_Define)</DCC_Define> + </PropertyGroup> + <ItemGroup> + <DelphiCompile Include="JVCLInstallStarter.dpr"> + <MainSource>MainSource</MainSource> + </DelphiCompile> + <BuildConfiguration Include="Basis"> + <Key>Base</Key> + </BuildConfiguration> + <BuildConfiguration Include="Debug"> + <Key>Cfg_2</Key> + <CfgParent>Base</CfgParent> + </BuildConfiguration> + <BuildConfiguration Include="Release"> + <Key>Cfg_1</Key> + <CfgParent>Base</CfgParent> + </BuildConfiguration> + </ItemGroup> + <Import Project="$(BDS)\Bin\CodeGear.Delphi.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Delphi.Targets')"/> + <ProjectExtensions> + <Borland.Personality>Delphi.Personality.12</Borland.Personality> + <Borland.ProjectType>VCLApplication</Borland.ProjectType> + <BorlandProject> + <Delphi.Personality> + <Source> + <Source Name="MainSource">JVCLInstallStarter.dpr</Source> + </Source> + <Parameters> + <Parameters Name="UseLauncher">False</Parameters> + <Parameters Name="LoadAllSymbols">True</Parameters> + <Parameters Name="LoadUnspecifiedSymbols">False</Parameters> + <Parameters Name="RunParams">bin\JVCLInstall.exe</Parameters> + <Parameters Name="DebugCWD">Z:\Jedi\JVCL3</Parameters> + </Parameters> + <VersionInfo> + <VersionInfo Name="IncludeVerInfo">False</VersionInfo> + <VersionInfo Name="AutoIncBuild">False</VersionInfo> + <VersionInfo Name="MajorVer">1</VersionInfo> + <VersionInfo Name="MinorVer">0</VersionInfo> + <VersionInfo Name="Release">0</VersionInfo> + <VersionInfo Name="Build">0</VersionInfo> + <VersionInfo Name="Debug">False</VersionInfo> + <VersionInfo Name="PreRelease">False</VersionInfo> + <VersionInfo Name="Special">False</VersionInfo> + <VersionInfo Name="Private">False</VersionInfo> + <VersionInfo Name="DLL">False</VersionInfo> + <VersionInfo Name="Locale">1031</VersionInfo> + <VersionInfo Name="CodePage">1252</VersionInfo> + </VersionInfo> + <VersionInfoKeys> + <VersionInfoKeys Name="CompanyName"/> + <VersionInfoKeys Name="FileDescription"/> + <VersionInfoKeys Name="FileVersion">1.0.0.0</VersionInfoKeys> + <VersionInfoKeys Name="InternalName"/> + <VersionInfoKeys Name="LegalCopyright"/> + <VersionInfoKeys Name="LegalTrademarks"/> + <VersionInfoKeys Name="OriginalFilename"/> + <VersionInfoKeys Name="ProductName"/> + <VersionInfoKeys Name="ProductVersion">1.0.0.0</VersionInfoKeys> + <VersionInfoKeys Name="Comments"/> + </VersionInfoKeys> + </Delphi.Personality> + </BorlandProject> + <ProjectFileVersion>12</ProjectFileVersion> + </ProjectExtensions> + </Project> Modified: trunk/jvcl/install/JVCLInstall/Main.pas =================================================================== --- trunk/jvcl/install/JVCLInstall/Main.pas 2008-11-11 17:54:45 UTC (rev 12043) +++ trunk/jvcl/install/JVCLInstall/Main.pas 2008-11-11 18:15:17 UTC (rev 12044) @@ -32,13 +32,6 @@ unit Main; {$I jvcl.inc} -{$IFNDEF INSTALLER} - {$IFDEF COMPILER6_UP} - {$MESSAGE FATAL 'Wrong jvcl.inc was used. The jvcl3\install\JVCLInstall\jvcl.inc should have been used.'} - {$ELSE} - 'Wrong jvcl.inc was used. The jvcl3\install\JVCLInstall\jvcl.inc should have been used.' - {$ENDIF COMPILER6_UP} -{$ENDIF !INSTALLER} interface Deleted: trunk/jvcl/install/JVCLInstall/jvcl.inc =================================================================== --- trunk/jvcl/install/JVCLInstall/jvcl.inc 2008-11-11 17:54:45 UTC (rev 12043) +++ trunk/jvcl/install/JVCLInstall/jvcl.inc 2008-11-11 18:15:17 UTC (rev 12044) @@ -1,40 +0,0 @@ -{----------------------------------------------------------------------------- -The contents of this file are subject to the Mozilla Public License -Version 1.1 (the "License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at -http://www.mozilla.org/MPL/MPL-1.1.html - -Software distributed under the License is distributed on an "AS IS" basis, -WITHOUT WARRANTY OF ANY KIND, either expressed or implied. See the License for -the specific language governing rights and limitations under the License. - -The Original Code is: JVCL.INC, released on 2004-04-14. - -You may retrieve the latest version of this file at the Project JEDI's JVCL home page, -located at http://jvcl.sourceforge.net - -Known Issues: ------------------------------------------------------------------------------} -// $Id$ - -{***************************************************************************} -{* THIS IS A SPECIAL VERSION OF THE jvcl.inc THAT IS ONLY USED BY THE JVCL *} -{* INSTALLER. *} -{***************************************************************************} - - -{$A+,B-,C+,D+,E-,F-,G+,H+,I+,J-,K-,L+,M-,N+,O+,P+,Q-,R-,S-,T-,U-,V+,W-,X+,Y+,Z1} - -{$I jedi.inc} - -{$DEFINE INSTALLER} - -{$DEFINE NO_JCL} -{$DEFINE VCL} - -// Reduces warnings on D7: -{$IFDEF COMPILER7_UP} - {$WARN UNSAFE_TYPE OFF} - {$WARN UNSAFE_CODE OFF} - {$WARN UNSAFE_CAST OFF} -{$ENDIF} Modified: trunk/jvcl/install.bat =================================================================== --- trunk/jvcl/install.bat 2008-11-11 17:54:45 UTC (rev 12043) +++ trunk/jvcl/install.bat 2008-11-11 18:15:17 UTC (rev 12044) @@ -7,10 +7,14 @@ :: compile installer echo [Compiling installer...] cd install\JVCLInstall + if EXIST JVCLInstall.cfg del JVCLInstall.cfg -..\..\packages\bin\dcc32ex.exe --runtime-package-rtl --runtime-package-vcl --requires-jcl=%JCLVERSION% -Q -B -DJVCLINSTALLER -DUSE_DXGETTEXT -E..\..\bin -I.;..\..\common -U..\..\common;..\..\run -n..\..\dcu JVCLInstall.dpr +..\..\packages\bin\dcc32ex.exe --requires-jcl=%JCLVERSION% -Q -B -DDEFAULT_JVCL_INC -DUSE_DXGETTEXT -E..\..\bin -I.;..\..\common -U..\..\run -R..\..\resources -n..\..\dcu JVCLInstall.dpr +:: --runtime-package-rtl --runtime-package-vcl if ERRORLEVEL 1 goto Failed -..\..\packages\bin\dcc32ex.exe -Q -B -E..\..\bin JVCLInstallStarter.dpr >NUL + +if EXIST JVCLInstallStarter.cfg del JVCLInstallStarter.cfg +..\..\packages\bin\dcc32ex.exe -Q -B -E..\..\bin -n..\..\dcu JVCLInstallStarter.dpr >NUL ::if ERRORLEVEL 1 goto Failed cd ..\.. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |