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
bc12873e
Kaydet (Commit)
bc12873e
authored
Eyl 24, 1995
tarafından
Jack Jansen
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Load toolbox modules "by hand" using imp, so this script should now
work in a virgin distribution.
üst
3f14f4a3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
52 additions
and
11 deletions
+52
-11
ConfigurePython.py
Mac/scripts/ConfigurePython.py
+52
-11
No files found.
Mac/scripts/ConfigurePython.py
Dosyayı görüntüle @
bc12873e
...
@@ -10,23 +10,64 @@
...
@@ -10,23 +10,64 @@
#
#
# Jack Jansen, CWI, August 1995
# Jack Jansen, CWI, August 1995
import
os
import
macfs
import
sys
import
sys
def
help
():
print
"""
Try the following:
1. Remove any old "Python Preferences" files from the system folder.
2. Remove any old "PythonCore" files from the system folder.
3. Make sure this script, PythonPPC and PythonCore are all located in the
python home folder (where the Lib and PlugIns folders are)
4. Run this script again, by dropping it on PythonPPC.
If this fails try removing starting afresh from the distribution archive.
"""
sys
.
exit
(
1
)
try
:
try
:
import
Re
s
import
o
s
except
ImportError
:
except
ImportError
:
print
"""
print
"""
Res module not found, which probably means that you are trying
I cannot import the 'os' module, so something is wrong with sys.path
to execute this script with a dynamically-linked python. This will
"""
not work, since the whole point of the script is to create aliases
help
()
for dynamically-linked python to use. Do one of the following:
- Run this script using a non-dynamic python
try
:
- Use MkPluginAliases.as (an AppleScript)
import
Res
- Create the aliases by hand (see the source for a list)."""
except
ImportError
:
sys
.
exit
(
1
)
#
# Check that we are actually in the main python directory
#
try
:
os
.
chdir
(
':PlugIns'
)
except
IOError
:
print
"""
I cannot find the 'PlugIns' folder, so I am obviously not run from the Python
home folder.
"""
help
()
import
imp
cwd
=
os
.
getcwd
()
tblibname
=
os
.
path
.
join
(
cwd
,
"toolboxmodules.slb"
)
if
not
os
.
exists
(
tblibname
):
print
"""
I cannot find the 'toolboxmodules.slb' file in the PlugIns directory.
Start afresh from a clean distribution.
"""
sys
.
exit
(
1
)
try
:
for
wtd
in
[
"Ctl"
,
"Dlg"
,
"Evt"
,
"Qd"
,
"Res"
,
"Win"
]:
imp
.
load_dynamic_module
(
wtd
,
tblibname
,
None
)
except
ImportError
:
print
"""
I cannot load the toolbox modules by hand. Are you sure you are
using a PowerPC mac?
"""
sys
.
exit
(
1
)
import
macfs
import
EasyDialogs
import
EasyDialogs
import
macostools
import
macostools
...
...
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