You've already forked lazarus-ccr
to V0.2.4.0. Works with GitHub branches
Update to open_ssl.pas git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@5659 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -55,7 +55,7 @@ More information in the Wiki Home Page http://wiki.freepascal.org/LazAutoUpdater
|
||||
along with this library; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
"/>
|
||||
<Version Minor="2" Release="3"/>
|
||||
<Version Minor="2" Release="4"/>
|
||||
<Files Count="6">
|
||||
<Item1>
|
||||
<Filename Value="ulazautoupdate.pas"/>
|
||||
|
@ -5,23 +5,26 @@ unit open_ssl;
|
||||
interface
|
||||
|
||||
uses
|
||||
// Built-in 'fphttpclient' replaces 'lazautoupdate_httpclient' for general use
|
||||
// Built-in 'fphttpclient' unit replaces 'lazautoupdate_httpclient' unit for general use
|
||||
Classes, SysUtils,lazautoupdate_httpclient,LazFileUtils,FileUtil,zipper;
|
||||
|
||||
function CheckForOpenSSL:Boolean;
|
||||
function OpenSSLInstalled:Boolean;
|
||||
|
||||
implementation
|
||||
const
|
||||
Var FHTTPClient:TFPHttpClient;
|
||||
|
||||
{$ifdef win64}
|
||||
const
|
||||
cOpenSSLURL = 'http://packages.lazarus-ide.org/openssl-1.0.2j-x64_86-win64.zip';
|
||||
cAltOpenSSLURL = 'http://indy.fulgan.com/SSL/openssl-1.0.2j-i386-win32.zip';
|
||||
{$endif}
|
||||
{$ifdef win32}
|
||||
const
|
||||
cOpenSSLURL = 'http://packages.lazarus-ide.org/openssl-1.0.2j-i386-win32.zip';
|
||||
cAltOpenSSLURL = 'http://indy.fulgan.com/SSL/openssl-1.0.2j-x64_86-win64.zip';
|
||||
{$endif}
|
||||
Var FHTTPClient:TFPHttpClient;
|
||||
|
||||
|
||||
function OpenSSLInstalled:Boolean;
|
||||
begin
|
||||
|
@ -4,13 +4,13 @@
|
||||
<PathDelim Value="\"/>
|
||||
<Version Value="10"/>
|
||||
<BuildModes Active="Win32"/>
|
||||
<Units Count="13">
|
||||
<Units Count="16">
|
||||
<Unit0>
|
||||
<Filename Value="testapp.lpr"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<EditorIndex Value="5"/>
|
||||
<CursorPos X="33" Y="27"/>
|
||||
<UsageCount Value="39"/>
|
||||
<UsageCount Value="42"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit0>
|
||||
<Unit1>
|
||||
@ -19,9 +19,10 @@
|
||||
<ComponentName Value="mainform"/>
|
||||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<TopLine Value="12"/>
|
||||
<CursorPos X="43" Y="13"/>
|
||||
<UsageCount Value="39"/>
|
||||
<IsVisibleTab Value="True"/>
|
||||
<TopLine Value="32"/>
|
||||
<CursorPos X="103" Y="53"/>
|
||||
<UsageCount Value="42"/>
|
||||
<Loaded Value="True"/>
|
||||
<LoadedDesigner Value="True"/>
|
||||
</Unit1>
|
||||
@ -30,30 +31,29 @@
|
||||
<IsPartOfProject Value="True"/>
|
||||
<EditorIndex Value="1"/>
|
||||
<WindowIndex Value="1"/>
|
||||
<TopLine Value="34"/>
|
||||
<CursorPos X="16" Y="57"/>
|
||||
<UsageCount Value="22"/>
|
||||
<TopLine Value="3"/>
|
||||
<CursorPos X="76" Y="8"/>
|
||||
<UsageCount Value="25"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit2>
|
||||
<Unit3>
|
||||
<Filename Value="..\lazautoupdate_httpclient.pas"/>
|
||||
<IsVisibleTab Value="True"/>
|
||||
<EditorIndex Value="2"/>
|
||||
<CursorPos X="97" Y="12"/>
|
||||
<UsageCount Value="18"/>
|
||||
<UsageCount Value="20"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit3>
|
||||
<Unit4>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<IsVisibleTab Value="True"/>
|
||||
<WindowIndex Value="1"/>
|
||||
<TopLine Value="519"/>
|
||||
<CursorPos X="45" Y="533"/>
|
||||
<TopLine Value="70"/>
|
||||
<CursorPos X="42" Y="110"/>
|
||||
<ExtraEditorCount Value="2"/>
|
||||
<ExtraEditor1>
|
||||
<EditorIndex Value="3"/>
|
||||
<TopLine Value="1137"/>
|
||||
<CursorPos X="11" Y="1227"/>
|
||||
<TopLine Value="1141"/>
|
||||
<CursorPos X="11" Y="1231"/>
|
||||
</ExtraEditor1>
|
||||
<ExtraEditor2>
|
||||
<EditorIndex Value="-1"/>
|
||||
@ -61,7 +61,7 @@
|
||||
<TopLine Value="-1"/>
|
||||
<CursorPos X="-1" Y="-1"/>
|
||||
</ExtraEditor2>
|
||||
<UsageCount Value="18"/>
|
||||
<UsageCount Value="20"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit4>
|
||||
<Unit5>
|
||||
@ -105,7 +105,7 @@
|
||||
<EditorIndex Value="1"/>
|
||||
<TopLine Value="25"/>
|
||||
<CursorPos X="25" Y="55"/>
|
||||
<UsageCount Value="16"/>
|
||||
<UsageCount Value="18"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit10>
|
||||
<Unit11>
|
||||
@ -120,98 +120,155 @@
|
||||
<EditorIndex Value="4"/>
|
||||
<TopLine Value="25"/>
|
||||
<CursorPos X="71" Y="44"/>
|
||||
<UsageCount Value="13"/>
|
||||
<UsageCount Value="15"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit12>
|
||||
<Unit13>
|
||||
<Filename Value="C:\laztrunk\fpc\examples\httpd22\minimain.pas"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<WindowIndex Value="1"/>
|
||||
<TopLine Value="3"/>
|
||||
<UsageCount Value="10"/>
|
||||
</Unit13>
|
||||
<Unit14>
|
||||
<Filename Value="..\uappisrunning.pas"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<WindowIndex Value="1"/>
|
||||
<TopLine Value="124"/>
|
||||
<UsageCount Value="10"/>
|
||||
</Unit14>
|
||||
<Unit15>
|
||||
<Filename Value="..\..\..\cryptini\latest_stable\ucryptini.pas"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<WindowIndex Value="1"/>
|
||||
<TopLine Value="372"/>
|
||||
<UsageCount Value="10"/>
|
||||
</Unit15>
|
||||
</Units>
|
||||
<General>
|
||||
<ActiveWindowIndexAtStart Value="1"/>
|
||||
</General>
|
||||
<JumpHistory Count="21" HistoryIndex="20">
|
||||
<JumpHistory Count="30" HistoryIndex="29">
|
||||
<Position1>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="913" Column="35" TopLine="875"/>
|
||||
<Caret Line="51" Column="20" TopLine="35"/>
|
||||
</Position1>
|
||||
<Position2>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="123" Column="52" TopLine="115"/>
|
||||
<Caret Line="914" TopLine="893"/>
|
||||
</Position2>
|
||||
<Position3>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="56" Column="3" TopLine="33"/>
|
||||
<Caret Line="1076" TopLine="1039"/>
|
||||
</Position3>
|
||||
<Position4>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="165" Column="36" TopLine="147"/>
|
||||
<Caret Line="180" Column="33" TopLine="157"/>
|
||||
</Position4>
|
||||
<Position5>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="913" Column="38" TopLine="891"/>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="76" Column="3" TopLine="74"/>
|
||||
</Position5>
|
||||
<Position6>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="1074" Column="38" TopLine="1053"/>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="129" Column="3" TopLine="92"/>
|
||||
</Position6>
|
||||
<Position7>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="182" Column="51" TopLine="159"/>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="122" Column="3" TopLine="92"/>
|
||||
</Position7>
|
||||
<Position8>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="935" TopLine="900"/>
|
||||
<Caret Line="56" Column="27" TopLine="28"/>
|
||||
</Position8>
|
||||
<Position9>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="1059" TopLine="1037"/>
|
||||
<Caret Line="533" Column="45" TopLine="519"/>
|
||||
</Position9>
|
||||
<Position10>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="1974" TopLine="1945"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="16"/>
|
||||
</Position10>
|
||||
<Position11>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="54" Column="18" TopLine="44"/>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="13" Column="43" TopLine="12"/>
|
||||
</Position11>
|
||||
<Position12>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="935" Column="89" TopLine="901"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="14" TopLine="3"/>
|
||||
</Position12>
|
||||
<Position13>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="108" Column="43" TopLine="88"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="22" TopLine="3"/>
|
||||
</Position13>
|
||||
<Position14>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="51" Column="20" TopLine="35"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="20" Column="7" TopLine="7"/>
|
||||
</Position14>
|
||||
<Position15>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="914" TopLine="893"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="25"/>
|
||||
</Position15>
|
||||
<Position16>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="1076" TopLine="1039"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="24"/>
|
||||
</Position16>
|
||||
<Position17>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="180" Column="33" TopLine="157"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="25"/>
|
||||
</Position17>
|
||||
<Position18>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="76" Column="3" TopLine="74"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="26" Column="8" TopLine="2"/>
|
||||
</Position18>
|
||||
<Position19>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="129" Column="3" TopLine="92"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="16" TopLine="3"/>
|
||||
</Position19>
|
||||
<Position20>
|
||||
<Filename Value="umainform.pas"/>
|
||||
<Caret Line="122" Column="3" TopLine="92"/>
|
||||
<Filename Value="..\open_ssl.pas"/>
|
||||
<Caret Line="26" Column="2" TopLine="5"/>
|
||||
</Position20>
|
||||
<Position21>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="56" Column="27" TopLine="28"/>
|
||||
</Position21>
|
||||
<Position22>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="52" Column="19" TopLine="28"/>
|
||||
</Position22>
|
||||
<Position23>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="56" Column="19" TopLine="28"/>
|
||||
</Position23>
|
||||
<Position24>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="926" Column="38" TopLine="889"/>
|
||||
</Position24>
|
||||
<Position25>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="55" Column="27" TopLine="29"/>
|
||||
</Position25>
|
||||
<Position26>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="926" Column="38" TopLine="892"/>
|
||||
</Position26>
|
||||
<Position27>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="1083" Column="39" TopLine="1045"/>
|
||||
</Position27>
|
||||
<Position28>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="51" Column="22" TopLine="28"/>
|
||||
</Position28>
|
||||
<Position29>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="52" Column="19" TopLine="28"/>
|
||||
</Position29>
|
||||
<Position30>
|
||||
<Filename Value="..\ulazautoupdate.pas"/>
|
||||
<Caret Line="55" Column="19" TopLine="28"/>
|
||||
</Position30>
|
||||
</JumpHistory>
|
||||
</ProjectSession>
|
||||
</CONFIG>
|
||||
|
@ -111,9 +111,10 @@ object mainform: Tmainform
|
||||
OnNewVersionAvailable = LazAutoUpdate1NewVersionAvailable
|
||||
OnDownloaded = LazAutoUpdate1Downloaded
|
||||
OnDebugEvent = LazAutoUpdate1DebugEvent
|
||||
SFProjectName = 'lazautoupdate'
|
||||
auOtherSourceURL = '<not applicable>/'
|
||||
SFProjectName = '<not applicable>'
|
||||
auOtherSourceURL = '<not applicable>'
|
||||
auOtherSourceFilename = '<not applicable>'
|
||||
ProjectType = auGitHubReleaseZip
|
||||
CopyTree = False
|
||||
UpdatesFolder = 'updates'
|
||||
VersionsININame = 'testapp.ini'
|
||||
@ -122,9 +123,9 @@ object mainform: Tmainform
|
||||
VersionCountLimit = 1000000
|
||||
DownloadCountLimit = 10000000
|
||||
ZipfileName = 'testapp.zip'
|
||||
GitHubUsername = '<not applicable>'
|
||||
GitHubProjectName = '<not applicable>'
|
||||
GitHubBranch = '<not applicable>'
|
||||
GitHubUsername = 'lazarusccr'
|
||||
GitHubProjectName = 'TestApp'
|
||||
GitHubBranch = 'TestBranch'
|
||||
Left = 200
|
||||
Top = 24
|
||||
end
|
||||
|
@ -49,11 +49,11 @@ const
|
||||
'https://sourceforge.net/projects/%s/files/%s/%s/download';
|
||||
// [updatepath,projectname,filename]
|
||||
// C_GITHUBFILE_URL = 'https://raw.github.com/%s/%s/master/%s/%s';
|
||||
C_GITHUBFILE_URL = 'https://raw.github.com/%s/%s/%s/%s/%s';
|
||||
// https://raw.github.com/<username>/<repo>/<branch>/some_directory/file
|
||||
C_GITHUBFILE_URL = 'https://raw.github.com/%s/%s/%s/%s';
|
||||
// https://raw.github.com/<username>/<repo>/<branch>/file
|
||||
// GitHubUserName,GitHubProjectName,updatepath,filename
|
||||
|
||||
C_GITHUBFILE_URL_UPDATES = 'https://raw.github.com/%s/%s/%s/%s/%s/%s';
|
||||
C_GITHUBFILE_URL_UPDATES = 'https://raw.github.com/%s/%s/%s/%s/%s';
|
||||
// https://raw.github.com/<username>/<repo>/<branch>/some_directory/file
|
||||
|
||||
C_TLazAutoUpdateComponentVersion = '0.2.3';
|
||||
C_LAUTRayINI = 'lauimport.ini';
|
||||
@ -107,6 +107,7 @@ const
|
||||
V0.1.25:Changed default: CopyTree = TRUE
|
||||
V0.1.26:Updated uses clause for FileUtils.
|
||||
V0.2.0: Rewritten for 2017
|
||||
V0.2.4: GitHub integration with branches
|
||||
}
|
||||
C_TThreadedDownloadComponentVersion = '0.0.3';
|
||||
{
|
||||
@ -923,9 +924,12 @@ begin
|
||||
fOndebugEvent(Self, 'NewVersionAvailable', C_PropIsEmpty);
|
||||
Exit;
|
||||
end;
|
||||
szURL := Format(C_GITHUBFILE_URL,
|
||||
[fGitHubUserName,fGitHubProjectName,fGitHubBranch,fVersionsININame]);
|
||||
If ((fUpdatesFolder=C_NotApplicable) or (fUpdatesFolder='')) then
|
||||
szURL := Format(C_GITHUBFILE_URL, [fGitHubUserName,fGitHubProjectName,fGitHubBranch,fVersionsININame])
|
||||
else
|
||||
szURL := Format(C_GITHUBFILE_URL_UPDATES, [fGitHubUserName,fGitHubProjectName,fGitHubBranch,fUpdatesFolder,fVersionsININame]);
|
||||
end;
|
||||
// ShowMessage(szURL);
|
||||
if fProjectType = auOther then
|
||||
// fauOtherSourceURL ends with '/'
|
||||
begin
|
||||
|
Reference in New Issue
Block a user