aboutsummaryrefslogtreecommitdiffstats
path: root/build/vty_reference_combine.sh
AgeCommit message (Collapse)AuthorFilesLines
2020-11-02vty_reference_combine.sh: print the final result to stdoutVadim Yanitskiy1-15/+16
This is a follow-up change for [1], making this script more flexible. It's now a task of the caller to store the merge results to a file. This approach allows to merge several *.xml files and store all the results in a single directory. Unfortunately, it's impossible to pass the same file as both input and output to xsltproc, because it would immediately overwrite its input. To work this around, create two temporary files and remove them at the end of the script. [1] Iabe729af22c235cf9c4b252acda99b43ebcae20c Change-Id: I6aac73d998c5937894233631e654a160d5623198 Related: SYS#4937
2020-11-02Makefile.vty-reference.inc: create 'generated' in this fileVadim Yanitskiy1-1/+0
Ideally, 'vty_reference_combine.sh' should not create any files nor directories on its own; it should do exactly what its name suggests - combine several XML files into a single one. Let's first make the target directory ('generated') creation a task of 'Makefile.vty-reference.inc', and then make it output the results to stdout in a follow-up change. Change-Id: Iabe729af22c235cf9c4b252acda99b43ebcae20c Related: SYS#4937
2019-12-03Support multiple VTY reference manualsOliver Smith1-3/+7
Adjust vty_reference_combine.sh, so we can change the output dir from "generated" to a subdir inside "generated" when building anything but the first VTY reference. Add a generic pattern to Makefile.vty-reference for additional VTY references, that uses slightly different paths compared to the first VTY reference, in order to avoid collisions. Related: OS#4292 Change-Id: I4dea3e07b88175b2a88e577129360af7ec5f87e1
2018-11-21vty_reference_combine.sh: chmod xsltproc outputOliver Smith1-0/+8
Force the xsltproc output file to be writable, if it exists already. This is needed for 'make distcheck': xsltproc gives output files the same permissions as input files. We need to change the output file in multiple iterations in vty_reference_combine.sh, hence it must be writable. (moving manuals to project repositories 15/19) Related: OS#3385 Change-Id: I693e12ee15665d01cbc50187e6cb3ca74ad0356a
2018-11-21vty_reference_combine.sh: add *reference.xml argOliver Smith1-4/+8
Pass the path to $(srcdir)/vty/*reference.xml as parameter to vty_reference_combine.sh instead of assuming that it will be in ./vty/*reference.xml. This is necessary to make the build scripts work for out-of-tree builds. Because when building out-of-tree, the source dir and build dir (the one where the Makefile gets generated, and in which "make" runs), are not the same anymore. The relative vty/reference.xml path is only valid in the source dir, not in the build dir. The next commits in this series have more changes for out-of-tree builds. Out-of-tree building is necessary for consistency with the other Osmocom code, which can be built out-of-tree as well. It would be strange if this did not work anymore as soon as the users enabled building the manuals. (moving manuals to project repositories 10/19) Related: OS#3385 Change-Id: I3dcb49d7705f882bd117088d4e5eab91dd1c7d8c
2017-10-25refactor Makefile build rules, don't use the FORCENeels Hofmeyr1-0/+25
The initial goal was to make sure we don't have overall FORCE rules causing unnecessary rebuilds -- annoying while writing documentation. As I looked through possible dependencies, I finally understood what's going on here. Remove code dup and nicely sort which belongs where in build/Makefile.*.inc. In each, describe in a top comment how to use it, and also unify how they are used: - Rename Makefile.inc to Makefile.docbook.inc and refactor - Add Makefile.vty-reference.inc - Add Makefile.common.inc Make sure that we accurately pick up all dependencies. Drop use of the macro called 'command', that silenced the actual command lines invoked and replaced them with short strings: it obscures what is actually going on and makes the Makefiles hard to read and understand. Each manual's makefile is greatly reduced to few definitions and a Makefile include, e.g. one for asciidoc, one for VTY reference. Move common/bsc_vty_additions.xml to OsmoBSC/vty/libbsc_vty_additions.xml, link from OsmoNITB. It applies only to OsmoBSC and OsmoNITB. Add a script that combines a VTY reference file with *all* additions files found in a manual's vty/ dir. Call this from Makefile.vty-reference.inc. Change-Id: I9758e04162a480e28c7dc83475b514cf7fd25ec0