Commit aec5cf36 authored by David Hendriks's avatar David Hendriks
Browse files

updated gitignore and working on the setup file

parent 72f12294
Loading
Loading
Loading
Loading
+134 −0
Original line number Diff line number Diff line
@@ -7,6 +7,7 @@ tests/json*
docs/build/*


# Standard template
*.org~
*.so
*.pyc
@@ -20,3 +21,136 @@ output/*

__pycache__/
.ipynb_checkpoints/


# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class
*.sqlite3
*.swp
*.swo
*.pdf

# C extensions
*.so

# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg

# PyInstaller
#  Usually these files are written by a python script from a template
#  before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
.hypothesis/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# pyenv
.python-version

# celery beat schedule file
celerybeat-schedule

# SageMath parsed files
*.sage.py

# dotenv
.env

# virtualenv
.venv
venv/
ENV/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

.ipython/profile_default
.bash_history
.cache
.viminfo
.mysql_history
.config
.local
.pki

# Project-specific folders
storage
apiweb/settings/*.env
apiweb/media
apiweb/static
apiweb/profiles
node_modules
dbschema.dot

databases/
apiweb/static/
apiweb/apps/research/static/research/documents
apiweb/apps/research/static/research/theses
apiweb/apps/alumni/static/alumni/theses
apiweb/templates/piwik.html
media/

db.sqlite3
*.swp
+26 −9
Original line number Diff line number Diff line
"""
Setup script for binarycpython
"""

import setuptools
from distutils.core import setup, Extension

# from setuptools import find_packages
# from setuptools import setup, find_packages, Extension
import os
import subprocess
import re
@@ -137,16 +135,22 @@ LIBRARY_DIRS = [
    os.path.join(BINARY_C_DIR, "src"),
    "./",
    os.path.join(CWD, "lib/"),
    # os.path.join(CWD, "binarycpython/core/"),
] + BINARY_C_LIBDIRS

RUNTIME_LIBRARY_DIRS = [
    os.path.join(BINARY_C_DIR, "src"),
    "./",
    os.path.join(CWD, "lib/"),
    # os.path.join(CWD, "binarycpython/core/"),
] + BINARY_C_LIBDIRS

# filter out duplicates
INCLUDE_DIRS = list(dict.fromkeys(INCLUDE_DIRS))
BINARY_C_LIBS = list(dict.fromkeys(BINARY_C_LIBS))
LIBRARIES = list(dict.fromkeys(LIBRARIES))
LIBRARY_DIRS = list(dict.fromkeys(LIBRARY_DIRS))
RUNTIME_LIBRARY_DIRS = list(dict.fromkeys(RUNTIME_LIBRARY_DIRS))

# 
# print('\n')
# print("BINARY_C_CONFIG: ", str(BINARY_C_CONFIG) + "\n")
# print("incdirs: ", str(INCLUDE_DIRS) + "\n")
@@ -159,6 +163,7 @@ RUNTIME_LIBRARY_DIRS = [
# print("macros: ", str(BINARY_C_DEFINE_MACROS) + "\n")
# print('\n')

#quit()
############################################################
# Making the extension function
############################################################
@@ -194,12 +199,11 @@ setup(
    """.format(
        str(REQUIRED_BINARY_C_VERSIONS), str(REQUIRED_BINARY_C_VERSIONS)
    ),
    author="David Hendriks, Robert Izzard and Jeff Andrews",
    author_email="davidhendriks93@gmail.com/d.hendriks@surrey.ac.uk,\
        r.izzard@surrey.ac.uk/rob.izzard@gmail.com andrews@physics.uoc.gr",
    author="David Hendriks",
    author_email="davidhendriks93@gmail.com",
    long_description=readme(),
    url="https://gitlab.eps.surrey.ac.uk/ri0005/binary_c-python",
    license="",
    license="gpl",
    package_dir={
        "binarycpython": "binarycpython",
        "binarycpython.utils": "binarycpython/utils",
@@ -214,4 +218,17 @@ setup(
    #     'binarycpython.core': ['libbinary_c_api.so'],
    # },
    ext_modules=[BINARY_C_PYTHON_API_MODULE],  # binary_c must be loaded

    classifiers=[
        "Development Status :: 3 - Alpha",
        "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
        "Intended Audience :: Developers",
        "Intended Audience :: Science/Research",
        "Operating System :: POSIX :: Linux",
        "Programming Language :: Python :: 3",
        "Programming Language :: C",
        "Topic :: Education",
        "Topic :: Scientific/Engineering :: Physics",
        "Topic :: Software Development :: Libraries :: Python Modules",
    ],
)