Matrisberäkningar med för STM32?

PIC, AVR, Arduino, Raspberry Pi, Basic Stamp, PLC mm.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

mankan skrev:Al, om du läste på och tog till dig de råd du fått tidigare i tråden, istället för att byta riktning så fort du stöter på ett problem likt en flipperkula så skulle det säkert gå mycket enklare. Du verkar fortfarande sakna basala kunskaper om korskompilering, t.o.m. om länkning osv.

Vad jag kan se och som andra redan sagt så är inte Makefilerna i det projekt du försöker bygga anpassade för korskompilering. Så jag ser två möjliga alternativ. 1. Fixa Makefilerna. 2. Knuffa in alla inblandade källkodsfiler inklusive din användning av biblioteket i ett projekt i Eclipse och pilla med lite include-pathar så kanske du får ihop något.
Det är inte så lätt när man är nybörjare.

Jag håller nu på att göra om makefilerna. Jag har redan stött på att kommandon så som ld och mv gillar inte kompilatorerna för ARM.

Annars så var det JAG som sade det fetmarkerade. Så du kanske bör ta och läsa bättre.
Senast redigerad av Al_Bundy 14 februari 2019, 17:25:54, redigerad totalt 1 gång.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

Jag tror jag är på väg en bit. Jag använder arm-none-eabi-gcc istället för arm-atollic-eabi-gcc.

Kod: Markera allt

dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE exit_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE getarg_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE iargc_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE getenv_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE signal_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_stop.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_paus.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE system_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE cabs.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE ctype.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE derf_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE derfc_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE erf_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE erfc_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE sig_die.c
arm-none-eabi-gcc -O3 -I../../INCLUDE -DNO_FPINIT arithchk.c -lm ||\
 arm-none-eabi-gcc -DNO_LONG_LONG -O3 -I../../INCLUDE -DNO_FPINIT arithchk.c -lm
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-exit.o): In function `exit':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/stdlib/../../../../../newlib/libc/stdlib/exit.c:70: undefined reference to `_exit'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-sbrkr.o): In function `_sbrk_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/sbrkr.c:58: undefined reference to `_sbrk'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-writer.o): In function `_write_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/writer.c:58: undefined reference to `_write'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-closer.o): In function `_close_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/closer.c:53: undefined reference to `_close'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-fstatr.o): In function `_fstat_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/fstatr.c:62: undefined reference to `_fstat'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-isattyr.o): In function `_isatty_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/isattyr.c:58: undefined reference to `_isatty'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-lseekr.o): In function `_lseek_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/lseekr.c:58: undefined reference to `_lseek'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-readr.o): In function `_read_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/readr.c:58: undefined reference to `_read'
collect2: error: ld returned 1 exit status
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-exit.o): In function `exit':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/stdlib/../../../../../newlib/libc/stdlib/exit.c:70: undefined reference to `_exit'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-sbrkr.o): In function `_sbrk_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/sbrkr.c:58: undefined reference to `_sbrk'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-writer.o): In function `_write_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/writer.c:58: undefined reference to `_write'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-closer.o): In function `_close_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/closer.c:53: undefined reference to `_close'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-fstatr.o): In function `_fstat_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/fstatr.c:62: undefined reference to `_fstat'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-isattyr.o): In function `_isatty_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/isattyr.c:58: undefined reference to `_isatty'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-lseekr.o): In function `_lseek_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/lseekr.c:58: undefined reference to `_lseek'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-readr.o): In function `_read_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/readr.c:58: undefined reference to `_read'
collect2: error: ld returned 1 exit status
Makefile:184: recipe for target 'arith.h' failed
make[1]: *** [arith.h] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ 
Användarvisningsbild
mankan
EF Sponsor
Inlägg: 905
Blev medlem: 18 juli 2015, 11:23:22
Ort: Linköping

Re: Matrisberäkningar med för STM32?

Inlägg av mankan »

Jag vet att du försökte köra allt i ett Eclipseprojekt men du gav ju upp direkt :D

Nu verkar du ha kompilerat kod som innehåller filrelaterade funktioner, verkar inte rätt för STM32.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

Jadu...nu är jag helt borta. Kanske lika bra att jag får köra på PC trots allt? Jag menar, Jag har ju C-koden kvar med CLapack och det fungerar fint med beräkningarna. Helt nöjd med biblioteket.
bearing
Inlägg: 11229
Blev medlem: 2 mars 2006, 01:01:45
Ort: Ängelholm

Re: Matrisberäkningar med för STM32?

Inlägg av bearing »

Al_Bundy skrev:Jag tror jag är på väg en bit. Jag använder arm-none-eabi-gcc istället för arm-atollic-eabi-gcc.

Kod: Markera allt

dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE exit_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE getarg_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE iargc_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE getenv_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE signal_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_stop.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_paus.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE system_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE cabs.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE ctype.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE derf_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE derfc_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE erf_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE erfc_.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE sig_die.c
arm-none-eabi-gcc -O3 -I../../INCLUDE -DNO_FPINIT arithchk.c -lm ||\
 arm-none-eabi-gcc -DNO_LONG_LONG -O3 -I../../INCLUDE -DNO_FPINIT arithchk.c -lm
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-exit.o): In function `exit':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/stdlib/../../../../../newlib/libc/stdlib/exit.c:70: undefined reference to `_exit'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-sbrkr.o): In function `_sbrk_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/sbrkr.c:58: undefined reference to `_sbrk'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-writer.o): In function `_write_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/writer.c:58: undefined reference to `_write'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-closer.o): In function `_close_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/closer.c:53: undefined reference to `_close'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-fstatr.o): In function `_fstat_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/fstatr.c:62: undefined reference to `_fstat'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-isattyr.o): In function `_isatty_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/isattyr.c:58: undefined reference to `_isatty'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-lseekr.o): In function `_lseek_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/lseekr.c:58: undefined reference to `_lseek'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-readr.o): In function `_read_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/readr.c:58: undefined reference to `_read'
collect2: error: ld returned 1 exit status
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-exit.o): In function `exit':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/stdlib/../../../../../newlib/libc/stdlib/exit.c:70: undefined reference to `_exit'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-sbrkr.o): In function `_sbrk_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/sbrkr.c:58: undefined reference to `_sbrk'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-writer.o): In function `_write_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/writer.c:58: undefined reference to `_write'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-closer.o): In function `_close_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/closer.c:53: undefined reference to `_close'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-fstatr.o): In function `_fstat_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/fstatr.c:62: undefined reference to `_fstat'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-isattyr.o): In function `_isatty_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/isattyr.c:58: undefined reference to `_isatty'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-lseekr.o): In function `_lseek_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/lseekr.c:58: undefined reference to `_lseek'
/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/libc.a(lib_a-readr.o): In function `_read_r':
/build/newlib-8gJlYR/newlib-2.4.0.20160527/build/arm-none-eabi/newlib/libc/reent/../../../../../newlib/libc/reent/readr.c:58: undefined reference to `_read'
collect2: error: ld returned 1 exit status
Makefile:184: recipe for target 'arith.h' failed
make[1]: *** [arith.h] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ 
Du har antagligen inte någon _exit rutin osv. Du har ju inte ett linux-system på din MCU
https://linux.die.net/man/2/_exit

