Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

first attempt to make zeromq compilation optional #19

Closed
wants to merge 1 commit into from

2 participants

@schmurfy

The option is used like this:
$ ZEROMQ_LIB=/usr/local/lib/libzmq.a make

I am not too sure about how it should be done but at least this method works :)

Julien Ammous added an option to reuse an already compiled zeromq
added ZEROMQ_LIB environment variable, usage :
$ ZEROMQ_LIB=/usr/local/lib/libzmq.a make
56c8735
@yrashk
Owner

Hey,

thanks for sending this in. Let me play with this a bit and see how this works.

@schmurfy

There is one problem with this approach: if you are using erlzmq2 as a dependency managed with rebar each time you do a "rebar compile" in your application folder it will run make in erlzmq2 meaning that for this patch to work effectively you need to have something like that in your main application Makefile:
export ZEROMQ_LIB=/usr/local/lib/libzmq.a
That is what I am currently doing but it kinda feels ugly :(

@yrashk
Owner

Hey, I didn't forget about this issue/pull request — just extremely busy. Will get back to you ASAP

@schmurfy

no problem :)

@schmurfy schmurfy closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jun 30, 2011
  1. added an option to reuse an already compiled zeromq

    Julien Ammous authored
    added ZEROMQ_LIB environment variable, usage :
    $ ZEROMQ_LIB=/usr/local/lib/libzmq.a make
This page is out of date. Refresh to see the latest.
Showing with 8 additions and 0 deletions.
  1. +8 −0 c_src/Makefile
View
8 c_src/Makefile
@@ -19,6 +19,7 @@ clean:
distclean:
@rm -rf $(DEPS)
+ifndef ZEROMQ_LIB
$(DEPS)/zeromq2:
@mkdir $(DEPS)
@git clone git://github.com/zeromq/zeromq2-1.git $(DEPS)/zeromq2
@@ -27,3 +28,10 @@ $(DEPS)/zeromq2:
$(DEPS)/zeromq2/src/.libs/libzmq.a: $(DEPS)/zeromq2
@cd $(DEPS)/zeromq2 && ./autogen.sh && ./configure $(ZMQ_FLAGS) && make
+
+else
+
+$(DEPS)/zeromq2/src/.libs/libzmq.a:
+ @mkdir -p $(DEPS)/zeromq2/src/.libs/
+ @ln -s $(ZEROMQ_LIB) $(DEPS)/zeromq2/src/.libs/libzmq.a
+endif
Something went wrong with that request. Please try again.