[5296] in Athena Bugs

home help back first fref pref prev next nref lref last post

Imake.rules: depend:: should depend on $(SRCS)

daemon@ATHENA.MIT.EDU (Jonathan I. Kamens)
Tue Jun 26 21:55:10 1990

Date: Tue, 26 Jun 90 21:54:47 -0400
From: "Jonathan I. Kamens" <jik@pit-manager.MIT.EDU>
To: xbugs@expo.lcs.mit.edu
Cc: bugs@ATHENA.MIT.EDU


			  X Window System Bug Report
			    xbugs@expo.lcs.mit.edu


VERSION:
    R4

CLIENT MACHINE and OPERATING SYSTEM:
    NA

DISPLAY TYPE:
    NA

WINDOW MANAGER:
    NA

AREA:
    config

SYNOPSIS:
    In Imake.rules, the depend:: rule should depend on $(SRCS).

DESCRIPTION:
    There are some .c files which are generated, rather than being
    real source files, e.g. y.tab.c.  These files should be included
    when makedepend is run; however, a make clean often delete them.
    Therefore, the depend rule should depend on all source files it is
    going to try to access, so that they will be regenerated
    automatically.

REPEAT BY:
    Write a makefile that contains an automatically generated C file,
    and add it to the list of SRCS in an Imakefile; build the makefile
    and try to do make depend without first generating the C file.

SAMPLE FIX:
    Patch below.

Jonathan Kamens			              USnail:
MIT Project Athena				11 Ashford Terrace
jik@Athena.MIT.EDU				Allston, MA  02134
Office: 617-253-8495			      Home: 617-782-0710

*** /tmp/,RCSt1001330	Tue Jun 26 21:54:37 1990
--- Imake.rules	Tue Jun 26 21:51:09 1990
***************
*** 543,549 ****
  #define	DependTarget()							@@\
  DependDependency()							@@\
  									@@\
! depend::								@@\
  	$(DEPEND) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- $(SRCS)
  #endif /* DependTarget */
  
--- 543,549 ----
  #define	DependTarget()							@@\
  DependDependency()							@@\
  									@@\
! depend:: $(SRCS)							@@\
  	$(DEPEND) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- $(SRCS)
  #endif /* DependTarget */
  


home help back first fref pref prev next nref lref last post