Kanske går att lägga till ett gäng tomma funktioner för att få en definition av dessa operativssystemsgrejerna (funktioner som börjar med underscore).

Det här tyckte jag så skumt ut. "Pipear" man alltså outputen från en kompilering in en annan kompilering (av samma fil?)

Kod: Markera allt

arm-none-eabi-gcc -O3 -I../../INCLUDE -DNO_FPINIT arithchk.c -lm ||\
 arm-none-eabi-gcc -DNO_LONG_LONG -O3 -I../../INCLUDE -DNO_FPINIT arithchk.c -lm
Användarvisningsbild
ahlsten
Inlägg: 659
Blev medlem: 12 november 2005, 00:24:14
Ort: Uppsala

Re: Matrisberäkningar med för STM32?

Inlägg av ahlsten »

Nä, det är || dvs or, om första kommandot returnerar felkod så körs det andra. Funktionen blir att först försöka utan --DNO_LONG_LONG och om det inte går läggs den växeln till.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

Inte en dum idé faktiskt! Jag undrar hur jag ska skriva denna kod. Hur som helst så verkar arm-none-eabi-arm fungera bra att kompilera med, jämfört med arm-artollic-eabi-arm, som endast ger felmeddelanden för ingen nytta alls. Hur arm-none-eabi-arm fungerar med STM32 vet jag inte.

I filen Makefile i mappen F2CLIB -> libf2c så finns det ett dokument som man ska ändra på, från detta.

Kod: Markera allt

# compile, then strip unnecessary symbols
.c.o:
	$(CC) -c -DSkip_f2c_Undefs $(CFLAGS) $*.c
	ld -r -x -o $*.xxx $*.o
	mv $*.xxx $*.o
## Under Solaris (and other systems that do not understand ld -x),
## omit -x in the ld line above.
## If your system does not have the ld command, comment out
## or remove both the ld and mv lines above.
Till

Kod: Markera allt

# compile, then strip unnecessary symbols
.c.o:
	$(CC) -c -DSkip_f2c_Undefs $(CFLAGS) $*.c
	ld -r -x -o $*.c $*.o
	mv $*.c $*.o
## Under Solaris (and other systems that do not understand ld -x),
## omit -x in the ld line above.
## If your system does not have the ld command, comment out
## or remove both the ld and mv lines above.
Då har man eliminerat bort ett problem.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

Efter man har fixat ordning det jag beskrev ovan, så är det dags för att gå igenom denna fil. Denna fil är viktig för den skapar en fil som heter "arith.h". Men som sagt, arm-none-eabi-gcc kan inte läsa och skriva till filer för det är anpassat för inbyggda system. Är det någon som har ett förslag på vad man kan göra?

Ett alternativ är att länka tillsammans så att filen "arith.h" kan skapas.

Kod: Markera allt

/****************************************************************
Copyright (C) 1997, 1998, 2000 Lucent Technologies
All Rights Reserved

Permission to use, copy, modify, and distribute this software and
its documentation for any purpose and without fee is hereby
granted, provided that the above copyright notice appear in all
copies and that both that the copyright notice and this
permission notice and warranty disclaimer appear in supporting
documentation, and that the name of Lucent or any of its entities
not be used in advertising or publicity pertaining to
distribution of the software without specific, written prior
permission.

LUCENT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS.
IN NO EVENT SHALL LUCENT OR ANY OF ITS ENTITIES BE LIABLE FOR ANY
SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER
IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
THIS SOFTWARE.
****************************************************************/

/* Try to deduce arith.h from arithmetic properties. */

#include <stdio.h>
#include <math.h>
#include <errno.h>

#ifdef NO_FPINIT
#define fpinit_ASL()
#else
#ifndef KR_headers
extern
#ifdef __cplusplus
	"C"
#endif
	void fpinit_ASL(void);
#endif /*KR_headers*/
#endif /*NO_FPINIT*/

 static int dalign;
 typedef struct
Akind {
	char *name;
	int   kind;
	} Akind;

 static Akind
IEEE_8087	= { "IEEE_8087", 1 },
IEEE_MC68k	= { "IEEE_MC68k", 2 },
IBM		= { "IBM", 3 },
VAX		= { "VAX", 4 },
CRAY		= { "CRAY", 5};

 static double t_nan;

 static Akind *
Lcheck(void)
{
	union {
		double d;
		long L[2];
		} u;
	struct {
		double d;
		long L;
		} x[2];

	if (sizeof(x) > 2*(sizeof(double) + sizeof(long)))
		dalign = 1;
	u.L[0] = u.L[1] = 0;
	u.d = 1e13;
	if (u.L[0] == 1117925532 && u.L[1] == -448790528)
		return &IEEE_MC68k;
	if (u.L[1] == 1117925532 && u.L[0] == -448790528)
		return &IEEE_8087;
	if (u.L[0] == -2065213935 && u.L[1] == 10752)
		return &VAX;
	if (u.L[0] == 1267827943 && u.L[1] == 704643072)
		return &IBM;
	return 0;
	}

 static Akind *
