Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
Pyston
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
Pyston
Commits
9c3659f7
Commit
9c3659f7
authored
Dec 17, 2014
by
Kevin Modzelewski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
In CMake, copy the stdlib over if they get changed
My first stab at writing CMake rules
parent
b9e2852f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
2 deletions
+18
-2
Makefile
Makefile
+2
-2
lib_python/CMakeLists.txt
lib_python/CMakeLists.txt
+16
-0
No files found.
Makefile
View file @
9c3659f7
...
...
@@ -749,10 +749,10 @@ $(call link,_release,$(OPT_OBJS),$(LDFLAGS_RELEASE),$(LLVM_RELEASE_DEPS))
else
.PHONY
:
pyston_dbg pyston_release
pyston_dbg
:
$(NINJA)
-C
$(HOME)
/pyston-build-dbg pyston
$(NINJAFLAGS)
$(NINJA)
-C
$(HOME)
/pyston-build-dbg pyston
copy_stdlib
$(NINJAFLAGS)
ln
-sf
$(HOME)
/pyston-build-dbg/pyston pyston_dbg
pyston_release
:
$(NINJA)
-C
$(HOME)
/pyston-build-release pyston
$(NINJAFLAGS)
$(NINJA)
-C
$(HOME)
/pyston-build-release pyston
copy_stdlib
$(NINJAFLAGS)
ln
-sf
$(HOME)
/pyston-build-release/pyston pyston_release
endif
...
...
lib_python/CMakeLists.txt
View file @
9c3659f7
# Copy any changed stdlib files to the destination:
file
(
GLOB_RECURSE STDLIB_SRCS 2.7/
"*.py"
)
SET
(
STDLIB_TARGETS
""
)
foreach
(
STDLIB_FILE
${
STDLIB_SRCS
}
)
file
(
RELATIVE_PATH FN_REL
${
CMAKE_SOURCE_DIR
}
${
STDLIB_FILE
}
)
set
(
TARGET
${
CMAKE_BINARY_DIR
}
/
${
FN_REL
}
)
add_custom_command
(
OUTPUT
${
TARGET
}
COMMAND
${
CMAKE_COMMAND
}
-E copy_if_different
${
STDLIB_FILE
}
${
TARGET
}
DEPENDS
${
STDLIB_FILE
}
COMMENT
"Copying
${
FN_REL
}
"
)
set
(
STDLIB_TARGETS
${
STDLIB_TARGETS
}
${
TARGET
}
)
endforeach
(
STDLIB_FILE
)
add_custom_target
(
copy_stdlib ALL DEPENDS
${
STDLIB_TARGETS
}
)
# compile specified files in lib_python/2.7_Modules
file
(
GLOB_RECURSE STDMODULE_SRCS 2.7_Modules errnomodule.c shamodule.c sha256module.c sha512module.c _math.c mathmodule.c md5.c md5module.c _randommodule.c _sre.c operator.c binascii.c pwdmodule.c posixmodule.c
)
...
...
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