Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-11 Thread Stephan Opfer

On 10.01.2017 23:04, Luca Boccassi wrote:

Gh. Why, gcc, why!!

You need to pass the source file BEFORE the linker flags.

This works:

g++ Discovery.cpp `pkg-config --libs --cflags libzmq` -o test

This fails:

g++ `pkg-config --libs --cflags libzmq` Discovery.cpp -o test

Unbelievable. And I'm sure I've tripped over this a few times already...

Thanks, that helped! Now I could compile it manually and know that I did 
install the zmq correctly.

With the help of this CMake Module: 
https://github.com/Kitware/Remus/blob/master/CMake/FindZeroMQ.cmake
I could make it work with my CMakeLists.txt.

These are the critical lines:

# Define where to find modules for ZeroMQ
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake CACHE INTERNAL "" FORCE)
add_definitions(-DZMQ_BUILD_DRAFT_API=1)
find_package(ZeroMQ)

The rest is just standard setting include dirs and linking libraries:

include_directories(include ${ZeroMQ_INCLUDE_DIRS})
target_link_libraries(${PROJECT_NAME} ${ZeroMQ_LIBRARIES})



--
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Holger Freyther

> On 10 Jan 2017, at 22:06, Stephan Opfer  wrote:
> 
> 
> On 10.01.2017 21:59, Luca Boccassi wrote:
>> Did you install the packages? Because then /usr/local is wrong, if you
>> did a make install before you should do a make uninstall to remove the
>> manually installed files
> I tried both ways. Currently I have the library manually compiled and did 
> make install.
> 
> When I install the packages and do make uninstall before, "pkg-config 
> --cflags --libs libzmq" only creates "-DZMQ_BUILD_DRAFT_API=1 -lzmq" and I 
> get the same linker errors doing this: g++ -DZMQ_BUILD_DRAFT_API=1 -lzmq 
> src/Discovery.cpp -o foo

put the library (-lzmq) after the source files on the compile/link line?



___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Luca Boccassi
On 10 January 2017 at 22:01, Luca Boccassi  wrote:
> On 10 January 2017 at 21:33, Stephan Opfer  wrote:
>> On 10.01.2017 22:20, Luca Boccassi wrote:
>>>
>>> luca@luca-desktop:/tmp$ apt-cache policy libzmq3-dev
>>> libzmq3-dev:
>>>Installed: 1483950852.598befc
>>>Candidate: 1483950852.598befc
>>>Version table:
>>>   *** 1483950852.598befc 0
>>>
>>> 500http://download.opensuse.org/repositories/home:/zeromq:/git-draft/Debian_8.0/
>>> ./ Packages
>>>  100 /var/lib/dpkg/status
>>>   4.2.1-2 0
>>>  103http://httpredir.debian.org/debian/  sid/main amd64 Packages
>>>   4.2.0-2 0
>>>  104http://httpredir.debian.org/debian/  stretch/main amd64
>>> Packages
>>>   4.0.5+dfsg-2+deb8u1 0
>>>  500http://httpredir.debian.org/debian/  jessie/main amd64
>>> Packages
>>>  500http://security.debian.org/  jessie/updates/main amd64
>>> Packages
>>> luca@luca-desktop:/tmp$ g++ `pkg-config --libs --cflags libzmq`
>>> Discovery.cpp -o test
>>> luca@luca-desktop:/tmp$ ./test
>>>
>>>
>>> Builds just fine (binary runs and never exits not sure if that's
>>> intended). I am honestly not sure why your linker is being picky. This
>>> is on Debian 8 with gcc 4.9.2
>>
>> $ apt-cache policy libzmq3-dev
>> libzmq3-dev:
>>   Installed: 1483950852.598befc
>>   Candidate: 1483950852.598befc
>>   Version table:
>>  *** 1483950852.598befc 500
>> 500
>> http://download.opensuse.org/repositories/home:/zeromq:/git-draft/xUbuntu_16.04
>> ./ Packages
>> 100 /var/lib/dpkg/status
>>  4.1.4-7 500
>> 500 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages
>>
>> A little bit strang, that I don't see a Version named 4.2.x like you have.
>> Nevertheless, this would only create a lack of the new UDP Multicast
>> feature, but my linker complains about standard functions like
>> zmq_ctx_new...
>>
>> I am using g++ version 5.4.0 on Ubuntu 16.04 LTS. I further guaranteed that
>> there is only one libzmq.
>> Its location is: /usr/lib/x86_64-linux-gnu/libzmq.so.5.1.2
>> And I checked that the wanted symbol is in there with: readelf -Ws
>> /usr/lib/x86_64-linux-gnu/libzmq.so.5.1.2
>>
>> Normally under this circumstances problems like mismatching architecture of
>> the .so is the case, but I can't see any hints for that.
>
> Uh, I have an Ubuntu 16.04 machine around and I can indeed reproduce
> the same problem. This is weird. Investigating...