icheck(void)
{
	union {
		double d;
		int L[2];
		} u;
	struct {
		double d;
		int L;
		} x[2];

	if (sizeof(x) > 2*(sizeof(double) + sizeof(int)))
		dalign = 1;
	u.L[0] = u.L[1] = 0;
	u.d = 1e13;
	if (u.L[0] == 1117925532 && u.L[1] == -448790528)
		return &IEEE_MC68k;
	if (u.L[1] == 1117925532 && u.L[0] == -448790528)
		return &IEEE_8087;
	if (u.L[0] == -2065213935 && u.L[1] == 10752)
		return &VAX;
	if (u.L[0] == 1267827943 && u.L[1] == 704643072)
		return &IBM;
	return 0;
	}

char *emptyfmt = "";	/* avoid possible warning message with printf("") */

 static Akind *
ccheck(void)
{
	union {
		double d;
		long L;
		} u;
	long Cray1;

	/* Cray1 = 4617762693716115456 -- without overflow on non-Crays */
	Cray1 = printf(emptyfmt) < 0 ? 0 : 4617762;
	if (printf(emptyfmt, Cray1) >= 0)
		Cray1 = 1000000*Cray1 + 693716;
	if (printf(emptyfmt, Cray1) >= 0)
		Cray1 = 1000000*Cray1 + 115456;
	u.d = 1e13;
	if (u.L == Cray1)
		return &CRAY;
	return 0;
	}

 static int
fzcheck(void)
{
	double a, b;
	int i;

	a = 1.;
	b = .1;
	for(i = 155;; b *= b, i >>= 1) {
		if (i & 1) {
			a *= b;
			if (i == 1)
				break;
			}
		}
	b = a * a;
	return b == 0.;
	}

 static int
need_nancheck(void)
{
	double t;

	errno = 0;
	t = log(t_nan);
	if (errno == 0)
		return 1;
	errno = 0;
	t = sqrt(t_nan);
	return errno == 0;
	}

 void
get_nanbits(unsigned int *b, int k)
{
	union { double d; unsigned int z[2]; } u, u1, u2;

	k = 2 - k;
	u1.z[k] = u2.z[k] = 0x7ff00000;
	u1.z[1-k] = u2.z[1-k] = 0;
	u.d = u1.d - u2.d;	/* Infinity - Infinity */
	b[0] = u.z[0];
	b[1] = u.z[1];
	}

 int
main(void)
{
	FILE *f;
	Akind *a = 0;
	int Ldef = 0;
	unsigned int nanbits[2];

	fpinit_ASL();
#ifdef WRITE_ARITH_H	/* for Symantec's buggy "make" */
	f = fopen("arith.h", "w");
	if (!f) {
		printf("Cannot open arith.h\n");
		return 1;
		}
#else
	f = stdout;
#endif

	if (sizeof(double) == 2*sizeof(long))
		a = Lcheck();
	else if (sizeof(double) == 2*sizeof(int)) {
		Ldef = 1;
		a = icheck();
		}
	else if (sizeof(double) == sizeof(long))
		a = ccheck();
	if (a) {
		fprintf(f, "#define %s\n#define Arith_Kind_ASL %d\n",
			a->name, a->kind);
		if (Ldef)
			fprintf(f, "#define Long int\n#define Intcast (int)(long)\n");
		if (dalign)
			fprintf(f, "#define Double_Align\n");
		if (sizeof(char*) == 8)
			fprintf(f, "#define X64_bit_pointers\n");
#ifndef NO_LONG_LONG
		if (sizeof(long long) < 8)
#endif
			fprintf(f, "#define NO_LONG_LONG\n");
		if (a->kind <= 2) {
			if (fzcheck())
				fprintf(f, "#define Sudden_Underflow\n");
			t_nan = -a->kind;
			if (need_nancheck())
				fprintf(f, "#define NANCHECK\n");
			if (sizeof(double) == 2*sizeof(unsigned int)) {
				get_nanbits(nanbits, a->kind);
				fprintf(f, "#define QNaN0 0x%x\n", nanbits[0]);
				fprintf(f, "#define QNaN1 0x%x\n", nanbits[1]);
				}
			}
		return 0;
		}
	fprintf(f, "/* Unknown arithmetic */\n");
	return 1;
	}

#ifdef __sun
#ifdef __i386
/* kludge for Intel Solaris */
void fpsetprec(int x) { }
#endif
#endif
bearing
Inlägg: 11229
Blev medlem: 2 mars 2006, 01:01:45
Ort: Ängelholm

Re: Matrisberäkningar med för STM32?

Inlägg av bearing »

Så makefilen kompilerar alltså ett program, och kör detta program, vars syfte är att skapa en h-fil?

Jag tycker att det låter som att den delen måste kompileras av din vanliga gcc i linux. Programmet kommer ju ändå inte kunna köras på din PC, eftersom att binären kommer bli för en ARM.

Eller om du bara kan kopiera filen från ditt linux-bygge?
IEEE 754 kommer tydligen från 8087. Så din PC kör antagligen samma flyttalsstandard som din ARM, och har nog skapat en h-filen som även funkar på din ARM. Sen vet jag inte om det finns andra detaljer i h-filen som är unika för just din PC och inte funkar på ARM, men du kan ju prova att bara kopiera filen iaf.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

bearing skrev:Så makefilen kompilerar alltså ett program, och kör detta program, vars syfte är att skapa en h-fil?
Jag vet inte vad syftet är. Koden är dåligt kommenterad.

Kod: Markera allt

Jag tycker att det låter som att den delen måste kompileras av din vanliga gcc i linux. Programmet kommer ju ändå inte kunna köras på din PC, eftersom att binären kommer bli för en ARM.
Det är alltså F2CLIB och BLAS som ska kompileras. F2CLIB är väll Fortran till C bibliotek och BLAS är väll typ hur linjär algebra fungerar i botten. Sedan Lapack är väll alla dessa stora funktioner så som LU, SVD, QR osv. Men i detta fall så komplimerar man F2CLIB och sedan BLAS och där efter länkar man lapack med -llapack. Så borde inte F2CLIB komplimeras med ARM också?

Kod: Markera allt

Eller om du bara kan kopiera filen från ditt linux-bygge?

Så här ser filen från mitt komplimerade Lapack för Linux.

Kod: Markera allt


