Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Mattias Fält
moberg
Commits
c82e5a22
Commit
c82e5a22
authored
Mar 26, 2019
by
Anders Blomdell
Browse files
Add python adapter
parent
025327b0
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
adaptors/python/.gitignore
0 → 100644
View file @
c82e5a22
/__pycache__
/install
\ No newline at end of file
adaptors/python/Makefile
0 → 100644
View file @
c82e5a22
MOBERG_VERSION
=
$(
shell
git describe
--tags
)
all
:
BUILD
.PHONY
:
BUILD
BUILD
:
python2 ./setup.py build
python3 ./setup.py build
.PHONY
:
INSTALL
INSTALL
:
MOBERG_VERSION
=
$(MOBERG_VERSION)
python2
\
./setup.py
install
-O1
--prefix
=
/usr/
--root
=
./install
MOBERG_VERSION
=
$(MOBERG_VERSION)
python3
\
./setup.py
install
-O1
--prefix
=
/usr/
--root
=
./install
clean
:
rm
-rf
build
install
adaptors/python/python-moberg.c
0 → 100644
View file @
c82e5a22
This diff is collapsed.
Click to expand it.
adaptors/python/setup.py
0 → 100755
View file @
c82e5a22
#!/usr/bin/env python
from
distutils.core
import
setup
,
Extension
module
=
Extension
(
'moberg'
,
sources
=
[
'python-moberg.c'
],
include_dirs
=
[
'../..'
],
libraries
=
[
'moberg'
])
longdesc
=
'''This extension provides bindings to the Moberg I/O library
'''
try
:
import
os
VERSION
=
os
.
environ
[
'MOBERG_VERSION'
]
except
KeyError
:
VERSION
=
'_UNKNOWN_'
pass
setup
(
name
=
'python-moberg'
,
version
=
VERSION
,
description
=
'Python bindings to the Moberg I/O library'
,
long_description
=
longdesc
,
author
=
'Anders Blomdell'
,
author_email
=
'anders.blomdell@control.lth.se'
,
url
=
'http://gitlab.control.lth.se/anders_blomdell/moberg.git'
,
license
=
'GPLv2'
,
platforms
=
'Linux'
,
ext_modules
=
[
module
])
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment