webrtc build on linux

660 views
Skip to first unread message

George Kastour

unread,
May 17, 2017, 11:28:16 AM5/17/17
to discuss-webrtc
Hi All

I'm new to webrtc , trying to build and use C++ API on Linux

I did below steps ,

mkdir webrtc-checkout
cd webrtc-checkout
fetch --nohooks webrtc
gclient sync

then using gn gen with target_os linux

then ninja -c to build

then combined all the static libraries generated after build in one static library
exported all header files of webrtc and third parties

tried an example with only one line of code, using the header files and the static library

#include "webrtc/api/peerconnectioninterface.h"



int main(int argc, char* argv[]) {

    

   

    rtc::scoped_refptr<webrtc::PeerConnectionFactoryInterface> peer_connection_factory = webrtc::CreatePeerConnectionFactory();

   

    

    return 0;

}



I got 124 errors


plz correct me, I'm sure I'm missing some stpes


Henrik Kjellander

unread,
May 17, 2017, 1:59:56 PM5/17/17
to discuss-webrtc
Please let us know how you setup your app and how you compiled it to link with the libraries. 
I think you should only need to link with out/Debug/obj/webrtc/libwebrtc.a in order to get it to run - it is a fat library that contains everything.

--

---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrtc+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/4705cfc6-f919-4867-b77a-1817ff4ee2aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

George Kastour

unread,
May 18, 2017, 10:30:03 AM5/18/17
to discuss-webrtc
Hi Henrik 

Thanks for your reply, I linked against the fat libwebrtc.a, tried it on mac OSX and it worked perfect, 

now I'm trying to do the same for IOS , so I fetched webrtc-ios and built it for arm , according to the device I'm testing on, when I link against libwebrtc.a , I get link error

To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.

Kári Helgason

unread,
May 19, 2017, 3:36:10 AM5/19/17
to discuss-webrtc
Could you please post the error you're seeing so we can help you get up and running?

To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrtc+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/cbe5b35a-a2bb-429a-a65a-d97a2e6cdcda%40googlegroups.com.

George Kastour

unread,
May 19, 2017, 3:41:06 AM5/19/17
to discuss-webrtc
here is the error

Apple Mach-O Linker (ld) Error Group

clang: error: linker command failed with exit code 1 (use -v to see invocation)


Thanks!

Reply all
Reply to author
Forward
0 new messages