File: ar65.sgml

package info (click to toggle)
cc65 2.17-1
  • links: PTS
  • area: main
  • in suites: buster
  • size: 19,032 kB
  • sloc: ansic: 111,990; asm: 59,701; pascal: 3,584; makefile: 953; perl: 607
file content (149 lines) | stat: -rw-r--r-- 4,634 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
<!doctype linuxdoc system>

<article>

<title>ar65 Users Guide
<author><url url="mailto:uz@cc65.org" name="Ullrich von Bassewitz">
<date>2017-05-28

<abstract>
ar65 is an archiver for object files generated by ca65. It allows to create
archives, add or remove modules from archives, and to extract modules from
existing archives.
</abstract>

<!-- Table of contents -->
<toc>

<!-- Begin the document -->

<sect>Overview<p>


ar65 is a replacement for the libr65 archiver that was part of the cc65 C
compiler suite developed by John R. Dunning. libr65 had some problems and
the copyright does not permit some things which I wanted to be possible,
so I decided to write a completely new assembler/linker/archiver suite
for the cc65 compiler. ar65 is part of this suite.

<sect>Usage<p>


The archiver is called as follows:

<tscreen><verb>
	Usage: ar65 <operation ...> lib file|module ...
	Operations are some of:
		r	Add modules
		d	Delete modules
		t	List library table
		v	Increase verbosity (put before other operation)
		x	Extract modules
		V	Print the archiver version
</verb></tscreen>

You may add modules to a library using the `r' command (`a' is deprecated). If the library
does not exist, it is created (and a warning message is printed which you
may ignore if creation of the library was your intention). You may
specify any number of modules on the command line following the library.

If a module with the same name exists in the library, it is replaced by
the new one. The archiver prints a warning, if the module in the library
has a newer timestamp than the one to add.

Here's an example:

<tscreen><verb>
	ar65 r mysubs.lib sub1.o sub2.o
</verb></tscreen>

This will add two modules to the library `mysubs.lib' creating the
library if necessary. If the library contains modules named sub1.o or
sub2.o, they are replaced by the new ones.

Modules names in the library are stored without the path, so, using

<tscreen><verb>
	ar65 v v r mysubs.lib ofiles/sub1.o ofiles/sub2.o
</verb></tscreen>

will verbose add two modules named `sub1.o' and `sub2.o' to the library.

Deleting modules from a library is done with the `d' command. You may not
give a path when naming the modules.

Example:

<tscreen><verb>
	ar65 d mysubs.lib sub1.o
</verb></tscreen>

This will delete the module named `sub1.o' from the library, printing an
error if the library does not contain that module.


The `t' command prints a table of all modules in the library (`l' is deprecated).
Any module names on the command line are ignored.

Example:

<tscreen><verb>
	ar65 tv mysubs.lib
</verb></tscreen>


Using the `x' command, you may extract modules from the library. The
modules named on the command line are extracted from the library and put
into the current directory.

Note: Because of the indexing done by the archiver, the modules may have
a changed binary layout, that is, a binary compare with the old module
(before importing it into the library) may yield differences. The
extracted modules are accepted by the linker and archiver, however, so
this is not a problem.

Example for extracting a module from the library:

<tscreen><verb>
	ar65 x mysubs.lib sub1.o
</verb></tscreen>


The `V' command prints the version number of the assembler. If you send
any suggestions or bugfixes, please include your version number.

In addition to these operations, the archiver will check for, and warn
about duplicate external symbols in the library, every time when an
operation does update the library. This is only a warning, the linker
will ignore one of the duplicate symbols (which one is unspecified).


<sect>Copyright<p>

ar65 (and all cc65 binutils) are (C) Copyright 1998-2000 Ullrich von
Bassewitz. For usage of the binaries and/or sources the following conditions
do apply:

This software is provided 'as-is', without any expressed or implied
warranty.  In no event will the authors be held liable for any damages
arising from the use of this software.

Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:

<enum>
<item>	The origin of this software must not be misrepresented; you must not
	claim that you wrote the original software. If you use this software
	in a product, an acknowledgment in the product documentation would be
	appreciated but is not required.
<item>	Altered source versions must be plainly marked as such, and must not
	be misrepresented as being the original software.
<item>	This notice may not be removed or altered from any source
	distribution.
</enum>

</article>