Fix syntax to be wrap-and-sort compatible
- May 23, 2023
-
-
Ritesh Raj Sarraf authored
Signed-off-by:
Ritesh Raj Sarraf <ritesh.sarraf@collabora.co.uk>
-
Ritesh Raj Sarraf authored
Signed-off-by:
Ritesh Raj Sarraf <ritesh.sarraf@collabora.com>
-
Ritesh Raj Sarraf authored
Because with wrap-and-sort the build fails with: ``` Traceback (most recent call last): File "/usr/bin/wrap-and-sort", line 496, in <module> main() File "/usr/bin/wrap-and-sort", line 481, in main modified_files = wrap_and_sort(args) ^^^^^^^^^^^^^^^^^^^ File "/usr/bin/wrap-and-sort", line 312, in wrap_and_sort control = WrapAndSortControl(control_file, args) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/bin/wrap-and-sort", line 99, in __init__ super().__init__(filename, use_rts_parser=args.rts_parser) File "/usr/lib/python3/dist-packages/devscripts/control.py", line 210, in __init__ self._deb822_file = parse_deb822_file(sequence) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/debian/_deb822_repro/parsing.py", line 3095, in parse_deb822_file deb822_file = Deb822FileElement(LinkedList(tokens)) ^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/debian/_util.py", line 159, in __init__ self.extend(values) File "/usr/lib/python3/dist-packages/debian/_util.py", line 272, in extend for v in values: File "/usr/lib/python3/dist-packages/debian/_deb822_repro/_util.py", line 104, in _impl for token in token_stream: File "/usr/lib/python3/dist-packages/debian/_deb822_repro/_util.py", line 104, in _impl for token in token_stream: File "/usr/lib/python3/dist-packages/debian/_deb822_repro/parsing.py", line 2991, in _build_field_with_value value_element = next(buffered_stream, None) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/debian/_deb822_repro/_util.py", line 143, in __next__ return next(self._stream) ^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/debian/_deb822_repro/_util.py", line 104, in _impl for token in token_stream: File "/usr/lib/python3/dist-packages/debian/_deb822_repro/parsing.py", line 2939, in _build_value_line tokens_in_value = list(buffered_stream.takewhile(_non_end_of_line_token)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/debian/_deb822_repro/_util.py", line 149, in takewhile while buffer or self._fill_buffer(5): ^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/debian/_deb822_repro/_util.py", line 198, in _fill_buffer self._buffer.append(next(self._stream)) ^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/debian/_deb822_repro/_util.py", line 104, in _impl for token in token_stream: File "/usr/lib/python3/dist-packages/debian/_deb822_repro/parsing.py", line 3031, in _abort_on_error_tokens raise SyntaxOrParseError( debian._deb822_repro.types.SyntaxOrParseError: Syntax or Parse error on the line: "@XS_RUBY_VERSIONS@\n" ``` Given that the d/control.in file is used only as a template in upstream's build recipe, rename d/control.in to d/control.in.template, to exclude it from being auto-scanned by wrap-and-sort Note: wrap-and-sort is used throughout Apertis, in our build recipes Signed-off-by:
Ritesh Raj Sarraf <ritesh.sarraf@collabora.com>
-