Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
C Ruby
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
.idea
Rpjsip
.gitignore
README
rtest_pjsip.rb
test_pjsip.rb

README

Ruby wrapper for pjsip library.
You must heave pjsip library compiled and installed.
This have be modified to support debian 6.0.4
also added a simple send_im method for sending out im message

For other linux distro/ osx (UNIX-like system), please edit the extconf.rb targetName to corresponding pjsip library (it should work)
(you may have to fix the audio issue depend on your linux distro, please include those library)
If you find make error while building the shared library,
something like "relocation R_X86_64_32 against `pjsua_var' can not be used when making a shared object; recompile with -fPIC"
You may have to re-compile the pjsip library again and add -fPIC as FLAG

$ ./configure CFLAGS=-fPIC CXXFLAGS=-fPIC
$ make dep && make


Some simple guideline:
compile pjsip on your system
modify extconf.rb depend on your system
change cfg.port in pjmanager.c to your preferred outgoing port if neccessary, currently is 55060
$ ruby extconf.rb
$ make
now you should have the .so / .bundle shared library file
you may want to "$ make install" them
and test with "$ ruby test_pjsip.rb" to see if it is work
(please modify the test_pjsip.rb with some working sip account)
Something went wrong with that request. Please try again.