xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Wei Liu <wei.liu2@citrix.com>
To: Xen-devel <xen-devel@lists.xenproject.org>
Cc: Ian Jackson <ian.jackson@eu.citrix.com>, Wei Liu <wei.liu2@citrix.com>
Subject: [PATCH 09/17] docs: honour XEN_DUMP_DIR
Date: Mon, 13 Jun 2016 08:49:07 +0100	[thread overview]
Message-ID: <1465804155-14469-10-git-send-email-wei.liu2@citrix.com> (raw)
In-Reply-To: <1465804155-14469-1-git-send-email-wei.liu2@citrix.com>

Use configure to generate xl.cfg and xl manpage. Add the generated files
to gitignore.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
Cc: Ian Jackson <ian.jackson@eu.citrix.com>

Not entirely sure if this is a good idea. I don't deem this patch
important so I'm fine with dropping it.

I've committed the result of running autogen.sh here. Please rerun
autogen.sh if necessary.
---
 .gitignore                                 |   2 +
 docs/configure                             | 184 ++++++++++++++++++++++++++++-
 docs/configure.ac                          |   9 +-
 docs/man/{xl.cfg.pod.5 => xl.cfg.pod.5.in} |   6 +-
 docs/man/{xl.pod.1 => xl.pod.1.in}         |   2 +-
 5 files changed, 197 insertions(+), 6 deletions(-)
 rename docs/man/{xl.cfg.pod.5 => xl.cfg.pod.5.in} (99%)
 rename docs/man/{xl.pod.1 => xl.pod.1.in} (99%)

