Opened 14 years ago

Closed 11 years ago

#2421 closed patch (fixed)

Add GCC >= gcc 4 support for default hidden/explicit public

Reported by: Anduin Withers Owned by: Anduin Withers
Priority: minor Milestone: unknown
Component: MythTV - General Version: head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

Submitted largely so people can look it over and make me not commit it.

This patch adds a new --enable-symbol-visibility switch to configure which turns on use_hidesyms which selectively turns on -fvisibility=hidden (currently selectively because only libmyth and libmythtv are close to done, external libs will never be done).

Objectives:

Smaller symbol tables An explicit API

Deficiencies:

Only the symbols I absolutely needed plus reasonable guesses are here (basically most of the stuff that would be exposed through mythtv/ includes). If you use this patch and find some I missed let me know.

Attachments (1)

hidden.patch (82.4 KB) - added by Anduin Withers 14 years ago.

Download all attachments as: .zip

Change History (23)

Changed 14 years ago by Anduin Withers

Attachment: hidden.patch added

comment:1 Changed 14 years ago by Anduin Withers

(In [11469]) References #2421

First of n patches to get explicit symbol visibility in myth (for use with newer gcc).

If you do not enable it, this should only make you rebuild everything. To enable it you must run configure with --enable-symbol-visibility.

This commit introduces the new mythpluginapi.h. The purpose of this header is to provide prototypes for the plugin entry points (previously every plugin prototyped them). Existing plugins should include this file (I'll be updating them soon).

If you enable this, expect to find symbols I've somehow missed, report them.

Why? Cleaner, smaller, tables. Everyone likes clean tables.

comment:2 Changed 14 years ago by Anduin Withers

(In [11470]) References #2421

Update to use explicit symbol visibility changes.

comment:3 Changed 14 years ago by greg

(In [11540])

Updates mythgame to use explicity symbol visibility changes

recently commited.

references #2421

comment:4 Changed 14 years ago by anonymous

getting follwing after this commit....

../../libs/libmythui/libmythui-0.20.so: undefined reference to `JoystickMenuClient::Init(QString&)' ../../libs/libmythui/libmythui-0.20.so: undefined reference to `JoystickMenuClient::JoystickMenuClient?(QObject*)' ../../libs/libmythui/libmythui-0.20.so: undefined reference to `JoystickMenuClient::Process()'

comment:5 Changed 14 years ago by Anduin Withers

(In [12854]) References #2421

Export ClearChannelLocks? for hidden symbols patch.

comment:6 Changed 14 years ago by Anduin Withers

(In [13050]) References #2421

comment:7 Changed 14 years ago by Anduin Withers

(In [13163]) References #2421

export ViewScheduleDiff?

comment:8 Changed 13 years ago by Anduin Withers

(In [14201]) References #2421

Export ThemeInfo?

comment:9 Changed 13 years ago by Anduin Withers

(In [15454]) References #2421

Mark InputGroupMap? as public, for --enable-symbol-visibility.

comment:10 Changed 13 years ago by Anduin Withers

(In [15823]) References #2421

Export ChannelTVFormat for GetFormats?().

comment:11 Changed 13 years ago by Anduin Withers

(In [16740]) References #2421

Exports AudioSettings? for --enable-symbol-visibility.

comment:12 Changed 12 years ago by Anduin Withers

(In [17695]) References #2421

Exports new MDBManager and MSocketDevice.

With thanks to Michael T. Dean for the reminder.

comment:13 Changed 12 years ago by Anduin Withers

(In [19073]) References #2421

Don't export a few things that are now only referenced inside libmythui, adds libmythui to those supporting --enable-symbol-visibility.

comment:14 Changed 12 years ago by Dibblah

Status: newassigned

comment:15 Changed 12 years ago by Anduin Withers

(In [19355]) References #2421

symbol visibility update

comment:16 Changed 12 years ago by Anduin Withers

(In [19420]) References #2421

Export PlayerContex? and MythApplication?.

comment:17 Changed 12 years ago by Anduin Withers

(In [19839]) References #2421

Export MythUIFileBrowser.

comment:18 Changed 12 years ago by Anduin Withers

(In [19984]) References #2421

decodeencode.cpp is discovering things about itself and liking what it finds.

comment:19 Changed 12 years ago by Anduin Withers

(In [20007]) References #2421

comment:20 Changed 11 years ago by stuartm

Component: mythtvMythTV - General

Anduin, is this unfinished or can the ticket now be closed?

comment:21 Changed 11 years ago by Anduin Withers

(In [23019]) References #2421

Fix build when --enable-symbol-visibility is used.

comment:22 Changed 11 years ago by Stuart Auchterlonie

Resolution: fixed
Status: assignedclosed

We've done lots of symbol visibility fixes. We can deal with any new ones on a case by case basis.

Note: See TracTickets for help on using tickets.