Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 572504

Summary: dev-vcs/git-annex-5.20150731 fails to build with =dev-haskell/quickcheck-2.8.2 - Duplicate instance declarations
Product: Gentoo Linux Reporter: bugtrack
Component: Current packagesAssignee: Gentoo's Haskell Language team <haskell>
Status: RESOLVED FIXED    
Severity: normal CC: zeekec
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description bugtrack 2016-01-21 10:50:04 UTC
dev-vcs/git-annex-5.20150731 fails to build with =dev-haskell/quickcheck-2.8.2 
in QuickCheck.hs due to Duplicate instance declarations,
but builds fine with =dev-haskell/quickcheck-2.8.1

Reproducible: Always

Steps to Reproduce:
emerge -1v =dev-haskell/quickcheck-2.8.2 git-annex
Actual Results:  
(...)
>>> Source configured.
>>> Compiling source in /home/var/tmp/portage/portage/dev-vcs/git-annex-5.20150731/work/git-annex-5.20150731 ...
./setup build
Building git-annex-5.20150731...
Preprocessing executable 'git-annex' for git-annex-5.20150731...

BuildFlags.hs:36:2:
     warning: #warning Building without the testsuite. [-Wcpp]
     #warning Building without the testsuite.
      ^
[  1 of 510] Compiling Utility.Dot      ( Utility/Dot.hs, dist/build/git-annex/git-annex-tmp/Utility/Dot.dyn_o )
[  2 of 510] Compiling Utility.Mounts   ( dist/build/git-annex/git-annex-tmp/Utility/Mounts.hs, dist/build/git-annex/git-annex-tmp/Utility/Mounts.dyn_o )
[  3 of 510] Compiling BuildFlags       ( BuildFlags.hs, dist/build/git-annex/git-annex-tmp/BuildFlags.dyn_o )
[  4 of 510] Compiling Utility.Yesod    ( Utility/Yesod.hs, dist/build/git-annex/git-annex-tmp/Utility/Yesod.dyn_o )
[  5 of 510] Compiling Assistant.Types.BranchChange ( Assistant/Types/BranchChange.hs, dist/build/git-annex/git-annex-tmp/Assistant/Types/BranchChange.dyn_o )
[  6 of 510] Compiling Assistant.Types.TransferSlots ( Assistant/Types/TransferSlots.hs, dist/build/git-annex/git-annex-tmp/Assistant/Types/TransferSlots.dyn_o )
[  7 of 510] Compiling Assistant.Types.ThreadName ( Assistant/Types/ThreadName.hs, dist/build/git-annex/git-annex-tmp/Assistant/Types/ThreadName.dyn_o )
[  8 of 510] Compiling Utility.Tense    ( Utility/Tense.hs, dist/build/git-annex/git-annex-tmp/Utility/Tense.dyn_o )
[  9 of 510] Compiling Assistant.Types.Alert ( Assistant/Types/Alert.hs, dist/build/git-annex/git-annex-tmp/Assistant/Types/Alert.dyn_o )
[ 10 of 510] Compiling Types.Test       ( Types/Test.hs, dist/build/git-annex/git-annex-tmp/Types/Test.dyn_o )
[ 11 of 510] Compiling Utility.ThreadLock ( Utility/ThreadLock.hs, dist/build/git-annex/git-annex-tmp/Utility/ThreadLock.dyn_o )
[ 12 of 510] Compiling Utility.ThreadScheduler ( Utility/ThreadScheduler.hs, dist/build/git-annex/git-annex-tmp/Utility/ThreadScheduler.dyn_o )
[ 13 of 510] Compiling Utility.Base64   ( Utility/Base64.hs, dist/build/git-annex/git-annex-tmp/Utility/Base64.dyn_o )
[ 14 of 510] Compiling Utility.Shell    ( Utility/Shell.hs, dist/build/git-annex/git-annex-tmp/Utility/Shell.dyn_o )
[ 15 of 510] Compiling Utility.JSONStream ( Utility/JSONStream.hs, dist/build/git-annex/git-annex-tmp/Utility/JSONStream.dyn_o )
[ 16 of 510] Compiling Messages.JSON    ( Messages/JSON.hs, dist/build/git-annex/git-annex-tmp/Messages/JSON.dyn_o )
[ 17 of 510] Compiling Utility.Glob     ( Utility/Glob.hs, dist/build/git-annex/git-annex-tmp/Utility/Glob.dyn_o )
[ 18 of 510] Compiling Utility.Hash     ( Utility/Hash.hs, dist/build/git-annex/git-annex-tmp/Utility/Hash.dyn_o )
[ 19 of 510] Compiling Utility.Verifiable ( Utility/Verifiable.hs, dist/build/git-annex/git-annex-tmp/Utility/Verifiable.dyn_o )
[ 20 of 510] Compiling Types.DesktopNotify ( Types/DesktopNotify.hs, dist/build/git-annex/git-annex-tmp/Types/DesktopNotify.dyn_o )
[ 21 of 510] Compiling Types.NumCopies  ( Types/NumCopies.hs, dist/build/git-annex/git-annex-tmp/Types/NumCopies.dyn_o )
[ 22 of 510] Compiling Types.UUID       ( Types/UUID.hs, dist/build/git-annex/git-annex-tmp/Types/UUID.dyn_o )
[ 23 of 510] Compiling Types.Messages   ( Types/Messages.hs, dist/build/git-annex/git-annex-tmp/Types/Messages.dyn_o )
[ 24 of 510] Compiling Types.Group      ( Types/Group.hs, dist/build/git-annex/git-annex-tmp/Types/Group.dyn_o )
[ 25 of 510] Compiling Types.TrustLevel ( Types/TrustLevel.hs, dist/build/git-annex/git-annex-tmp/Types/TrustLevel.dyn_o )
[ 26 of 510] Compiling Types.BranchState ( Types/BranchState.hs, dist/build/git-annex/git-annex-tmp/Types/BranchState.dyn_o )
[ 27 of 510] Compiling Types.Availability ( Types/Availability.hs, dist/build/git-annex/git-annex-tmp/Types/Availability.dyn_o )
[ 28 of 510] Compiling Utility.Bloom    ( Utility/Bloom.hs, dist/build/git-annex/git-annex-tmp/Utility/Bloom.dyn_o )
[ 29 of 510] Compiling Utility.HumanNumber ( Utility/HumanNumber.hs, dist/build/git-annex/git-annex-tmp/Utility/HumanNumber.dyn_o )
[ 30 of 510] Compiling Utility.DataUnits ( Utility/DataUnits.hs, dist/build/git-annex/git-annex-tmp/Utility/DataUnits.dyn_o )
[ 31 of 510] Compiling Utility.LockPool.STM ( Utility/LockPool/STM.hs, dist/build/git-annex/git-annex-tmp/Utility/LockPool/STM.dyn_o )
[ 32 of 510] Compiling Logs.TimeStamp   ( Logs/TimeStamp.hs, dist/build/git-annex/git-annex-tmp/Logs/TimeStamp.dyn_o )
[ 33 of 510] Compiling Utility.PID      ( Utility/PID.hs, dist/build/git-annex/git-annex-tmp/Utility/PID.dyn_o )
[ 34 of 510] Compiling Utility.QuickCheck ( Utility/QuickCheck.hs, dist/build/git-annex/git-annex-tmp/Utility/QuickCheck.dyn_o )

