forked from lanl/qmasm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
35 lines (30 loc) · 1.14 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#! /usr/bin/env python
###################################
# Install QMASM #
# By Scott Pakin <[email protected]> #
###################################
import os.path
from setuptools import setup, find_packages
from setuptools.command.install import install as _install
script_list = ["qmasm", "qb2qmasm", "qmasm-ground-state", "qmasm-qbsolv"]
class install(_install):
def run(self):
# Install, then remove <script>.py, keeping only <script>.
_install.run(self)
for scr in script_list:
pyscript = os.path.join(self.install_scripts, scr + ".py")
script = os.path.join(self.install_scripts, scr)
os.rename(pyscript, script)
setup(name = "QMASM",
version = "1.2",
description = "Quantum Macro Assembler",
author = "Scott Pakin",
author_email = "[email protected]",
classifiers = ["Topic :: Software Development :: Compilers"],
url = "https://github.com/lanl/qmasm",
license = "BSD",
keywords = "quantum assembler d-wave",
packages = find_packages(),
scripts = [s + ".py" for s in script_list],
cmdclass = {"install": install}
)