#define IEEE_8087
#define Arith_Kind_ASL 1
#define Long int
#define Intcast (int)(long)
#define Double_Align
#define X64_bit_pointers
#define QNaN0 0x0
#define QNaN1 0xfff80000
Nu fungerar det! Men man fick köra typ så här hela tiden..

Kod: Markera allt

dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wref.c
ld -r -x -o wref.c wref.o
ld: wref.o: omlokaliseringar i vanlig ELF (EM: 40)
wref.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'wref.o' failed
make[1]: *** [wref.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wrtfmt.c
^[[Ald -r -x -o wrtfmt.c wrtfmt.o
ld: wrtfmt.o: omlokaliseringar i vanlig ELF (EM: 40)
wrtfmt.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'wrtfmt.o' failed
make[1]: *** [wrtfmt.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wsfe.c
ld -r -x -o wsfe.c wsfe.o
ld: wsfe.o: omlokaliseringar i vanlig ELF (EM: 40)
wsfe.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'wsfe.o' failed
make[1]: *** [wsfe.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wsle.c
ld -r -x -o wsle.c wsle.o
ld: wsle.o: omlokaliseringar i vanlig ELF (EM: 40)
wsle.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'wsle.o' failed
make[1]: *** [wsle.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wsne.c
ld -r -x -o wsne.c wsne.o
ld: wsne.o: omlokaliseringar i vanlig ELF (EM: 40)
wsne.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'wsne.o' failed
make[1]: *** [wsne.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE xwsne.c
ld -r -x -o xwsne.c xwsne.o
ld: xwsne.o: omlokaliseringar i vanlig ELF (EM: 40)
xwsne.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'xwsne.o' failed
make[1]: *** [xwsne.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE dtime_.c
ld -r -x -o dtime_.c dtime_.o
ld: dtime_.o: omlokaliseringar i vanlig ELF (EM: 40)
dtime_.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'dtime_.o' failed
make[1]: *** [dtime_.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE etime_.c
ld -r -x -o etime_.c etime_.o
ld: etime_.o: omlokaliseringar i vanlig ELF (EM: 40)
etime_.o: fel då symboler lades till: Filen är i fel format
Makefile:22: recipe for target 'etime_.o' failed
make[1]: *** [etime_.o] Error 1
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
Makefile:41: recipe for target 'f2clib' failed
make: *** [f2clib] Error 2
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
ar r libf2c.a f77vers.o i77vers.o main.o s_rnge.o abort_.o exit_.o getarg_.o iargc_.o getenv_.o signal_.o s_stop.o s_paus.o system_.o cabs.o ctype.o derf_.o derfc_.o erf_.o erfc_.o sig_die.o uninit.o pow_ci.o pow_dd.o pow_di.o pow_hh.o pow_ii.o pow_ri.o pow_zi.o pow_zz.o c_abs.o c_cos.o c_div.o c_exp.o c_log.o c_sin.o c_sqrt.o z_abs.o z_cos.o z_div.o z_exp.o z_log.o z_sin.o z_sqrt.o r_abs.o r_acos.o r_asin.o r_atan.o r_atn2.o r_cnjg.o r_cos.o r_cosh.o r_dim.o r_exp.o r_imag.o r_int.o r_lg10.o r_log.o r_mod.o r_nint.o r_sign.o r_sin.o r_sinh.o r_sqrt.o r_tan.o r_tanh.o d_abs.o d_acos.o d_asin.o d_atan.o d_atn2.o d_cnjg.o d_cos.o d_cosh.o d_dim.o d_exp.o d_imag.o d_int.o d_lg10.o d_log.o d_mod.o d_nint.o d_prod.o d_sign.o d_sin.o d_sinh.o d_sqrt.o d_tan.o d_tanh.o i_abs.o i_dim.o i_dnnt.o i_indx.o i_len.o i_len_trim.o i_mod.o i_nint.o i_sign.o lbitbits.o lbitshft.o i_ceiling.o h_abs.o h_dim.o h_dnnt.o h_indx.o h_len.o h_mod.o h_nint.o h_sign.o l_ge.o l_gt.o l_le.o l_lt.o hl_ge.o hl_gt.o hl_le.o hl_lt.o ef1asc_.o ef1cmc_.o f77_aloc.o s_cat.o s_cmp.o s_copy.o backspac.o close.o dfe.o dolio.o due.o endfile.o err.o fmt.o fmtlib.o ftell_.o iio.o ilnw.o inquire.o lread.o lwrite.o open.o rdfmt.o rewind.o rsfe.o rsli.o rsne.o sfe.o sue.o typesize.o uio.o util.o wref.o wrtfmt.o wsfe.o wsle.o wsne.o xwsne.o dtime_.o etime_.o
ar: skapar libf2c.a
ranlib libf2c.a
mv libf2c.a ..
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$
bearing
Inlägg: 11229
Blev medlem: 2 mars 2006, 01:01:45
Ort: Ängelholm

Re: Matrisberäkningar med för STM32?

Inlägg av bearing »

Kod: Markera allt

#define Double_Align
#define X64_bit_pointers
Dom här är nog inte lämpliga på din ARM

Men nu är det kompilerat med 64-bits flyttal?

Om libbet kommer funka efter alla dom byggfelen är väl osäkert. Men jag avvaktar och ser vad andra säger.

(Har du någon sorts autokorrigering som ändrar kompilerat till komplimerat?)
bearing
Inlägg: 11229
Blev medlem: 2 mars 2006, 01:01:45
Ort: Ängelholm

Re: Matrisberäkningar med för STM32?

Inlägg av bearing »

Och var det inte så att vi föreslog att byta ut
gcc till arm-none-eabi-gcc
ld till arm-none-eabi-ld
ar till arm-none-eabi-ar

osv?

Du verkar bara ha bytt gcc.

Om det har någon betydelse för ar vet jag inte, men ld borde väl rimligtvis behöva vara för arm?
Mr Andersson
Inlägg: 1394
Blev medlem: 29 januari 2011, 21:06:30
Ort: Lapplandet

Re: Matrisberäkningar med för STM32?

Inlägg av Mr Andersson »

Nu fungerar det!
ld: wref.o: omlokaliseringar i vanlig ELF (EM: 40)
wref.o: fel då symboler lades till: Filen är i fel format
(gånger några hundra)
Konstig definition av fungerande :doubt:

Jag ger snart upp.. Det här blir tredje gången jag säger att du kan inte blanda verktyg för olika cpu-arkitekturer..
Byt alla ld till arm-none-eabi-ld
Gör sen samma sak för alla andra binärer som felar.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

Ok! Nu har jag kommit på en lösning för att komplimera F2CLIB för ARM.

Steg 1:
Packa upp clapack.tgz filen

Steg 2:
Gå till F2CLIBS -> libf2c

Steg 3:
Klistra in filen arith.h. Det finns olika saker att välja mellan. Jag har noll aning om vad som ska stå där. Jag har bara fått denna fil från när jag komplimerande för Ubuntu Linux som jag kör just nu. I filen arithchk.c som är bredvid arith.h, så kan man läsa vilka alternativ som finns.

Kod: Markera allt

#define IEEE_8087
#define Arith_Kind_ASL 1
#define Long int
#define Intcast (int)(long)
#define Double_Align
#define X64_bit_pointers
#define QNaN0 0x0
#define QNaN1 0xfff80000
Steg 4:
Ändra filen Make filen till. Här ska vi kommentera bort ld och mv.

Kod: Markera allt

# compile, then strip unnecessary symbols
.c.o:
	$(CC) -c -DSkip_f2c_Undefs $(CFLAGS) $*.c
	#ld -r -x -o $*.xxx $*.o
	#mv $*.xxx $*.o
## Under Solaris (and other systems that do not understand ld -x),
## omit -x in the ld line above.
## If your system does not have the ld command, comment out
## or remove both the ld and mv lines above.
Steg 5:
Ändra denna fil "make.inc" som finns i CLAPACK mappen till.

Kod: Markera allt

#######################################################
# This is used to compile C libary
CC        = arm-none-eabi-gcc
# if no wrapping of the blas library is needed, uncomment next line
#CC        = gcc -DNO_BLAS_WRAP
CFLAGS    = -O3 -I$(TOPDIR)/INCLUDE
LOADER    = arm-none-eabi-gcc
LOADOPTS  =
NOOPT     = -O0 -I$(TOPDIR)/INCLUDE
DRVCFLAGS = $(CFLAGS)
F2CCFLAGS = $(CFLAGS)
#######################################################################
Steg 6:
Öppna terminalen eller komandotolken och kör:

Kod: Markera allt

dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ make f2clib
( cd F2CLIBS/libf2c; make )
make[1]: Går till katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
arm-none-eabi-gcc -c f77vers.c
arm-none-eabi-gcc -c i77vers.c
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE main.c
#ld -r -x -o main.xxx main.o
#mv main.xxx main.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_rnge.c
#ld -r -x -o s_rnge.xxx s_rnge.o
#mv s_rnge.xxx s_rnge.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE abort_.c
#ld -r -x -o abort_.xxx abort_.o
#mv abort_.xxx abort_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE exit_.c
#ld -r -x -o exit_.xxx exit_.o
#mv exit_.xxx exit_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE getarg_.c
#ld -r -x -o getarg_.xxx getarg_.o
#mv getarg_.xxx getarg_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE iargc_.c
#ld -r -x -o iargc_.xxx iargc_.o
#mv iargc_.xxx iargc_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE getenv_.c
#ld -r -x -o getenv_.xxx getenv_.o
#mv getenv_.xxx getenv_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE signal_.c
#ld -r -x -o signal_.xxx signal_.o
#mv signal_.xxx signal_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_stop.c
#ld -r -x -o s_stop.xxx s_stop.o
#mv s_stop.xxx s_stop.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_paus.c
#ld -r -x -o s_paus.xxx s_paus.o
#mv s_paus.xxx s_paus.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE system_.c
#ld -r -x -o system_.xxx system_.o
#mv system_.xxx system_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE cabs.c
#ld -r -x -o cabs.xxx cabs.o
#mv cabs.xxx cabs.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE ctype.c
#ld -r -x -o ctype.xxx ctype.o
#mv ctype.xxx ctype.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE derf_.c
#ld -r -x -o derf_.xxx derf_.o
#mv derf_.xxx derf_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE derfc_.c
#ld -r -x -o derfc_.xxx derfc_.o
#mv derfc_.xxx derfc_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE erf_.c
#ld -r -x -o erf_.xxx erf_.o
#mv erf_.xxx erf_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE erfc_.c
#ld -r -x -o erfc_.xxx erfc_.o
#mv erfc_.xxx erfc_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE sig_die.c
#ld -r -x -o sig_die.xxx sig_die.o
#mv sig_die.xxx sig_die.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE uninit.c
#ld -r -x -o uninit.xxx uninit.o
#mv uninit.xxx uninit.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_ci.c
#ld -r -x -o pow_ci.xxx pow_ci.o
#mv pow_ci.xxx pow_ci.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_dd.c
#ld -r -x -o pow_dd.xxx pow_dd.o
#mv pow_dd.xxx pow_dd.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_di.c
#ld -r -x -o pow_di.xxx pow_di.o
#mv pow_di.xxx pow_di.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_hh.c
#ld -r -x -o pow_hh.xxx pow_hh.o
#mv pow_hh.xxx pow_hh.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_ii.c
#ld -r -x -o pow_ii.xxx pow_ii.o
#mv pow_ii.xxx pow_ii.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_ri.c
#ld -r -x -o pow_ri.xxx pow_ri.o
#mv pow_ri.xxx pow_ri.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_zi.c
#ld -r -x -o pow_zi.xxx pow_zi.o
#mv pow_zi.xxx pow_zi.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE pow_zz.c
#ld -r -x -o pow_zz.xxx pow_zz.o
#mv pow_zz.xxx pow_zz.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE c_abs.c
#ld -r -x -o c_abs.xxx c_abs.o
#mv c_abs.xxx c_abs.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE c_cos.c
#ld -r -x -o c_cos.xxx c_cos.o
#mv c_cos.xxx c_cos.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE c_div.c
#ld -r -x -o c_div.xxx c_div.o
#mv c_div.xxx c_div.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE c_exp.c
#ld -r -x -o c_exp.xxx c_exp.o
#mv c_exp.xxx c_exp.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE c_log.c
#ld -r -x -o c_log.xxx c_log.o
#mv c_log.xxx c_log.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE c_sin.c
#ld -r -x -o c_sin.xxx c_sin.o
#mv c_sin.xxx c_sin.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE c_sqrt.c
#ld -r -x -o c_sqrt.xxx c_sqrt.o
#mv c_sqrt.xxx c_sqrt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE z_abs.c
#ld -r -x -o z_abs.xxx z_abs.o
#mv z_abs.xxx z_abs.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE z_cos.c
#ld -r -x -o z_cos.xxx z_cos.o
#mv z_cos.xxx z_cos.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE z_div.c
#ld -r -x -o z_div.xxx z_div.o
#mv z_div.xxx z_div.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE z_exp.c
#ld -r -x -o z_exp.xxx z_exp.o
#mv z_exp.xxx z_exp.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE z_log.c
#ld -r -x -o z_log.xxx z_log.o
#mv z_log.xxx z_log.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE z_sin.c
#ld -r -x -o z_sin.xxx z_sin.o
#mv z_sin.xxx z_sin.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE z_sqrt.c
#ld -r -x -o z_sqrt.xxx z_sqrt.o
#mv z_sqrt.xxx z_sqrt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_abs.c
#ld -r -x -o r_abs.xxx r_abs.o
#mv r_abs.xxx r_abs.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_acos.c
#ld -r -x -o r_acos.xxx r_acos.o
#mv r_acos.xxx r_acos.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_asin.c
#ld -r -x -o r_asin.xxx r_asin.o
#mv r_asin.xxx r_asin.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_atan.c
#ld -r -x -o r_atan.xxx r_atan.o
#mv r_atan.xxx r_atan.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_atn2.c
#ld -r -x -o r_atn2.xxx r_atn2.o
#mv r_atn2.xxx r_atn2.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_cnjg.c
#ld -r -x -o r_cnjg.xxx r_cnjg.o
#mv r_cnjg.xxx r_cnjg.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_cos.c
#ld -r -x -o r_cos.xxx r_cos.o
#mv r_cos.xxx r_cos.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_cosh.c
#ld -r -x -o r_cosh.xxx r_cosh.o
#mv r_cosh.xxx r_cosh.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_dim.c
#ld -r -x -o r_dim.xxx r_dim.o
#mv r_dim.xxx r_dim.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_exp.c
#ld -r -x -o r_exp.xxx r_exp.o
#mv r_exp.xxx r_exp.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_imag.c
#ld -r -x -o r_imag.xxx r_imag.o
#mv r_imag.xxx r_imag.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_int.c
#ld -r -x -o r_int.xxx r_int.o
#mv r_int.xxx r_int.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_lg10.c
#ld -r -x -o r_lg10.xxx r_lg10.o
#mv r_lg10.xxx r_lg10.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_log.c
#ld -r -x -o r_log.xxx r_log.o
#mv r_log.xxx r_log.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_mod.c
#ld -r -x -o r_mod.xxx r_mod.o
#mv r_mod.xxx r_mod.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_nint.c
#ld -r -x -o r_nint.xxx r_nint.o
#mv r_nint.xxx r_nint.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_sign.c
#ld -r -x -o r_sign.xxx r_sign.o
#mv r_sign.xxx r_sign.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_sin.c
#ld -r -x -o r_sin.xxx r_sin.o
#mv r_sin.xxx r_sin.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_sinh.c
#ld -r -x -o r_sinh.xxx r_sinh.o
#mv r_sinh.xxx r_sinh.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_sqrt.c
#ld -r -x -o r_sqrt.xxx r_sqrt.o
#mv r_sqrt.xxx r_sqrt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_tan.c
#ld -r -x -o r_tan.xxx r_tan.o
#mv r_tan.xxx r_tan.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE r_tanh.c
#ld -r -x -o r_tanh.xxx r_tanh.o
#mv r_tanh.xxx r_tanh.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_abs.c
#ld -r -x -o d_abs.xxx d_abs.o
#mv d_abs.xxx d_abs.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_acos.c
#ld -r -x -o d_acos.xxx d_acos.o
#mv d_acos.xxx d_acos.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_asin.c
#ld -r -x -o d_asin.xxx d_asin.o
#mv d_asin.xxx d_asin.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_atan.c
#ld -r -x -o d_atan.xxx d_atan.o
#mv d_atan.xxx d_atan.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_atn2.c
#ld -r -x -o d_atn2.xxx d_atn2.o
#mv d_atn2.xxx d_atn2.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_cnjg.c
#ld -r -x -o d_cnjg.xxx d_cnjg.o
#mv d_cnjg.xxx d_cnjg.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_cos.c
#ld -r -x -o d_cos.xxx d_cos.o
#mv d_cos.xxx d_cos.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_cosh.c
#ld -r -x -o d_cosh.xxx d_cosh.o
#mv d_cosh.xxx d_cosh.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_dim.c
#ld -r -x -o d_dim.xxx d_dim.o
#mv d_dim.xxx d_dim.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_exp.c
#ld -r -x -o d_exp.xxx d_exp.o
#mv d_exp.xxx d_exp.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_imag.c
#ld -r -x -o d_imag.xxx d_imag.o
#mv d_imag.xxx d_imag.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_int.c
#ld -r -x -o d_int.xxx d_int.o
#mv d_int.xxx d_int.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_lg10.c
#ld -r -x -o d_lg10.xxx d_lg10.o
#mv d_lg10.xxx d_lg10.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_log.c
#ld -r -x -o d_log.xxx d_log.o
#mv d_log.xxx d_log.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_mod.c
#ld -r -x -o d_mod.xxx d_mod.o
#mv d_mod.xxx d_mod.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_nint.c
#ld -r -x -o d_nint.xxx d_nint.o
#mv d_nint.xxx d_nint.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_prod.c
#ld -r -x -o d_prod.xxx d_prod.o
#mv d_prod.xxx d_prod.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_sign.c
#ld -r -x -o d_sign.xxx d_sign.o
#mv d_sign.xxx d_sign.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_sin.c
#ld -r -x -o d_sin.xxx d_sin.o
#mv d_sin.xxx d_sin.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_sinh.c
#ld -r -x -o d_sinh.xxx d_sinh.o
#mv d_sinh.xxx d_sinh.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_sqrt.c
#ld -r -x -o d_sqrt.xxx d_sqrt.o
#mv d_sqrt.xxx d_sqrt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_tan.c
#ld -r -x -o d_tan.xxx d_tan.o
#mv d_tan.xxx d_tan.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE d_tanh.c
#ld -r -x -o d_tanh.xxx d_tanh.o
#mv d_tanh.xxx d_tanh.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_abs.c
#ld -r -x -o i_abs.xxx i_abs.o
#mv i_abs.xxx i_abs.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_dim.c
#ld -r -x -o i_dim.xxx i_dim.o
#mv i_dim.xxx i_dim.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_dnnt.c
#ld -r -x -o i_dnnt.xxx i_dnnt.o
#mv i_dnnt.xxx i_dnnt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_indx.c
#ld -r -x -o i_indx.xxx i_indx.o
#mv i_indx.xxx i_indx.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_len.c
#ld -r -x -o i_len.xxx i_len.o
#mv i_len.xxx i_len.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_len_trim.c
#ld -r -x -o i_len_trim.xxx i_len_trim.o
#mv i_len_trim.xxx i_len_trim.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_mod.c
#ld -r -x -o i_mod.xxx i_mod.o
#mv i_mod.xxx i_mod.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_nint.c
#ld -r -x -o i_nint.xxx i_nint.o
#mv i_nint.xxx i_nint.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_sign.c
#ld -r -x -o i_sign.xxx i_sign.o
#mv i_sign.xxx i_sign.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE lbitbits.c
#ld -r -x -o lbitbits.xxx lbitbits.o
#mv lbitbits.xxx lbitbits.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE lbitshft.c
#ld -r -x -o lbitshft.xxx lbitshft.o
#mv lbitshft.xxx lbitshft.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE i_ceiling.c
#ld -r -x -o i_ceiling.xxx i_ceiling.o
#mv i_ceiling.xxx i_ceiling.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_abs.c
#ld -r -x -o h_abs.xxx h_abs.o
#mv h_abs.xxx h_abs.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_dim.c
#ld -r -x -o h_dim.xxx h_dim.o
#mv h_dim.xxx h_dim.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_dnnt.c
#ld -r -x -o h_dnnt.xxx h_dnnt.o
#mv h_dnnt.xxx h_dnnt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_indx.c
#ld -r -x -o h_indx.xxx h_indx.o
#mv h_indx.xxx h_indx.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_len.c
#ld -r -x -o h_len.xxx h_len.o
#mv h_len.xxx h_len.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_mod.c
#ld -r -x -o h_mod.xxx h_mod.o
#mv h_mod.xxx h_mod.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_nint.c
#ld -r -x -o h_nint.xxx h_nint.o
#mv h_nint.xxx h_nint.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE h_sign.c
#ld -r -x -o h_sign.xxx h_sign.o
#mv h_sign.xxx h_sign.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE l_ge.c
#ld -r -x -o l_ge.xxx l_ge.o
#mv l_ge.xxx l_ge.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE l_gt.c
#ld -r -x -o l_gt.xxx l_gt.o
#mv l_gt.xxx l_gt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE l_le.c
#ld -r -x -o l_le.xxx l_le.o
#mv l_le.xxx l_le.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE l_lt.c
#ld -r -x -o l_lt.xxx l_lt.o
#mv l_lt.xxx l_lt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE hl_ge.c
#ld -r -x -o hl_ge.xxx hl_ge.o
#mv hl_ge.xxx hl_ge.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE hl_gt.c
#ld -r -x -o hl_gt.xxx hl_gt.o
#mv hl_gt.xxx hl_gt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE hl_le.c
#ld -r -x -o hl_le.xxx hl_le.o
#mv hl_le.xxx hl_le.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE hl_lt.c
#ld -r -x -o hl_lt.xxx hl_lt.o
#mv hl_lt.xxx hl_lt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE ef1asc_.c
#ld -r -x -o ef1asc_.xxx ef1asc_.o
#mv ef1asc_.xxx ef1asc_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE ef1cmc_.c
#ld -r -x -o ef1cmc_.xxx ef1cmc_.o
#mv ef1cmc_.xxx ef1cmc_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE f77_aloc.c
#ld -r -x -o f77_aloc.xxx f77_aloc.o
#mv f77_aloc.xxx f77_aloc.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_cat.c
#ld -r -x -o s_cat.xxx s_cat.o
#mv s_cat.xxx s_cat.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_cmp.c
#ld -r -x -o s_cmp.xxx s_cmp.o
#mv s_cmp.xxx s_cmp.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE s_copy.c
#ld -r -x -o s_copy.xxx s_copy.o
#mv s_copy.xxx s_copy.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE backspac.c
#ld -r -x -o backspac.xxx backspac.o
#mv backspac.xxx backspac.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE close.c
#ld -r -x -o close.xxx close.o
#mv close.xxx close.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE dfe.c
#ld -r -x -o dfe.xxx dfe.o
#mv dfe.xxx dfe.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE dolio.c
#ld -r -x -o dolio.xxx dolio.o
#mv dolio.xxx dolio.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE due.c
#ld -r -x -o due.xxx due.o
#mv due.xxx due.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE endfile.c
#ld -r -x -o endfile.xxx endfile.o
#mv endfile.xxx endfile.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE err.c
#ld -r -x -o err.xxx err.o
#mv err.xxx err.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE fmt.c
#ld -r -x -o fmt.xxx fmt.o
#mv fmt.xxx fmt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE fmtlib.c
#ld -r -x -o fmtlib.xxx fmtlib.o
#mv fmtlib.xxx fmtlib.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE ftell_.c
#ld -r -x -o ftell_.xxx ftell_.o
#mv ftell_.xxx ftell_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE iio.c
#ld -r -x -o iio.xxx iio.o
#mv iio.xxx iio.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE ilnw.c
#ld -r -x -o ilnw.xxx ilnw.o
#mv ilnw.xxx ilnw.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE inquire.c
#ld -r -x -o inquire.xxx inquire.o
#mv inquire.xxx inquire.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE lread.c
#ld -r -x -o lread.xxx lread.o
#mv lread.xxx lread.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE lwrite.c
#ld -r -x -o lwrite.xxx lwrite.o
#mv lwrite.xxx lwrite.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE open.c
#ld -r -x -o open.xxx open.o
#mv open.xxx open.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE rdfmt.c
#ld -r -x -o rdfmt.xxx rdfmt.o
#mv rdfmt.xxx rdfmt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE rewind.c
#ld -r -x -o rewind.xxx rewind.o
#mv rewind.xxx rewind.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE rsfe.c
#ld -r -x -o rsfe.xxx rsfe.o
#mv rsfe.xxx rsfe.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE rsli.c
#ld -r -x -o rsli.xxx rsli.o
#mv rsli.xxx rsli.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE rsne.c
#ld -r -x -o rsne.xxx rsne.o
#mv rsne.xxx rsne.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE sfe.c
#ld -r -x -o sfe.xxx sfe.o
#mv sfe.xxx sfe.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE sue.c
#ld -r -x -o sue.xxx sue.o
#mv sue.xxx sue.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE typesize.c
#ld -r -x -o typesize.xxx typesize.o
#mv typesize.xxx typesize.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE uio.c
#ld -r -x -o uio.xxx uio.o
#mv uio.xxx uio.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE util.c
#ld -r -x -o util.xxx util.o
#mv util.xxx util.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wref.c
#ld -r -x -o wref.xxx wref.o
#mv wref.xxx wref.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wrtfmt.c
#ld -r -x -o wrtfmt.xxx wrtfmt.o
#mv wrtfmt.xxx wrtfmt.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wsfe.c
#ld -r -x -o wsfe.xxx wsfe.o
#mv wsfe.xxx wsfe.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wsle.c
#ld -r -x -o wsle.xxx wsle.o
#mv wsle.xxx wsle.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE wsne.c
#ld -r -x -o wsne.xxx wsne.o
#mv wsne.xxx wsne.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE xwsne.c
#ld -r -x -o xwsne.xxx xwsne.o
#mv xwsne.xxx xwsne.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE dtime_.c
#ld -r -x -o dtime_.xxx dtime_.o
#mv dtime_.xxx dtime_.o
arm-none-eabi-gcc -c -DSkip_f2c_Undefs -O3 -I../../INCLUDE etime_.c
#ld -r -x -o etime_.xxx etime_.o
#mv etime_.xxx etime_.o
ar r libf2c.a f77vers.o i77vers.o main.o s_rnge.o abort_.o exit_.o getarg_.o iargc_.o getenv_.o signal_.o s_stop.o s_paus.o system_.o cabs.o ctype.o derf_.o derfc_.o erf_.o erfc_.o sig_die.o uninit.o pow_ci.o pow_dd.o pow_di.o pow_hh.o pow_ii.o pow_ri.o pow_zi.o pow_zz.o c_abs.o c_cos.o c_div.o c_exp.o c_log.o c_sin.o c_sqrt.o z_abs.o z_cos.o z_div.o z_exp.o z_log.o z_sin.o z_sqrt.o r_abs.o r_acos.o r_asin.o r_atan.o r_atn2.o r_cnjg.o r_cos.o r_cosh.o r_dim.o r_exp.o r_imag.o r_int.o r_lg10.o r_log.o r_mod.o r_nint.o r_sign.o r_sin.o r_sinh.o r_sqrt.o r_tan.o r_tanh.o d_abs.o d_acos.o d_asin.o d_atan.o d_atn2.o d_cnjg.o d_cos.o d_cosh.o d_dim.o d_exp.o d_imag.o d_int.o d_lg10.o d_log.o d_mod.o d_nint.o d_prod.o d_sign.o d_sin.o d_sinh.o d_sqrt.o d_tan.o d_tanh.o i_abs.o i_dim.o i_dnnt.o i_indx.o i_len.o i_len_trim.o i_mod.o i_nint.o i_sign.o lbitbits.o lbitshft.o i_ceiling.o h_abs.o h_dim.o h_dnnt.o h_indx.o h_len.o h_mod.o h_nint.o h_sign.o l_ge.o l_gt.o l_le.o l_lt.o hl_ge.o hl_gt.o hl_le.o hl_lt.o ef1asc_.o ef1cmc_.o f77_aloc.o s_cat.o s_cmp.o s_copy.o backspac.o close.o dfe.o dolio.o due.o endfile.o err.o fmt.o fmtlib.o ftell_.o iio.o ilnw.o inquire.o lread.o lwrite.o open.o rdfmt.o rewind.o rsfe.o rsli.o rsne.o sfe.o sue.o typesize.o uio.o util.o wref.o wrtfmt.o wsfe.o wsle.o wsne.o xwsne.o dtime_.o etime_.o
ar: skapar libf2c.a
ranlib libf2c.a
mv libf2c.a ..
make[1]: Lämnar katalogen ”/home/dell/Program/CLAPACK-3.2.1-ARM/F2CLIBS/libf2c”
dell@dell-Precision-M6400:~/Program/CLAPACK-3.2.1-ARM$ 
Klart!
Senast redigerad av Al_Bundy 14 februari 2019, 20:58:09, redigerad totalt 1 gång.
Användarvisningsbild
Al_Bundy
Inlägg: 2889
Blev medlem: 11 september 2012, 23:59:50
Ort: The U.S - Chicago
Kontakt:

Re: Matrisberäkningar med för STM32?

Inlägg av Al_Bundy »

Mr Andersson skrev:
Nu fungerar det!
ld: wref.o: omlokaliseringar i vanlig ELF (EM: 40)
wref.o: fel då symboler lades till: Filen är i fel format
(gånger några hundra)
Konstig definition av fungerande :doubt:

Jag ger snart upp.. Det här blir tredje gången jag säger att du kan inte blanda verktyg för olika cpu-arkitekturer..
Byt alla ld till arm-none-eabi-ld
Gör sen samma sak för alla andra binärer som felar.
Man måste kommentera bort ld och mv. Då fungerar det. Det står även så i makefilen.

Byt alla Id ? Vart finns det Id?
Skriv svar