1 /* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9 * or http://www.opensolaris.org/os/licensing. 10 * See the License for the specific language governing permissions 11 * and limitations under the License. 12 * 13 * When distributing Covered Code, include this CDDL HEADER in each 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15 * If applicable, add the following below this CDDL HEADER, with the 16 * fields enclosed by brackets "[]" replaced with your own identifying 17 * information: Portions Copyright [yyyy] [name of copyright owner] 18 * 19 * CDDL HEADER END 20 */ 21 22 /* 23 * Copyright 2008 Sun Microsystems, Inc. All rights reserved. 24 * Use is subject to license terms. 25 */ 26 /* LINTLIBRARY */ 27 /* PROTOLIB1 */ 28 29 #pragma ident "%Z%%M% %I% %E% SMI" 30 31 /* 32 * Supplemental Pseudo-code to get lint to consider these symbols used. 33 */ 34 #include <msg.h> 35 #include <debug.h> 36 #include <elfedit.h> 37 38 /* 39 * Lint doesn't understand that both elfedit{32|64}_init_obj_state() 40 * gets built, because it doesn't know that elfedit_machelf.c gets 41 * compiled twice. The difference between this case and the others 42 * is that we don't use macros to give them both the same name, 43 * because elfedit.c needs to know about both explictly. So, 44 * supply the "missing" one here, for lint's benefit. 45 * 46 * This dummy routine eliminates the "name used but not defined" 47 * errors that otherwise result. 48 */ 49 #ifdef _ELF64 50 /*ARGSUSED*/ 51 void 52 elfedit32_init_obj_state(const char *file, int fd, Elf *elf) 53 { 54 } 55 #else 56 /*ARGSUSED*/ 57 void 58 elfedit64_init_obj_state(const char *file, int fd, Elf *elf) 59 { 60 } 61 #endif 62 63 64 void 65 foo() 66 { 67 dbg_print(NULL, NULL, 0); 68 69 elfedit_array_elts_delete(NULL, NULL, 0, 0, 0, 0); 70 elfedit_array_elts_move(NULL, NULL, 0, 0, 0, 0, 0, NULL); 71 72 (void) _elfedit_msg((Msg)&__elfedit_msg[0]); 73 74 (void) elfedit_atoi(NULL, NULL); 75 (void) elfedit_atoui(NULL, NULL); 76 (void) elfedit_atoconst(NULL, 0); 77 78 (void) elfedit_atoi2(NULL, NULL, NULL); 79 (void) elfedit_atoui2(NULL, NULL, NULL); 80 (void) elfedit_atoconst2(NULL, 0, NULL); 81 82 (void) elfedit_atoi_range(NULL, NULL, 0, 0, NULL); 83 (void) elfedit_atoui_range(NULL, NULL, 0, 0, NULL); 84 (void) elfedit_atoconst_range(NULL, NULL, 0, 0, 0); 85 86 (void) elfedit_atoi_range2(NULL, 0, 0, NULL, NULL); 87 (void) elfedit_atoui_range2(NULL, 0, 0, NULL, NULL); 88 (void) elfedit_atoconst_range2(NULL, 0, 0, 0, NULL); 89 90 (void) elfedit_atoi_value_to_str(NULL, 0, 0); 91 (void) elfedit_atoui_value_to_str(NULL, 0, 0); 92 (void) elfedit_atoconst_value_to_str(0, 0, 0); 93 94 (void) elfedit_atoshndx(NULL, 0); 95 96 (void) elfedit_cpl_atoi(NULL, NULL); 97 (void) elfedit_cpl_atoui(NULL, NULL); 98 (void) elfedit_cpl_atoconst(NULL, 0); 99 100 (void) elfedit_dyn_offset_to_str(NULL, NULL); 101 (void) elfedit_dynstr_insert(NULL, NULL, NULL, NULL); 102 (void) elfedit_flags(); 103 (void) elfedit_modified_ehdr(NULL); 104 (void) elfedit_modified_phdr(NULL); 105 (void) elfedit_modified_shdr(NULL); 106 (void) elfedit_mach_sunw_hw1_to_atoui(0); 107 (void) elfedit_name_to_shndx(NULL, NULL); 108 (void) elfedit_name_to_symndx(NULL, NULL, NULL, ELFEDIT_MSG_ERR, NULL); 109 (void) elfedit_outstyle(); 110 (void) elfedit_sec_get(NULL, NULL); 111 (void) elfedit_sec_getcap(NULL, NULL, NULL); 112 (void) elfedit_sec_getdyn(NULL, NULL, NULL); 113 (void) elfedit_sec_getstr(NULL, 0); 114 (void) elfedit_sec_getsyminfo(NULL, NULL, NULL); 115 (void) elfedit_sec_getsymtab(NULL, 0, 0, NULL, NULL, NULL, NULL); 116 (void) elfedit_sec_getversym(NULL, NULL, NULL, NULL); 117 (void) elfedit_sec_getxshndx(NULL, NULL, NULL, NULL); 118 (void) elfedit_sec_msgprefix(NULL); 119 (void) elfedit_shndx_to_name(NULL, NULL); 120 elfedit_str_to_c_literal(NULL, NULL); 121 (void) elfedit_strtab_insert(NULL, NULL, NULL, NULL); 122 (void) elfedit_strtab_insert_test(NULL, NULL, NULL, NULL); 123 (void) elfedit_type_to_shndx(NULL, 0); 124 } 125