Gh. Why, gcc, why!!

You need to pass the source file BEFORE the linker flags.

This works:

g++ Discovery.cpp `pkg-config --libs --cflags libzmq` -o test

This fails:

g++ `pkg-config --libs --cflags libzmq` Discovery.cpp -o test

Unbelievable. And I'm sure I've tripped over this a few times already...
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Luca Boccassi
On 10 January 2017 at 21:33, Stephan Opfer  wrote:
> On 10.01.2017 22:20, Luca Boccassi wrote:
>>
>> luca@luca-desktop:/tmp$ apt-cache policy libzmq3-dev
>> libzmq3-dev:
>>Installed: 1483950852.598befc
>>Candidate: 1483950852.598befc
>>Version table:
>>   *** 1483950852.598befc 0
>>
>> 500http://download.opensuse.org/repositories/home:/zeromq:/git-draft/Debian_8.0/
>> ./ Packages
>>  100 /var/lib/dpkg/status
>>   4.2.1-2 0
>>  103http://httpredir.debian.org/debian/  sid/main amd64 Packages
>>   4.2.0-2 0
>>  104http://httpredir.debian.org/debian/  stretch/main amd64
>> Packages
>>   4.0.5+dfsg-2+deb8u1 0
>>  500http://httpredir.debian.org/debian/  jessie/main amd64
>> Packages
>>  500http://security.debian.org/  jessie/updates/main amd64
>> Packages
>> luca@luca-desktop:/tmp$ g++ `pkg-config --libs --cflags libzmq`
>> Discovery.cpp -o test
>> luca@luca-desktop:/tmp$ ./test
>>
>>
>> Builds just fine (binary runs and never exits not sure if that's
>> intended). I am honestly not sure why your linker is being picky. This
>> is on Debian 8 with gcc 4.9.2
>
> $ apt-cache policy libzmq3-dev
> libzmq3-dev:
>   Installed: 1483950852.598befc
>   Candidate: 1483950852.598befc
>   Version table:
>  *** 1483950852.598befc 500
> 500
> http://download.opensuse.org/repositories/home:/zeromq:/git-draft/xUbuntu_16.04
> ./ Packages
> 100 /var/lib/dpkg/status
>  4.1.4-7 500
> 500 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages
>
> A little bit strang, that I don't see a Version named 4.2.x like you have.
> Nevertheless, this would only create a lack of the new UDP Multicast
> feature, but my linker complains about standard functions like
> zmq_ctx_new...
>
> I am using g++ version 5.4.0 on Ubuntu 16.04 LTS. I further guaranteed that
> there is only one libzmq.
> Its location is: /usr/lib/x86_64-linux-gnu/libzmq.so.5.1.2
> And I checked that the wanted symbol is in there with: readelf -Ws
> /usr/lib/x86_64-linux-gnu/libzmq.so.5.1.2
>
> Normally under this circumstances problems like mismatching architecture of
> the .so is the case, but I can't see any hints for that.

Uh, I have an Ubuntu 16.04 machine around and I can indeed reproduce
the same problem. This is weird. Investigating...
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Stephan Opfer

On 10.01.2017 22:20, Luca Boccassi wrote:

luca@luca-desktop:/tmp$ apt-cache policy libzmq3-dev
libzmq3-dev:
   Installed: 1483950852.598befc
   Candidate: 1483950852.598befc
   Version table:
  *** 1483950852.598befc 0
 
500http://download.opensuse.org/repositories/home:/zeromq:/git-draft/Debian_8.0/
./ Packages
 100 /var/lib/dpkg/status
  4.2.1-2 0
 103http://httpredir.debian.org/debian/  sid/main amd64 Packages
  4.2.0-2 0
 104http://httpredir.debian.org/debian/  stretch/main amd64 Packages
  4.0.5+dfsg-2+deb8u1 0
 500http://httpredir.debian.org/debian/  jessie/main amd64 Packages
 500http://security.debian.org/  jessie/updates/main amd64 Packages
luca@luca-desktop:/tmp$ g++ `pkg-config --libs --cflags libzmq`
Discovery.cpp -o test
luca@luca-desktop:/tmp$ ./test


Builds just fine (binary runs and never exits not sure if that's
intended). I am honestly not sure why your linker is being picky. This
is on Debian 8 with gcc 4.9.2

