Ignore:
Timestamp:
Nov 23, 2013 7:13:40 AM (10 years ago)
Author:
bennylp
Message:

Fixed #1713: Enable building the libraries as shared libraries/DLLs for GNU targets

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip-apps/build/Samples.mak

    r4440 r4656  
    1  
     1include ../../build.mak 
     2include ../../version.mak 
    23include ../../build/common.mak 
    34 
     5RULES_MAK := $(PJDIR)/build/rules.mak 
    46 
    57############################################################################### 
     
    1719           aviplay \ 
    1820           aectest \ 
    19            aviplay \ 
    2021           clidemo \ 
    2122           confsample \ 
     
    4647           vid_streamutil 
    4748 
    48 EXES := $(foreach file, $(SAMPLES), $(BINDIR)/$(file)$(HOST_EXE)) 
     49EXES := $(foreach file, $(SAMPLES), $(file)$(HOST_EXE)) 
    4950 
    50 all: $(BINDIR) $(OBJDIR) $(EXES) 
     51.PHONY: $(EXES) 
    5152 
    52 $(BINDIR)/%$(HOST_EXE): $(OBJDIR)/%$(OBJEXT) $(PJ_LIB_FILES) 
    53         $(LD) $(LDOUT)$(subst /,$(HOST_PSEP),$@) \ 
    54             $(subst /,$(HOST_PSEP),$<) \ 
    55             $(_LDFLAGS) 
     53all: $(EXES) 
    5654 
    57 $(OBJDIR)/%$(OBJEXT): $(SRCDIR)/%.c 
    58         $(CC) $(_CFLAGS) \ 
    59           $(CC_OUT)$(subst /,$(HOST_PSEP),$@) \ 
    60           $(subst /,$(HOST_PSEP),$<)  
    61  
    62 $(OBJDIR): 
    63         $(subst @@,$(subst /,$(HOST_PSEP),$@),$(HOST_MKDIR))  
    64  
    65 $(BINDIR): 
    66         $(subst @@,$(subst /,$(HOST_PSEP),$@),$(HOST_MKDIR))  
     55$(EXES): 
     56        $(MAKE) --no-print-directory -f $(RULES_MAK) SAMPLE_SRCDIR=$(SRCDIR) SAMPLE_OBJS=$@.o SAMPLE_CFLAGS="$(_CFLAGS)" SAMPLE_LDFLAGS="$(_LDFLAGS)" SAMPLE_EXE=$@ APP=SAMPLE app=sample $(subst /,$(HOST_PSEP),$(BINDIR)/$@) 
    6757 
    6858depend: 
    6959 
    7060clean: 
    71         $(subst @@,$(subst /,$(HOST_PSEP),$(OBJDIR)/*),$(HOST_RMR)) 
    72         $(subst @@,$(subst /,$(HOST_PSEP),$(OBJDIR)),$(HOST_RMDIR)) 
     61        $(MAKE) -f $(RULES_MAK) APP=SAMPLE app=sample $@ 
    7362        $(subst @@,$(EXES),$(HOST_RM)) 
    74         rm -rf $(BINDIR) 
     63        $(subst @@,$(BINDIR),$(HOST_RMDIR)) 
    7564 
    7665distclean realclean: clean 
    77 #       $(subst @@,$(subst /,$(HOST_PSEP),$(EXES)) $(subst /,$(HOST_PSEP),$(EXES)),$(HOST_RM)) 
    78 #       $(subst @@,$(DEP_FILE),$(HOST_RM)) 
     66        $(MAKE) -f $(RULES_MAK) APP=SAMPLE app=sample $@ 
    7967 
Note: See TracChangeset for help on using the changeset viewer.