Help required to use arm-hitex-elf-ar

Guest #2352612
Rate this post
• ▲ useful
▼ not useful
Hello there,
Recently, I want to create static library using HITEX ARM GNU compiler. 
I am using arm-hitex-elf-g++.exe & arm-hitex-elf-ar.exe to compile set 
of .cpp files and from these resultant object files, I want to create 
static library to make a binary image to be deployed on ARM board. 
Following is the syntax, I am using

GG = arm-hitex-elf-g++.exe
CC = arm-hitex-elf-gcc.exe
AS = arm-hitex-elf-as.exe
LD = arm-hitex-elf-ld.exe
OC = arm-hitex-elf-objcopy.exe
AR = arm-hitex-elf-ar.exe

CCOPTIONS = -DJUP_1 -I..\ -I..\.. -mcpu=arm968e-s -c -gdwarf-2 -MD -Wall 
-O3 \
-mthumb-interwork -mapcs-frame -fsigned-char -mlittle-endian -marm \
-fomit-frame-pointer -fno-rtti -fno-exceptions -msoft-float

all: clean xyz.a

{..}.c.o:
   $(CC) $(CCOPTIONS) -xc -o $*.o $*.c

{..}.cpp.o:
   $(GG) $(CCOPTIONS) -xc++ -o $*.o $*.cpp

clean:
   -@echo Cleaning up files ...
   -@erase *.d
   -@erase *.o
   -@erase *.a


OBJS = \
1.o \
2.o \
3.o \


COMDEPS = \
..\..\1.h \
..\..\2.h \
..\..\3.h \

LCLDEPS = \
..\a.h \
..\b.h \
..\c.h \

$(OBJS) : $*.cpp $(COMDEPS) $(LCLDEPS)


xyz.a : $(OBJS)
  $(AR) -mac -v  xyz.a $(OBJS)

when I am using the above command, it's giving me following error:
"File format not recognized"

Also, I tried to give emulation option elf32-littlearm as following 
sytax
$(AR) elf32-littlearm -mac -v  xyz.a $(OBJS)

It's giveing me syntax error.

Help in this regard is highly appreciated

Note: the above code is from the makefile I have writtena and I am using 
nmake to execute this makefile.

Regards,
Tameez

Reply

Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.

Formatting
  • [c]C-Code[/c]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]
  • [[Title]] – link to an article
  • Link to another post: right-click its post ID (#8078628), copy the address, paste it into the text

More about formatting

Post long source code as an attachment, not in the text.

Already registered? Log in

Not shown to anyone. We send you a link; your post appears once you confirm it there.

By submitting you create a free account and accept the terms of use.