$ apt-cache policy libzmq3-dev
libzmq3-dev:
  Installed: 1483950852.598befc
  Candidate: 1483950852.598befc
  Version table:
 *** 1483950852.598befc 500
500 
http://download.opensuse.org/repositories/home:/zeromq:/git-draft/xUbuntu_16.04 
./ Packages

100 /var/lib/dpkg/status
 4.1.4-7 500
500 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages

A little bit strang, that I don't see a Version named 4.2.x like you 
have. Nevertheless, this would only create a lack of the new UDP 
Multicast feature, but my linker complains about standard functions like 
zmq_ctx_new...


I am using g++ version 5.4.0 on Ubuntu 16.04 LTS. I further guaranteed 
that there is only one libzmq.

Its location is: /usr/lib/x86_64-linux-gnu/libzmq.so.5.1.2
And I checked that the wanted symbol is in there with: readelf -Ws 
/usr/lib/x86_64-linux-gnu/libzmq.so.5.1.2


Normally under this circumstances problems like mismatching architecture 
of the .so is the case, but I can't see any hints for that.


--
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Luca Boccassi
On 10 January 2017 at 21:16, Stephan Opfer  wrote:
> On 10.01.2017 22:10, Luca Boccassi wrote:
>>
>> Can you share the source of discovery.ccp in a gitst/pastebin, or
>> another minimal example that reproduces the problem?
>
> Yes no problem: Discovery.cpp is basically copy past of
> https://github.com/zeromq/libzmq/blob/master/tests/test_radio_dish.cpp but I
> made some changes:
>
> https://gist.github.com/StephanOpfer/df1f589c69da6c2e264bddbd9afe730c

luca@luca-desktop:/tmp$ apt-cache policy libzmq3-dev
libzmq3-dev:
  Installed: 1483950852.598befc
  Candidate: 1483950852.598befc
  Version table:
 *** 1483950852.598befc 0
500 
http://download.opensuse.org/repositories/home:/zeromq:/git-draft/Debian_8.0/
./ Packages
100 /var/lib/dpkg/status
 4.2.1-2 0
103 http://httpredir.debian.org/debian/ sid/main amd64 Packages
 4.2.0-2 0
104 http://httpredir.debian.org/debian/ stretch/main amd64 Packages
 4.0.5+dfsg-2+deb8u1 0
500 http://httpredir.debian.org/debian/ jessie/main amd64 Packages
500 http://security.debian.org/ jessie/updates/main amd64 Packages
luca@luca-desktop:/tmp$ g++ `pkg-config --libs --cflags libzmq`
Discovery.cpp -o test
luca@luca-desktop:/tmp$ ./test


Builds just fine (binary runs and never exits not sure if that's
intended). I am honestly not sure why your linker is being picky. This
is on Debian 8 with gcc 4.9.2
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Stephan Opfer

On 10.01.2017 22:10, Luca Boccassi wrote:

Can you share the source of discovery.ccp in a gitst/pastebin, or
another minimal example that reproduces the problem?
Yes no problem: Discovery.cpp is basically copy past of 
https://github.com/zeromq/libzmq/blob/master/tests/test_radio_dish.cpp 
but I made some changes:


https://gist.github.com/StephanOpfer/df1f589c69da6c2e264bddbd9afe730c

--
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Luca Boccassi
On 10 January 2017 at 21:06, Stephan Opfer  wrote:
>
> On 10.01.2017 21:59, Luca Boccassi wrote:
>>
>> Did you install the packages? Because then /usr/local is wrong, if you
>> did a make install before you should do a make uninstall to remove the
>> manually installed files
>
> I tried both ways. Currently I have the library manually compiled and did
> make install.
>
> When I install the packages and do make uninstall before, "pkg-config
> --cflags --libs libzmq" only creates "-DZMQ_BUILD_DRAFT_API=1 -lzmq" and I
> get the same linker errors doing this: g++ -DZMQ_BUILD_DRAFT_API=1 -lzmq
> src/Discovery.cpp -o foo

That output is correct, as the library and headers are in the default
path so there is no need to override.

I use the packages on Debian and compile all the time, never seen that.

