From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 114228 invoked by alias); 7 Jan 2019 20:50:47 -0000 Mailing-List: contact newlib-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: newlib-owner@sourceware.org Received: (qmail 114217 invoked by uid 89); 7 Jan 2019 20:50:46 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=BAYES_00,HTML_MESSAGE,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE autolearn=no version=3.3.2 spammy=H*c:alternative, noticed, somewhere, advise X-HELO: mail-io1-f50.google.com Received: from mail-io1-f50.google.com (HELO mail-io1-f50.google.com) (209.85.166.50) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 07 Jan 2019 20:50:45 +0000 Received: by mail-io1-f50.google.com with SMTP id x6so1441432ioa.9 for ; Mon, 07 Jan 2019 12:50:44 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Jeff Johnston Date: Mon, 07 Jan 2019 20:50:00 -0000 Message-ID: Subject: Re: Properly building newlib to install spec files To: Mojca Miklavec Cc: Newlib Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2019/txt/msg00004.txt.bz2 If you build and install the various components to the same installation directory, it should just work. See: https://gist.github.com/resetnow/1b55beed32f3eb3f90513896565ef5c0 (your gcc compiler config options may vary) If a spec file is installed somewhere else, you can use the -B option on the compile to specify a location for gcc to look for it. -- Jeff J. On Sat, Jan 5, 2019 at 4:20 PM Mojca Miklavec wrote: > Hi, > > I'm fixing some packages for a package manager. I think I have a bunch > of various working gcc crosscompilers, but if I try to test something > like > > $ msp430-elf-gcc -mmcu=msp430g2211 -specs=nosys.specs -o test.elf test.c > msp430-elf-gcc: error: nosys.specs: No such file or directory > > apparently the specs files are missing. > > I'm creating a symlink from gcc to newlib and build gcc with > --with-newlib, but apparently the files don't get installed. I noticed > that random instructions suggest separately building: > - first gcc > - then newlib > - then gcc again > http://www.ifp.illinois.edu/~nakazato/tips/xgcc.html#gccagain > > while other instructions say to use just --with-newlib. > > Can you please advise me how to build newlib in a proper way, so that > the spec files will be installed? Where should they usually end up? > > Thank you very much, > Mojca >