From 455e55f8e51c328400c36d65a15d76e7c4be08eb Mon Sep 17 00:00:00 2001 From: Jussi Pakkanen Date: Wed, 2 Mar 2016 21:49:29 +0200 Subject: Back to .py suffix in files. Closes #394. --- meson | 24 ------------------------ meson.py | 24 ++++++++++++++++++++++++ mesonconf | 20 -------------------- mesonconf.py | 20 ++++++++++++++++++++ mesongui | 20 -------------------- mesongui.py | 20 ++++++++++++++++++++ mesonintrospect | 20 -------------------- mesonintrospect.py | 20 ++++++++++++++++++++ run_tests.py | 4 ++++ setup.py | 6 +++++- wraptool | 20 -------------------- wraptool.py | 20 ++++++++++++++++++++ 12 files changed, 113 insertions(+), 105 deletions(-) delete mode 100755 meson create mode 100755 meson.py delete mode 100755 mesonconf create mode 100755 mesonconf.py delete mode 100755 mesongui create mode 100755 mesongui.py delete mode 100755 mesonintrospect create mode 100755 mesonintrospect.py delete mode 100755 wraptool create mode 100755 wraptool.py diff --git a/meson b/meson deleted file mode 100755 index b9773687b..000000000 --- a/meson +++ /dev/null @@ -1,24 +0,0 @@ -#!/usr/bin/env python3 - -# Copyright 2016 The Meson development team - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -from mesonbuild import mesonmain -import sys, os - -thisfile = __file__ -if not os.path.isabs(thisfile): - thisfile = os.path.normpath(os.path.join(os.getcwd(), thisfile)) - -sys.exit(mesonmain.run(thisfile, sys.argv[1:])) diff --git a/meson.py b/meson.py new file mode 100755 index 000000000..b9773687b --- /dev/null +++ b/meson.py @@ -0,0 +1,24 @@ +#!/usr/bin/env python3 + +# Copyright 2016 The Meson development team + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +from mesonbuild import mesonmain +import sys, os + +thisfile = __file__ +if not os.path.isabs(thisfile): + thisfile = os.path.normpath(os.path.join(os.getcwd(), thisfile)) + +sys.exit(mesonmain.run(thisfile, sys.argv[1:])) diff --git a/mesonconf b/mesonconf deleted file mode 100755 index 2b0a1a61f..000000000 --- a/mesonconf +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env python3 - -# Copyright 2016 The Meson development team - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -from mesonbuild import mconf -import sys - -sys.exit(mconf.run(sys.argv[1:])) diff --git a/mesonconf.py b/mesonconf.py new file mode 100755 index 000000000..2b0a1a61f --- /dev/null +++ b/mesonconf.py @@ -0,0 +1,20 @@ +#!/usr/bin/env python3 + +# Copyright 2016 The Meson development team + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +from mesonbuild import mconf +import sys + +sys.exit(mconf.run(sys.argv[1:])) diff --git a/mesongui b/mesongui deleted file mode 100755 index 9e16b001c..000000000 --- a/mesongui +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env python3 - -# Copyright 2016 The Meson development team - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -from mesonbuild import mgui -import sys - -sys.exit(mgui.run(sys.argv)) diff --git a/mesongui.py b/mesongui.py new file mode 100755 index 000000000..9e16b001c --- /dev/null +++ b/mesongui.py @@ -0,0 +1,20 @@ +#!/usr/bin/env python3 + +# Copyright 2016 The Meson development team + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +from mesonbuild import mgui +import sys + +sys.exit(mgui.run(sys.argv)) diff --git a/mesonintrospect b/mesonintrospect deleted file mode 100755 index 4d20548b1..000000000 --- a/mesonintrospect +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env python3 - -# Copyright 2016 The Meson development team - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -from mesonbuild import mintro -import sys - -sys.exit(mintro.run(sys.argv[1:])) diff --git a/mesonintrospect.py b/mesonintrospect.py new file mode 100755 index 000000000..4d20548b1 --- /dev/null +++ b/mesonintrospect.py @@ -0,0 +1,20 @@ +#!/usr/bin/env python3 + +# Copyright 2016 The Meson development team + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +from mesonbuild import mintro +import sys + +sys.exit(mintro.run(sys.argv[1:])) diff --git a/run_tests.py b/run_tests.py index e85a6d6ce..7e799cb70 100755 --- a/run_tests.py +++ b/run_tests.py @@ -46,6 +46,10 @@ print_debug = 'MESON_PRINT_TEST_OUTPUT' in os.environ test_build_dir = 'work area' install_dir = os.path.join(os.path.split(os.path.abspath(__file__))[0], 'install dir') meson_command = os.path.join(os.getcwd(), 'meson') +if not os.path.exists(meson_command): + meson_command += '.py' + if not os.path.exists(meson_command): + raise RuntimeError('Could not find main Meson script to run.') class StopException(Exception): def __init__(self): diff --git a/setup.py b/setup.py index 0ccd81fae..0acce4d5e 100644 --- a/setup.py +++ b/setup.py @@ -37,7 +37,11 @@ setup(name='meson', 'mesonbuild.backend', 'mesonbuild.wrap'], package_data={'mesonbuild': ['*.ui']}, - scripts=['meson', 'mesonconf', 'mesongui', 'mesonintrospect', 'wraptool'], + scripts=['meson.py', + 'mesonconf.py', + 'mesongui.py', + 'mesonintrospect.py', + 'wraptool.py'], data_files=[('share/man/man1', ['man/meson.1', 'man/mesonconf.1', 'man/mesongui.1', diff --git a/wraptool b/wraptool deleted file mode 100755 index 5e03efd18..000000000 --- a/wraptool +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env python3 - -# Copyright 2016 The Meson development team - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -from mesonbuild.wrap import wraptool -import sys - -sys.exit(wraptool.run(sys.argv[1:])) diff --git a/wraptool.py b/wraptool.py new file mode 100755 index 000000000..5e03efd18 --- /dev/null +++ b/wraptool.py @@ -0,0 +1,20 @@ +#!/usr/bin/env python3 + +# Copyright 2016 The Meson development team + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +from mesonbuild.wrap import wraptool +import sys + +sys.exit(wraptool.run(sys.argv[1:])) -- cgit v1.2.3