Can you share the source of discovery.ccp in a gitst/pastebin, or
another minimal example that reproduces the problem?
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Luca Boccassi
On 10 January 2017 at 20:47, Stephan Opfer  wrote:
> On 10.01.2017 17:28, Luca Boccassi wrote:
>>
>> As always on *NIX, use pkg-config and your life will be much easier.
>>
>> eg:
>>
>> g++ `pkg-config --cflags --libs libzmq` foo.cpp -o foo
>
> Ok, with pkg-config I can compile, but the linker is still complaining.
>
> Here is my command for compiling:
>
> g++ -DZMQ_BUILD_DRAFT_API=1 -I/usr/local/include -L/usr/local/lib -lzmq
> Discovery.cpp -o foo
>
> "pkg-config --cflags --libs libzmq" created "-DZMQ_BUILD_DRAFT_API=1
> -I/usr/local/include -L/usr/local/lib -lzmq", which seems right as far as I
> can tell.
>
> Here some linker errors:
>
> /tmp/ccLV8vrk.o: In function `main':
> Discovery.cpp:(.text+0x24e): undefined reference to `zmq_ctx_new'
> Discovery.cpp:(.text+0x28c): undefined reference to `zmq_socket'
> Discovery.cpp:(.text+0x2a7): undefined reference to `zmq_socket'
> Discovery.cpp:(.text+0x2c2): undefined reference to `zmq_bind'
> Discovery.cpp:(.text+0x2fe): undefined reference to `zmq_leave'
> Discovery.cpp:(.text+0x369): undefined reference to `zmq_join'
> Discovery.cpp:(.text+0x3a5): undefined reference to `zmq_join'
> Discovery.cpp:(.text+0x3e1): undefined reference to `zmq_join'
> Discovery.cpp:(.text+0x41d): undefined reference to `zmq_connect'
> Discovery.cpp:(.text+0x528): undefined reference to `zmq_join'
> Discovery.cpp:(.text+0x55a): undefined reference to `zmq_sleep'
> Discovery.cpp:(.text+0x5f8): undefined reference to `zmq_leave'
> Discovery.cpp:(.text+0x62a): undefined reference to `zmq_sleep'
> Discovery.cpp:(.text+0x70c): undefined reference to `zmq_poll'
> Discovery.cpp:(.text+0x7ab): undefined reference to `zmq_close'
> Discovery.cpp:(.text+0x7e2): undefined reference to `zmq_close'
> Discovery.cpp:(.text+0x819): undefined reference to `zmq_ctx_term'
> collect2: error: ld returned 1 exit status

Did you install the packages? Because then /usr/local is wrong, if you
did a make install before you should do a make uninstall to remove the
manually installed files
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Stephan Opfer

On 10.01.2017 17:28, Luca Boccassi wrote:

As always on *NIX, use pkg-config and your life will be much easier.

eg:

g++ `pkg-config --cflags --libs libzmq` foo.cpp -o foo

Ok, with pkg-config I can compile, but the linker is still complaining.

Here is my command for compiling:

g++ -DZMQ_BUILD_DRAFT_API=1 -I/usr/local/include -L/usr/local/lib -lzmq 
Discovery.cpp -o foo


"pkg-config --cflags --libs libzmq" created "-DZMQ_BUILD_DRAFT_API=1 
-I/usr/local/include -L/usr/local/lib -lzmq", which seems right as far 
as I can tell.


Here some linker errors:

/tmp/ccLV8vrk.o: In function `main':
Discovery.cpp:(.text+0x24e): undefined reference to `zmq_ctx_new'
Discovery.cpp:(.text+0x28c): undefined reference to `zmq_socket'
Discovery.cpp:(.text+0x2a7): undefined reference to `zmq_socket'
Discovery.cpp:(.text+0x2c2): undefined reference to `zmq_bind'
Discovery.cpp:(.text+0x2fe): undefined reference to `zmq_leave'
Discovery.cpp:(.text+0x369): undefined reference to `zmq_join'
Discovery.cpp:(.text+0x3a5): undefined reference to `zmq_join'
Discovery.cpp:(.text+0x3e1): undefined reference to `zmq_join'
Discovery.cpp:(.text+0x41d): undefined reference to `zmq_connect'
Discovery.cpp:(.text+0x528): undefined reference to `zmq_join'
Discovery.cpp:(.text+0x55a): undefined reference to `zmq_sleep'
Discovery.cpp:(.text+0x5f8): undefined reference to `zmq_leave'
Discovery.cpp:(.text+0x62a): undefined reference to `zmq_sleep'
Discovery.cpp:(.text+0x70c): undefined reference to `zmq_poll'
Discovery.cpp:(.text+0x7ab): undefined reference to `zmq_close'
Discovery.cpp:(.text+0x7e2): undefined reference to `zmq_close'
Discovery.cpp:(.text+0x819): undefined reference to `zmq_ctx_term'
collect2: error: ld returned 1 exit status



--
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Luca Boccassi
On Tue, 2017-01-10 at 17:39 +0100, Stephan Opfer wrote:
> On 10.01.2017 17:28, Luca Boccassi wrote:
> > Append to /etc/apt/sources.list :
> > debhttp://download.opensuse.org/repositories/home:/zeromq:/git-draft/xUbuntu_16.04/
> >   ./
> How do I sign the key of this repo?

