Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
731f4a2c
Kaydet (Commit)
731f4a2c
authored
Eki 11, 2015
tarafından
Steve Dower
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #25163: Display correct directory in installer when using non-default settings.
üst
5700ae87
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
41 additions
and
24 deletions
+41
-24
NEWS
Misc/NEWS
+3
-0
Default.thm
Tools/msi/bundle/Default.thm
+1
-1
Default.wxl
Tools/msi/bundle/Default.wxl
+1
-1
PythonBootstrapperApplication.cpp
Tools/msi/bundle/bootstrap/PythonBootstrapperApplication.cpp
+36
-22
No files found.
Misc/NEWS
Dosyayı görüntüle @
731f4a2c
...
@@ -308,6 +308,9 @@ Build
...
@@ -308,6 +308,9 @@ Build
Windows
Windows
-------
-------
- Issue #25163: Display correct directory in installer when using non-default
settings.
- Issue #25361: Disables use of SSE2 instructions in Windows 32-bit build
- Issue #25361: Disables use of SSE2 instructions in Windows 32-bit build
- Issue #25089: Adds logging to installer for case where launcher is not
- Issue #25089: Adds logging to installer for case where launcher is not
...
...
Tools/msi/bundle/Default.thm
Dosyayı görüntüle @
731f4a2c
...
@@ -24,8 +24,8 @@
...
@@ -24,8 +24,8 @@
<Button
Name=
"InstallButton"
X=
"185"
Y=
"101"
Width=
"-11"
Height=
"109"
TabStop=
"yes"
FontId=
"3"
HexStyle=
"0xE"
>
#(loc.InstallButton)
</Button>
<Button
Name=
"InstallButton"
X=
"185"
Y=
"101"
Width=
"-11"
Height=
"109"
TabStop=
"yes"
FontId=
"3"
HexStyle=
"0xE"
>
#(loc.InstallButton)
</Button>
<Button
Name=
"InstallCustomButton"
X=
"185"
Y=
"221"
Width=
"-11"
Height=
"59"
TabStop=
"yes"
FontId=
"3"
HexStyle=
"0xE"
>
#(loc.InstallCustomButton)
</Button>
<Button
Name=
"InstallCustomButton"
X=
"185"
Y=
"221"
Width=
"-11"
Height=
"59"
TabStop=
"yes"
FontId=
"3"
HexStyle=
"0xE"
>
#(loc.InstallCustomButton)
</Button>
<Checkbox
Name=
"PrependPath"
X=
"185"
Y=
"-13"
Width=
"-100"
Height=
"24"
TabStop=
"yes"
FontId=
"3"
>
#(loc.ShortPrependPathLabel)
</Checkbox>
<Checkbox
Name=
"InstallLauncherAllUsers"
X=
"185"
Y=
"-37"
Width=
"-100"
Height=
"24"
TabStop=
"yes"
FontId=
"3"
HideWhenDisabled=
"yes"
>
#(loc.ShortInstallLauncherAllUsersLabel)
</Checkbox>
<Checkbox
Name=
"InstallLauncherAllUsers"
X=
"185"
Y=
"-37"
Width=
"-100"
Height=
"24"
TabStop=
"yes"
FontId=
"3"
HideWhenDisabled=
"yes"
>
#(loc.ShortInstallLauncherAllUsersLabel)
</Checkbox>
<Checkbox
Name=
"PrependPath"
X=
"185"
Y=
"-13"
Width=
"-100"
Height=
"24"
TabStop=
"yes"
FontId=
"3"
>
#(loc.ShortPrependPathLabel)
</Checkbox>
<Button
Name=
"InstallCancelButton"
X=
"-11"
Y=
"-11"
Width=
"85"
Height=
"27"
TabStop=
"yes"
FontId=
"0"
>
#(loc.CancelButton)
</Button>
<Button
Name=
"InstallCancelButton"
X=
"-11"
Y=
"-11"
Width=
"85"
Height=
"27"
TabStop=
"yes"
FontId=
"0"
>
#(loc.CancelButton)
</Button>
</Page>
</Page>
...
...
Tools/msi/bundle/Default.wxl
Dosyayı görüntüle @
731f4a2c
...
@@ -42,7 +42,7 @@ Continue?</String>
...
@@ -42,7 +42,7 @@ Continue?</String>
<String
Id=
"InstallLicenseLinkText"
>
[WixBundleName]
<
a href="#"
>
license terms
<
/a
>
.
</String>
<String
Id=
"InstallLicenseLinkText"
>
[WixBundleName]
<
a href="#"
>
license terms
<
/a
>
.
</String>
<String
Id=
"InstallAcceptCheckbox"
>
I
&
agree to the license terms and conditions
</String>
<String
Id=
"InstallAcceptCheckbox"
>
I
&
agree to the license terms and conditions
</String>
<String
Id=
"InstallButton"
>
&
Install Now
</String>
<String
Id=
"InstallButton"
>
&
Install Now
</String>
<String
Id=
"InstallButtonNote"
>
[
DefaultJustForMe
TargetDir]
<String
Id=
"InstallButtonNote"
>
[TargetDir]
Includes IDLE, pip and documentation
Includes IDLE, pip and documentation
Creates shortcuts and file associations
</String>
Creates shortcuts and file associations
</String>
...
...
Tools/msi/bundle/bootstrap/PythonBootstrapperApplication.cpp
Dosyayı görüntüle @
731f4a2c
...
@@ -293,28 +293,8 @@ class PythonBootstrapperApplication : public CBalBaseBootstrapperApplication {
...
@@ -293,28 +293,8 @@ class PythonBootstrapperApplication : public CBalBaseBootstrapperApplication {
hr
=
_engine
->
SetVariableNumeric
(
L"CompileAll"
,
installAllUsers
);
hr
=
_engine
->
SetVariableNumeric
(
L"CompileAll"
,
installAllUsers
);
ExitOnFailure
(
hr
,
L"Failed to update CompileAll"
);
ExitOnFailure
(
hr
,
L"Failed to update CompileAll"
);
hr
=
BalGetStringVariable
(
L"TargetDir"
,
&
targetDir
);
hr
=
EnsureTargetDir
();
if
(
FAILED
(
hr
)
||
!
targetDir
||
!
targetDir
[
0
])
{
ExitOnFailure
(
hr
,
L"Failed to set TargetDir"
);
ReleaseStr
(
targetDir
);
targetDir
=
nullptr
;
hr
=
BalGetStringVariable
(
installAllUsers
?
L"DefaultAllUsersTargetDir"
:
L"DefaultJustForMeTargetDir"
,
&
defaultDir
);
BalExitOnFailure
(
hr
,
"Failed to get the default install directory"
);
if
(
!
defaultDir
||
!
defaultDir
[
0
])
{
BalLogError
(
E_INVALIDARG
,
"Default install directory is blank"
);
}
hr
=
BalFormatString
(
defaultDir
,
&
targetDir
);
BalExitOnFailure1
(
hr
,
"Failed to format '%ls'"
,
defaultDir
);
hr
=
_engine
->
SetVariableString
(
L"TargetDir"
,
targetDir
);
BalExitOnFailure
(
hr
,
"Failed to set install target directory"
);
}
ReleaseStr
(
targetDir
);
OnPlan
(
BOOTSTRAPPER_ACTION_INSTALL
);
OnPlan
(
BOOTSTRAPPER_ACTION_INSTALL
);
break
;
break
;
...
@@ -2972,6 +2952,39 @@ private:
...
@@ -2972,6 +2952,39 @@ private:
return
;
return
;
}
}
HRESULT
EnsureTargetDir
()
{
LONGLONG
installAllUsers
;
LPWSTR
targetDir
=
nullptr
,
defaultDir
=
nullptr
;
HRESULT
hr
=
BalGetStringVariable
(
L"TargetDir"
,
&
targetDir
);
if
(
FAILED
(
hr
)
||
!
targetDir
||
!
targetDir
[
0
])
{
ReleaseStr
(
targetDir
);
targetDir
=
nullptr
;
hr
=
BalGetNumericVariable
(
L"InstallAllUsers"
,
&
installAllUsers
);
ExitOnFailure
(
hr
,
L"Failed to get install scope"
);
hr
=
BalGetStringVariable
(
installAllUsers
?
L"DefaultAllUsersTargetDir"
:
L"DefaultJustForMeTargetDir"
,
&
defaultDir
);
BalExitOnFailure
(
hr
,
"Failed to get the default install directory"
);
if
(
!
defaultDir
||
!
defaultDir
[
0
])
{
BalLogError
(
E_INVALIDARG
,
"Default install directory is blank"
);
}
hr
=
BalFormatString
(
defaultDir
,
&
targetDir
);
BalExitOnFailure1
(
hr
,
"Failed to format '%ls'"
,
defaultDir
);
hr
=
_engine
->
SetVariableString
(
L"TargetDir"
,
targetDir
);
BalExitOnFailure
(
hr
,
"Failed to set install target directory"
);
}
LExit
:
ReleaseStr
(
defaultDir
);
ReleaseStr
(
targetDir
);
return
hr
;
}
public
:
public
:
//
//
// Constructor - initialize member variables.
// Constructor - initialize member variables.
...
@@ -3057,6 +3070,7 @@ public:
...
@@ -3057,6 +3070,7 @@ public:
_baFunction
=
nullptr
;
_baFunction
=
nullptr
;
LoadOptionalFeatureStates
(
pEngine
);
LoadOptionalFeatureStates
(
pEngine
);
EnsureTargetDir
();
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment