auto-configure properly for libxslt present or not.
index c55c95ccf01e732cad34a57a2a0f901f43da2719..b9453dad7e7a6b8a24928ba919d954e23fc73bdd 100644 (file)
-# $PostgreSQL: pgsql/contrib/Makefile,v 1.82 2007年11月13日 21:04:45 tgl Exp $
+# $PostgreSQL: pgsql/contrib/Makefile,v 1.83 2008年05月08日 16:49:36 tgl Exp $
subdir = contrib
top_builddir = ..
endif
ifeq ($(with_libxml),yes)
-ifeq ($(with_libxslt),yes)
WANTED_DIRS += xml2
endif
-endif
# Missing:
# start-scripts \ (does not have a makefile)
index 0f9c51b116cb1d99aa750307e1e54e7cb8fc3e17..b96defa5d604f88c44b4945c84323f78c4418335 100644 (file)
-# $PostgreSQL: pgsql/contrib/xml2/Makefile,v 1.11 2007年11月10日 23:59:52 momjian Exp $
+# $PostgreSQL: pgsql/contrib/xml2/Makefile,v 1.12 2008年05月08日 16:49:37 tgl Exp $
MODULE_big = pgxml
-# Remove xslt_proc.o from the following line if you don't have libxslt
-OBJS = xpath.o xslt_proc.o
+OBJS = $(if $(filter -lxslt, $(LIBS)), xpath.o xslt_proc.o, xpath.o)
-# Remove -lxslt from the following line if you don't have libxslt.
-SHLIB_LINK = -lxslt -lxml2
+SHLIB_LINK += $(filter -lxslt, $(LIBS)) $(filter -lxml2, $(LIBS))
DATA_built = pgxml.sql
DATA = uninstall_pgxml.sql
-override CFLAGS += $(shell xml2-config --cflags)
-
ifdef USE_PGXS
PG_CONFIG = pg_config
PGXS := $(shell $(PG_CONFIG) --pgxs)
index f498192426098a10713a9c0b25b08c07b3e32356..b2349aaace7ec2cb64c10a213f9812da23f71dc5 100644 (file)
if (resstat < 0)
PG_RETURN_NULL();
- PG_RETURN_TEXT_P(cstring_to_text_with_len(resstr, reslen));
+ PG_RETURN_TEXT_P(cstring_to_text_with_len((char *) resstr, reslen));
}
index 96f8b18d876411134b0cffe9f30a10a801308479..b1caba0a554a76a1f55ff46122cfad722856a616 100644 (file)
-<!-- $PostgreSQL: pgsql/doc/src/sgml/xml2.sgml,v 1.4 2007年12月06日 04:12:10 tgl Exp $ -->
+<!-- $PostgreSQL: pgsql/doc/src/sgml/xml2.sgml,v 1.5 2008年05月08日 16:49:37 tgl Exp $ -->
<sect1 id="xml2">
<title>xml2</title>
<title>XSLT functions</title>
<para>
- The following functions are available if libxslt is installed (this is
- not currently detected automatically, so you will have to amend the
- Makefile):
+ The following functions are available if libxslt is installed:
</para>
<sect3>