@@ -2,18 +2,26 @@ name: yaml
22version: 0.4.1
33license: BSD3
44license-file: LICENSE
5−author: Michael Snoyman <michael@snoyman.com>, Anton Ageev <antage@gmail.com>
5+author: Michael Snoyman <michael@snoyman.com>, Anton Ageev <antage@gmail.com>,Kirill Simonov
66maintainer: Michael Snoyman <michael@snoyman.com>
77synopsis: Low-level binding to the libyaml C library.
8−description: Provides support for parsing and emitting Yaml documents. Includes the full C library in the package so you don't need to worry about any non-Haskell dependencies.
8+description: Provides support for parsing and emitting Yaml documents.
9+ .
10+ This package includes the full libyaml C library version 0.1.12 by Kirill
11+ Simonov (<http://pyyaml.org/wiki/LibYAML>) in the package so you
12+ don't need to worry about any non-Haskell dependencies.
913category: Web
1014stability: unstable
1115cabal-version: >= 1.2
1216build-type: Simple
1317homepage: http://github.com/snoyberg/yaml/
1418extra-source-files: c/helper.h,
15− c/yaml_private.h,
16− c/yaml.h
19+ libyaml/yaml_private.h,
20+ libyaml/yaml.h,
21+ libyaml/LICENSE
22+
23+flag system-libyaml
24+ description: Use the system-wide libyaml instead of the bundled copy
1725
1826flag nolib
1927 description: Skip building the library
@@ -33,16 +41,20 @@ library
3341 , enumerator >= 0.4 && < 0.5
3442 exposed-modules: Text.Libyaml
3543 ghc-options: -Wall
36− c-sources: c/helper.c,
37− c/api.c,
38− c/dumper.c,
39− c/emitter.c,
40− c/loader.c,
41− c/parser.c,
42− c/reader.c,
43− c/scanner.c,
44− c/writer.c
44+ c-sources: c/helper.c
4545 include-dirs: c
46+ if flag(system-libyaml)
47+ pkgconfig-depends: yaml-0.1
48+ else
49+ c-sources: libyaml/api.c,
50+ libyaml/dumper.c,
51+ libyaml/emitter.c,
52+ libyaml/loader.c,
53+ libyaml/parser.c,
54+ libyaml/reader.c,
55+ libyaml/scanner.c,
56+ libyaml/writer.c
57+ include-dirs: libyaml
4658
4759executable runtests
4860 if flag(buildtests)
@@ -60,14 +72,18 @@ executable runtests
6072 else
6173 Buildable: False
6274 ghc-options: -Wall
63− c-sources: c/helper.c,
64− c/api.c,
65− c/dumper.c,
66− c/emitter.c,
67− c/loader.c,
68− c/parser.c,
69− c/reader.c,
70− c/scanner.c,
71− c/writer.c
75+ c-sources: c/helper.c
7276 include-dirs: c
77+ if flag(system-libyaml)
78+ pkgconfig-depends: yaml-0.1
79+ else
80+ c-sources: libyaml/api.c,
81+ libyaml/dumper.c,
82+ libyaml/emitter.c,
83+ libyaml/loader.c,
84+ libyaml/parser.c,
85+ libyaml/reader.c,
86+ libyaml/scanner.c,
87+ libyaml/writer.c
88+ include-dirs: libyaml
7389 main-is: runtests.hs