1Alien::Libxml2(3) User Contributed Perl Documentation Alien::Libxml2(3)
2
3
4
6 Alien::Libxml2 - Install the C libxml2 library on your system
7
9 version 0.14
10
12 In your Build.PL:
13
14 use Module::Build;
15 use Alien::Libxml2;
16 my $builder = Module::Build->new(
17 ...
18 configure_requires => {
19 'Alien::Libxml2' => '0',
20 ...
21 },
22 extra_compiler_flags => Alien::Libxml2->cflags,
23 extra_linker_flags => Alien::Libxml2->libs,
24 ...
25 );
26
27 $build->create_build_script;
28
29 In your Makefile.PL:
30
31 use ExtUtils::MakeMaker;
32 use Config;
33 use Alien::Libxml2;
34
35 WriteMakefile(
36 ...
37 CONFIGURE_REQUIRES => {
38 'Alien::Libxml2' => '0',
39 },
40 CCFLAGS => Alien::Libxml2->cflags . " $Config{ccflags}",
41 LIBS => [ Alien::Libxml2->libs ],
42 ...
43 );
44
45 In your FFI::Platypus script or module:
46
47 use FFI::Platypus;
48 use Alien::Libxml2;
49
50 my $ffi = FFI::Platypus->new(
51 lib => [ Alien::Libxml2->dynamic_libs ],
52 );
53
55 This module provides libxml2 for other modules to use. There was an
56 already existing Alien::LibXML, but it uses the older
57 Alien::Build::ModuleBuild and has not been actively maintained for a
58 while.
59
61 "libxml2" has some optional prereqs, including "zlib" and "iconv". For
62 a "share" install you will want to make sure that these are installed
63 prior to installing Alien::Libxml2 if you want to make use of features
64 relying on them.
65
66 For a system install, you want to make sure the development packages
67 for "libxml2", "zlib" and "iconv" are installed if "libxml2" has been
68 configured to use them, otherwise XML::LibXML will not install as
69 expected. If the tests for this module fail with a missing "iconv.h"
70 or "zlib.h", then this is likely the reason.
71
73 Alien::LibXML
74 Unmaintained Alien for the same library.
75
77 Author: Graham Ollis <plicease@cpan.org>
78
79 Contributors:
80
81 Shlomi Fish (shlomif)
82
84 This software is copyright (c) 2013 by Graham Ollis.
85
86 This is free software; you can redistribute it and/or modify it under
87 the same terms as the Perl 5 programming language system itself.
88
89
90
91perl v5.30.1 2020-03-10 Alien::Libxml2(3)