From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21138 invoked by alias); 18 Sep 2013 13:18:50 -0000 Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Received: (qmail 21126 invoked by uid 89); 18 Sep 2013 13:18:50 -0000 Received: from mail-pb0-f68.google.com (HELO mail-pb0-f68.google.com) (209.85.160.68) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Wed, 18 Sep 2013 13:18:50 +0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,KHOP_THREADED,NO_RELAYS autolearn=ham version=3.3.2 X-HELO: mail-pb0-f68.google.com Received: by mail-pb0-f68.google.com with SMTP id rq2so3194264pbb.3 for ; Wed, 18 Sep 2013 06:18:47 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.66.162.167 with SMTP id yb7mr43367831pab.16.1379510327056; Wed, 18 Sep 2013 06:18:47 -0700 (PDT) Received: by 10.70.130.66 with HTTP; Wed, 18 Sep 2013 06:18:46 -0700 (PDT) In-Reply-To: <5238697B.4090205@cetoni.de> References: <5238697B.4090205@cetoni.de> Date: Wed, 18 Sep 2013 13:18:00 -0000 Message-ID: From: Jabran Bhatti To: cetoni GmbH - Uwe Kindler Cc: eCos Discussion Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Subject: [ECOS] Re: Building C++ application for eCos on ARM X-SW-Source: 2013-09/txt/msg00008.txt.bz2 Hello John/cetoni, Thanks for your replies. * I tried the stl compatibility layer solution and all goes well until I get the following error: /usr/local/include/ptlib/critsec.h:37:30: fatal error: ext/atomicity.h: No such file or directory It appears that the ptlib library also requires header files that are actually extensions of STL (header files in the folder ext/). These extensions are not defined in ustl, which means this solution will not work. Am I right? * I also tried to build a toolchain including Erik Aagaard Knudsen's libstdc++ for eCos (as described in the file eCos_libstdcxx_compatibility/libstdcxx_compatibility.eak). Here, I encountered the following problem: when configuring GCC (4.3.2.), I get a warning that most of the options such as --enable-languages, --with-gnu-as, --with-gnu-ld, --with-newlib,... are not recognized. When i try to build and install GCC next, I get a whole bunch of assembler messages as follows: /usr/src/gcc-4.3.2/libiberty/regex.c: In function =91xregerror=92: /usr/src/gcc-4.3.2/libiberty/regex.c:8089: warning: implicit declaration of function =91mempcpy=92 /usr/src/gcc-4.3.2/libiberty/regex.c:8089: warning: incompatible implicit declaration of built-in function =91mempcpy=92 /tmp/ccNe5Dme.s: Assembler messages: /tmp/ccNe5Dme.s:5991: Error: r13 not allowed here -- `lsr r3,sp,#3' /tmp/ccNe5Dme.s:6498: Error: r13 not allowed here -- `rsb sp,r3,sp' /tmp/ccNe5Dme.s:6500: Error: r13 not allowed here -- `lsr r0,sp,#3' I think these errors might be caused by a conflict between my native GCC compiler (4.8) and gcc-4.3.2. So I tried to install gcc-4.3.2 on my machine (32-bit ubuntu 12.04) from source (since it's no longer available on aptitude). Here, I encountered a known bug in the linker step (https://bugs.launchpad.net/ubuntu/+source/binutils/+bug/738098). The workaround described here didn't work for me. What do you guys think? 2013/9/17 cetoni GmbH - Uwe Kindler : > Hi, > > we also had an own library that uses stl and we managed to build it for e= Cos > uSTL. We did the following > > 1. > We created an stl compatibility layer: a folder that contains the stl > include files for eCos: > vector > string > map > ... > > 2. > Each of these include files contains the same content - it simply includes > ustl_compat.h file > > #ifndef ustl_compat_vectorH > #define ustl_compat_vectorH > #include "ustl_compat.h" > > #endif > > 3. > The ustl_compat.h file contains the following code: > > #ifndef ustl_compatH > #define ustl_compatH > #include > > #define std ustl > > #endif // ustl_compatH > > > So it simply includes the ustl.h header file and defines the preprocessor > macro std. So each occurence of std::vector will be replaced by ustl::vec= tor > > This worked for us and we could compile the library. > > > > > -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss