[pjsip] pjsip Digest, Vol 36, Issue 3

Shamun toha md shamun.toha at gmail.com
Sun Aug 1 10:29:30 CDT 2010


WORKS!! Thanks a lot.

In my penguin nothing was wrong, its the build.mak file which need to use
for to collect all the -l (small L) liners (there is PJ linker + Third party
linker, manually we can make PJ linker only, but third party linker are
build by build.mak file which is located in root trunk directory)

Hello World - Tutorial 1 Red Hat Penguin
==============================

##########################
# My application directory:
##########################
[root at example mysip]# tree
.
├── Makefile
├── myapp
├── myapp.c
├── myapp.cpp


##########################
#  @file: myapp.c
##########################
#include <pjlib.h>
#include <pjlib-util.h>
#include <pjmedia.h>
#include <pjmedia-codec.h>
#include <pjsip.h>
#include <pjsip_simple.h>
#include <pjsip_ua.h>
#include <pjsua-lib/pjsua.h>

int main(int argc, char *argv[]) {
   pj_status_t status;
   status = pjsua_create();
  return 0;
}

#########################
# @file: Build/Compile - 2 choice
#########################

Choice 1. Makefile automatic
------------------------------------------
#
# Step - 1
# @build.mak file is very import here
#
PJBASE=/home/sun/Downloads/pjsip/trunk
include $(PJBASE)/build.mak

#
# Step - 2
# values are used from build.mak file
#
all: myapp

myapp: myapp.c
    $(CC_NAME) $@.c -o $@ $(APP_LDLIBS)

clean:
    rm -f myapp.o myapp


Choice 2. GCC by hand
----------------------------------
gcc myapp.c -o myapp -lpjsua-i686-pc-linux-gnu -lpjsip-ua-i686-pc-linux-gnu
-lpjsip-simple-i686-pc-linux-gnu -lpjsip-i686-pc-linux-gnu
-lpjmedia-codec-i686-pc-linux-gnu -lpjmedia-i686-pc-linux-gnu
-lpjmedia-audiodev-i686-pc-linux-gnu -lpjnath-i686-pc-linux-gnu
-lpjlib-util-i686-pc-linux-gnu -lresample-i686-pc-linux-gnu
-lmilenage-i686-pc-linux-gnu -lsrtp-i686-pc-linux-gnu
-lgsmcodec-i686-pc-linux-gnu -lspeex-i686-pc-linux-gnu
-lilbccodec-i686-pc-linux-gnu -lg7221codec-i686-pc-linux-gnu
-lportaudio-i686-pc-linux-gnu  -lpj-i686-pc-linux-gnu -lm -lnsl -lrt
-lpthread


Conclusion:
=========

SO, i pass my PJ level 1, cake is served, moving next level.

Many thanks
Best regards
Shamun
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20100801/71b7a4c4/attachment.html>


More information about the pjsip mailing list