Print this page
6117 Many small bugs prevent a clean build on SPARC

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/sgs/lex/Makefile.com
          +++ new/usr/src/cmd/sgs/lex/Makefile.com
↓ open down ↓ 11 lines elided ↑ open up ↑
  12   12  #
  13   13  # When distributing Covered Code, include this CDDL HEADER in each
  14   14  # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15  # If applicable, add the following below this CDDL HEADER, with the
  16   16  # fields enclosed by brackets "[]" replaced with your own identifying
  17   17  # information: Portions Copyright [yyyy] [name of copyright owner]
  18   18  #
  19   19  # CDDL HEADER END
  20   20  #
  21   21  #
       22 +# Copyright 2015 Gary Mills
  22   23  # Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
  23   24  # Use is subject to license terms.
  24   25  #
  25   26  
  26   27  PROG=           lex
  27   28  
  28   29  MACHOBJS=       main.o sub1.o sub2.o sub3.o header.o parser.o
  29   30  POBJECTS=       $(MACHOBJS)
  30   31  POBJS=          $(POBJECTS:%=objs/%)
  31   32  
↓ open down ↓ 19 lines elided ↑ open up ↑
  51   52  
  52   53  # Override default source file derivation rule (in Makefile.lib)
  53   54  # from objects
  54   55  #
  55   56  MACHSRCS=       $(MACHOBJS:%.o=../common/%.c)
  56   57  LIBSRCS =       $(LIBOBJS:%.o=../common/%.c)
  57   58  SRCS=           $(MACHSRCS) $(LIBSRCS)
  58   59  
  59   60  LIBS =          $(DYNLIB) $(LINTLIB)
  60   61  
       62 +# Append to LINTFLAGS and LINTFLAGS64 from lib/Makefile.lib
       63 +LINTFLAGS +=    -erroff=E_NAME_MULTIPLY_DEF2 -erroff=E_FUNC_RET_MAYBE_IGNORED2
       64 +LINTFLAGS64 +=  -erroff=E_NAME_MULTIPLY_DEF2 -erroff=E_FUNC_RET_MAYBE_IGNORED2
       65 +
  61   66  LINTSRCS=       ../common/llib-l$(LIBNAME)
       67 +$(LINTLIB):=    SRCS = $(SRCDIR)/$(LINTSRC)
  62   68  
  63   69  INCLIST=        $(INCLIST_$(MACH)) -I../../include -I../../include/$(MACH)
  64   70  DEFLIST=        -DELF
  65   71  
  66   72  # It is not very clean to base the conditional definitions as below, but
  67   73  # this will have to do for now.
  68   74  #
  69   75  #$(LIBOBJS_W):= DEFLIST = -DEUC -DJLSLEX  -DWOPTION -D$*=$*_w
  70   76  objs/%_w.o:=    DEFLIST = -DEUC -DJLSLEX  -DWOPTION -D$*=$*_w
  71   77  pics/%_w.o:=    DEFLIST = -DEUC -DJLSLEX  -DWOPTION -D$*=$*_w
  72   78  
  73   79  #$(LIBOBJS_E):= DEFLIST = -DEUC -DJLSLEX  -DEOPTION -D$*=$*_e
  74   80  objs/%_e.o:=    DEFLIST = -DEUC -DJLSLEX  -DEOPTION -D$*=$*_e
  75   81  pics/%_e.o:=    DEFLIST = -DEUC -DJLSLEX  -DEOPTION -D$*=$*_e
  76   82  
  77   83  CPPFLAGS=       $(INCLIST) $(DEFLIST) $(CPPFLAGS.master)
  78   84  BUILD.AR=       $(AR) $(ARFLAGS) $@ `$(LORDER) $(OBJS) | $(TSORT)`
  79      -LINTFLAGS=      -amux
       85 +
  80   86  LINTPOUT=       lint.out
  81   87  
  82      -$(LINTLIB):=    LINTFLAGS = -nvx
  83   88  $(ROOTPROG):=   FILEMODE = 0555
  84   89  
  85   90  ROOTFORMS=      $(FORMS:%=$(ROOTSHLIBCCS)/%)
  86   91  
  87   92  ROOTLINTDIR=    $(ROOTLIBDIR)
  88   93  ROOTLINT=       $(LINTSRCS:../common/%=$(ROOTLINTDIR)/%)
  89   94  
  90   95  DYNLINKLIBDIR=  $(ROOTLIBDIR)
  91   96  DYNLINKLIB=     $(LIBLINKS:%=$(DYNLINKLIBDIR)/%)
  92   97  
  93   98  # Need to make sure lib-make's are warning free
  94   99  $(DYNLIB) :=    CFLAGS += $(CCVERBOSE)
  95  100  $(DYNLIB) :=    CFLAGS64 += $(CCVERBOSE)
  96  101  
  97      -$(DYNLIB) :=    LDLIBS += -lc
      102 +LDLIBS += -lc
  98  103  
  99  104  CLEANFILES +=   ../common/parser.c $(LINTPOUT)
 100  105  CLOBBERFILES += $(LIBS) $(LIBRARY)
      106 +
      107 +lint: lintcheck
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX