[geany/geany-plugins] a283e6: Markdown: Fix Waf to check/link to external Discount library

Matthew Brush git-noreply at xxxxx
Mon Mar 4 03:27:47 UTC 2013


Branch:      refs/heads/master
Author:      Matthew Brush <matt at geany.org>
Committer:   Matthew Brush <matt at geany.org>
Date:        Mon, 04 Mar 2013 03:27:47 UTC
Commit:      a283e67479a315f477e9a33ba1b4769e518840ac
             https://github.com/geany/geany-plugins/commit/a283e67479a315f477e9a33ba1b4769e518840ac

Log Message:
-----------
Markdown: Fix Waf to check/link to external Discount library

It makes no attempt to use the built-in peg-markdown library or add
the configure option like Autotools has to enable using it. I have no
idea how to do this in Waf.


Modified Paths:
--------------
    markdown/wscript_build
    markdown/wscript_configure

Modified: markdown/wscript_build
25 files changed, 3 insertions(+), 22 deletions(-)
===================================================================
@@ -24,31 +24,12 @@ from build.wafutils import build_plugin
 from waflib.Utils import subst_vars
 
 name = 'Markdown'
-includes = [ 'src', 'discount' ]
+includes = [ 'src' ]
 defines = [ subst_vars('MARKDOWN_DATA_DIR="${PKGDATADIR}/markdown"', bld.env),
             subst_vars('MARKDOWN_DOC_DIR="${DOCDIR}/markdown"', bld.env),
             subst_vars('MARKDOWN_HELP_FILE="${DOCDIR}/markdown/html/help.html"', bld.env) ]
-libraries = [ 'GTK', 'GTHREAD', 'WEBKIT' ]
-sources = [ "discount/amalloc.c",
-            "discount/basename.c",
-            "discount/Csio.c",
-            "discount/css.c",
-            "discount/docheader.c",
-            "discount/dumptree.c",
-            "discount/emmatch.c",
-            "discount/flags.c",
-            "discount/generate.c",
-            "discount/html5.c",
-            "discount/markdown.c",
-            "discount/mkdio.c",
-            "discount/resource.c",
-            "discount/setup.c",
-            "discount/tags.c",
-            "discount/toc.c",
-            "discount/version.c",
-            "discount/xml.c",
-            "discount/xmlpage.c",
-            "src/conf.c",
+libraries = [ 'GTK', 'GTHREAD', 'WEBKIT', 'DISCOUNT' ]
+sources = [ "src/conf.c",
             "src/plugin.c",
             "src/viewer.c" ]
 


Modified: markdown/wscript_configure
7 files changed, 7 insertions(+), 0 deletions(-)
===================================================================
@@ -33,3 +33,10 @@ for package_name, package_version, uselib_store in packages:
                      uselib_store=uselib_store,
                      mandatory=True,
                      args='--cflags --libs')
+
+conf.check(header_name='mkdio.h',
+           mandatory=True)
+
+conf.check(lib='markdown',
+           uselib_store='DISCOUNT',
+           mandatory=True)



--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).


More information about the Plugins-Commits mailing list