From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14286 invoked by alias); 21 Nov 2003 09:32:57 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 14279 invoked from network); 21 Nov 2003 09:32:55 -0000 Received: from unknown (HELO bosgate02.infosys.com) (216.251.53.4) by sources.redhat.com with SMTP; 21 Nov 2003 09:32:55 -0000 Received: from 192.168.200.81 by bosgate02.infosys.com (InterScan E-Mail VirusWall NT); Fri, 21 Nov 2003 04:35:00 -0500 Received: from mohmsg01.ad.infosys.com ([192.168.122.42]) by indhubbhs01.ad.infosys.com with Microsoft SMTPSVC(5.0.2195.6713); Fri, 21 Nov 2003 15:01:55 +0530 X-MimeOLE: Produced By Microsoft Exchange V6.0.6375.0 content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: Supressing Symbols of Shared Library on Linux Date: Fri, 21 Nov 2003 09:32:00 -0000 Message-ID: <2B721C6525F0D411B1E900B0D0226BDD02884639@mohmsg01.ad.infosys.com> X-MS-Has-Attach: X-MS-TNEF-Correlator: From: "Romil_Singla" To: X-OriginalArrivalTime: 21 Nov 2003 09:31:55.0413 (UTC) FILETIME=[4D96BC50:01C3B012] X-SW-Source: 2003-11/txt/msg00277.txt.bz2 Hi=20 =20 We are building a shared library on Red Hat Linux release 6.2 (Zoot) Kernel 2.2.14-5.0 on an i686.We are using gcc version egcs-2.91.66 and GNU ld version 2.9.5 (with BFD 2.9.5.0.22) for making our shared library. We want to export only specific external symbols of our library and want to suppress all other symbols. What are the various Linker options for doing the same (I tried --exclude-symbol option , but the linker gives unrecognized option `--exclude-symbols' error.) The GCC documentation says that `--exclude-symbols' is an option specific to i386 PE targets. Can I use this option for the my above mentioned platform??? Is there any other way also to suppress the symbols in Linux(version-script is I think another option, but I don't know the format of writing version scripts).=20 Romil