summaryrefslogtreecommitdiff
path: root/doc/source/f2py/code/setup_example.py
diff options
context:
space:
mode:
authorDevin Shanahan <dshanahan88@gmail.com>2022-01-16 05:12:59 -0700
committerDevin Shanahan <dshanahan88@gmail.com>2022-01-16 05:12:59 -0700
commit0f66b6032a2c5039007d5041398561b452ddabef (patch)
treed030c1ae812e138f74a29b280cddde376d821ab8 /doc/source/f2py/code/setup_example.py
parent5a52c717fe45c7c6bdc3d20b178a00bffbe9e24e (diff)
parent7191d9a4773d77205349ac151f84b72c0ffcf848 (diff)
downloadnumpy-0f66b6032a2c5039007d5041398561b452ddabef.tar.gz
MAINT: Merge branch 'main' into delete-speedup
Diffstat (limited to 'doc/source/f2py/code/setup_example.py')
-rw-r--r--doc/source/f2py/code/setup_example.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/doc/source/f2py/code/setup_example.py b/doc/source/f2py/code/setup_example.py
new file mode 100644
index 000000000..479acc004
--- /dev/null
+++ b/doc/source/f2py/code/setup_example.py
@@ -0,0 +1,16 @@
+from numpy.distutils.core import Extension
+
+ext1 = Extension(name = 'scalar',
+ sources = ['scalar.f'])
+ext2 = Extension(name = 'fib2',
+ sources = ['fib2.pyf', 'fib1.f'])
+
+if __name__ == "__main__":
+ from numpy.distutils.core import setup
+ setup(name = 'f2py_example',
+ description = "F2PY Users Guide examples",
+ author = "Pearu Peterson",
+ author_email = "pearu@cens.ioc.ee",
+ ext_modules = [ext1, ext2]
+ )
+# End of setup_example.py