IAR Linker and Library To o l s Reference Guide Version 4.60 XLINK-460G COPYRIGHT NOTICE © Copyright 1987–2007 IAR Systems. All rights reserved. No part of this document may be reproduced without the prior written consent of IAR Systems. The software described in this document is furnished under a license and may only be used or copied in accordance with the terms of such a license. DISCLAIMER The information in this document is subject to change without notice and does not represent a commitment on any part of IAR Systems. While the information contained herein is assumed to be accurate, IAR Systems assumes no responsibility for any errors or omissions. In no event shall IAR Systems, its employees, its contractors, or the authors of this document be liable for special, direct, indirect, or consequential damage, losses, costs, charges, claims, demands, claim for lost profits, fees, or expenses of any nature or kind. TRADEMARKS IAR, IAR Systems, IAR Embedded Workbench, IAR MakeApp, C-SPY, visualSTATE, From Idea To Target, IAR KickStart Kit and IAR PowerPac are trademarks or registered trademarks owned by IAR Systems AB. All other product names are trademarks or registered trademarks of their respective owners. EDITION NOTICE April 2007 Part number: XLINK-460G The IAR Linker and Library Tools Reference Guide replaces all versions of the IAR XLINK Linker™ and IAR XLIB Librarian™ Reference Guide. XLINK-460G Contents Tables ...................................................................................................................... vii Preface ..................................................................................................................... ix Who should read this guide ................................................................ix How to use this guide ............................................................................ix What this guide contains ....................................................................... x Document conventions ......................................................................... x Part 1: The IAR XLINK Linker ............................................. 1 Introduction to the IAR XLINK Linker ................................................. 3 Key features ................................................................................................ 3 MISRA C ............................................................................................. 4 The linking process ................................................................................. 4 Object format ....................................................................................... 5 XLINK functions ................................................................................. 5 Libraries .............................................................................................. 5 Output format ....................................................................................... 6 Input files and modules .......................................................................... 6 Libraries ............................................................................................... 7 Segments .............................................................................................. 8 Segment control ....................................................................................... 9 Address translation ............................................................................. 10 Allocation segment types ................................................................... 10 Memory segment types ...................................................................... 11 Overlap errors ................................................................................... 12 Range errors ...................................................................................... 12 Segment placement examples ............................................................ 13 Listing format ........................................................................................... 14 Header ................................................................................................ 14 Cross-reference .................................................................................. 15 Checksummed areas and memory usage ........................................... 22 iii XLINK-460G Contents XLINK options .................................................................................................. 23 Setting XLINK options ......................................................................... 23 Summary of options .............................................................................. 23 Descriptions of XLINK options ........................................................ 25 Splitting segments .............................................................................. 54 XLINK output formats .................................................................................. 55 Single output file ..................................................................................... 55 UBROF versions ............................................................................... 57 Two output files ...................................................................................... 58 Output format variants ........................................................................ 59 IEEE695 ............................................................................................. 60 ELF ..................................................................................................... 62 XCOFF78K ........................................................................................ 64 Restricting the output to a single address space ..................... 65 XLINK environment variables ................................................................... 67 Summary of XLINK environment variables ............................... 67 XLINK diagnostics ........................................................................................... 71 Introduction .............................................................................................. 71 XLINK warning messages ................................................................. 71 XLINK error messages ...................................................................... 71 XLINK fatal error messages .............................................................. 71 XLINK internal error messages ......................................................... 71 Error messages ........................................................................................ 72 Warning messages ................................................................................. 87 Part 2: The IAR Library Tools .............................................. 97 Introduction to the IAR Systems library tools ................................. 99 Libraries ...................................................................................................... 99 IAR XAR Library Builder and IAR XLIB Librarian ................. 99 Choosing which tool to use .............................................................. 100 Using libraries with C/C++ programs .......................................... 100 IAR Linker and Library Tools iv Reference Guide XLINK-460G Contents Using libraries with assembler programs .................................. 100 The IAR XAR Library Builder .................................................................. 103 Using XAR ............................................................................................... 103 Basic syntax .................................................................................... 103 Summary of XAR options ............................................................... 103 Descriptions of XAR options ........................................................... 104 XAR diagnostics .............................................................................................. 105 XAR messages ....................................................................................... 105 IAR XLIB Librarian options ....................................................................... 107 Using XLIB options .............................................................................. 107 Giving XLIB options from the command line ................................. 107 XLIB batch files ............................................................................... 107 Parameters ........................................................................................ 108 Module expressions .......................................................................... 108 List format ........................................................................................ 109 Using environment variables ........................................................... 109 Summary of XLIB options for all UBROF versions ............... 110 Descriptions of XLIB options for all UBROF versions ......... 111 Summary of XLIB options for older UBROF versions ........ 120 Descriptions of XLIB options for older UBROF versions ... 121 XLIB diagnostics .............................................................................................. 123 XLIB messages ...................................................................................... 123 Index ..................................................................................................................... 125 v XLINK-460G
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages146 Page
-
File Size-