Merged r9433:9527 from features/gr-usrp2 into trunk. Adds usrp2 and gr-usrp2 top...
[debian/gnuradio] / usrp2 / fpga / opencores / aemb / sw / gccrom
1 #!/bin/sh
2 # $Id: gccrom,v 1.13 2008/01/19 16:42:54 sybreon Exp $
3
4 # Compile using C++ pre-processor
5 mb-g++ -g -Wl,-defsym -Wl,_HEAP_SIZE=0x800 -mxl-soft-div -msoft-float -mxl-barrel-shift -mno-xl-soft-mul -mno-clearbss $@ -o rom.elf -lc_m_bs -lm_m_bs && \
6
7 # Create a text listing of the compiled code
8 mb-objdump -DSC rom.elf > rom.dump && \
9
10 # Convert the ELF file to an SREC file
11 mb-objcopy -O srec rom.elf rom.srec && \
12
13 # Generate a Verilog VMEM file from the SREC file
14 srec_cat rom.srec -o ../sim/dump.vmem -vmem 32 && \
15
16 # Cleanup code
17 rm rom.srec && \
18
19 # Say Cheeze!
20 echo "ROM generated"
21
22 # $Log: gccrom,v $
23 # Revision 1.13  2008/01/19 16:42:54  sybreon
24 # Uses multiplier + barrel shifter as default.
25 #
26 # Revision 1.12  2007/12/11 00:44:32  sybreon
27 # Modified for AEMB2
28 #
29 # Revision 1.11  2007/11/30 17:09:27  sybreon
30 # Minor code cleanup.
31 #
32 # Revision 1.10  2007/11/20 18:35:34  sybreon
33 # Generate VMEM instead of HEX dumps of programme.
34 #
35 # Revision 1.9  2007/11/18 19:41:46  sybreon
36 # Minor simulation fixes.
37 #
38 # Revision 1.8  2007/11/09 20:52:37  sybreon
39 # Added some compilation optimisations.
40 #
41 # Revision 1.7  2007/11/04 05:16:25  sybreon
42 # Added -msoft-float and -mxl-soft-div compiler flags.
43 #
44 # Revision 1.6  2007/11/02 03:25:46  sybreon
45 # New EDK 3.2 compatible design with optional barrel-shifter and multiplier.
46 # Fixed various minor data hazard bugs.
47 # Code compatible with -O0/1/2/3/s generated code.
48 #
49 # Revision 1.5  2007/10/22 19:14:38  sybreon
50 # Recommended to compile code with -O2/3/s
51 #
52 # Revision 1.4  2007/04/30 15:57:31  sybreon
53 # Modified compilation sequence.
54 #
55 # Revision 1.3  2007/04/25 22:15:06  sybreon
56 # Added support for 8-bit and 16-bit data types.
57 #
58 # Revision 1.2  2007/04/04 06:14:39  sybreon
59 # Minor changes
60 #
61 # Revision 1.1  2007/03/09 17:41:56  sybreon
62 # initial import