This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Small #include question


On Tue, Oct 22, 2002 at 11:15:19AM -0400, Cusson, Pascal wrote:
> Hi everyone,

> I am starting to write my Ethernet driver. From the ecos
> documentation, it says the only file I need to include is network.h.

For network application code, ie using sockets etc, you should only
need network.h. For device drivers you need many more header files. eg
the i82559 driver includes

#include <pkgconf/system.h>
#ifdef CYGPKG_IO_ETH_DRIVERS
#include <pkgconf/io_eth_drivers.h>
#endif
#include <pkgconf/devs_eth_intel_i82559.h>
 
#include <cyg/infra/cyg_type.h>
#include <cyg/infra/cyg_ass.h>
#include <cyg/hal/hal_arch.h>
#include <cyg/hal/hal_intr.h>
#include <cyg/infra/diag.h>
#include <cyg/hal/hal_if.h>
#include <cyg/hal/drv_api.h>
#include <cyg/io/eth/netdev.h>
#include <cyg/io/eth/eth_drv.h>

> However When I include the file, I get I bunch of errors ( .h files
> not found). In my ecos build, I include NET and OPENBSD. Do I need
> to include a different file or do I need to include more packages
> ???

You also need net_drivers. This is the basic ethernet driver
framework.

        Andrew

-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]