Skip to content

Commit

Permalink
Move macros.i and doc files to gphoto2/common
Browse files Browse the repository at this point in the history
  • Loading branch information
jim-easterbrook committed Oct 21, 2017
1 parent 24b861a commit b27bd05
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Expand Up @@ -3,6 +3,6 @@ dist
doxy2swig
libgphoto2-*
MANIFEST
src/doc-*
src/gphoto2/common/doc-*
src/info.txt
src/swig-*
9 changes: 5 additions & 4 deletions setup.py
Expand Up @@ -162,7 +162,8 @@ def run(self):
('gp_port_info_', '_GPPortInfo', 'PortInfo'),
('gp_widget_', '_CameraWidget', 'CameraWidget'),
)
with open(os.path.join('src', 'doc-' + gp_version + '.i'), 'w') as of:
with open(os.path.join('src', 'gphoto2', 'common',
'doc-' + gp_version + '.i'), 'w') as of:
for match in re.finditer('%feature\("docstring"\) (\w+) \"(.+?)\";',
text, re.DOTALL):
symbol = match.group(1)
Expand Down Expand Up @@ -215,13 +216,13 @@ def run(self):
break
for use_builtin in swig_bis:
# make options list
swig_opts = ['-python', '-nodefaultctor', '-O', '-Isrc',
'-Wextra', '-Werror']
swig_opts = ['-python', '-nodefaultctor', '-O', '-Wextra', '-Werror']
if use_builtin:
swig_opts += ['-builtin', '-nofastunpack']
# do each gphoto2 version
for gp_version in gp_versions:
doc_file = os.path.join('src', 'doc-' + gp_version + '.i')
doc_file = os.path.join(
'src', 'gphoto2', 'common', 'doc-' + gp_version + '.i')
# do Python 2 and 3
for py_version in 2, 3:
output_dir = os.path.join('src', 'swig')
Expand Down
File renamed without changes.

0 comments on commit b27bd05

Please sign in to comment.