Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dlib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
钟尚武
dlib
Commits
69ff6a3f
Commit
69ff6a3f
authored
Aug 20, 2015
by
Ehsan Azarnasab
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make sure sdist includes all necessary packages and no build directories
parent
ae5c6242
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
14 deletions
+20
-14
MANIFEST.in
MANIFEST.in
+8
-4
setup.py
setup.py
+12
-10
No files found.
MANIFEST.in
View file @
69ff6a3f
...
...
@@ -5,12 +5,16 @@
include MANIFEST.in
include setup.py
include README.txt
# sources
# recursive-include sources/dlib **
# recursive-include sources/docs **
# recursive-include sources/python_examples **
# recursive-include sources/tools/python **
recursive-include dlib **
recursive-exclude dlib/test **
recursive-include docs **
recursive-include python_examples *.txt *.py *.bat
recursive-include python_examples/build **
recursive-include tools/python **
recursive-exclude tools/python/build **
# dlib package
recursive-include dist/dlib **
...
...
setup.py
View file @
69ff6a3f
...
...
@@ -222,8 +222,8 @@ def readme(fname):
def
read_version
():
"""Read version information
"""
major
=
readme
(
'.
./..
/docs/.current_release_number'
)
.
strip
()
minor
=
readme
(
'.
./..
/docs/.current_minor_release_number'
)
.
strip
()
major
=
readme
(
'./docs/.current_release_number'
)
.
strip
()
minor
=
readme
(
'./docs/.current_minor_release_number'
)
.
strip
()
return
major
+
'.'
+
minor
...
...
@@ -259,14 +259,16 @@ class build(_build):
log
.
info
(
'Removing distribution directory
%
s'
%
dist_dir
)
rmtree
(
dist_dir
)
dist_dir_examples
=
os
.
path
.
join
(
script_dir
,
"dist/dlib/examples"
)
# this is where the extension examples go
dist_dir_examples
=
os
.
path
.
join
(
script_dir
,
"./dist/dlib/examples"
)
try
:
os
.
makedirs
(
dist_dir_examples
)
except
OSError
:
pass
log
.
info
(
'Populating the distribution directory
%
s'
%
dist_dir
)
dist_dir
=
os
.
path
.
join
(
script_dir
,
"dist/dlib"
)
# this is where the extension goes
log
.
info
(
'Populating the distribution directory
%
s ...'
%
dist_dir
)
dist_dir
=
os
.
path
.
join
(
script_dir
,
"./dist/dlib"
)
# create the module init files
with
open
(
os
.
path
.
join
(
dist_dir
,
'__init__.py'
),
'w'
):
...
...
@@ -275,7 +277,7 @@ class build(_build):
pass
# this is where the extension and Python examples are located
out_dir
=
os
.
path
.
join
(
script_dir
,
".
./..
/python_examples"
)
out_dir
=
os
.
path
.
join
(
script_dir
,
"./python_examples"
)
ext_found
=
False
# manually copy everything to distribution folder with package hierarchy in mind
...
...
@@ -292,7 +294,7 @@ class build(_build):
copy_file
(
srcname
,
dstname
)
if
not
ext_found
:
raise
DistutilsSetupError
(
"Cannot find dlib extension module."
)
raise
DistutilsSetupError
(
"Cannot find
built
dlib extension module."
)
return
_build
.
run
(
self
)
...
...
@@ -303,7 +305,7 @@ class build(_build):
platform_arch
=
platform
.
architecture
()[
0
]
log
.
info
(
"Detected Python architecture:
%
s"
%
platform_arch
)
build_dir
=
os
.
path
.
join
(
script_dir
,
"build"
)
build_dir
=
os
.
path
.
join
(
script_dir
,
"
./tools/python/
build"
)
if
os
.
path
.
exists
(
build_dir
):
log
.
info
(
'Removing build directory
%
s'
%
build_dir
)
rmtree
(
build_dir
)
...
...
@@ -335,7 +337,7 @@ class build(_build):
if
run_process
(
cmake_cmd
):
raise
DistutilsSetupError
(
"cmake build failed!"
)
# cd
where setup know
s
# cd
back where setup await
s
os
.
chdir
(
script_dir
)
...
...
@@ -374,7 +376,7 @@ setup(
version
=
read_version
(),
keywords
=
[
'dlib'
,
'Computer Vision'
,
'Machine Learning'
],
description
=
'A toolkit for making real world machine learning and data analysis applications'
,
long_description
=
readme
(
'.
./..
/README.txt'
),
long_description
=
readme
(
'./README.txt'
),
author
=
'Davis King'
,
author_email
=
'davis@dlib.net'
,
url
=
'https://github.com/davisking/dlib'
,
...
...
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