]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
meson: add man/doc-sync target
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 15 Apr 2017 04:07:57 +0000 (00:07 -0400)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Mon, 24 Apr 2017 01:47:28 +0000 (21:47 -0400)
Seems to work OK. It would be nicer to call it 'doc-sync' not 'man/doc-sync',
but OK.

man/meson.build
meson_options.txt

index 6efec4069566b6c070fb5c55a4de4aeb913f4fca..9d8d1a9922fff32ca47474ecaedaf03afbc1c836 100644 (file)
@@ -133,12 +133,24 @@ foreach tuple : [['systemd.directives', '7', systemd_directives_xml],
   html_pages += [p2]
 endforeach
 
-custom_target('man',
-              depends : man_pages,
-              output : ['man'],
-              command : ['echo'])
-
-custom_target('html',
-              depends : html_pages,
-              output : ['html'],
-              command : ['echo'])
+man = custom_target('man',
+                    depends : man_pages,
+                    output : 'man',
+                    command : ['echo'])
+
+html = custom_target('html',
+                     depends : html_pages,
+                     output : 'html',
+                     command : ['echo'])
+
+custom_target('doc-sync',
+              depends : [man, html],
+              output : ['doc-sync'],
+              command : ['rsync', '-rlv',
+                         '--delete-excluded',
+                         '--include=man',
+                         '--include=*.html',
+                         '--exclude=*',
+                         '--omit-dir-times',
+                         meson.current_build_dir(),
+                         get_option('www-target')])
index 005fd0e99249a02bb45bc3669465d6b41c4ac945..9caf9a329f6af3335e58c78c0625feee585763dc 100644 (file)
@@ -154,6 +154,9 @@ option('ntp-servers', type : 'string',
 option('support-url', type : 'string',
        description : 'the support URL to show in catalog entries included in systemd',
        value : 'https://lists.freedesktop.org/mailman/listinfo/systemd-devel')
+option('www-target', type : 'string',
+       description : 'the address and dir to upload docs too',
+       value : 'www.freedesktop.org:/srv/www.freedesktop.org/www/software/systemd')
 
 option('seccomp', type : 'combo', choices : ['auto', 'true', 'false'],
        description : 'SECCOMP support')