From db62f9e750674aebb6bf8132dedda785fd690bf7 Mon Sep 17 00:00:00 2001 From: jacob Date: Mon, 5 Jan 2004 20:05:51 +0000 Subject: [PATCH] b=2421 r=phil (i'm just committing jerrifer's work + a couple of typo fixes) add a --disable-doc option to lustre's configure which skips .pdf doc building (to ease rpm creation). --- lnet/doc/Makefile.am | 7 ++++++- lustre/configure.in | 13 +++++++++++++ lustre/doc/Makefile.am | 10 ++++++++-- lustre/portals/doc/Makefile.am | 7 ++++++- lustre/scripts/lustre.spec.in | 16 ++++++++++++++-- 5 files changed, 47 insertions(+), 6 deletions(-) diff --git a/lnet/doc/Makefile.am b/lnet/doc/Makefile.am index 7c65e6c..b7f6252 100644 --- a/lnet/doc/Makefile.am +++ b/lnet/doc/Makefile.am @@ -8,7 +8,12 @@ LYX2TXT = lyx --export text LYX2HTML = lyx --export html SUFFIXES = .lin .lyx .pdf .sgml .html .txt .fig .eps -DOCS = portals3.pdf +if DOC + DOCS = portals3.pdf +else + DOCS = +endif + IMAGES = file.eps flow_new.eps get.eps mpi.eps portals.eps put.eps LYXFILES= portals3.lyx diff --git a/lustre/configure.in b/lustre/configure.in index cbaca48..48e55f7 100644 --- a/lustre/configure.in +++ b/lustre/configure.in @@ -14,6 +14,19 @@ AM_INIT_AUTOMAKE(lustre, builtin([esyscmd], [sed -ne '/^%define version /{ s/.*v AC_ARG_ENABLE(extN, [ --enable-extN use extN instead of ext3 for lustre backend]) AM_CONDITIONAL(EXTN, test x$enable_extN = xyes) +# specify wether to build doc or not +AC_ARG_ENABLE(doc, [ --disable-doc skip creation of pdf documentation], + [ + if test x$enable_doc = xyes ; then + ENABLE_DOC=1 + else + ENABLE_DOC=0 + fi + ], + [ ENABLE_DOC=1 ]) +AM_CONDITIONAL(DOC, test x$ENABLE_DOC = x1) +AC_SUBST(ENABLE_DOC) + # the pinger is temporary, until we have the recovery node in place AC_ARG_ENABLE(pinger, [ --enable-pinger recovery pinger support]) if test x$enable_pinger = xyes ; then diff --git a/lustre/doc/Makefile.am b/lustre/doc/Makefile.am index d261050..8302275 100644 --- a/lustre/doc/Makefile.am +++ b/lustre/doc/Makefile.am @@ -14,8 +14,14 @@ PS2PDF = ps2pdf TEXEXPAND = texexpand SUFFIXES = .lin .lyx .pdf .ps .sgml .html .txt .tex .fig .eps .dvi -DOCS = lustre.pdf lustre-HOWTO.txt -HOWTODOC = lustre-HOWTO.txt +if DOC + DOCS = lustre.pdf lustre-HOWTO.txt + HOWTODOC = lustre-HOWTO.txt +else + DOCS = + HOWTODOC = +endif + IMAGES := $(patsubst %.fig,%.eps,$(wildcard *.fig)) LYXFILES= $(filter-out $(patsubst %.lin,%.lyx,$(wildcard *.lin)),\ $(wildcard *.lin *.lyx)) diff --git a/lustre/portals/doc/Makefile.am b/lustre/portals/doc/Makefile.am index 7c65e6c..b7f6252 100644 --- a/lustre/portals/doc/Makefile.am +++ b/lustre/portals/doc/Makefile.am @@ -8,7 +8,12 @@ LYX2TXT = lyx --export text LYX2HTML = lyx --export html SUFFIXES = .lin .lyx .pdf .sgml .html .txt .fig .eps -DOCS = portals3.pdf +if DOC + DOCS = portals3.pdf +else + DOCS = +endif + IMAGES = file.eps flow_new.eps get.eps mpi.eps portals.eps put.eps LYXFILES= portals3.lyx diff --git a/lustre/scripts/lustre.spec.in b/lustre/scripts/lustre.spec.in index 437fd55..974a91d 100644 --- a/lustre/scripts/lustre.spec.in +++ b/lustre/scripts/lustre.spec.in @@ -2,6 +2,7 @@ %define version HEAD %define kversion @LINUXRELEASE@ %define linuxdir @LINUX@ +%define enable_doc @ENABLE_DOC@ Summary: Lustre Lite File System Name: lustre-lite @@ -60,13 +61,18 @@ Configures openldap server for LDAP Lustre config database %prep %setup -qn lustre-%{version} #%setup -c -n lustre-%{version}-lib +%if %{enable_doc} + %define disable_doc +%else + %define disable_doc --disable-doc +%endif %build rm -rf $RPM_BUILD_ROOT # Set an explicit path to our Linux tree, if we can. cd $RPM_BUILD_DIR/lustre-%{version} -./configure --with-linux='%{linuxdir}' +./configure --with-linux='%{linuxdir}' %{disable_doc} make %install @@ -79,7 +85,7 @@ make install prefix=$RPM_BUILD_ROOT linuxdir=%{linuxdir} test -d $linuxdir && conf_flag=--with-linux=$linuxdir make clean - ./configure --enable-rtscts-myrinet $conf_flag + ./configure --enable-rtscts-myrinet $conf_flag %{disable_doc} make cp linux/rtscts/rtscts.o $RPM_BUILD_ROOT/lib/modules/%{kversion}/kernel/net/lustre/rtscts_myrinet.o cp user/myrinet_utils/mcpload $RPM_BUILD_ROOT/usr/sbin/mcpload @@ -100,6 +106,8 @@ mkdir -p $RPM_BUILD_ROOT/var/lib/ldap/lustre %attr(-, root, root) /usr/sbin/lmc %attr(-, root, root) /usr/sbin/lctl %attr(-, root, root) /usr/sbin/lconf +%attr(-, root, root) /usr/sbin/lrun +%attr(-, root, root) /usr/sbin/llmount %attr(-, root, root) /usr/sbin/lwizard %attr(-, root, root) /usr/sbin/wiretest %attr(-, root, root) /usr/sbin/lactive @@ -111,6 +119,8 @@ mkdir -p $RPM_BUILD_ROOT/var/lib/ldap/lustre %attr(-, root, root) /usr/bin/mcreate %attr(-, root, root) /usr/bin/munlink %attr(-, root, root) /usr/bin/mkdirmany +%attr(-, root, root) /usr/bin/iopentest1 +%attr(-, root, root) /usr/bin/iopentest2 %attr(-, root, root) /usr/sbin/llstat.pl %attr(-, root, root) /usr/sbin/llobdstat.pl %attr(-, root, root) /usr/sbin/load_ldap.sh @@ -145,7 +155,9 @@ mkdir -p $RPM_BUILD_ROOT/var/lib/ldap/lustre %files -n lustre-doc %attr(-, root, root) %doc COPYING FDL +%if %{enable_doc} %attr(-, root, root) %doc doc/lustre.pdf doc/lustre-HOWTO.txt +%endif #%attr(-, root, root) %doc tests/client-echo.cfg tests/client-mount.cfg #%attr(-, root, root) %doc tests/client-mount2.cfg #%attr(-, root, root) %doc tests/elan-client.cfg tests/elan-server.cfg -- 1.8.3.1