From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11002 invoked by alias); 15 Dec 2010 13:55:30 -0000 Received: (qmail 10992 invoked by uid 22791); 15 Dec 2010 13:55:29 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from chiark.greenend.org.uk (HELO chiark.greenend.org.uk) (212.13.197.229) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 15 Dec 2010 13:55:24 +0000 Received: by chiark.greenend.org.uk (Debian Exim 4.69 #1) with local (return-path ryounger@chiark.greenend.org.uk) id 1PSrpC-0005KN-AO for ecos-maintainers@ecos.sourceware.org; Wed, 15 Dec 2010 13:55:22 +0000 Date: Wed, 15 Dec 2010 13:55:00 -0000 From: Ross Younger To: ecos-maintainers@ecos.sourceware.org Subject: FAQ suggestions Message-ID: <20101215135522.GB12170@chiark.greenend.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Mailing-List: contact ecos-maintainers-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: ecos-maintainers-owner@ecos.sourceware.org X-SW-Source: 2010-12/txt/msg00000.txt.bz2 Hi all, two suggestions come to mind following ecos-discuss yesterday and today: Q. My build fails with "undefined reference to `puts'" (or similar) A. Usually, when your build fails due to a missing library function, the function is present within eCos but has not been selected in your build configuration. For example, building the hello world example might fail with: .../ecos-3.0/examples/hello.c:6: undefined reference to `puts' In this case, puts can be found in the ISO C standard I/O library package. To successfully use it, you need to either: * use a template which includes the required packages ("default" is a good place to start in most cases) or * manually add the stdio package (and the packages it depends on) to your existing configuration. ~~~~~~~~~~~~~~~ Q. I selected the "kernel" or "minimal" configuration to make my build smaller, but now my application won't build. A. Your build size is really a feature of your application, not of eCos itself. eCos uses a linker feature called link-time garbage collection. This means that library functions not used by your application do not get built into your final image. Because of this, the "kernel" and "minimal" configurations are often unhelpful: they switch off many library functions, often leading to requests for help from developers surprised that their applications no longer build. Most applications should start with the "default" template (or one of "net", "lwip_eth" or "lwip_ppp" if networking is required). We recommend that you first build your application and see what size of image it gives: only then, should you start looking at tuning it (and your eCos configuration) for size. ~~~~~~~~~~~~~~~ Cheers, Ross