Discussion:
Linking to library in other project
(too old to reply)
B.R.
2014-08-18 13:33:50 UTC
Permalink
Raw Message
Hello,

I am a new user here :o)

I plan on using the libevent library for the very first time in a project.
I wonder about something related to cross-compiling for Windows and Linux:

I compiled libevent with MinGW+MSYS on Windows in order to link my project
against the libevent.a (static linking).
What if I want to link my project with the same library for the Linux
version? I do not see any libevent.lib. Shall I use the libevent.a again?
Or should I compile libevent in Linux first then use its output library,
which I guess would be libevent(.dll).lib?

​Thanks,​

---
*B. R.*
Azat Khuzhin
2014-08-18 13:41:54 UTC
Permalink
Raw Message
Post by B.R.
Hello,
I am a new user here :o)
I plan on using the libevent library for the very first time in a project.
Take a look at cmake.
http://cmake.org
Post by B.R.
I compiled libevent with MinGW+MSYS on Windows in order to link my project
against the libevent.a (static linking).
What if I want to link my project with the same library for the Linux
version? I do not see any libevent.lib. Shall I use the libevent.a again?
Or should I compile libevent in Linux first then use its output library,
which I guess would be libevent(.dll).lib?
linux libraries -extensions-:

dynamic library: *.so
$ l .cmake/lib/*.so
.cmake/lib/libevent_core.so@
.cmake/lib/libevent_extra.so@
.cmake/lib/libevent.so

static/archivied library: *.a
$ l .cmake/lib/*.so
.cmake/lib/libevent_core.so@
.cmake/lib/libevent_extra.so@
.cmake/lib/libevent.so@
--
Respectfully
Azat Khuzhin
***********************************************************************
To unsubscribe, send an e-mail to ***@freehaven.net with
unsubscribe libevent-users in the body.
B.R.
2014-08-29 17:58:21 UTC
Permalink
Raw Message
I saw the answer on the ML archive on the website project.
It seems the message did not go through some spam filters at some point...

OK thanks, I need to use CMake if I want to use it on Windows platforms. I
will see to that when needed.
---
*B. R.*
Post by B.R.
Hello,
I am a new user here :o)
I plan on using the libevent library for the very first time in a project.
I compiled libevent with MinGW+MSYS on Windows in order to link my project
against the libevent.a (static linking).
What if I want to link my project with the same library for the Linux
version? I do not see any libevent.lib. Shall I use the libevent.a again?
Or should I compile libevent in Linux first then use its output library,
which I guess would be libevent(.dll).lib?
​Thanks,​
---
*B. R.*
Loading...