🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.interviews
Article #1518

Re: Need help compiling InterViews 3.0-beta

#1518
From: David D. Loeffler
Date: Mon, 24 Jun 1991 13:19
102 lines
4520 bytes
Well I would like to thank two people, Charles Garrett and Brian Kennedy
for their replies.  They read my rather mangled message (written after
fighting too may sysadmin fires here) and sent solutions which I am
posting below.  I used Brian's second option just to finish compiling
the IV-X11 library.  That is, I added the +i option for compiling and
ran "make all" all in that directory only.  This finished the compile
of the library.  Now I am running make all from the iv directory and
all seems to be going well.  If I do run into a problem I will setenv
APP_CCDEFINES to +i in the offending directory and continue.  The
reason many of the compiles failed later was because the IV-X11 lib
did not exist.


-----------------------------------------------------------------------------
    Full-Name: Charles Garrett
    To: loeffler@MCC.COM
    Subject: Re: Need help compiling InterViews 3.0-beta
    Organization: Yale University Computer Science Dept., New Haven, CT 06520-2158


    Hi,

	    Your problem reminds me of one that I had when compiling some
    large C++ files. The problem is that the cfront program creates an
    intermediate C file with lots of #line declarations for cpp to handle.
    In fact some programs will have so many #line declarations that cpp
    will crash. I worked around this problem by writing a shell script that
    removes #line declarations from files before passing them to the C
    compiler. Then I defined the environment variable ccC to call this
    script. When ccC is defined, the C++ compiler will use it rather than
    the regular cc command. I can't be sure that your problem is the
    same one, but it might be something similar, so I will enclose the
    files I wrote for this workaround.

    --------- file mycc ---------

    for A do
	    case $A in
	    *.c)
		    if test -f $A
		    then
			    awk -f awkfile < $A > temp
			    mv temp $A
		    fi;;
	    esac
    done

    cc $*

    --------- file awkfile --------

    $1 != "#line" {print}
    $1 == "#line" && $3 !~ /sweeper|usr|InterViews/ {print}

    -------------------------------

    Then do:
	    setenv ccC mycc


    Good luck,
	    Charlie Garrett

-----------------------------------------------------------------------------

    To: loeffler@bluebell.aca.mcc.com (David D. Loeffler)
    Cc: bmk@csc.ti.com
    Subject: Re: Need help compiling InterViews 3.0-beta
    Date: Fri, 21 Jun 91 15:57:27 -0500
    From: Brian M Kennedy <bmk@ninja.csc.ti.com>

    David,

    This is almost becoming a faq for Sun users.  The cpp shipped with
    SunOS 4.0.3 can only handle a certain number of #line directives.
    Your alternatives are:

	    1) Ask Sun for a copy of the SunOS 4.1 version of cpp.
	       This version has a much higher limit, which I have hit
	       but I'm sure InterViews would not.

	    2) Compile with option +i.  This option is designed to
	       produce the intermediate C file; however, it has the
	       fortunate side-effect of eliminating all #line directives.

	    3) Get Sun CC 2.1 -- I highly recommend this if you do much
	       C++ work at all.  This version is much more stable, has
	       much higher arbitrary limits, and works very well with its
	       dbx and dbxtool (which runs under X now).  Note that it is
	       a much better release than 2.0 was.

	    4) Use GNU cc as your backend C compiler (by setting the ccC
	       environment variable to the full pathname of gcc).
	       GNU cc has no bogus, arbitrary limits.

    Hope this helps,

    == Brian M. Kennedy <bmk@csc.ti.com> ==
    == Computer Systems Laboratory ========
    == Computer Science Center ============
    == Texas Instruments ==================
Technical Details
Message-ID: <LOEFFLER.91Jun24081951@bluebell.aca.mcc.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!cs.utexas.edu!radar!bluebell!bluebell.aca.mcc.com!loeffler
References: <LOEFFLER.91Jun21111300@bluebell.aca.mcc.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!cs.utexas.edu!radar!bluebell!bluebell.aca.mcc.com!loeffler
From: loeffler@bluebell.aca.mcc.com (David D. Loeffler)
Newsgroups: comp.windows.interviews
Subject: Re: Need help compiling InterViews 3.0-beta
Message-ID: <LOEFFLER.91Jun24081951@bluebell.aca.mcc.com>
Date: 24 Jun 91 13:19:51 GMT
References: <LOEFFLER.91Jun21111300@bluebell.aca.mcc.com>
Sender: loeffler@bluebell.ACA.MCC.COM
Reply-To: "David D. Loeffler" <loeffler@MCC.COM>
Distribution: comp.windows.interviews
Organization: MCC, Austin, TX 78759, U.S.A
Lines: 102
In-reply-to: loeffler@bluebell.aca.mcc.com's message of 21 Jun 91 16:13:00 GMT