bnicholes    2002/10/16 16:53:03

  Modified:    build    NWGNUtail.inc NWGNUmakefile NWGNUenvironment.inc
               .        NWGNUmakefile
  Added:       build    nw_ver.awk
  Log:
  Adding the current version string to the link of each NLM
  
  Revision  Changes    Path
  1.4       +16 -1     apr/build/NWGNUtail.inc
  
  Index: NWGNUtail.inc
  ===================================================================
  RCS file: /home/cvs/apr/build/NWGNUtail.inc,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- NWGNUtail.inc     26 Sep 2002 20:16:27 -0000      1.3
  +++ NWGNUtail.inc     16 Oct 2002 23:53:03 -0000      1.4
  @@ -52,6 +52,7 @@
                                NWGNUmakefile \
                                $(APR_WORK)\build\NWGNUtail.inc \
                                $(CUSTOM_INI) \
  +                             $(VERSION_INC) \
                                $(EOLIST)
   
   ifeq "$(words $(strip $(TARGET_lib)))" "1"
  @@ -79,6 +80,20 @@
   # Generic compiler rules
   #
   
  +$(APR_WORK)\build\NWGNUversion.inc : $(APR_WORK)\include\apr_version.h 
$(APR_WORK)\build\nw_ver.awk
  +     @echo Generating $(subst /,\,$@)
  +     awk -f $(APR_WORK)\build\nw_ver.awk $(APR_WORK)\include\apr_version.h > 
$(APR_WORK)\build\NWGNUversion.inc
  +
  +-include $(APR_WORK)\build\NWGNUversion.inc
  +
  +ifneq "$(strip $(VERSION_STR))" ""
  +VERSION_INC = $(APR_WORK)\build\NWGNUversion.inc
  +else
  +VERSION              = 1,0,0
  +VERSION_STR  = 1.0.0
  +endif
  +
  +
   $(OBJDIR)/%.o: %.c $(OBJDIR)\cc.opt
        @echo Compiling $<
        $(CC) $< -o=$(OBJDIR)\$(@F) @$(OBJDIR)\cc.opt
  @@ -275,7 +290,7 @@
   
   ifndef NO_LICENSE_FILE
   
  -$(OBJDIR)/%.nlm: NWGNU% $(APR_WORK)\build\NWGNUhead.inc 
$(APR_WORK)\build\NWGNUtail.inc $(APR_WORK)\build\NWGNUenvironment.inc 
$(CUSTOM_INI) FORCE
  +$(OBJDIR)/%.nlm: NWGNU% $(APR_WORK)\build\NWGNUhead.inc 
$(APR_WORK)\build\NWGNUtail.inc $(APR_WORK)\build\NWGNUenvironment.inc 
$(CUSTOM_INI) $(VERSION_INC) FORCE
        @echo Calling $<
        $(MAKE) -f $< $(MAKECMDGOALS) RELEASE=$(RELEASE)
        $(CMD) echo.
  
  
  
  1.2       +1 -0      apr/build/NWGNUmakefile
  
  Index: NWGNUmakefile
  ===================================================================
  RCS file: /home/cvs/apr/build/NWGNUmakefile,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- NWGNUmakefile     1 Mar 2002 22:25:26 -0000       1.1
  +++ NWGNUmakefile     16 Oct 2002 23:53:03 -0000      1.2
  @@ -78,6 +78,7 @@
   clean ::
        $(CHK) nw_export.i                                              $(DEL) 
nw_export.i
        $(CHK) cc.opt                                                   $(DEL) 
cc.opt
  +     $(CHK) NWGNUversion.inc                                         $(DEL) 
NWGNUversion.inc 
        $(CHK) $(subst /,\,$(APR))\include\apr.h                        $(DEL) 
$(subst /,\,$(APR))\include\apr.h
        $(CHK) $(subst /,\,$(APRUTIL))\include\apu.h                    $(DEL) 
$(subst /,\,$(APRUTIL))\include\apu.h
        $(CHK) $(subst /,\,$(APRUTIL))\include\apr_ldap.h               $(DEL) 
$(subst /,\,$(APRUTIL))\include\apr_ldap.h
  
  
  
  1.6       +0 -1      apr/build/NWGNUenvironment.inc
  
  Index: NWGNUenvironment.inc
  ===================================================================
  RCS file: /home/cvs/apr/build/NWGNUenvironment.inc,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- NWGNUenvironment.inc      26 Sep 2002 20:16:27 -0000      1.5
  +++ NWGNUenvironment.inc      16 Oct 2002 23:53:03 -0000      1.6
  @@ -254,7 +254,6 @@
   #
   # Additional general defines
   #
  -VERSION              = 2,0,0
   
   EnvironmentDefined = 1
   endif # ifndef EnvironmentDefined
  
  
  
  1.1                  apr/build/nw_ver.awk
  
  Index: nw_ver.awk
  ===================================================================
  BEGIN {
  
    # fetch APR version numbers from input file and writes them to STDOUT
  
    while ((getline < ARGV[1]) > 0) {
      if (match ($0, /^#define APR_MAJOR_VERSION/)) {
        ver_major = $3;
      }
      else if (match ($0, /^#define APR_MINOR_VERSION/)) {
        ver_minor = $3;
      }
      else if (match ($0, /^#define APR_PATCH_VERSION/)) {
        ver_str_patch = $3;
        if (match (ver_str_patch, /[0-9][0-9]*/)) {
           ver_patch = substr(ver_str_patch, RSTART, RLENGTH); 
        }
      }
    }
    ver = ver_major "," ver_minor "," ver_patch;
    ver_str = ver_major "." ver_minor "." ver_str_patch;
  
    print "VERSION = " ver "";
    print "VERSION_STR = " ver_str "";
  
  }
  
  
  
  1.10      +1 -1      apr/NWGNUmakefile
  
  Index: NWGNUmakefile
  ===================================================================
  RCS file: /home/cvs/apr/NWGNUmakefile,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- NWGNUmakefile     19 Jul 2002 19:47:39 -0000      1.9
  +++ NWGNUmakefile     16 Oct 2002 23:53:03 -0000      1.10
  @@ -108,7 +108,7 @@
   # This is used by the link '-desc ' directive. 
   # If left blank, NLM_NAME will be used.
   #
  -NLM_DESCRIPTION      = Apache Portability Runtime Library
  +NLM_DESCRIPTION      = Apache Portability Runtime Library $(VERSION_STR)
   
   #
   # This is used by the '-threadname' directive.  If left blank,
  
  
  

Reply via email to