[ 
https://issues.apache.org/jira/browse/COUCHDB-1012?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Randall Leeds updated COUCHDB-1012:
-----------------------------------

    Attachment: 0001-support-pkg-config-for-plugins-COUCHDB-1012.patch

You're right, Paul. No double substitution needed.
I'm curious if anyone can build against this. If there's something I should do 
different to make integration with other tools, and especially rebar (which I'm 
not too familiar with), smoother please let me know.

I don't know any projects that install pkg-config files for erlang, so it's 
sort of up to us to define what the useful variables are.

Right now I've got `pkg-config --cflags couchdb` giving:
-I/usr/local/lib/couchdb/erlang/lib/couch-1.2.0af9ee604-git

and `pkg-config --libs couchdb` giving:
-pa /usr/local/lib/couchdb/erlang/lib

which are flags suitable for passing to erlc (the first two) and erl (just the 
--libs). However, if it's easier to just give the directories without the 
flags, for example for an install command to the place files in the couchdb 
code path, maybe that's better? It might be less confusing to just ignore the 
standard --cflags and --libs and use --variable=code_path and 
--variable=include_dir or something. Though, to be honest, --cflags doesn't 
bother to me toooo much (it's erl *c* after all...), but I digress.

Feedback appreciated.

> Utility to help plugin developers manage paths
> ----------------------------------------------
>
>                 Key: COUCHDB-1012
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1012
>             Project: CouchDB
>          Issue Type: New Feature
>          Components: Build System
>            Reporter: Randall Leeds
>         Attachments: 0001-support-pkg-config-for-plugins-COUCHDB-1012.patch
>
>
> Developers may want to write plugins (like GeoCouch) for CouchDB. Many hooks 
> in the configuration system allow loading arbitrary Erlang modules to handle 
> various internal tasks, but currently there is no straightforward and 
> portable way for developers of these plugins to discover the location of the 
> CouchDB library files.
> Two options that have been proposed are to use pkg-config or install a 
> separate script that could be invoked (e.g. as couch-config --erl-libs) to 
> discover important CouchDB installation paths.
> As far as I know the loudest argument against pkg-config is lack of support 
> for Windows.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to