Changeset 4756


Ignore:
Timestamp:
Feb 21, 2014 7:49:37 AM (11 years ago)
Author:
nanang
Message:

More pjsua2 SWIG Python (re #1519): Separate library dependencies from Python Extension setting 'extra_link_args', so PJ lib dependencies are specified before Python's (otherwise strange crash happens on MinGW).

Location:
pjproject/trunk/pjsip-apps/src/swig/python
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip-apps/src/swig/python/helper.mak

    r4753 r4756  
    33 
    44ldflags: 
    5         @for token in `echo $(PJ_LDXXLIBS) $(PJ_LDXXFLAGS) $(LDFLAGS)`; do \ 
     5        @for token in `echo $(PJ_LDXXFLAGS) $(LDFLAGS)`; do \ 
    66                echo $$token; \ 
     7        done 
     8 
     9libs: 
     10        @for token in `echo $(PJ_LDXXLIBS) $(LIBS)`; do \ 
     11                echo $$token | grep \\-l | sed 's/-l//'; \ 
    712        done 
    813 
  • pjproject/trunk/pjsip-apps/src/swig/python/setup.py

    r4753 r4756  
    7474f.close() 
    7575 
     76# Fill in libraries 
     77libraries = [] 
     78f = os.popen("make --no-print-directory -f helper.mak libs") 
     79for line in f: 
     80    libraries.append(line.rstrip("\r\n")) 
     81f.close() 
     82 
    7683# Fill in extra_link_args 
    7784extra_link_args = [] 
     
    9198      url='http://www.pjsip.org', 
    9299      ext_modules = [Extension("_pjsua2",  
    93                                ["pjsua2_wrap.cpp"],  
     100                               ["pjsua2_wrap.cpp"], 
     101                               libraries=libraries, 
    94102                               extra_compile_args=extra_compile_args, 
    95103                               extra_link_args=extra_link_args 
Note: See TracChangeset for help on using the changeset viewer.