Bug 222617 - util.h contains bad HAVE_CONFIG_H conditional
Summary: util.h contains bad HAVE_CONFIG_H conditional
Alias: None
Product: Fedora
Classification: Fedora
Component: audacious   
(Show other bugs)
Version: rawhide
Hardware: All Linux
Target Milestone: ---
Assignee: Ralf Ertzinger
QA Contact: Fedora Extras Quality Assurance
URL: http://bugs-meta.atheme.org/view.php?...
Keywords: EasyFix
Depends On:
TreeView+ depends on / blocked
Reported: 2007-01-15 09:46 UTC by Michael Schwendt
Modified: 2007-11-30 22:11 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-04-06 21:45:58 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
patch against audacious 1.2.2 (383 bytes, patch)
2007-01-15 14:47 UTC, Michael Schwendt
no flags Details | Diff

Description Michael Schwendt 2007-01-15 09:46:35 UTC
Upstream http://bugs-meta.atheme.org/view.php?id=760

Audacious' API does this in its "util.h":

# include "config.h"

This is a bad assumption. First of all, you don't include a "config.h" header in
your API headers,

In file included from configure.c:2:
/usr/include/audacious/util.h:26:22: error: config.h: No such file or directory

and secondly, with GNU Automake, it is possible to redefine the config
autoheader like this:


Still HAVE_CONFIG_H will be set, but since the autoheaders file is not named
"config.h", your API headers fail.

The fix is simple. Never expose autoheaders to your API.

Comment 1 Ralf Ertzinger 2007-01-15 12:24:20 UTC
The clean solution for this would be to create util.h from util.h.in with the
correct definition for bmp_menu_translate, I think.

This is way beyond my non-existing autofoo-skills, though.

Comment 2 Michael Schwendt 2007-01-15 14:47:22 UTC
Created attachment 145577 [details]
patch against audacious 1.2.2

Comment 3 Ralf Ertzinger 2007-01-15 14:54:03 UTC
I'm not sure this is right. config.h defines ENABLE_NLS, which is used later in
the file.

(Of course, given that there most likely is no config.h file at compile time
against this header (when not building audacious itself) anyway your patch does
not change the current behaviour.)

Comment 4 Michael Schwendt 2007-01-15 15:22:27 UTC
config.h is included in every file before util.h is included

That ENABLE_NLS is undefined, but alters the API, is even worse

Comment 5 Ralf Ertzinger 2007-04-06 21:45:58 UTC
Fixed in the 1.3.x releases.

Note You need to log in before you can comment on or make changes to this bug.