David Reiss | ea2cba8 | 2009-03-30 21:35:00 +0000 | [diff] [blame] | 1 | # |
| 2 | # Licensed to the Apache Software Foundation (ASF) under one |
| 3 | # or more contributor license agreements. See the NOTICE file |
| 4 | # distributed with this work for additional information |
| 5 | # regarding copyright ownership. The ASF licenses this file |
| 6 | # to you under the Apache License, Version 2.0 (the |
| 7 | # "License"); you may not use this file except in compliance |
| 8 | # with the License. You may obtain a copy of the License at |
| 9 | # |
| 10 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | # |
| 12 | # Unless required by applicable law or agreed to in writing, |
| 13 | # software distributed under the License is distributed on an |
| 14 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 15 | # KIND, either express or implied. See the License for the |
| 16 | # specific language governing permissions and limitations |
| 17 | # under the License. |
| 18 | # |
Roger Meier | 81a1f99 | 2014-10-22 14:09:43 +0200 | [diff] [blame] | 19 | AUTOMAKE_OPTIONS = serial-tests |
| 20 | |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 21 | THRIFT = $(top_builddir)/compiler/cpp/thrift |
David Reiss | 9ff3b9d | 2008-02-15 01:10:23 +0000 | [diff] [blame] | 22 | |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 23 | py_unit_tests = RunClientServer.py |
David Reiss | 9ff3b9d | 2008-02-15 01:10:23 +0000 | [diff] [blame] | 24 | |
| 25 | thrift_gen = \ |
David Reiss | 8cee47c | 2009-02-07 02:37:05 +0000 | [diff] [blame] | 26 | gen-py/ThriftTest/__init__.py \ |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 27 | gen-py/DebugProtoTest/__init__.py \ |
| 28 | gen-py-default/ThriftTest/__init__.py \ |
| 29 | gen-py-default/DebugProtoTest/__init__.py \ |
| 30 | gen-py-slots/ThriftTest/__init__.py \ |
| 31 | gen-py-slots/DebugProtoTest/__init__.py \ |
| 32 | gen-py-newstyle/ThriftTest/__init__.py \ |
| 33 | gen-py-newstyle/DebugProtoTest/__init__.py \ |
| 34 | gen-py-newstyleslots/ThriftTest/__init__.py \ |
| 35 | gen-py-newstyleslots/DebugProtoTest/__init__.py \ |
| 36 | gen-py-dynamic/ThriftTest/__init__.py \ |
| 37 | gen-py-dynamic/DebugProtoTest/__init__.py \ |
| 38 | gen-py-dynamicslots/ThriftTest/__init__.py \ |
| 39 | gen-py-dynamicslots/DebugProtoTest/__init__.py |
David Reiss | 9ff3b9d | 2008-02-15 01:10:23 +0000 | [diff] [blame] | 40 | |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 41 | precross: $(THRIFT) $(thrift_gen) |
| 42 | |
David Reiss | 9ff3b9d | 2008-02-15 01:10:23 +0000 | [diff] [blame] | 43 | helper_scripts= \ |
| 44 | TestClient.py \ |
| 45 | TestServer.py |
| 46 | |
| 47 | check_SCRIPTS= \ |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 48 | $(thrift_gen) \ |
David Reiss | 9ff3b9d | 2008-02-15 01:10:23 +0000 | [diff] [blame] | 49 | $(py_unit_tests) \ |
| 50 | $(helper_scripts) |
| 51 | |
| 52 | TESTS= $(py_unit_tests) |
| 53 | |
| 54 | |
David Reiss | 8cee47c | 2009-02-07 02:37:05 +0000 | [diff] [blame] | 55 | gen-py/%/__init__.py: ../%.thrift |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 56 | $(THRIFT) --gen py $< |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 57 | |
| 58 | gen-py-default/%/__init__.py: ../%.thrift |
| 59 | test -d gen-py-default || $(MKDIR_P) gen-py-default |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 60 | $(THRIFT) --gen py -out gen-py-default $< |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 61 | |
| 62 | gen-py-slots/%/__init__.py: ../%.thrift |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 63 | test -d gen-py-slots || $(MKDIR_P) gen-py-slots |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 64 | $(THRIFT) --gen py:slots -out gen-py-slots $< |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 65 | |
| 66 | gen-py-newstyle/%/__init__.py: ../%.thrift |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 67 | test -d gen-py-newstyle || $(MKDIR_P) gen-py-newstyle |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 68 | $(THRIFT) --gen py:new_style -out gen-py-newstyle $< |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 69 | |
| 70 | gen-py-newstyleslots/%/__init__.py: ../%.thrift |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 71 | test -d gen-py-newstyleslots || $(MKDIR_P) gen-py-newstyleslots |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 72 | $(THRIFT) --gen py:new_style,slots -out gen-py-newstyleslots $< |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 73 | |
| 74 | gen-py-dynamic/%/__init__.py: ../%.thrift |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 75 | test -d gen-py-dynamic || $(MKDIR_P) gen-py-dynamic |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 76 | $(THRIFT) --gen py:dynamic -out gen-py-dynamic $< |
Roger Meier | f4eec7a | 2011-09-11 18:16:21 +0000 | [diff] [blame] | 77 | |
| 78 | gen-py-dynamicslots/%/__init__.py: ../%.thrift |
Roger Meier | 41ad434 | 2015-03-24 22:30:40 +0100 | [diff] [blame^] | 79 | test -d gen-py-dynamicslots || $(MKDIR_P) gen-py-dynamicslots |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 80 | $(THRIFT) --gen py:dynamic,slots -out gen-py-dynamicslots $< |
David Reiss | 9ff3b9d | 2008-02-15 01:10:23 +0000 | [diff] [blame] | 81 | |
| 82 | clean-local: |
Jens Geyer | 79f988c | 2014-10-03 20:42:54 +0200 | [diff] [blame] | 83 | $(RM) -r gen-py gen-py-slots gen-py-default gen-py-newstyle gen-py-newstyleslots gen-py-dynamic gen-py-dynamicslots |