source: rtems-tools/rtemstoolkit/rld-outputter.h @ 3618a62

Last change on this file since 3618a62 was 82c8788, checked in by Chris Johns <chrisj@…>, on Apr 14, 2018 at 4:15:07 AM

rtemstoolkit/rtl-file: Remove a file on close if requested

Close #3395

  • Property mode set to 100644
File size: 4.9 KB
Line 
1/*
2 * Copyright (c) 2011, Chris Johns <chrisj@rtems.org>
3 *
4 * Permission to use, copy, modify, and/or distribute this software for any
5 * purpose with or without fee is hereby granted, provided that the above
6 * copyright notice and this permission notice appear in all copies.
7 *
8 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15 */
16/**
17 * @file
18 *
19 * @ingroup rtems-ld
20 *
21 * @brief RTEMS Linker outputter handles the various output formats.
22 *
23 */
24
25#if !defined (_RLD_OUTPUTTER_H_)
26#define _RLD_OUTPUTTER_H_
27
28#include <rld-files.h>
29
30namespace rld
31{
32  namespace outputter
33  {
34    /**
35     * Output the object file list as a string.
36     *
37     * @param entry The name of the entry point symbol.
38     * @param exit The name of the exit point symbol.
39     * @param dependents The list of dependent object files
40     * @param cache The file cache for the link. Includes the object list
41     *              the user requested.
42     * @return std::string The list as a text string.
43     */
44    std::string script_text (const std::string&        entry,
45                             const std::string&        exit,
46                             const files::object_list& dependents,
47                             const files::cache&       cache);
48    /**
49     * Output the object files as an archive format file with the metadata as
50     * the first ELF file.
51     *
52     * @param name The name of the archive.
53     * @param entry The name of the entry point symbol.
54     * @param exit The name of the exit point symbol.
55     * @param dependents The list of dependent object files
56     * @param cache The file cache for the link. Includes the object list
57     *              the user requested.
58     */
59    void archive (const std::string&        name,
60                  const std::string&        entry,
61                  const std::string&        exit,
62                  const files::object_list& dependents,
63                  const files::cache&       cache);
64
65    void archivera (const std::string&        name,
66                    const files::object_list& dependents,
67                    files::cache&             cache,
68                    bool                      ra_exist,
69                    bool                      ra_rap);
70
71    /**
72     * Output the object file list as a script.
73     *
74     * @param name The name of the script.
75     * @param entry The name of the entry point symbol.
76     * @param exit The name of the exit point symbol.
77     * @param dependents The list of dependent object files
78     * @param cache The file cache for the link. Includes the object list
79     *              the user requested.
80     */
81    void script (const std::string&        name,
82                 const std::string&        entry,
83                 const std::string&        exit,
84                 const files::object_list& dependents,
85                 const files::cache&       cache);
86
87    /**
88     * Output the object files in an archive with the metadata.
89     *
90     * @param name The name of the script.
91     * @param entry The name of the entry point symbol.
92     * @param exit The name of the exit point symbol.
93     * @param dependents The list of dependent object files
94     * @param cache The file cache for the link. Includes the object list
95     *              the user requested.
96     */
97    void elf_application (const std::string&        name,
98                          const std::string&        entry,
99                          const std::string&        exit,
100                          const files::object_list& dependents,
101                          const files::cache&       cache);
102
103    /**
104     * Output the object files in an archive with the metadata.
105     *
106     * @param name The name of the script.
107     * @param entry The name of the entry point symbol.
108     * @param exit The name of the exit point symbol.
109     * @param dependents The list of dependent object files
110     * @param cache The file cache for the link. Includes the object list
111     *              the user requested.
112     * @param symbols The symbol table used to resolve the application.
113     */
114    void rap_application (const std::string&        name,
115                          const std::string&        entry,
116                          const std::string&        exit,
117                          const files::object_list& dependents,
118                          const files::cache&       cache,
119                          const symbols::table&     symbols,
120                          bool                      one_file);
121
122  }
123}
124
125#endif
Note: See TracBrowser for help on using the repository browser.