Bug 885306 - /usr/include/alsa/asoundlib.h needs to include sys/types.h?
Summary: /usr/include/alsa/asoundlib.h needs to include sys/types.h?
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: alsa-lib
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Stephen Gallagher
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-12-08 14:29 UTC by Richard Shaw
Modified: 2013-04-20 19:52 UTC (History)
3 users (show)

Fixed In Version: alsa-lib-1.0.26-4.fc19
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-04-20 19:52:15 UTC
Type: Bug


Attachments (Terms of Use)
Git diff from master (1.43 KB, patch)
2012-12-10 17:02 UTC, Richard Shaw
no flags Details | Diff
Patch to asoundlib.h (431 bytes, patch)
2012-12-10 17:04 UTC, Richard Shaw
no flags Details | Diff

Description Richard Shaw 2012-12-08 14:29:54 UTC
Description of problem:
While trying to build the latest mythtv on RPM Fusion for rawhide I ran into the following issue:

g++ -c -pipe -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -O2 -g
-pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic -fomit-frame-pointer
-fomit-frame-pointer -fPIC -pthread -g -Wall -Wpointer-arith
-Wno-non-virtual-dtor -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS
-fvisibility-inlines-hidden -Wmissing-declarations -Wno-switch
-Wredundant-decls -funit-at-a-time -D_REENTRANT -fPIC -DMMX
-D_GNU_SOURCE -DQT_NO_DEBUG -DQT_CORE_LIB -DQT_SHARED
-I/usr/lib64/qt4/mkspecs/linux-g++ -I. -I/usr/include/QtCore
-I/usr/include -I/usr/include -I/usr -I/usr/include/libxml2
-I../../zeromq/include -I../../nzmqt/include/nzmqt -I../include -I.
-I. -o parser.o parser.cpp
In file included from /usr/include/alsa/asoundlib.h:49:0,
                 from libavdevice/alsa-audio-common.c:31:
/usr/include/alsa/pcm.h:944:1: error: unknown type name 'u_int8_t'
/usr/include/alsa/pcm.h:945:1: error: unknown type name 'u_int16_t'
/usr/include/alsa/pcm.h:946:1: error: unknown type name 'u_int32_t'
/usr/include/alsa/pcm.h:947:1: error: unknown type name 'u_int64_t'
In file included from /usr/include/alsa/asoundlib.h:49:0,
                 from libavdevice/alsa-audio-common.c:31:
/usr/include/alsa/pcm.h:1052:1: error: unknown type name 'int16_t'
make[2]: *** [libavdevice/alsa-audio-common.o] Error 1
make[2]: Leaving directory
`/builddir/build/BUILD/MythTV-mythtv-d2f9798/mythtv/external/FFmpeg'
make[1]: *** [FFmpeg-all] Error 2


Version-Release number of selected component (if applicable):
alsa-lib-devel-1.0.26-1.fc19.x86_64


A mythtv dev suggested the following *might* be the fix. Since I build mythtv in mock/rpmbuild I don't think it's possible/practical to test this patch:

--- /usr/include/alsa/asoundlib.h       2012-09-06 06:18:02.000000000 -0700
+++ asoundlib.h 2012-12-07 19:30:53.131751067 -0800
@@ -31,6 +31,7 @@
 #include <unistd.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <sys/types.h>
 #include <string.h>
 #include <fcntl.h>
 #include <assert.h>

Comment 1 Richard Shaw 2012-12-10 17:02:58 UTC
Created attachment 660967 [details]
Git diff from master

I have verified that the patch essentially works (I had to actually patch asoundlib-head.h)

Comment 2 Richard Shaw 2012-12-10 17:04:16 UTC
Created attachment 660968 [details]
Patch to asoundlib.h

Attaching since I couldn't get it to show up in the git diff...

Comment 3 Gary Buhrmaster 2012-12-10 18:44:22 UTC
(In reply to comment #0)
.....
> A mythtv dev suggested the following *might* be the fix. 

I believe the (root) cause is that stdlib.h no longer
includes sys/types.h, and the alsa includes depend on
the u_int... types being defined (which were being
defined in sys/types.h, no longer included).

Comment 4 Richard Shaw 2012-12-20 21:55:10 UTC
As it's been 10 days since the last comment on this bug I just wanted to ping you guys to see if anyone is working on a fix.

I would think that breaking a program from building would be considered a serious, though not urgent, bug.

Comment 5 Gary Buhrmaster 2013-03-23 04:29:02 UTC
It appears that this has been addressed upstream http://git.alsa-project.org/?p=alsa-lib.git;a=commit;h=3e7dc283ed2d3ed2341f0657811c588f4dbcba6d

Comment 6 Fedora End Of Life 2013-04-03 15:18:49 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19

Comment 7 Richard Shaw 2013-04-03 19:14:46 UTC
(In reply to comment #4)
> As it's been 10 days since the last comment on this bug I just wanted to
> ping you guys to see if anyone is working on a fix.
> 
> I would think that breaking a program from building would be considered a
> serious, though not urgent, bug.

Ping?

Comment 8 Stephen Gallagher 2013-04-03 20:01:35 UTC
Taking over this trivial fix as a provenpackager action.

Comment 9 Fedora Update System 2013-04-03 20:17:12 UTC
alsa-lib-1.0.26-4.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/alsa-lib-1.0.26-4.fc19

Comment 10 Fedora Update System 2013-04-05 02:55:33 UTC
Package alsa-lib-1.0.26-4.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing alsa-lib-1.0.26-4.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-4892/alsa-lib-1.0.26-4.fc19
then log in and leave karma (feedback).

Comment 11 Fedora Update System 2013-04-20 19:52:17 UTC
alsa-lib-1.0.26-4.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.


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