Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BlenderPhi
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
raas
BlenderPhi
Commits
5ef65a0a
Commit
5ef65a0a
authored
Feb 28, 2011
by
Campbell Barton
Browse files
Options
Downloads
Patches
Plain Diff
build system now exclude config-*, turtledemo when copying system python.
also remove __pycache__ dirs when cleaning (new in python 3.2)
parent
e09189cf
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
build_files/scons/tools/Blender.py
+27
-22
27 additions, 22 deletions
build_files/scons/tools/Blender.py
release/scripts/modules/bpy/utils.py
+1
-4
1 addition, 4 deletions
release/scripts/modules/bpy/utils.py
source/creator/CMakeLists.txt
+11
-6
11 additions, 6 deletions
source/creator/CMakeLists.txt
with
39 additions
and
32 deletions
build_files/scons/tools/Blender.py
+
27
−
22
View file @
5ef65a0a
...
@@ -625,30 +625,35 @@ def UnixPyBundle(target=None, source=None, env=None):
...
@@ -625,30 +625,35 @@ def UnixPyBundle(target=None, source=None, env=None):
print
'
\t
(skipping copy)
\n
'
print
'
\t
(skipping copy)
\n
'
return
return
# Copied from source/creator/CMakeLists.txt, keep in sync.
# Copied from source/creator/CMakeLists.txt, keep in sync.
print
'
Install python from:
'
print
'
Install python from:
'
print
'
\t
"
%s
"
into...
'
%
py_src
print
'
\t
"
%s
"
into...
'
%
py_src
print
'
\t
"
%s
"
\n
'
%
py_target
print
'
\t
"
%s
"
\n
'
%
py_target
run
(
'
rm -rf
"
%s
"'
%
py_target
)
run
(
"
rm -rf
'
%s
'"
%
py_target
)
try
:
os
.
makedirs
(
os
.
path
.
dirname
(
py_target
))
# the final part is copied
try
:
except
:
pass
os
.
makedirs
(
os
.
path
.
dirname
(
py_target
))
# the final part is copied
except
:
pass
run
(
"
cp -R
'
%s
'
'
%s
'"
%
(
py_src
,
os
.
path
.
dirname
(
py_target
)))
run
(
"
rm -rf
'
%s/distutils
'"
%
py_target
)
run
(
"
rm -rf
'
%s/lib2to3
'"
%
py_target
)
run
(
"
rm -rf
'
%s/idlelib
'"
%
py_target
)
run
(
"
rm -rf
'
%s/tkinter
'"
%
py_target
)
run
(
"
rm -rf
'
%s/config
'"
%
py_target
)
run
(
'
cp -R
"
%s
"
"
%s
"'
%
(
py_src
,
os
.
path
.
dirname
(
py_target
)))
run
(
"
rm -rf
'
%s/site-packages
'"
%
py_target
)
run
(
'
rm -rf
"
%s/distutils
"'
%
py_target
)
run
(
"
mkdir
'
%s/site-packages
'"
%
py_target
)
# python needs it.'
run
(
'
rm -rf
"
%s/lib2to3
"'
%
py_target
)
run
(
'
rm -rf
"
%s/idlelib
"'
%
py_target
)
run
(
'
rm -rf
"
%s/tkinter
"'
%
py_target
)
run
(
'
rm -rf
"
%s/config
"'
%
py_target
)
run
(
'
rm -rf
"
%s/site-packages
"'
%
py_target
)
run
(
"
rm -f
'
%s/lib-dynload/_tkinter.so
'"
%
py_target
)
run
(
'
mkdir
"
%s/site-packages
"'
%
py_target
)
# python needs it.'
run
(
"
find
'
%s
'
-type d -name
'
test
'
-prune -exec rm -rf {}
'
;
'"
%
py_target
)
run
(
"
find
'
%s
'
-type d -name
'
config-*
'
-prune -exec rm -rf {}
'
;
'"
%
py_target
)
run
(
"
find
'
%s
'
-type d -name
'
turtledemo
'
-prune -exec rm -rf {}
'
;
'"
%
py_target
)
run
(
"
find
'
%s
'
-type d -name
'
__pycache__
'
-exec rm -rf {}
'
;
'"
%
py_target
)
run
(
"
find
'
%s
'
-name
'
*.py[co]
'
-exec rm -rf {}
'
;
'"
%
py_target
)
run
(
"
find
'
%s
'
-name
'
*.so
'
-exec strip -s {}
'
;
'"
%
py_target
)
run
(
'
rm -f
"
%s/lib-dynload/_tkinter.so
"'
%
py_target
)
run
(
'
find
"
%s
"
-name
"
test
"
-prune -exec rm -rf {} \;
'
%
py_target
)
run
(
'
find
"
%s
"
-name
"
*.py?
"
-exec rm -rf {} \;
'
%
py_target
)
run
(
'
find
"
%s
"
-name
"
*.so
"
-exec strip -s {} \;
'
%
py_target
)
#### END ACTION STUFF #########
#### END ACTION STUFF #########
...
...
This diff is collapsed.
Click to expand it.
release/scripts/modules/bpy/utils.py
+
1
−
4
View file @
5ef65a0a
...
@@ -23,10 +23,7 @@ This module contains utility functions specific to blender but
...
@@ -23,10 +23,7 @@ This module contains utility functions specific to blender but
not assosiated with blenders internal data.
not assosiated with blenders internal data.
"""
"""
from
_bpy
import
register_class
from
_bpy
import
register_class
,
unregister_class
,
blend_paths
from
_bpy
import
unregister_class
from
_bpy
import
blend_paths
from
_bpy
import
script_paths
as
_bpy_script_paths
from
_bpy
import
script_paths
as
_bpy_script_paths
from
_bpy
import
user_resource
as
_user_resource
from
_bpy
import
user_resource
as
_user_resource
...
...
This diff is collapsed.
Click to expand it.
source/creator/CMakeLists.txt
+
11
−
6
View file @
5ef65a0a
...
@@ -218,7 +218,8 @@ if(WITH_INSTALL)
...
@@ -218,7 +218,8 @@ if(WITH_INSTALL)
TARGET blender POST_BUILD MAIN_DEPENDENCY blender
TARGET blender POST_BUILD MAIN_DEPENDENCY blender
COMMENT
"copying blender scripts..."
COMMENT
"copying blender scripts..."
COMMAND cp -R
${
CMAKE_SOURCE_DIR
}
/release/scripts
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/
COMMAND cp -R
${
CMAKE_SOURCE_DIR
}
/release/scripts
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/
COMMAND find
${
TARGETDIR
}
-name
"*.py?"
-prune -exec rm -rf {}
"
\;
"
COMMAND find
${
TARGETDIR
}
-name '*.py[co]' -prune -exec rm -rf {} '\;'
COMMAND find
${
TARGETDIR
}
-name '__pycache__' -exec rmdir {} '+'
)
)
if
(
WITH_PYTHON_INSTALL
)
if
(
WITH_PYTHON_INSTALL
)
# Copy the systems python into the install directory
# Copy the systems python into the install directory
...
@@ -241,9 +242,12 @@ if(WITH_INSTALL)
...
@@ -241,9 +242,12 @@ if(WITH_INSTALL)
COMMAND mkdir
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
/site-packages
# python needs it.
COMMAND mkdir
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
/site-packages
# python needs it.
COMMAND rm -f
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
/lib-dynload/_tkinter.so
COMMAND rm -f
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
/lib-dynload/_tkinter.so
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-name
"test"
-prune -exec rm -rf {}
"
\;
"
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-type d -name 'test' -prune -exec rm -rf {} '\;'
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-name
"*.py?"
-exec rm -rf {}
"
\;
"
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-type d -name 'turtledemo' -prune -exec rm -rf {} '\;'
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-name
"*.so"
-exec strip -s {}
"
\;
"
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-type d -name 'config-*' -prune -exec rm -rf {} '\;'
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-name '*.py[co]' -exec rm -rf {} '\;'
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-name '__pycache__' -exec rmdir {} '+'
COMMAND find
${
TARGETDIR
}
/
${
BLENDER_VERSION
}
/python/lib/python
${
PYTHON_VERSION
}
-name '*.so' -exec strip -s {} '\;'
)
)
endif
()
endif
()
endif
()
endif
()
...
@@ -489,7 +493,8 @@ if(WITH_INSTALL)
...
@@ -489,7 +493,8 @@ if(WITH_INSTALL)
COMMAND cp -Rf
${
CMAKE_SOURCE_DIR
}
/release/scripts
${
TARGETDIR
}
/blender.app/Contents/MacOS/
${
BLENDER_VERSION
}
/
COMMAND cp -Rf
${
CMAKE_SOURCE_DIR
}
/release/scripts
${
TARGETDIR
}
/blender.app/Contents/MacOS/
${
BLENDER_VERSION
}
/
COMMAND mkdir
${
TARGETDIR
}
/blender.app/Contents/MacOS/
${
BLENDER_VERSION
}
/python/
COMMAND mkdir
${
TARGETDIR
}
/blender.app/Contents/MacOS/
${
BLENDER_VERSION
}
/python/
COMMAND unzip -q
${
LIBDIR
}
/release/
${
PYTHON_ZIP
}
-d
${
TARGETDIR
}
/blender.app/Contents/MacOS/
${
BLENDER_VERSION
}
/python/
COMMAND unzip -q
${
LIBDIR
}
/release/
${
PYTHON_ZIP
}
-d
${
TARGETDIR
}
/blender.app/Contents/MacOS/
${
BLENDER_VERSION
}
/python/
COMMAND find
${
TARGETDIR
}
/blender.app -name
"*.py?"
-prune -exec rm -rf {}
"
\;
"
COMMAND find
${
TARGETDIR
}
/blender.app -name '*.py[co]' -prune -exec rm -rf {} ';'
COMMAND find
${
TARGETDIR
}
/blender.app -name '__pycache__' -exec rmdir {} '+'
)
)
endif
()
endif
()
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
sign in
to comment