Utility/QuickCheck.hs:24:10:
    Duplicate instance declarations:
      instance (Arbitrary k, Arbitrary v, Eq k, Ord k) =>
               Arbitrary (M.Map k v)
        -- Defined at Utility/QuickCheck.hs:24:10
      instance [safe] (Ord k, Arbitrary k, Arbitrary v) =>
                      Arbitrary (M.Map k v)
        -- Defined in ‘Test.QuickCheck.Arbitrary’

Utility/QuickCheck.hs:27:10:
    Duplicate instance declarations:
      instance (Arbitrary v, Eq v, Ord v) => Arbitrary (S.Set v)
        -- Defined at Utility/QuickCheck.hs:27:10
      instance [safe] (Ord a, Arbitrary a) => Arbitrary (S.Set a)
        -- Defined in ‘Test.QuickCheck.Arbitrary’
[ 35 of 510] Compiling Utility.Percentage ( Utility/Percentage.hs, dist/build/git-annex/git-annex-tmp/Utility/Percentage.dyn_o )
(...)
[163 of 510] Compiling Git.Remote.Remove ( Git/Remote/Remove.hs, dist/build/git-annex/git-annex-tmp/Git/Remote/Remove.dyn_o )
[164 of 510] Compiling Git.Command.Batch ( Git/Command/Batch.hs, dist/build/git-annex/git-annex-tmp/Git/Command/Batch.dyn_o )
[509 of 510] Compiling Test             ( Test.hs, dist/build/git-annex/git-annex-tmp/Test.dyn_o )

