*BSD News Article 92442


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!munnari.OZ.AU!news.ecn.uoknor.edu!feed1.news.erols.com!cpk-news-hub1.bbnplanet.com!news.bbnplanet.com!cyclic.gsl.net!news.gsl.net!gsl-stkh-ns.gsl.net!news.gsl.net!eru.mt.luth.se!newsfeed2.luth.se!news.luth.se!not-for-mail
From: Joachim Strömbergson <watchman@ludd.luth.se>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: How are Includes found? (problems with gdbm)
Date: Sun, 30 Mar 1997 10:07:35 -0800
Organization: Acne
Lines: 30
Message-ID: <333EABE7.15C4@ludd.luth.se>
Reply-To: watchman@ludd.luth.se
NNTP-Posting-Host: my21.sm.luth.se
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
X-Mailer: Mozilla 3.0 (Win95; I)
Xref: euryale.cc.adfa.oz.au comp.unix.bsd.freebsd.misc:38161

Tja!

This might be a very embarrasing question; What path variables are used
when you compile a program in FreeBD. Let's say that I have a program
like this:

[kalle.c]
#include <stdio.h>
main() {
  printf("Kalle rewls\n");
}

and I compile this with 'gcc kalle.c'.

Now, how does the compiler go about to find stdio.h ? Can I control
where it should look? The specific problem I have is that I have
installed gdbm with the ports collection. When I try to compile stuff
that uses gdbm, they can't find it (it is in /usr/local/include).

Any help greatly appreciated.

-- 
Cheers!
Joachim - Alltid i harmonisk svängning
--------------------------------------------------------
Joachim Strömbergson  MSc Student, nice to CUTE animals.
Porsögården 24:6    PC    e-mail : watchman@ludd.luth.se
977 54 Luleå       C64       phone: +46(0)920 - 22 16 42
Sweden         -FairLight-   alt:   +46(0)10 - 22 10 543
--------------------------------------------------------