diff --git a/.gitignore b/.gitignore
index 496194f..8e0a177 100644
--- a/.gitignore
+++ b/.gitignore
@@ -41,6 +41,8 @@ config/Paths.mk
 build-*
 dist/*
 docs/html/
+docs/man/xl.cfg.pod.5
+docs/man/xl.pod.1
 docs/man1/
 docs/man5/
 docs/man8/
diff --git a/docs/configure b/docs/configure
index fbb78ac..46f0e68 100755
--- a/docs/configure
+++ b/docs/configure
@@ -594,6 +594,24 @@ POD2TEXT
 POD2HTML
 POD2MAN
 FIG2DEV
+XEN_DUMP_DIR
+XEN_PAGING_DIR
+XEN_LOCK_DIR
+XEN_SCRIPT_DIR
+XEN_CONFIG_DIR
+INITD_DIR
+CONFIG_DIR
+SHAREDIR
+XEN_LIB_DIR
+XEN_LIB_STORED
+XEN_LOG_DIR
+XEN_RUN_DIR
+XENFIRMWAREDIR
+LIBEXEC_INC
+LIBEXEC_LIB
+LIBEXEC_BIN
+LIBEXEC
+CONFIG_LEAF_DIR
 target_alias
 host_alias
 build_alias
@@ -635,6 +653,10 @@ SHELL'
 ac_subst_files=''
 ac_user_opts='
 enable_option_checking
+with_initddir
+with_sysconfig_leaf_dir
+with_libexec_leaf_dir
+with_xen_dumpdir
 '
       ac_precious_vars='build_alias
 host_alias
@@ -1251,6 +1273,21 @@ if test -n "$ac_init_help"; then
    esac
   cat <<\_ACEOF
 
+Optional Packages:
+  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
+  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
+  --with-initddir=DIR     Path to directory with sysv runlevel scripts.
+                          [SYSCONFDIR/init.d]
+  --with-sysconfig-leaf-dir=SUBDIR
+                          Name of subdirectory in /etc to store runtime
+                          options for runlevel scripts and daemons such as
+                          xenstored. This should be either "sysconfig" or
+                          "default". [sysconfig]
+  --with-libexec-leaf-dir=SUBDIR
+                          Name of subdirectory in libexecdir to use.
+  --with-xen-dumpdir=DIR  Path to directory for domU crash dumps.
+                          [LOCALSTATEDIR/lib/xen/dump]
+
 Some influential environment variables:
   FIG2DEV     Path to fig2dev tool
   POD2MAN     Path to pod2man tool
@@ -1693,7 +1730,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
 
 
 
-ac_config_files="$ac_config_files ../config/Docs.mk"
+ac_config_files="$ac_config_files ../config/Docs.mk man/xl.cfg.pod.5 man/xl.pod.1"
 
 ac_aux_dir=
 for ac_dir in ../ "$srcdir"/../; do
@@ -1741,6 +1778,149 @@ ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
 
 
 
+
+test "x$prefix" = "xNONE" && prefix=$ac_default_prefix
+test "x$exec_prefix" = "xNONE" && exec_prefix=${prefix}
+
+if test "$localstatedir" = '${prefix}/var' ; then
+    localstatedir=/var
+fi
+
+bindir=`eval echo $bindir`
+sbindir=`eval echo $sbindir`
+libdir=`eval echo $libdir`
+
+if test "x$sysconfdir" = 'x${prefix}/etc' ; then
+    case "$host_os" in
+         *freebsd*)
+         sysconfdir=$prefix/etc
+         ;;
+         *solaris*)
+         if test "$prefix" = "/usr" ; then
+             sysconfdir=/etc
+         else
+             sysconfdir=$prefix/etc
+         fi
+         ;;
+         *)
+         sysconfdir=/etc
+         ;;
+    esac
+fi
+
+
+# Check whether --with-initddir was given.
+if test "${with_initddir+set}" = set; then :
+  withval=$with_initddir; initddir_path=$withval
+else
+  case "$host_os" in
+         *linux*)
+         if test -d $sysconfdir/rc.d/init.d ; then
+             initddir_path=$sysconfdir/rc.d/init.d
+         else
+             initddir_path=$sysconfdir/init.d
+         fi
+         ;;
+         *)
+         initddir_path=$sysconfdir/rc.d
+         ;;
+     esac
+fi
+
+
+
+# Check whether --with-sysconfig-leaf-dir was given.
+if test "${with_sysconfig_leaf_dir+set}" = set; then :
+  withval=$with_sysconfig_leaf_dir; config_leaf_dir=$withval
+else
+  config_leaf_dir=sysconfig
+    if test ! -d /etc/sysconfig ; then config_leaf_dir=default ; fi
+fi
+
+CONFIG_LEAF_DIR=$config_leaf_dir
+
+
+
+# Check whether --with-libexec-leaf-dir was given.
+if test "${with_libexec_leaf_dir+set}" = set; then :
+  withval=$with_libexec_leaf_dir; libexec_subdir=$withval
+else
+  libexec_subdir=$PACKAGE_TARNAME
+fi
+
+
+
+# Check whether --with-xen-dumpdir was given.
+if test "${with_xen_dumpdir+set}" = set; then :
+  withval=$with_xen_dumpdir; xen_dumpdir_path=$withval
+else
+  xen_dumpdir_path=$localstatedir/lib/xen/dump
+fi
+
+
+if test "$libexecdir" = '${exec_prefix}/libexec' ; then
+    case "$host_os" in
+         *netbsd*) ;;
+         *)
+         libexecdir='${exec_prefix}/lib'
+         ;;
+    esac
+fi
+LIBEXEC=`eval echo $libexecdir/$libexec_subdir`
+
+
+LIBEXEC_BIN=${LIBEXEC}/bin
+
+LIBEXEC_LIB=${LIBEXEC}/lib
+
+LIBEXEC_INC=${LIBEXEC}/include
+
+XENFIRMWAREDIR=${LIBEXEC}/boot
+
+
+XEN_RUN_DIR=$localstatedir/run/xen
+
+
+XEN_LOG_DIR=$localstatedir/log/xen
+
+
+XEN_LIB_STORED=$localstatedir/lib/xenstored
+
+
+XEN_LIB_DIR=$localstatedir/lib/xen
+
+
+SHAREDIR=$prefix/share
+
+
+CONFIG_DIR=$sysconfdir
+
+
+INITD_DIR=$initddir_path
+
+
+XEN_CONFIG_DIR=$CONFIG_DIR/xen
+
+
+XEN_SCRIPT_DIR=$XEN_CONFIG_DIR/scripts
+
+
+case "$host_os" in
+*freebsd*) XEN_LOCK_DIR=$localstatedir/lib ;;
+*netbsd*) XEN_LOCK_DIR=$localstatedir/lib ;;
+*) XEN_LOCK_DIR=$localstatedir/lock ;;
+esac
+
+
+XEN_PAGING_DIR=$localstatedir/lib/xen/xenpaging
+
+
+XEN_DUMP_DIR=$xen_dumpdir_path
+
+
+
+
+
     # Extract the first word of "fig2dev", so it can be a program name with args.
 set dummy fig2dev; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
@@ -2793,6 +2973,8 @@ for ac_config_target in $ac_config_targets
 do
   case $ac_config_target in
     "../config/Docs.mk") CONFIG_FILES="$CONFIG_FILES ../config/Docs.mk" ;;
+    "man/xl.cfg.pod.5") CONFIG_FILES="$CONFIG_FILES man/xl.cfg.pod.5" ;;
+    "man/xl.pod.1") CONFIG_FILES="$CONFIG_FILES man/xl.pod.1" ;;
 
   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
   esac
diff --git a/docs/configure.ac b/docs/configure.ac
index bc77f49..a2929c4 100644
--- a/docs/configure.ac
+++ b/docs/configure.ac
@@ -5,13 +5,20 @@ AC_PREREQ([2.67])
 AC_INIT([Xen Hypervisor Documentation], m4_esyscmd([../version.sh ../xen/Makefile]),
     [xen-devel@lists.xen.org], [xen], [http://www.xen.org/])
 AC_CONFIG_SRCDIR([misc/xen-command-line.markdown])
-AC_CONFIG_FILES([../config/Docs.mk])
+AC_CONFIG_FILES([
+../config/Docs.mk
+man/xl.cfg.pod.5
+man/xl.pod.1
+])
 AC_CONFIG_AUX_DIR([../])
 
 # M4 Macro includes
 m4_include([../m4/docs_tool.m4])
 m4_include([../m4/path_or_fail.m4])
 m4_include([../m4/features.m4])
+m4_include([../m4/paths.m4])
+
+AX_XEN_EXPAND_CONFIG()
 
 AX_DOCS_TOOL_PROG([FIG2DEV], [fig2dev])
 AX_DOCS_TOOL_PROG([POD2MAN], [pod2man])
diff --git a/docs/man/xl.cfg.pod.5 b/docs/man/xl.cfg.pod.5.in
similarity index 99%
rename from docs/man/xl.cfg.pod.5
rename to docs/man/xl.cfg.pod.5.in
index 4a8bf51..3bb27d0 100644
--- a/docs/man/xl.cfg.pod.5
+++ b/docs/man/xl.cfg.pod.5.in
@@ -343,12 +343,12 @@ destroy`.
 
 =item B<coredump-destroy>
 
-write a "coredump" of the domain to F</var/lib/xen/dump/NAME> and then
+write a "coredump" of the domain to F<@XEN_DUMP_DIR@/NAME> and then
 destroy the domain.
 
 =item B<coredump-restart>
 
-write a "coredump" of the domain to F</var/lib/xen/dump/NAME> and then
+write a "coredump" of the domain to F<@XEN_DUMP_DIR@/NAME> and then
 restart the domain.
 
 =item B<soft-reset>
@@ -2017,7 +2017,7 @@ natively or via hardware backwards compatibility support.
 =head1 FILES
 
 F</etc/xen/NAME.cfg>
-F</var/lib/xen/dump/NAME>
+F<@XEN_DUMP_DIR@/NAME>
 
 =head1 BUGS
 
diff --git a/docs/man/xl.pod.1 b/docs/man/xl.pod.1.in
similarity index 99%
rename from docs/man/xl.pod.1
rename to docs/man/xl.pod.1.in
index f4dc32c..c1e6b7f 100644
--- a/docs/man/xl.pod.1
+++ b/docs/man/xl.pod.1.in
@@ -280,7 +280,7 @@ Change the domain name of I<domain-id> to I<new-name>.
 Dumps the virtual machine's memory for the specified domain to the
 I<filename> specified, without pausing the domain.  The dump file will
 be written to a distribution specific directory for dump files.  Such
-as: /var/lib/xen/dump.
+as: @XEN_DUMP_DIR@/dump.
 
 =item B<help> [I<--long>]
 
-- 
2.1.4


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

  parent reply	other threads:[~2016-06-13  7:49 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-13  7:48 [PATCH 00/17] Honour more configure variables in various places (iteration 2) Wei Liu
2016-06-13  7:48 ` [PATCH 01/17] oxenstored: honour XEN_{LOG, RUN}_DIR in oxenstored.conf Wei Liu
2016-06-13  7:49 ` [PATCH 02/17] oxenstored: generate a paths module Wei Liu
2016-06-13  7:49 ` [PATCH 03/17] oxenstored: honour XEN_LOG_DIR defined by configure Wei Liu
2016-06-13 10:07   ` Andrew Cooper
2016-06-13 10:34     ` Wei Liu
2016-06-13  7:49 ` [PATCH 04/17] build: introduce and export XEN_LIB_DIR Wei Liu
2016-06-13 15:10   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 05/17] tools: install and remove XEN_LIB_DIR in Makefile Wei Liu
2016-06-13 15:11   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 06/17] hotplug/Linux: honour XEN_LIB_DIR Wei Liu
2016-06-13 15:12   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 07/17] libxl: " Wei Liu
2016-06-13 15:12   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 08/17] tools: remove hard-coded /var/lib/xen in Makefile Wei Liu
2016-06-13 15:13   ` Ian Jackson
2016-06-13 15:29     ` Wei Liu
2016-06-13 16:07       ` Ian Jackson
2016-06-13 16:33         ` Wei Liu
2016-06-13 16:57           ` Ian Jackson
2016-06-13 18:16             ` Wei Liu
2016-06-14  9:56               ` Ian Jackson
2016-06-13  7:49 ` Wei Liu [this message]
2016-06-13 15:15   ` [PATCH 09/17] docs: honour XEN_DUMP_DIR Ian Jackson
2016-06-13  7:49 ` [PATCH 10/17] build: introduce XEN_RUN_STORED Wei Liu
2016-06-14 17:00   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 11/17] hotplug/Linux: honour XEN_RUN_STORED Wei Liu
2016-06-13 15:19   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 12/17] libxenstore: " Wei Liu
2016-06-13 15:19   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 13/17] hotplug/FreeBSD: " Wei Liu
2016-06-13  9:32   ` Roger Pau Monné
2016-06-13 15:20   ` Ian Jackson
2016-06-13  7:49 ` [PATCH 14/17] ocaml/libxs: generate a paths.ml Wei Liu
2016-06-13 15:19   ` Ian Jackson
2016-06-13 15:22     ` Wei Liu
2016-06-13 19:50       ` David Scott
2016-06-14  9:36         ` Wei Liu
2016-06-14 20:08           ` David Scott
2016-06-15  9:07             ` Wei Liu
2016-06-13  7:49 ` [PATCH 15/17] ocaml/libxs: honour XEN_RUN_STORED Wei Liu
2016-06-14 20:06   ` David Scott
2016-06-13  7:49 ` [PATCH 16/17] oxenstored: honour XEN_RUN_STORED and XEN_CONFIG_DIR Wei Liu
2016-06-14 20:07   ` David Scott
2016-06-13  7:49 ` [PATCH 17/17] oxenstored: honour XEN_RUN_STORED in systemd C stub Wei Liu
2016-06-14 20:07   ` David Scott
2016-06-14 13:17 ` [PATCH 00/17] Honour more configure variables in various places (iteration 2) Wei Liu
2016-06-17 10:43   ` Wei Liu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1465804155-14469-10-git-send-email-wei.liu2@citrix.com \
    --to=wei.liu2@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).