Test.hs:16:1: Warning:
    The import of ‘Options.Applicative’ is redundant
      except perhaps to import instances from ‘Options.Applicative’
    To import instances alone, use: import Options.Applicative()
 * ERROR: dev-vcs/git-annex-5.20150731::gentoo failed (compile phase):
 *   setup build failed
 * 
 * Call stack:
 *     ebuild.sh, line  133:  Called src_compile
 *   environment, line 3014:  Called haskell-cabal_src_compile
 *   environment, line 2128:  Called cabal_src_compile
 *   environment, line  939:  Called cabal-build
 *   environment, line  688:  Called die
 * The specific snippet of code:
 *       ./setup "$@" || die "setup build failed"
 * 
 * If you need support, post the output of `emerge --info '=dev-vcs/git-annex-5.20150731::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=dev-vcs/git-annex-5.20150731::gentoo'`.
 * The complete build log is located at '/home/var/tmp/portage/portage/dev-vcs/git-annex-5.20150731/temp/build.log'.
 * The ebuild environment file is located at '/home/var/tmp/portage/portage/dev-vcs/git-annex-5.20150731/temp/environment'.
 * Working directory: '/home/var/tmp/portage/portage/dev-vcs/git-annex-5.20150731/work/git-annex-5.20150731'
 * S: '/home/var/tmp/portage/portage/dev-vcs/git-annex-5.20150731/work/git-annex-5.20150731'


Expected Results:  
Compilation shall not fail ;)

echo "=dev-haskell/quickcheck-2.8.2" >> /etc/portage/package.mask/dev-haskell-quickcheck
emerge -1v dev-haskell/quickcheck dev-vcs/git-annex

helps temporarily as a workaround.
Comment 1 Matthias Maier gentoo-dev 2016-01-21 16:06:40 UTC
Also dev-vcs/git-annex-5.20151218:0/0::haskell fails.


[ 36 of 523] Compiling Utility.QuickCheck ( Utility/QuickCheck.hs, dist/build/git-annex/git-annex-tmp/Utility/QuickCheck.dyn_o )

Utility/QuickCheck.hs:24:10:
    Duplicate instance declarations:
      instance (Arbitrary k, Arbitrary v, Eq k, Ord k) =>
               Arbitrary (M.Map k v)
        -- Defined at Utility/QuickCheck.hs:24:10
      instance [safe] (Ord k, Arbitrary k, Arbitrary v) =>
                      Arbitrary (M.Map k v)
        -- Defined in ‘Test.QuickCheck.Arbitrary’
Comment 2 Sergei Trofimovich (RETIRED) gentoo-dev 2016-01-22 20:24:33 UTC
Pushed new version as:

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d22fc278d5994d554e99365e980d64237f2a9350

Thank you!
Comment 3 Sergei Trofimovich (RETIRED) gentoo-dev 2016-01-22 20:25:42 UTC
Sorry, didn't pay enough attention to my QC version.
I use outdated one.
Comment 4 Sergei Trofimovich (RETIRED) gentoo-dev 2016-01-22 21:05:21 UTC
Pushed fix as: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e93088f01d942229515808ff165d616b5191cc6a

Thanks again!