frech@mwraaa.army.mil (Norman R. Frech CPLS) (10/20/90)
I am having problems with the make depend for patchlevel 36. I get the following: Make: Must be a sperator on rules line 122. Stop. Stop. Error code 1 I had to use the -l switch on patches 29-36 and I also did a 1,$s/ /^I/g on the Makefile which helped a little but not enough. Any Suggestions? Norm Frech < frech@mwraaa.army.mil >
ling@uunet.UU.NET (Ling Kan) (03/16/91)
Just out of curiosity, has anyone wrote a makedepend in perl? Name: Ling Kan Tel: (503) 690-1386 mail: CADRE Technologies Inc. e-mail: sun!nosun!cadreor!ling 19545 N.W. Von Neumann Drive FAX: (503) 690-1320 Beaverton, OR 97006
lwall@jpl-devvax.jpl.nasa.gov (Larry Wall) (03/16/91)
In article <1991Mar16.032210.16252@uvaarpa.Virginia.EDU> uwm!ogicse!cadreor!ling@uunet.UU.NET (Ling Kan) writes:
: Just out of curiosity, has anyone wrote a makedepend in perl?
Look at the w4 program in the book, pg 273.
Why do I feel like a Scientology ad?
Larry
merlyn@iwarp.intel.com (Randal L. Schwartz) (03/17/91)
In article <1991Mar16.035028.2799@jpl-devvax.jpl.nasa.gov>, lwall@jpl-devvax (Larry Wall) writes: | Look at the w4 program in the book, pg 273. Or download ftp.uu.net:/nutshell/perl/perl.tar.Z and look at ch6/w4, if your bookstore is all out of The Book (highly possible... it's in its second printing already!). $_ = "just another perl hacker,"; s/([jp])/\u\1/g; print -- /=Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095 ==========\ | on contract to Intel's iWarp project, Beaverton, Oregon, USA, Sol III | | merlyn@iwarp.intel.com ...!any-MX-mailer-like-uunet!iwarp.intel.com!merlyn | \=Cute Quote: "Intel: putting the 'backward' in 'backward compatible'..."====/
dlee@pallas.athenanet.com (Doug Lee) (03/18/91)
In article <1991Mar16.032210.16252@uvaarpa.Virginia.EDU> uwm!ogicse!cadreor!ling@uunet.UU.NET (Ling Kan) writes: >Just out of curiosity, has anyone wrote a makedepend in perl? I wrote a perl script called ``mkdep'' in November of '90 and posted it (I forgot in which group). A net.safe version of the man page follows: ------------------------------------------------------------------ MKDEP(1) UNIX System V (LOCAL COMMANDS) MKDEP(1) NAME mkdep - Automatic makefile dependency list generator SYNOPSIS mkdep [ -d ] [ -s[include_dir] ] [ list_file ... ] DESCRIPTION mkdep is a perl script which takes a list of C source files on stdin and sends to stdout a list of dependencies for each corresponding object file in a format suitable for inclusion in a makefile. Files listed as dependencies are also scanned for dependencies of their own, and any files found in this way are also listed as dependencies of the object file. File inclusions of virtually unlimited depth are handled properly, and no file will be listed as a dependency more than once, regardless of how often it is referenced. The dependency lists produced by mkdep appear in the order of a ``breadth-first'' search. Thus, all files listed as dependencies of directly included files will be listed after ALL files which are directly included. This permits mkdep to trace complicated dependency relationships while never needing more than one file open at a time. By default, a standard header file (one referenced via ``#include <...>'') is not listed as a dependency and is not scanned for dependencies of its own. See the -s option below. mkdep can be invoked directly from a shell on most systems, since it is set up to run itself through perl if necessary. However, perl must be accessible for mkdep to run. OPTIONS The following options are recognized by mkdep: -d Debugging output. Sends a progress report to stderr. -s Consider standard header files in addition to ``local'' headers. This will also cause standard header files referenced to be scanned for dependencies. Probably not necessary unless your system is extremely dynamic. The directory containing standard header files (/usr/include by default) may be given as an argument. list_file Use one or more list files rather than stdin for the list of source files to check. If multiple filenames are given, the final list will be formed by concatenating all specified files. (This is actually a side effect of mkdep's being written in perl, since this is part of perl's command line syntax.) EXAMPLES Consider the following files. For simplicity, assume that global.h does not make any inclusions of its own. a.c: #include <stdio.h> #include "global.h" #include "a.h" /* code ... */ b.c: #include <stdio.h> #include <errno.h> #include "global.h" #include "b.h" /* code ... */ a.h: #include <signal.h> /* ... */ b.h: #include "global.h" /* Redundant but common */ /* ... */ If mkdep is run with the names ``a.c'' and ``b.c'' passed as the standard input, the following output results: a.o: a.c global.h a.h b.o: b.c global.h b.h If the -s option is used, the output will be similar to the following (depending on the local standard header files): a.o: a.c /usr/include/stdio.h global.h a.h /usr/include/signal.h /usr/include/sys/signal.h b.o: b.c /usr/include/stdio.h /usr/include/errno.h global.h b.h /usr/include/sys/errno.h (There are only two lines of output; they were split above for easier printing.) In the latter example, the files /usr/include/sys/errno.h and /usr/include/sys/signal.h appear because they were referenced by the files /usr/include/errno.h and /usr/include/signal.h, respectively. BUGS At this writing, conditionals are not recognized; thus, if a file is included conditionally, it WILL be listed as a dependency in all cases. If an infinite dependency loop exists, mkdep will simply list the dependencies without comment. mkdep is not intended to verify the consistency of file dependencies. ACKNOWLEDGEMENTS Thanks to Larry Wall, the author of perl, for providing a language powerful enough to do this and many other similar tasks without requiring an inordinate amount of programming time. Thanks also to the author of the Getopts routine, a modified version of which appears at the end of mkdep. (Unfortunately, the author's name was not included in the version of Getopts available here; perhaps it was Larry wall again.) ------------------------------------------------------------------ -- Doug Lee (dlee@athenanet.com or {bradley,uunet}!pallas!dlee)
dboles@ccwf.cc.utexas.edu (David Boles) (03/19/91)
-- ------------------------------------------------------------------------------- David Boles Applied Research Laboratories dboles@ccwf.cc.utexas.edu DOS is severely brain-damaged, apas611@chpc.utexas.edu so just pull the plug and let it DIE. -------------------------------------------------------------------------------
rbj@uunet.UU.NET (Root Boy Jim) (03/19/91)
In article <1037@pallas.athenanet.com> dlee@pallas.athenanet.com (Doug Lee) writes: >In article <1991Mar16.032210.16252@uvaarpa.Virginia.EDU> uwm!ogicse!cadreor!ling@uunet.UU.NET (Ling Kan) writes: >>Just out of curiosity, has anyone wrote a makedepend in perl? > >I wrote a perl script called ``mkdep'' in November of '90 and posted it >(I forgot in which group). A net.safe version of the man page follows: You can't call it mkdep. Berkeley has a shell script by the same name. And X11 has a program called makedepend. If you want to use one of these names, you should emulate its behavior. There is no sense in reinventing the wheel. And that includes you too, Larry. Much better is to grab one of these and pass it around. I also feel the same way about Larry's install scripts. What's wrong with the BSD install script? Just make it a part of your distribution rather than rolling your own. -- [rbj@uunet 1] stty sane unknown mode: sane
gpvos@cs.vu.nl (Gerben 'P' Vos) (03/20/91)
uwm!ogicse!cadreor!ling@uunet.UU.NET (Ling Kan) writes: >Just out of curiosity, has anyone wrote a makedepend in perl? Just for the record: i wrote a "genmake" for Modula-2. In perl, of course. - Gerben -- --- Gerben Vos - Aconet: BIGBEN!Gerben Vos - Internet: gpvos@cs.vu.nl <>< ---- The question if a computer can think is as interesting as the question if ----- a submarine can swim. -- E. Dijkstra