swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Application specific include and library directories


From: Rick Riolo
Subject: Re: Application specific include and library directories
Date: Mon, 4 May 1998 07:22:44 -0400 (EDT)

Just fyi, I approached this problem a little differently:

1) I get the includes in by this in my application Makefile:

include $(SWARMHOME)/Makefile.appl
# this next line MUST be after the include above!
OTHERINCDIRS+=-I$(EXPTOOLSPATH)

2) And I get the application libs by explicitly giving the path
   to them:

APPLIBS=-lspace $(EXPTOOLSPATH)/libUM-ExpTools-4.a

I think your approach is a bit nicer (assuming it or some
version of it gets back into the swarm distribution).

 - r

Rick Riolo                           address@hidden
Program for Study of Complex Systems (PSCS)
4068 Randall Lab                
University of Michigan         Ann Arbor MI 48109-1120
Phone: 313 763 3323                  Fax: 313 763 9267
http://www.pscs.umich.edu/PEOPLE/rlr-home.html

On Mon, 4 May 1998, Rob Kewley wrote:

> Date: Mon, 04 May 1998 06:17:35 -0400
> From: Rob Kewley <address@hidden>
> To: address@hidden
> Subject: Application specific include and library directories
> 
> I have added a couple of lines to an application Makefile and
> Makefile.conf which make it easy to link a swarm application against an
> existing library (without having to edit OTHERINCDIRS and OTHERLIBDIRS)
> in Makefile.conf each time.  These changes along with a couple lines of
> instruction may be a useful addition to the Swarm distribution.
> 
> I added the variable APPLIBDIRS and APPINCDIRS to Makefile as shown
> below:
> 
> SWARMHOME=/usr/local/swarm-1.0.5
> APPLICATION=battle
> OBJECTS=Location.o MilMap.o BatSummary.o Order.o Coa.o UnitOrg.o
> TaskOrg.o UnitCdr.o BattleStats.o BatModSwarm.o Combatant.o
> BatObsSwarm.o CoaGenome.o MapDisplay.o GraphicControlMeasure.o
> PointGraphic.o PolygonGCM.o main.o DynMatrix.o trig.o
> APPLIBS= -lspace -lmylib /home/kewler/GCTP/gctpc/source/geolib.a
> APPINCDIRS= -I/home/kewler/GCTP/gctpc/source/
> APPLIBDIRS=
> include $(SWARMHOME)/Makefile.appl
> 
> ...
> 
> I edited line 469 of Makefile.conf as follows:
> 
> CFLAGS=       $(OPTFLAGS) $(WARNFLAGS) -I$(INCDIR) $(OTHERINCDIRS)
> $(APPINCDIRS) $(EXTRACFLAGS)
> 
> 
> and line 480 as follows:
> 
> MINLDFLAGS=   -L$(LIBDIR) $(OTHERLIBDIRS) $(APPLIBDIRS) $(EXTRALDFLAGS)
> 
> Rob Kewley
> 
>                   ==================================
>    Swarm-Support is for discussion of the technical details of the day
>    to day usage of Swarm.  For list administration needs (esp.
>    [un]subscribing), please send a message to <address@hidden>
>    with "help" in the body of the message.
>                   ==================================
> 

                  ==================================
   Swarm-Support is for discussion of the technical details of the day
   to day usage of Swarm.  For list administration needs (esp.
   [un]subscribing), please send a message to <address@hidden>
   with "help" in the body of the message.
                  ==================================


reply via email to

[Prev in Thread] Current Thread [Next in Thread]