Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commiteb915ca

Browse files
committed
Fix contrib/xml2 makefile to not override CFLAGS, and in passing make it
auto-configure properly for libxslt present or not.
1 parentabb78b1 commiteb915ca

File tree

4 files changed

+7
-15
lines changed

4 files changed

+7
-15
lines changed

‎contrib/Makefile

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $PostgreSQL: pgsql/contrib/Makefile,v 1.82 2007/11/13 21:04:45 tgl Exp $
1+
# $PostgreSQL: pgsql/contrib/Makefile,v 1.83 2008/05/08 16:49:36 tgl Exp $
22

33
subdir = contrib
44
top_builddir = ..
@@ -46,10 +46,8 @@ WANTED_DIRS += uuid-ossp
4646
endif
4747

4848
ifeq ($(with_libxml),yes)
49-
ifeq ($(with_libxslt),yes)
5049
WANTED_DIRS += xml2
5150
endif
52-
endif
5351

5452
# Missing:
5553
#start-scripts\ (does not have a makefile)

‎contrib/xml2/Makefile

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,14 @@
1-
# $PostgreSQL: pgsql/contrib/xml2/Makefile,v 1.11 2007/11/10 23:59:52 momjian Exp $
1+
# $PostgreSQL: pgsql/contrib/xml2/Makefile,v 1.12 2008/05/08 16:49:37 tgl Exp $
22

33
MODULE_big = pgxml
44

5-
# Remove xslt_proc.o from the following line if you don't have libxslt
6-
OBJS = xpath.o xslt_proc.o
5+
OBJS =$(if$(filter -lxslt,$(LIBS)), xpath.o xslt_proc.o, xpath.o)
76

8-
# Remove -lxslt from the following line if you don't have libxslt.
9-
SHLIB_LINK = -lxslt -lxml2
7+
SHLIB_LINK +=$(filter -lxslt,$(LIBS))$(filter -lxml2,$(LIBS))
108

119
DATA_built = pgxml.sql
1210
DATA = uninstall_pgxml.sql
1311

14-
overrideCFLAGS +=$(shell xml2-config --cflags)
15-
1612
ifdefUSE_PGXS
1713
PG_CONFIG = pg_config
1814
PGXS :=$(shell$(PG_CONFIG) --pgxs)

‎contrib/xml2/xslt_proc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ xslt_process(PG_FUNCTION_ARGS)
119119
if (resstat<0)
120120
PG_RETURN_NULL();
121121

122-
PG_RETURN_TEXT_P(cstring_to_text_with_len(resstr,reslen));
122+
PG_RETURN_TEXT_P(cstring_to_text_with_len((char*)resstr,reslen));
123123
}
124124

125125

‎doc/src/sgml/xml2.sgml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $PostgreSQL: pgsql/doc/src/sgml/xml2.sgml,v 1.4 2007/12/06 04:12:10 tgl Exp $ -->
1+
<!-- $PostgreSQL: pgsql/doc/src/sgml/xml2.sgml,v 1.5 2008/05/08 16:49:37 tgl Exp $ -->
22

33
<sect1 id="xml2">
44
<title>xml2</title>
@@ -374,9 +374,7 @@ WHERE t.author_id = p.person_id;
374374
<title>XSLT functions</title>
375375

376376
<para>
377-
The following functions are available if libxslt is installed (this is
378-
not currently detected automatically, so you will have to amend the
379-
Makefile):
377+
The following functions are available if libxslt is installed:
380378
</para>
381379

382380
<sect3>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp