Skip to content

Commit 9526b05

Browse files
committed
Create capsule for benchmark
1 parent cc684d2 commit 9526b05

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/benchmark.py

+11
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,18 @@ def obffuscate_python_scripts(output, filename):
137137
'encrypt', '-O', output, '-i', filename])
138138
p.wait()
139139

140+
def check_default_capsule():
141+
capsule = 'project.zip'
142+
if os.path.exists(capsule):
143+
logging.info('Use capsule: %s', capsule)
144+
return
145+
146+
p = subprocess.Popen([sys.executable, 'pyarmor.py', 'capsule'])
147+
p.wait()
148+
140149
def main():
150+
check_default_capsule()
151+
141152
time.clock()
142153
pytransform = load_pytransform()
143154
init_pytransform(pytransform)

0 commit comments

Comments
 (0)