@ -2,19 +2,6 @@ project('Meson documentation', version: '1.0')
cur_bdir = meson . current_build_dir ( )
cur_bdir = meson . current_build_dir ( )
# Only the script knows which files are being generated
docs_gen = custom_target (
'gen_docs' ,
input : files ( 'markdown/index.md' ) ,
output : 'gen_docs.stamp' ,
command : [
files ( '../tools/regenerate_docs.py' ) ,
'--output-dir' , cur_bdir ,
'--dummy-output-file' , '@OUTPUT@' ,
] ,
build_by_default : true ,
install : false )
sitemap = files ( 'sitemap.txt' )
sitemap = files ( 'sitemap.txt' )
yaml_loader = get_option ( 'unsafe_yaml' ) ? 'fastyaml' : 'yaml'
yaml_loader = get_option ( 'unsafe_yaml' ) ? 'fastyaml' : 'yaml'
@ -34,24 +21,6 @@ refman_binary = custom_target(
]
]
)
)
refman_md = custom_target (
'gen_refman_md' ,
input : refman_binary ,
output : [ 'configured_sitemap.txt' , 'refman_links.json' ] ,
command : [
genrefman ,
'-l' , 'pickle' ,
'-g' , 'md' ,
'-s' , sitemap ,
'-i' , '@INPUT@' ,
'-o' , '@OUTPUT0@' ,
'--link-defs' , '@OUTPUT1@' ,
'--force-color' ,
'--no-modules' ,
] ,
)
sitemap = refman_md [ 0 ]
refman_json = custom_target (
refman_json = custom_target (
'gen_refman_json' ,
'gen_refman_json' ,
build_by_default : true ,
build_by_default : true ,
@ -66,6 +35,7 @@ refman_json = custom_target(
'--force-color' ,
'--force-color' ,
] ,
] ,
)
)
test ( 'validate_docs' , find_program ( './jsonvalidator.py' ) , args : [ refman_json ] )
refman_man = custom_target (
refman_man = custom_target (
'gen_refman_man' ,
'gen_refman_man' ,
@ -83,6 +53,43 @@ refman_man = custom_target(
] ,
] ,
)
)
# Everything past here is HTML resources.
if not get_option ( 'html' )
subdir_done ( )
endif
# Only the script knows which files are being generated
docs_gen = custom_target (
'gen_docs' ,
input : files ( 'markdown/index.md' ) ,
output : 'gen_docs.stamp' ,
command : [
files ( '../tools/regenerate_docs.py' ) ,
'--output-dir' , cur_bdir ,
'--dummy-output-file' , '@OUTPUT@' ,
] ,
build_by_default : true ,
install : false ,
)
refman_md = custom_target (
'gen_refman_md' ,
input : refman_binary ,
output : [ 'configured_sitemap.txt' , 'refman_links.json' ] ,
command : [
genrefman ,
'-l' , 'pickle' ,
'-g' , 'md' ,
'-s' , sitemap ,
'-i' , '@INPUT@' ,
'-o' , '@OUTPUT0@' ,
'--link-defs' , '@OUTPUT1@' ,
'--force-color' ,
'--no-modules' ,
] ,
)
sitemap = refman_md [ 0 ]
genrelnotes = custom_target (
genrelnotes = custom_target (
output : [ 'sitemap-genrelnotes.txt' ] ,
output : [ 'sitemap-genrelnotes.txt' ] ,
build_always_stale : true ,
build_always_stale : true ,
@ -95,8 +102,6 @@ genrelnotes = custom_target(
)
)
sitemap = genrelnotes [ 0 ]
sitemap = genrelnotes [ 0 ]
test ( 'validate_docs' , find_program ( './jsonvalidator.py' ) , args : [ refman_json ] )
hotdoc_prog = find_program ( 'hotdoc' , version : '>=0.13.7' )
hotdoc_prog = find_program ( 'hotdoc' , version : '>=0.13.7' )
hotdoc = import ( 'hotdoc' )
hotdoc = import ( 'hotdoc' )