W3C home > Mailing lists > Public > www-lib@w3.org > April to June 1999

Re: [5.2.8] include file trouble and messing with TMPDIR

From: Henrik Frystyk Nielsen <frystyk@w3.org>
Date: Tue, 22 Jun 1999 18:42:21 -0400
To: www-lib@w3.org
Message-ID: <3770114D.BD99EF6A@w3.org>
To: Luc Van Eycken <Luc.VanEycken@esat.kuleuven.ac.be>
Luc Van Eycken wrote:
> Since it's used for xdvi from the TeX-suite, I decided to install the
> libwww library system-wide so it can also be used for other applications.
> With version 5.2.8, this gave me the following problems:

in xdvi? Do you know for what?

>  1) System-wide implies that it's available for at least 5 architectures
>     (HPUX, Solaris, Digital Unix, SGI, and Linux). However, the wwwconf.h
>     include file is architecture-dependent, so I have to install all the
>     include files in an architecture-dependent directory, which is possible
>     thanks to libwww-config. But first of all, this is a waste of disk
>     space, since all the other include files are the same.

I agree, what about installing it in {prefix}/include instead:

Index: Makefile.am
RCS file: /sources/public/libwww/Makefile.am,v
retrieving revision 1.36
diff -c -r1.36 Makefile.am
*** Makefile.am	1999/04/12 23:55:02	1.36
--- Makefile.am	1999/06/22 22:28:38
*** 24,31 ****
  # We need to install the config.h header file as well
! 	$(mkinstalldirs) $(pkgincludedir)
! 	$(INSTALL_DATA) $(top_builddir)/$(CONFIG_HEADER)
  # This is our install script provided by Soren Sandmann
  bin_SCRIPTS = libwww-config
--- 24,31 ----
  # We need to install the config.h header file as well
! 	$(mkinstalldirs) $(includedir)
! 	$(INSTALL_DATA) $(top_builddir)/$(CONFIG_HEADER)
  # This is our install script provided by Soren Sandmann
  bin_SCRIPTS = libwww-config

>     Furthermore
>     "libwww-config --cflags" does not include the directory where
>     xmlparse.h is installed (which wasn't a problem when all was installed
>     in default include directory), so the libwww-config program must be
>     modified to include this directory as well.

It probably makes sense to move xmlparse.h to the libwww include folder
together with the other libwww include files. Does anyone object to this

Index: Makefile.am
RCS file: /sources/public/libwww/modules/expat/xmlparse/Makefile.am,v
retrieving revision 1.4
diff -c -r1.4 Makefile.am
*** Makefile.am	1999/04/13 00:01:16	1.4
--- Makefile.am	1999/06/22 22:13:16
*** 17,21 ****
  libxmlparse_la_LDFLAGS = -rpath $(libdir)
! include_HEADERS = \
--- 17,21 ----
  libxmlparse_la_LDFLAGS = -rpath $(libdir)
! pkginclude_HEADERS = \

>  2) HTLibInit sets the environment variable TMPDIR to "" (which is not the
>     same as unsetting it, as the comment claims) so the function tempnam
>     (in HTGetTmpFileName) does not get confused. However this assumes that
>     HTGetTmpFileName is the only user of TMPDIR, which is not at all
>     evident since this is part of a library which can be linked to any other
>     kind of program. In fact I ran into this problem using xdvi, which
>     calls a script mktexpk containing "TEMPDIR=${TMPDIR-/tmp}/mt$$.tmp". If
>     TMPDIR is set to "", this results in an unusable TEMPDIR = /mt$$.tmp.
>     In my opinion, the correct way to do it, is to change TMPDIR only
>     locally in HTGetTmpFileName and I hope that someone can make the
>     appropriate changes. Below you find the patches I tried as a
>     suggestion, please feel free to use any part of it you like.

Thanks for the patch - I have committed it so that others can try it as
well, see 


Henrik Frystyk Nielsen, <frystyk@w3.org>
World Wide Web Consortium, MIT/LCS NE43-356
545 Technology Square, Cambridge MA 02139, USA
Received on Tuesday, 22 June 1999 18:42:25 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:33:49 UTC