Ignore:
Timestamp:
Jan 15, 2010 3:06:20 PM (12 years ago)
Author:
bennylp
Message:

Ticket #694: work on 'make install':

  • adhere to --prefix
  • header and lib files installation
  • pkgconfig creation
  • also added version.mak to fill in with the correct version
File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/Makefile

    r3024 r3063  
    3636        pjmedia/lib/libpjmedia-audiodev-$(TARGET_NAME).a \ 
    3737        pjmedia/lib/libpjmedia-codec-$(TARGET_NAME).a \ 
    38         pjsip/lib/libpjsip-$(TARGET_NAME).a \ 
     38        pjsip/lib/libpjsip-$(TARGET_NAME).a \ 
    3939        pjsip/lib/libpjsip-ua-$(TARGET_NAME).a \ 
    4040        pjsip/lib/libpjsip-simple-$(TARGET_NAME).a \ 
     
    9191        cd tests/pjsua && python runall.py 
    9292 
    93 prefix = /usr/local 
     93prefix = $(ac_prefix) 
     94include version.mak 
     95 
    9496install: 
    9597        mkdir -p $(DESTDIR)$(prefix)/lib 
    96         cp -L $$(find . -name '*.a') $(DESTDIR)$(prefix)/lib 
     98        cp -f $(APP_LIB_FILES) $(DESTDIR)$(prefix)/lib/ 
    9799        mkdir -p $(DESTDIR)$(prefix)/include 
    98         cp -RL $$(find  . -name include) $(DESTDIR)$(prefix) 
    99         cd $(DESTDIR)$(prefix)/lib && for i in $$(find . -name 'libpj*a'); do\ 
    100                 ln -s $$i $$(echo $$i | sed -e "s/-$(TARGET_NAME)//");\ 
     100        for d in pjlib pjlib-util pjnath pjmedia pjsip; do \ 
     101                cp -RLf $$d/include/* $(DESTDIR)$(prefix)/include/; \ 
    101102        done 
    102103        mkdir -p $(DESTDIR)$(prefix)/lib/pkgconfig 
    103         sed -e "s!@PREFIX@!$(DESTDIR)$(prefix)!" libpj.pc.in > $(DESTDIR)/$(prefix)/lib/pkgconfig/libpj.pc 
     104        sed -e "s!@PREFIX@!$(DESTDIR)$(prefix)!" libpjproject.pc.in | \ 
     105                sed -e "s/@PJ_VERSION@/$(PJ_VERSION)/" | \ 
     106                sed -e "s!@PJ_LDLIBS@!$(PJ_LDLIBS)!" | \ 
     107                sed -e "s!@PJ_INSTALL_CFLAGS@!$(PJ_INSTALL_CFLAGS)!" > $(DESTDIR)/$(prefix)/lib/pkgconfig/libpjproject.pc 
Note: See TracChangeset for help on using the changeset viewer.