Hi Philip,

Thanks for these changes. Make a pull request and I'll merge them into czmq
master. Please patch the readme.txt to suit.

- Pieter
On Nov 12, 2011 3:20 PM, "Philip Kovacs" <[email protected]> wrote:

> I forked CZMQ up here: https://github.com/pkovacs/czmq so that I could
> apply some minor patches for your consideration.
>
> The first commit moves the distributed headers out of the main include
> directory, e.g. /usr/include or /usr/local/include, etc., and into a
> subdirectory, e.g. /usr/include/czmq.
>
> The motivation here is that developers ought to be able to inspect the
> libraries headers in one area without fishing around for them.  Yes, this
> does introduce the need for -I, but I also modified the pkg-config file
> to accommodate the change:
>
> gcc `pkg-config --cflags libczmq` -c program.c
>
> Anyone using autotools can also use the pkg-config macros (pkg.m4):
>
> ---configure.ac/in---
> PKG_CHECK_MODULES(CZMQ, libczmq)
>
> ---src/Makefile.am---
> program_CFLAGS =   \
>   $(CZMQ_CFLAGS)  \
>   ...
>
> or
>
> library_la_CFLAGS = \
>    $(CZMQ_CFLAGS)  \
>    ...
>
> etc.
>
> Anyway, it's a common approach to use subdirectories for packages
> distributing
> multiple headers.  Should I send a patch up for 0MQ as well?  Same idea.
>
> The second commit is to fix the broken builds I observed when performing
> out of tree
> "VPATH" builds.  To replicate the issue you need the package from git (not
> a tarball)
> and you need the doc tools asciidoc and xmlto.
>
> make distclean
> ./autogen.sh
> mkdir i686
> cd i686
> ../configure
> make
>
> The build will break in the doc directory as both the Makefile.am and the
> mkman
> script ignore the directory shift when building out of tree.  Also,
> asciidoc has
> a quirk that took me a little while to pin down.  When you do not specify
> the
> output file, asciidoc always places the output in the location of the
> source file,
> not the target file, no matter what the current working (build) directory
> is.
> This also breaks VPATH builds as those .xml files need to be generated in
> the build
> tree, not the source tree.  Adding -o$@ causes asciidoc to build the
> target file
> _in the current directory_ (== build tree) and this fixes it.  I also
> fixed up
> mkman so it handles out of tree builds, and the Makefile.am as well.
>
> Cheers,
>
> Phil
>
>
> _______________________________________________
> zeromq-dev mailing list
> [email protected]
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
>
>
_______________________________________________
zeromq-dev mailing list
[email protected]
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to