https://bugzilla.redhat.com/show_bug.cgi?id=1175667
Bug ID: 1175667 Summary: "./Setup configure --ghc-option=-optc-Wall" gives "warning: control reaches end of non-void function [-Wreturn-type]" Product: Fedora Version: rawhide Component: ghc-rpm-macros Assignee: petersen@redhat.com Reporter: petersen@redhat.com QA Contact: extras-qa@fedoraproject.org CC: haskell-devel@lists.fedoraproject.org, petersen@redhat.com
Description of problem: After adding CFLAGS to %cabal_configure build.log's now include
+ ./Setup configure --prefix=/usr --libdir=/usr/lib64 --docdir=/usr/share/doc/cabal-rpm '--libsubdir=$compiler/$pkgid' '--datasubdir=$pkgid' --ghc --enable-executable-dynamic '--ghc-options= -optc-O2 -optc-g -optc-pipe -optc-Wall -optc-Werror=format-security -optc-Wp,-D_FORTIFY_SOURCE=2 -optc-fexceptions -optc-fstack-protector-strong -optc--param=ssp-buffer-size=4 -optc-grecord-gcc-switches -optc-m64 -optc-mtune=generic -optl-Wl,-z,relro' Configuring cabal-rpm-0.9.2... /tmp/18846.c: In function 'foo': /tmp/18846.c:1:1: warning: control reaches end of non-void function [-Wreturn-type] int foo() {} ^
This caused by -Wall and something in Cabal I guess. Grepping the Cabal source only shows up:
./Distribution/Simple/GHC.hs:362: hPutStrLn testchnd "int foo() { return 0; }"
Version-Release number of selected component (if applicable): ghc-rpm-macros-1.2.17-1.fc21 ghc-rpm-macros-1.3.9-1.fc22
Steps to Reproduce: 1. build Fedora Haskell package Cabal-based package
Actual results: : warning: control reaches end of non-void function [-Wreturn-type] :
Expected results: no warning
Additional info: Should probably report this upstream.
It can be reproduced by:
./Setup configure --ghc-option=-optc-Wall
https://bugzilla.redhat.com/show_bug.cgi?id=1175667
--- Comment #1 from Jens Petersen petersen@redhat.com --- Looks like this is fixed with Cabal-1.18 (ghc-7.8.3+) but happens with ghc-7.6.3 Cabal.
https://bugzilla.redhat.com/show_bug.cgi?id=1175667
Jens Petersen petersen@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Version|rawhide |21
--- Comment #2 from Jens Petersen petersen@redhat.com --- Moving to F21 since this will not affect ghc-7.8.
https://bugzilla.redhat.com/show_bug.cgi?id=1175667
Fedora Update System updates@fedoraproject.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |MODIFIED
https://bugzilla.redhat.com/show_bug.cgi?id=1175667
--- Comment #3 from Fedora Update System updates@fedoraproject.org --- ghc-rpm-macros-1.2.18-1.fc21 has been submitted as an update for Fedora 21. https://admin.fedoraproject.org/updates/ghc-rpm-macros-1.2.18-1.fc21
https://bugzilla.redhat.com/show_bug.cgi?id=1175667
Fedora Update System updates@fedoraproject.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|MODIFIED |ON_QA
--- Comment #4 from Fedora Update System updates@fedoraproject.org --- Package ghc-rpm-macros-1.2.18-1.fc21: * should fix your issue, * was pushed to the Fedora 21 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing ghc-rpm-macros-1.2.18-1.fc21' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2015-0932/ghc-rpm-macros-1.2.... then log in and leave karma (feedback).
https://bugzilla.redhat.com/show_bug.cgi?id=1175667
--- Comment #5 from Fedora Update System updates@fedoraproject.org --- ghc-rpm-macros-1.2.19-1.fc21 has been submitted as an update for Fedora 21. https://admin.fedoraproject.org/updates/ghc-rpm-macros-1.2.19-1.fc21
https://bugzilla.redhat.com/show_bug.cgi?id=1175667
Fedora Update System updates@fedoraproject.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|ON_QA |CLOSED Fixed In Version| |ghc-rpm-macros-1.2.19-1.fc2 | |1 Resolution|--- |ERRATA Last Closed| |2015-02-20 03:33:39
--- Comment #6 from Fedora Update System updates@fedoraproject.org --- ghc-rpm-macros-1.2.19-1.fc21 has been pushed to the Fedora 21 stable repository. If problems still persist, please make note of it in this bug report.
haskell-devel@lists.fedoraproject.org