#
# Setup script for libxml2 and libxslt if found
#
# On *nix, it is not needed (but should not harm),
# on Windows, it is set by configure.js.
ROOT = r'@prefix@'
# Thread-enabled libxml2
# If this flag is set (windows only),
# a private copy of the dlls are included in the package.
# If this flag is not set, the libxml2 and libxslt
# dlls must be found somewhere in the PATH at runtime.
return 1
return 0
try:
HOME="C:"
if WITHDLLS:
# create __init__.py for the libxmlmods package
return s
libraryPrefix = 'lib'
platformLibs = []
else:
libraryPrefix = ''
# those are examined to find
# - iconv.h
# - libxslt/xsltconfig.h
includes_dir = [
];
xml_includes=""
break;
if xml_includes == "":
print "failed to find headers for libxml2: update includes_dir"
sys.exit(1)
break;
if iconv_includes == "":
print "failed to find headers for libiconv: update includes_dir"
sys.exit(1)
# those are added in the linker search path for libraries
libdirs = [
]
try:
try:
print "failed to find and generate stubs for libxml2, aborting ..."
sys.exit(1)
if WITHDLLS:
else:
print "libxslt stub generator not found, libxslt not built"
else:
try:
print "failed to generate stubs for libxslt, aborting ..."
else:
if WITHDLLS:
else:
else:
if with_xslt == 1:
break;
if xslt_includes == "":
print "failed to find headers for libxslt: update includes_dir"
with_xslt = 0
descr = "libxml2 package"
if WITHDLLS:
macros = []
if with_threads:
if with_xslt == 1:
descr = "libxml2 and libxslt package"
#
# We are gonna build 2 identical shared libs with merge initializing
# both libxml2mod and libxsltmod
#
else:
#
# On windows the MERGED_MODULE option is not needed
# (and does not work)
#
if with_xslt == 1:
if with_xslt == 1:
if WITHDLLS:
ext_package = "libxmlmods"
if sys.version >= "2.2":
base = "lib/site-packages/"
else:
base = ""
else:
data_files = []
# On *nix, the version number is created from setup.py.in
# On windows, it is set by configure.js
description = descr,
)
sys.exit(0)