Bug 1697142

Summary: butt: fails to compile on s390x
Product: [Fedora] Fedora Reporter: Carl George <carl>
Component: buttAssignee: Carl George <carl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: rawhideCC: carl, dan, hannsj_uhl
Target Milestone: ---Keywords: FutureFeature
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: butt-0.1.17-3.fc30 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-04-09 20:44:25 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 485231    

Description Carl George 2019-04-07 21:20:59 UTC
Description of problem:
butt fails to compile on s90x.  I've reported this upstream.

Version-Release number of selected component (if applicable):
butt-0.1.17-1 (initial package)

Additional info:
https://sourceforge.net/p/butt/bugs/24/
https://koji.fedoraproject.org/koji/taskinfo?taskID=34034866

Comment 1 Dan Horák 2019-04-07 21:39:13 UTC
There is something wrong going on ...

from config.log

configure:6096: checking for X
configure:6204: gcc -E  conftest.c
configure:6204: $? = 0
configure:6235: gcc -o conftest -lfdk-aac -lsamplerate -lpthread -lportaudio -lFLAC -lmp3lame -lopus -lvorbisenc -lvorbis -logg -lX11 -lfltk_images -lfltk -ldbus-1  -I/usr/include/dbus-1.0 -
I/usr/lib64/dbus-1.0/include   -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -L/usr/local/lib conftest.c -lX11 -lfdk-aac -lsamplerate -lpthread -lpor
taudio -lFLAC -lmp3lame -lopus -lvorbisenc -lvorbis -logg -lX11 -lfltk_images -lfltk -ldbus-1  >&5
/usr/bin/ld: /tmp/cc4MHsUf.o: `XrmInitialize' non-PLT reloc for symbol defined in shared library and accessed from executable (rebuild file with -fPIC ?)
/usr/bin/ld: final link failed: bad value
collect2: error: ld returned 1 exit status

and similar errors are printed for the other not found stuff ...

Comment 2 Dan Horák 2019-04-08 07:54:53 UTC
Nothing s390x specific, the buildsystem is generally buggy.

diff -up butt-0.1.17/configure.ac.flags butt-0.1.17/configure.ac
--- butt-0.1.17/configure.ac.flags	2019-04-08 03:51:02.967273801 -0400
+++ butt-0.1.17/configure.ac	2019-04-08 03:51:11.777273801 -0400
@@ -113,7 +113,7 @@ if test "$build_linux" = "yes"; then
 	PKG_CHECK_MODULES([DBUS], [dbus-1], [
 		AC_DEFINE([HAVE_DBUS], [1], [Use dbus to get current tracks])
 		LIBS="$LIBS $DBUS_LIBS"
-		CFLAGS="$LIBS $DBUS_CFLAGS"
+		CFLAGS="$CFLAGS $DBUS_CFLAGS"
 		CXXFLAGS="$CXXFLAGS $DBUS_CFLAGS"
 	], [
 		AC_DEFINE([HAVE_DBUS], [0], [Use dbus to get current tracks])

Comment 3 Carl George 2019-04-09 15:26:55 UTC
Thanks for finding that bug Dan.  I verified that adding that as a patch builds on all architectures (scratch build [0]).  Would you like to comment on the upstream bug report [1] and share the fix, or should I?

[0]: https://koji.fedoraproject.org/koji/taskinfo?taskID=34079001
[1]: https://sourceforge.net/p/butt/bugs/24/

Comment 4 Dan Horák 2019-04-09 15:40:44 UTC
Please forward it upstream.

Comment 5 Carl George 2019-04-09 20:44:25 UTC
Reported upstream and added as a patch to the package.  Thanks for the assist Dan!

https://src.fedoraproject.org/rpms/butt/c/11aed7ac3a3a25dd19185154880a7c935c3c0b78
https://koji.fedoraproject.org/koji/buildinfo?buildID=1247304

Comment 6 Fedora Update System 2019-04-09 20:55:25 UTC
butt-0.1.17-3.fc30 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-f8ffbae5a7

Comment 7 Fedora Update System 2019-04-15 01:42:48 UTC
butt-0.1.17-3.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-f8ffbae5a7

Comment 8 Fedora Update System 2019-04-16 03:54:42 UTC
butt-0.1.17-3.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.