aboutsummaryrefslogtreecommitdiffstats
path: root/BuildTests/ModuleTest
diff options
context:
space:
mode:
Diffstat (limited to 'BuildTests/ModuleTest')
-rw-r--r--BuildTests/ModuleTest/Dummy.S4
-rw-r--r--BuildTests/ModuleTest/Modules.h4
-rw-r--r--BuildTests/ModuleTest/Test_C.c4
-rw-r--r--BuildTests/ModuleTest/Test_CPP.cpp4
-rw-r--r--BuildTests/ModuleTest/makefile2
-rw-r--r--BuildTests/ModuleTest/makefile.test2
6 files changed, 10 insertions, 10 deletions
diff --git a/BuildTests/ModuleTest/Dummy.S b/BuildTests/ModuleTest/Dummy.S
index b44cf4c25..bc5270ab8 100644
--- a/BuildTests/ModuleTest/Dummy.S
+++ b/BuildTests/ModuleTest/Dummy.S
@@ -1,13 +1,13 @@
/*
LUFA Library
- Copyright (C) Dean Camera, 2017.
+ Copyright (C) Dean Camera, 2018.
dean [at] fourwalledcubicle [dot] com
www.lufa-lib.org
*/
/*
- Copyright 2017 Dean Camera (dean [at] fourwalledcubicle [dot] com)
+ Copyright 2018 Dean Camera (dean [at] fourwalledcubicle [dot] com)
Permission to use, copy, modify, distribute, and sell this
software and its documentation for any purpose is hereby granted
diff --git a/BuildTests/ModuleTest/Modules.h b/BuildTests/ModuleTest/Modules.h
index 686183245..b7028a950 100644
--- a/BuildTests/ModuleTest/Modules.h
+++ b/BuildTests/ModuleTest/Modules.h
@@ -1,13 +1,13 @@
/*
LUFA Library
- Copyright (C) Dean Camera, 2017.
+ Copyright (C) Dean Camera, 2018.
dean [at] fourwalledcubicle [dot] com
www.lufa-lib.org
*/
/*
- Copyright 2017 Dean Camera (dean [at] fourwalledcubicle [dot] com)
+ Copyright 2018 Dean Camera (dean [at] fourwalledcubicle [dot] com)
Permission to use, copy, modify, distribute, and sell this
software and its documentation for any purpose is hereby granted
diff --git a/BuildTests/ModuleTest/Test_C.c b/BuildTests/ModuleTest/Test_C.c
index 3c3f5a2ab..47905d2b3 100644
--- a/BuildTests/ModuleTest/Test_C.c
+++ b/BuildTests/ModuleTest/Test_C.c
@@ -1,13 +1,13 @@
/*
LUFA Library
- Copyright (C) Dean Camera, 2017.
+ Copyright (C) Dean Camera, 2018.
dean [at] fourwalledcubicle [dot] com
www.lufa-lib.org
*/
/*
- Copyright 2017 Dean Camera (dean [at] fourwalledcubicle [dot] com)
+ Copyright 2018 Dean Camera (dean [at] fourwalledcubicle [dot] com)
Permission to use, copy, modify, distribute, and sell this
software and its documentation for any purpose is hereby granted
diff --git a/BuildTests/ModuleTest/Test_CPP.cpp b/BuildTests/ModuleTest/Test_CPP.cpp
index 3c3f5a2ab..47905d2b3 100644
--- a/BuildTests/ModuleTest/Test_CPP.cpp
+++ b/BuildTests/ModuleTest/Test_CPP.cpp
@@ -1,13 +1,13 @@
/*
LUFA Library
- Copyright (C) Dean Camera, 2017.
+ Copyright (C) Dean Camera, 2018.
dean [at] fourwalledcubicle [dot] com
www.lufa-lib.org
*/
/*
- Copyright 2017 Dean Camera (dean [at] fourwalledcubicle [dot] com)
+ Copyright 2018 Dean Camera (dean [at] fourwalledcubicle [dot] com)
Permission to use, copy, modify, distribute, and sell this
software and its documentation for any purpose is hereby granted
diff --git a/BuildTests/ModuleTest/makefile b/BuildTests/ModuleTest/makefile
index 50f1909a3..32e3d7164 100644
--- a/BuildTests/ModuleTest/makefile
+++ b/BuildTests/ModuleTest/makefile
@@ -1,6 +1,6 @@
#
# LUFA Library
-# Copyright (C) Dean Camera, 2017.
+# Copyright (C) Dean Camera, 2018.
#
# dean [at] fourwalledcubicle [dot] com
# www.lufa-lib.org
diff --git a/BuildTests/ModuleTest/makefile.test b/BuildTests/ModuleTest/makefile.test
index 5eeb40398..4f1b54d14 100644
--- a/BuildTests/ModuleTest/makefile.test
+++ b/BuildTests/ModuleTest/makefile.test
@@ -1,6 +1,6 @@
#
# LUFA Library
-# Copyright (C) Dean Camera, 2017.
+# Copyright (C) Dean Camera, 2018.
#
# dean [at] fourwalledcubicle [dot] com
# www.lufa-lib.org
n>), ("setup.py", setup_py), ) # Read the listed version with open("pybind11/_version.py") as f: code = compile(f.read(), "pybind11/_version.py", "exec") loc = {} exec(code, loc) version = loc["__version__"] # Verify that the version matches the one in C++ with open("include/pybind11/detail/common.h") as f: matches = dict(VERSION_REGEX.findall(f.read())) cpp_version = "{MAJOR}.{MINOR}.{PATCH}".format(**matches) if version != cpp_version: msg = "Python version {} does not match C++ version {}!".format( version, cpp_version ) raise RuntimeError(msg) def get_and_replace(filename, binary=False, **opts): with open(filename, "rb" if binary else "r") as f: contents = f.read() # Replacement has to be done on text in Python 3 (both work in Python 2) if binary: return string.Template(contents.decode()).substitute(opts).encode() else: return string.Template(contents).substitute(opts) # Use our input files instead when making the SDist (and anything that depends # on it, like a wheel) class SDist(setuptools.command.sdist.sdist): def make_release_tree(self, base_dir, files): setuptools.command.sdist.sdist.make_release_tree(self, base_dir, files) for to, src in to_src: txt = get_and_replace(src, binary=True, version=version, extra_cmd="") dest = os.path.join(base_dir, to) # This is normally linked, so unlink before writing! os.unlink(dest) with open(dest, "wb") as f: f.write(txt) # Backport from Python 3 @contextlib.contextmanager def TemporaryDirectory(): # noqa: N802 "Prepare a temporary directory, cleanup when done" try: tmpdir = tempfile.mkdtemp() yield tmpdir finally: shutil.rmtree(tmpdir) # Remove the CMake install directory when done @contextlib.contextmanager def remove_output(*sources): try: yield finally: for src in sources: shutil.rmtree(src) with remove_output("pybind11/include", "pybind11/share"): # Generate the files if they are not present. with TemporaryDirectory() as tmpdir: cmd = ["cmake", "-S", ".", "-B", tmpdir] + [ "-DCMAKE_INSTALL_PREFIX=pybind11", "-DBUILD_TESTING=OFF", "-DPYBIND11_NOPYTHON=ON", ] cmake_opts = dict(cwd=DIR, stdout=sys.stdout, stderr=sys.stderr) subprocess.check_call(cmd, **cmake_opts) subprocess.check_call(["cmake", "--install", tmpdir], **cmake_opts) txt = get_and_replace(setup_py, version=version, extra_cmd=extra_cmd) code = compile(txt, setup_py, "exec") exec(code, {"SDist": SDist})