It's a standard apt repository, so:

wget --quiet -O - 
http://download.opensuse.org/repositories/home:/zeromq:/git-draft/xUbuntu_16.04/Release.key
 | sudo apt-key add -

Kind regards,
Luca Boccassi


signature.asc
Description: This is a digitally signed message part
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Stephan Opfer

On 10.01.2017 17:28, Luca Boccassi wrote:

Append to /etc/apt/sources.list :
debhttp://download.opensuse.org/repositories/home:/zeromq:/git-draft/xUbuntu_16.04/
  ./

How do I sign the key of this repo?


--
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Luca Boccassi
On Tue, 2017-01-10 at 17:23 +0100, Stephan Opfer wrote:
> On 10.01.2017 17:21, Kevin Sapper wrote:
> > there is a cmake option "ENABLE_DRAFTS" which should do the same. 
> Do I have to include this option into the compilation of my project, too? Or 
> is it just for compiling libzmq with CMake?

As always on *NIX, use pkg-config and your life will be much easier.

eg:

g++ `pkg-config --cflags --libs libzmq` foo.cpp -o foo

Or if you don't install via packages:

g++ `PKG_CONFIG_PATH=/path/to/pkgconfig pkg-config --cflags --libs libzmq` 
foo.cpp -o foo

Even easier, we provide repositories and packages for the most used
distros and architectures, including Ubuntu. So if you add this
repository and then run apt-get update; apt-get install libzmq3-dev and
then everything will be in the right path for your application to find.

Append to /etc/apt/sources.list :
deb 
http://download.opensuse.org/repositories/home:/zeromq:/git-draft/xUbuntu_16.04/
 ./

Kind regards,
Luca Boccassi


signature.asc
Description: This is a digitally signed message part
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Stephan Opfer

On 10.01.2017 17:21, Kevin Sapper wrote:
there is a cmake option "ENABLE_DRAFTS" which should do the same. 

Do I have to include this option into the compilation of my project, too? Or is 
it just for compiling libzmq with CMake?


--
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Kevin Sapper
Hi Stephan,

there is a cmake option "ENABLE_DRAFTS" which should do the same.

//Kevin

Am 10.01.2017 17:13 schrieb "Stephan Opfer" :

Hi all,

I could need a little help with using ZMQ. I try to setup my project with
CMake under Ubuntu 16.04 LTS and I need the ZMQ UDP Multicast Support
available as draft in the latest version.

Does somebody have an working example CMake based project?

I tried to compile the test_radio_dish.cpp by replacing the testutil.hpp by
directly including the necessary headers. So far I #include  and
#include .

I got the compile error: ‘zmq_msg_set_group’ was not declared in this scope
"rc = zmq_msg_set_group (msg_, group_);"

My first guess would be that I didn't compile libzmq the right way for
being "zmq_msg_set_group" available. Here is what I did:

- Download the tar for libzmq 4.2

- ./configure --enable-drafts

- make

- sudo make install

After that the libraries where located in /usr/local/lib and the headers in
/usr/local/include.

Greetings,

  Stephan


-- 
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev
___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev

[zeromq-dev] Example for building against ZMQ with CMake + UDP Multicast Support

2017-01-10 Thread Stephan Opfer

Hi all,

I could need a little help with using ZMQ. I try to setup my project with CMake 
under Ubuntu 16.04 LTS and I need the ZMQ UDP Multicast Support available as 
draft in the latest version.

Does somebody have an working example CMake based project?

I tried to compile the test_radio_dish.cpp by replacing the testutil.hpp by directly 
including the necessary headers. So far I #include  and #include 
.

I got the compile error: ‘zmq_msg_set_group’ was not declared in this scope "rc = 
zmq_msg_set_group (msg_, group_);"

My first guess would be that I didn't compile libzmq the right way for being 
"zmq_msg_set_group" available. Here is what I did:

- Download the tar for libzmq 4.2

- ./configure --enable-drafts

- make

- sudo make install

After that the libraries where located in /usr/local/lib and the headers in 
/usr/local/include.

Greetings,

  Stephan


--
Distributed Systems Research Group
Stephan Opfer  T. +49 561 804-6283  F. +49 561 804-6277
Univ. Kassel,  FB 16,  Wilhelmshöher Allee 73,  D-34121 Kassel
WWW: http://www.uni-kassel.de/go/vs_stephan-opfer/

___
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
https://lists.zeromq.org/mailman/listinfo/zeromq-dev