From: Richard Jones Date: Thu, 31 Dec 2009 12:26:04 +0000 (+0000) Subject: Move guestfs(3) and guestfish(1) man pages into subdirectories. X-Git-Tag: 1.0.81~12 X-Git-Url: http://git.annexia.org/?a=commitdiff_plain;h=8980c01b46eafcf4b5dc127e4696c2cbe1bff09f;p=libguestfs.git Move guestfs(3) and guestfish(1) man pages into subdirectories. These manual pages have for a very long time 'lived' in the top source directory. Clean up this situation by moving those manual pages (plus associated generated files) into the src/ and fish/ subdirectories respectively. --- diff --git a/Makefile.am b/Makefile.am index c33710a..38beecd 100644 --- a/Makefile.am +++ b/Makefile.am @@ -56,16 +56,8 @@ if HAVE_HASKELL SUBDIRS += haskell endif -generator_built = \ - guestfs-actions.pod \ - guestfs-availability.pod \ - guestfs-structs.pod \ - guestfish-actions.pod - EXTRA_DIST = \ $(generator_built) \ - guestfs.pod \ - guestfish.pod \ html/pod.css \ HACKING TODO \ libguestfs.pc libguestfs.pc.in \ @@ -77,52 +69,16 @@ EXTRA_DIST = \ html/recipes.css \ make-recipes.sh \ contrib/README \ - bindtests \ - libguestfs.3 - -# Manual pages. -# guestfs-actions.pod, guestfs-availability.pod and guestfs-structs -# are autogenerated. There is no include mechanism for POD, so we -# have to do it by hand. + bindtests -man_MANS = guestfs.3 libguestfs.3 guestfish.1 - -guestfs.3: guestfs.pod \ - guestfs-actions.pod \ - guestfs-availability.pod \ - guestfs-structs.pod - sed \ - -e '/@ACTIONS@/rguestfs-actions.pod' \ - -e 's/@ACTIONS@//' \ - -e '/@AVAILABILITY@/rguestfs-availability.pod' \ - -e 's/@AVAILABILITY@//' \ - -e '/@STRUCTS@/rguestfs-structs.pod' \ - -e 's/@STRUCTS@//' \ - < $< | \ - $(POD2MAN) \ - --section 3 \ - -c "Virtualization Support" \ - --name "guestfs" \ - --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \ - > $@ - -guestfish.1: guestfish.pod guestfish-actions.pod - sed \ - -e '/@ACTIONS@/rguestfish-actions.pod' -e 's/@ACTIONS@//' \ - < $< | \ - $(POD2MAN) \ - --section 1 \ - -c "Virtualization Support" \ - --name "guestfish" \ - --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \ - > $@ +# HTML versions of manual pages. noinst_DATA = html/guestfs.3.html html/guestfish.1.html -html/guestfs.3.html: guestfs.pod \ - guestfs-actions.pod \ - guestfs-availability.pod \ - guestfs-structs.pod +html/guestfs.3.html: src/guestfs.pod \ + src/guestfs-actions.pod \ + src/guestfs-availability.pod \ + src/guestfs-structs.pod mkdir -p html sed \ -e '/@ACTIONS@/rguestfs-actions.pod' \ @@ -138,7 +94,7 @@ html/guestfs.3.html: guestfs.pod \ --htmldir html \ --outfile $@ -html/guestfish.1.html: guestfish.pod guestfish-actions.pod +html/guestfish.1.html: fish/guestfish.pod fish/guestfish-actions.pod mkdir -p html sed \ -e '/@ACTIONS@/rguestfish-actions.pod' -e 's/@ACTIONS@//' \ diff --git a/fish/Makefile.am b/fish/Makefile.am index 795952a..1652c54 100644 --- a/fish/Makefile.am +++ b/fish/Makefile.am @@ -21,7 +21,8 @@ bin_PROGRAMS = guestfish generator_built = \ cmds.c \ - completion.c + completion.c \ + guestfish-actions.pod BUILT_SOURCES = \ $(generator_built) \ @@ -79,3 +80,20 @@ rc_protocol.h: rc_protocol.x $(RPCGEN) -h -o $@-t $< mv $@-t $@ endif + +# Manual page. +# guestfish-actions.pod is autogenerated. There is no include +# mechanism for POD, so we have to do it by hand. + +man_MANS = guestfish.1 + +guestfish.1: guestfish.pod guestfish-actions.pod + sed \ + -e '/@ACTIONS@/rguestfish-actions.pod' -e 's/@ACTIONS@//' \ + < $< | \ + $(POD2MAN) \ + --section 1 \ + -c "Virtualization Support" \ + --name "guestfish" \ + --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \ + > $@ diff --git a/guestfish.pod b/fish/guestfish.pod similarity index 100% rename from guestfish.pod rename to fish/guestfish.pod diff --git a/src/Makefile.am b/src/Makefile.am index 2e33c1a..7d9220a 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -23,7 +23,10 @@ generator_built = \ guestfs-actions.h \ guestfs-internal-actions.h \ guestfs-actions.c \ - guestfs-bindtests.c + guestfs-bindtests.c \ + guestfs-actions.pod \ + guestfs-availability.pod \ + guestfs-structs.pod $(generator_built): stamp-generator @@ -36,7 +39,8 @@ EXTRA_DIST = \ $(BUILT_SOURCES) \ MAX_PROC_NR \ stamp-generator \ - generator.ml + generator.ml \ + libguestfs.3 # Rerun the generator if it has changed. # Git removes empty directories, so in cases where the @@ -140,3 +144,29 @@ guestfs_protocol.h: guestfs_protocol.x $(RPCGEN) -h -o $@-t $< mv $@-t $@ endif + +# Manual page. +# guestfs-actions.pod, guestfs-availability.pod and guestfs-structs +# are autogenerated. There is no include mechanism for POD, so we +# have to do it by hand. + +man_MANS = guestfs.3 libguestfs.3 + +guestfs.3: guestfs.pod \ + guestfs-actions.pod \ + guestfs-availability.pod \ + guestfs-structs.pod + sed \ + -e '/@ACTIONS@/rguestfs-actions.pod' \ + -e 's/@ACTIONS@//' \ + -e '/@AVAILABILITY@/rguestfs-availability.pod' \ + -e 's/@AVAILABILITY@//' \ + -e '/@STRUCTS@/rguestfs-structs.pod' \ + -e 's/@STRUCTS@//' \ + < $< | \ + $(POD2MAN) \ + --section 3 \ + -c "Virtualization Support" \ + --name "guestfs" \ + --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \ + > $@ diff --git a/src/generator.ml b/src/generator.ml index 8d2a075..dc0c9c1 100755 --- a/src/generator.ml +++ b/src/generator.ml @@ -10884,6 +10884,9 @@ Run it from the top source directory using the command output_to "src/guestfs-internal-actions.h" generate_internal_actions_h; output_to "src/guestfs-actions.c" generate_client_actions; output_to "src/guestfs-bindtests.c" generate_bindtests; + output_to "src/guestfs-structs.pod" generate_structs_pod; + output_to "src/guestfs-actions.pod" generate_actions_pod; + output_to "src/guestfs-availability.pod" generate_availability_pod; output_to "daemon/actions.h" generate_daemon_actions_h; output_to "daemon/stubs.c" generate_daemon_actions; output_to "daemon/names.c" generate_daemon_names; @@ -10892,10 +10895,7 @@ Run it from the top source directory using the command output_to "capitests/tests.c" generate_tests; output_to "fish/cmds.c" generate_fish_cmds; output_to "fish/completion.c" generate_fish_completion; - output_to "guestfs-structs.pod" generate_structs_pod; - output_to "guestfs-actions.pod" generate_actions_pod; - output_to "guestfs-availability.pod" generate_availability_pod; - output_to "guestfish-actions.pod" generate_fish_actions_pod; + output_to "fish/guestfish-actions.pod" generate_fish_actions_pod; output_to "ocaml/guestfs.mli" generate_ocaml_mli; output_to "ocaml/guestfs.ml" generate_ocaml_ml; output_to "ocaml/guestfs_c_actions.c" generate_ocaml_c; diff --git a/guestfs.pod b/src/guestfs.pod similarity index 100% rename from guestfs.pod rename to src/guestfs.pod diff --git a/libguestfs.3 b/src/libguestfs.3 similarity index 100% rename from libguestfs.3 rename to src/libguestfs.3