Commit 5b0191f7 authored by Edward Z. Yang's avatar Edward Z. Yang

Update Cabal to HEAD, IPID renamed to Component ID.

This commit contains a Cabal submodule update which unifies installed
package IDs and package keys under a single notion, a Component ID.
We update GHC to keep follow this unification.  However, this commit
does NOT rename installed package ID to component ID and package key to
unit ID; the plan is to do that in a companion commit.

    - Compiler info now has "Requires unified installed package IDs"

    - 'exposed' is now expected to contain unit keys, not IPIDs.

    - Shadowing is no more.  We now just have a very simple strategy
      to deal with duplicate unit keys in combined package databases:
      if their ABIs are the same, use the latest one; otherwise error.
      Package databases maintain the invariant that there can only
      be one entry of a unit ID.
Signed-off-by: default avatarEdward Z. Yang <ezyang@cs.stanford.edu>

Test Plan: validate

Reviewers: simonpj, austin, bgamari, hvr, goldfire

Subscribers: thomie

Differential Revision: https://phabricator.haskell.org/D1184

GHC Trac Issues: #10714
parent 729bf08e
......@@ -1091,8 +1091,7 @@ linkPackages' dflags new_pks pls = do
| Just pkg_cfg <- lookupPackage dflags new_pkg
= do { -- Link dependents first
pkgs' <- link pkgs [ resolveInstalledPackageId dflags ipid
| ipid <- depends pkg_cfg ]
pkgs' <- link pkgs (depends pkg_cfg)
-- Now link the package itself
; linkPackage dflags pkg_cfg
; return (new_pkg : pkgs') }
......
......@@ -1913,7 +1913,7 @@ parseSigOf str = case filter ((=="").snd) (readP_to_S parse str) of
m <- tok $ parseModule
return (n, m)
parseModule = do
pk <- munch1 (\c -> isAlphaNum c || c `elem` "-_")
pk <- munch1 (\c -> isAlphaNum c || c `elem` "-_.")
_ <- R.char ':'
m <- parseModuleName
return (mkModule (stringToPackageKey pk) m)
......@@ -4072,6 +4072,7 @@ compilerInfo dflags
("Support parallel --make", "YES"),
("Support reexported-modules", "YES"),
("Support thinning and renaming package flags", "YES"),
("Requires unified installed package IDs", "YES"),
("Uses package keys", "YES"),
("Dynamic by default", if dYNAMIC_BY_DEFAULT dflags
then "YES" else "NO"),
......
......@@ -1543,15 +1543,8 @@ Note [Printing package keys]
In the old days, original names were tied to PackageIds, which directly
corresponded to the entities that users wrote in Cabal files, and were perfectly
suitable for printing when we need to disambiguate packages. However, with
PackageKey, the situation is different. First, the key is not a human readable
at all, so we need to consult the package database to find the appropriate
PackageId to display. Second, there may be multiple copies of a library visible
with the same PackageId, in which case we need to disambiguate. For now,
we just emit the actual package key (which the user can go look up); however,
another scheme is to (recursively) say which dependencies are different.
NB: When we extend package keys to also have holes, we will have to disambiguate
those as well.
PackageKey, the situation can be different: if the key is instantiated with
some holes, we should try to give the user some more useful information.
-}
-- | Creates some functions that work out the best ways to format
......
......@@ -128,7 +128,6 @@ pprPackageConfig InstalledPackageInfo {..} =
field "name" (ppr packageName),
field "version" (text (showVersion packageVersion)),
field "id" (ppr installedPackageId),
field "key" (ppr packageKey),
field "exposed" (ppr exposed),
field "exposed-modules"
(if all isExposedModule exposedModules
......
This diff is collapsed.
Subproject commit e6304ff660ca629b1b664f0848a601959e31cb31
Subproject commit b083151f2a01ad7245f21502fd20f21189ab7665
......@@ -73,7 +73,8 @@ data InstalledPackageInfo instpkgid srcpkgid srcpkgname pkgkey modulename
packageName :: srcpkgname,
packageVersion :: Version,
packageKey :: pkgkey,
depends :: [instpkgid],
abiHash :: String,
depends :: [pkgkey],
importDirs :: [FilePath],
hsLibraries :: [String],
extraLibraries :: [String],
......@@ -87,9 +88,9 @@ data InstalledPackageInfo instpkgid srcpkgid srcpkgname pkgkey modulename
includeDirs :: [FilePath],
haddockInterfaces :: [FilePath],
haddockHTMLs :: [FilePath],
exposedModules :: [ExposedModule instpkgid modulename],
exposedModules :: [ExposedModule pkgkey modulename],
hiddenModules :: [modulename],
instantiatedWith :: [(modulename,OriginalModule instpkgid modulename)],
instantiatedWith :: [(modulename,OriginalModule pkgkey modulename)],
exposed :: Bool,
trusted :: Bool
}
......@@ -99,9 +100,9 @@ data InstalledPackageInfo instpkgid srcpkgid srcpkgname pkgkey modulename
-- plus module name) representing where a module was *originally* defined
-- (i.e., the 'exposedReexport' field of the original ExposedModule entry should
-- be 'Nothing'). Invariant: an OriginalModule never points to a reexport.
data OriginalModule instpkgid modulename
data OriginalModule pkgkey modulename
= OriginalModule {
originalPackageId :: instpkgid,
originalPackageId :: pkgkey,
originalModuleName :: modulename
}
deriving (Eq, Show)
......@@ -128,11 +129,11 @@ data OriginalModule instpkgid modulename
-- We use two 'Maybe' data types instead of an ADT with four branches or
-- four fields because this representation allows us to treat
-- reexports/signatures uniformly.
data ExposedModule instpkgid modulename
data ExposedModule pkgkey modulename
= ExposedModule {
exposedName :: modulename,
exposedReexport :: Maybe (OriginalModule instpkgid modulename),
exposedSignature :: Maybe (OriginalModule instpkgid modulename)
exposedReexport :: Maybe (OriginalModule pkgkey modulename),
exposedSignature :: Maybe (OriginalModule pkgkey modulename)
}
deriving (Eq, Show)
......@@ -150,6 +151,7 @@ emptyInstalledPackageInfo =
packageName = fromStringRep BS.empty,
packageVersion = Version [] [],
packageKey = fromStringRep BS.empty,
abiHash = "",
depends = [],
importDirs = [],
hsLibraries = [],
......@@ -301,7 +303,7 @@ instance (BinaryStringRep a, BinaryStringRep b, BinaryStringRep c,
put (InstalledPackageInfo
installedPackageId sourcePackageId
packageName packageVersion packageKey
depends importDirs
abiHash depends importDirs
hsLibraries extraLibraries extraGHCiLibraries libraryDirs
frameworks frameworkDirs
ldOptions ccOptions
......@@ -314,6 +316,7 @@ instance (BinaryStringRep a, BinaryStringRep b, BinaryStringRep c,
put (toStringRep packageName)
put packageVersion
put (toStringRep packageKey)
put abiHash
put (map toStringRep depends)
put importDirs
put hsLibraries
......@@ -340,6 +343,7 @@ instance (BinaryStringRep a, BinaryStringRep b, BinaryStringRep c,
packageName <- get
packageVersion <- get
packageKey <- get
abiHash <- get
depends <- get
importDirs <- get
hsLibraries <- get
......@@ -364,6 +368,7 @@ instance (BinaryStringRep a, BinaryStringRep b, BinaryStringRep c,
(fromStringRep sourcePackageId)
(fromStringRep packageName) packageVersion
(fromStringRep packageKey)
abiHash
(map fromStringRep depends)
importDirs
hsLibraries extraLibraries extraGHCiLibraries libraryDirs
......
......@@ -5,7 +5,7 @@
name: rts
version: 1.0
id: builtin_rts
id: rts
key: rts
license: BSD3
maintainer: glasgow-haskell-users@haskell.org
......
......@@ -128,6 +128,7 @@ mk/ghcconfig*_bin_ghc*.exe.mk
/tests/cabal/localT1750.package.conf/
/tests/cabal/localshadow1.package.conf/
/tests/cabal/localshadow2.package.conf/
/tests/cabal/localshadow3.package.conf/
/tests/cabal/package.conf.*/
/tests/cabal/recache_reexport_db/package.cache
/tests/cabal/shadow.hs
......
......@@ -127,43 +127,51 @@ T1750:
PKGCONFSHADOW1=localshadow1.package.conf
PKGCONFSHADOW2=localshadow2.package.conf
PKGCONFSHADOW3=localshadow3.package.conf
LOCAL_GHC_PKGSHADOW1 = '$(GHC_PKG)' --no-user-package-db -f $(PKGCONFSHADOW1)
LOCAL_GHC_PKGSHADOW2 = '$(GHC_PKG)' --no-user-package-db -f $(PKGCONFSHADOW2)
LOCAL_GHC_PKGSHADOW3 = '$(GHC_PKG)' --no-user-package-db -f $(PKGCONFSHADOW1) -f $(PKGCONFSHADOW2)
LOCAL_GHC_PKGSHADOW3 = '$(GHC_PKG)' --no-user-package-db -f $(PKGCONFSHADOW3)
LOCAL_GHC_PKGSHADOW12 = '$(GHC_PKG)' --no-user-package-db -f $(PKGCONFSHADOW1) -f $(PKGCONFSHADOW2)
LOCAL_GHC_PKGSHADOW13 = '$(GHC_PKG)' --no-user-package-db -f $(PKGCONFSHADOW1) -f $(PKGCONFSHADOW3)
# Test package shadowing behaviour.
#
# localshadow1.package.conf: shadowdep-1-XXX <- shadow-1-XXX
# localshadow2.package.conf: shadow-1-YYY
#
# shadow-1-XXX will be shadowed by shadow-1-YYY, thus invalidating
# shadowdep-1-XXX.
# localshadow2.package.conf: shadow-1-XXX
#
# If the ABI hash of boths shadow-1s are the same, we'll just accept
# the later shadow version. However, if the ABIs are different, we
# should complain!
shadow:
rm -rf $(PKGCONFSHADOW1) $(PKGCONFSHADOW2) shadow.hs shadow.o shadow.hi shadow.out shadow.hs shadow.hi
rm -rf $(PKGCONFSHADOW1) $(PKGCONFSHADOW2) $(PKGCONFSHADOW3) shadow.hs shadow.o shadow.hi shadow.out shadow.hs shadow.hi
$(LOCAL_GHC_PKGSHADOW1) init $(PKGCONFSHADOW1)
$(LOCAL_GHC_PKGSHADOW2) init $(PKGCONFSHADOW2)
$(LOCAL_GHC_PKGSHADOW3) init $(PKGCONFSHADOW3)
$(LOCAL_GHC_PKGSHADOW1) register -v0 --force shadow1.pkg
$(LOCAL_GHC_PKGSHADOW1) register -v0 --force shadow2.pkg
$(LOCAL_GHC_PKGSHADOW2) register -v0 --force shadow3.pkg
$(LOCAL_GHC_PKGSHADOW3) list
$(LOCAL_GHC_PKGSHADOW3) register -v0 --force shadow1.pkg
@echo "databases 1 and 2:"
$(LOCAL_GHC_PKGSHADOW12) list
@echo "databases 1 and 3:"
$(LOCAL_GHC_PKGSHADOW13) list
echo "main = return ()" >shadow.hs
#
# In this test, shadow-1-XXX is shadowed by shadow-1-YYY, which causes
# shadowdep-1-XXX to be unavailable:
# In this test, shadow-1-XXX with ABI hash aaa conflicts with shadow-1-XXX with
# ABI hash bbb, so GHC errors
#
@echo "should FAIL:"
'$(TEST_HC)' $(TEST_HC_OPTS) -package-db $(PKGCONFSHADOW1) -package-db $(PKGCONFSHADOW2) -package shadowdep -c shadow.hs -fno-code || true
#
# Reversing the order of the package.conf files should fix the problem:
if '$(TEST_HC)' $(TEST_HC_OPTS) -package-db $(PKGCONFSHADOW1) -package-db $(PKGCONFSHADOW2) -package shadowdep -c shadow.hs -fno-code; then false; else true; fi
#
@echo "should SUCCEED:"
'$(TEST_HC)' $(TEST_HC_OPTS) -package-db $(PKGCONFSHADOW2) -package-db $(PKGCONFSHADOW1) -package shadowdep -c shadow.hs -fno-code || true
# Reversing the orders of the configs does not fix the problem
#
@echo "should FAIL:"
if '$(TEST_HC)' $(TEST_HC_OPTS) -package-db $(PKGCONFSHADOW2) -package-db $(PKGCONFSHADOW1) -package shadowdep -c shadow.hs -fno-code; then false; else true; fi
#
# We can also fix the problem by using an explicit -package-id flag to
# specify a package we really want to use:
# When the ABIs are the same, there is no problem
#
@echo "should SUCCEED:"
'$(TEST_HC)' $(TEST_HC_OPTS) -package-db $(PKGCONFSHADOW1) -package-db $(PKGCONFSHADOW2) -package-id shadowdep-1-XXX -c shadow.hs -fno-code
'$(TEST_HC)' $(TEST_HC_OPTS) -package-db $(PKGCONFSHADOW3) -package-db $(PKGCONFSHADOW1) -package shadowdep -c shadow.hs -fno-code
# If we pass --global, we should ignore instances in the user database
T5442a:
......@@ -210,7 +218,7 @@ T5442d:
'$(GHC_PKG)' init package.conf.T5442d.user
'$(GHC_PKG)' init package.conf.T5442d.extra
'$(GHC_PKG)' -f package.conf.T5442d.global register --force-files shadow1.pkg 2>/dev/null
'$(GHC_PKG)' -f package.conf.T5442d.user register --force-files shadow3.pkg 2>/dev/null
'$(GHC_PKG)' -f package.conf.T5442d.user register --force-files shadow4.pkg 2>/dev/null
'$(GHC_PKG)' --global-package-db=package.conf.T5442d.global -f package.conf.T5442d.extra register --force-files shadow2.pkg 2>/dev/null
'$(GHC_PKG)' --global-package-db=package.conf.T5442d.global --user-package-db=package.conf.T5442d.user -f package.conf.T5442d.extra --global unregister shadow --force
@echo "global (should be empty):"
......
name: T1750A
version: 1
id: T1750A-1-XXX
key: T1750A-1
depends: T1750B-1-XXX
name: T1750B
version: 1
id: T1750B-1-XXX
key: T1750B-1
depends: T1750A-1-XXX
Reading package info from "shadow1.pkg" ... done.
Reading package info from "shadow3.pkg" ... done.
Reading package info from "shadow4.pkg" ... done.
Reading package info from "shadow2.pkg" ... done.
global (should be empty):
user:
shadow-1
shadow-2
extra:
shadowdep-1
......@@ -20,14 +20,14 @@ cabal03: clean
'$(GHC_PKG)' init tmp.d
'$(TEST_HC)' -v0 --make Setup
cd p && $(SETUP) clean
cd p && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --disable-optimisation --ghc-pkg-option=--force
cd p && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --disable-optimisation --ghc-pkg-option=--force --ipid p-noopt
cd p && $(SETUP) build
cd p && $(SETUP) register
cd q && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --ghc-pkg-option=--force
cd q && $(SETUP) build
cd q && $(SETUP) register
cd p && $(SETUP) clean
cd p && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --ghc-pkg-option=--force
cd p && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --ghc-pkg-option=--force --ipid p-withopt
cd p && $(SETUP) build
cd p && $(SETUP) register
cd r && ! ../Setup configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --ghc-pkg-option=--force
......
......@@ -4,7 +4,7 @@ include $(TOP)/mk/test.mk
SETUP=../Setup -v0
# This test is for packages whose package IDs overlap, but whose package keys
# This test is for packages whose package IDs overlap, but whose IPIDs
# do not.
#
# 1. install p-1.0
......@@ -15,7 +15,7 @@ SETUP=../Setup -v0
# 6. install r-1.0 asking for p-1.0
#
# The notable steps are (4), which previously would have required a reinstall,
# and (6), where the dependency solver picks between two package keys with the
# and (6), where the dependency solver picks between two IPIDs with the
# same package ID based on their depenencies.
#
# ./Setup configure is pretty dumb, so we spoonfeed it precisely the
......@@ -29,7 +29,7 @@ cabal06: clean
cd p-1.0 && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --prefix='$(PWD)/inst-a' --ghc-pkg-options='--enable-multi-instance'
cd p-1.0 && $(SETUP) build
cd p-1.0 && $(SETUP) copy
cd p-1.0 && $(SETUP) register
(cd p-1.0 && $(SETUP) register --print-ipid) > tmp_p_1_0
cd q && $(SETUP) clean
cd q && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --prefix='$(PWD)/inst-b' --ghc-pkg-options='--enable-multi-instance'
cd q && $(SETUP) build
......@@ -39,16 +39,16 @@ cabal06: clean
cd p-1.1 && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --prefix='$(PWD)/inst-c' --ghc-pkg-options='--enable-multi-instance'
cd p-1.1 && $(SETUP) build
cd p-1.1 && $(SETUP) copy
cd p-1.1 && $(SETUP) register
(cd p-1.1 && $(SETUP) register --print-ipid) > tmp_p_1_1
cd q && $(SETUP) clean
cd q && $(SETUP) configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --constraint="p==1.1" --prefix='$(PWD)/inst-d' --ghc-pkg-options='--enable-multi-instance'
cd q && $(SETUP) build
cd q && $(SETUP) copy
(cd q && $(SETUP) register --print-ipid) > tmp_second_q
@echo "Does the first instance of q depend on p-1.0?"
'$(GHC_PKG)' field --ipid `cat tmp_first_q` depends -f tmp.d | grep p-1.0 | wc -l | sed 's/[[:space:]]//g'
'$(GHC_PKG)' field --ipid `cat tmp_first_q` depends -f tmp.d | grep `cat tmp_p_1_0` | wc -l | sed 's/[[:space:]]//g'
@echo "Does the second instance of q depend on p-1.0?"
'$(GHC_PKG)' field --ipid `cat tmp_second_q` depends -f tmp.d | grep p-1.1 | wc -l | sed 's/[[:space:]]//g'
'$(GHC_PKG)' field --ipid `cat tmp_second_q` depends -f tmp.d | grep `cat tmp_p_1_1` | wc -l | sed 's/[[:space:]]//g'
cd r && $(SETUP) clean
cd r && ../Setup configure $(CABAL_MINIMAL_BUILD) --with-ghc='$(TEST_HC)' --ghc-options='$(TEST_HC_OPTS)' --package-db=../tmp.d --dependency="q=`cat ../tmp_first_q`" --constraint="p==1.0" --prefix='$(PWD)/inst-e' --ghc-pkg-options='--enable-multi-instance'
cd r && $(SETUP) build
......
......@@ -3,10 +3,7 @@ if default_testopts.cleanup != '':
else:
cleanup = ''
def normaliseContainersPackage(str):
return re.sub('containers-[^@]+@[A-Za-z0-9]+', 'containers-<VERSION>@<HASH>', str)
test('cabal07',
normalise_errmsg_fun(normaliseContainersPackage),
normalise_version('containers'),
run_command,
['$MAKE -s --no-print-directory cabal07 ' + cleanup])
Q.hs:3:8: error:
Could not find module ‘Data.Set’
It is a member of the hidden package ‘containers-0.5.6.2@0tT640fErehCGZtZRn6YbE’.
It is a member of the hidden package ‘containers-0.5.6.2@containers-0.5.6.2’.
Perhaps you need to add ‘containers’ to the build-depends in your .cabal file.
Use -v to see a list of the files searched for.
......@@ -4,7 +4,7 @@ Reading package info from "test.pkg" ... done.
name: testpkg
version: 1.2.3.4
id: testpkg-1.2.3.4-XXX
key: testpkg-1.2.3.4
key: testpkg-1.2.3.4-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -19,17 +19,18 @@ exposed: True
exposed-modules:
A
hidden-modules: B C.D
abi:
trusted: False
import-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
hs-libraries: testpkg-1.2.3.4
hs-libraries: testpkg-1.2.3.4-XXX
include-dirs: /usr/local/include/testpkg "c:/Program Files/testpkg"
pkgroot:
name: testpkg
version: 1.2.3.4
id: testpkg-1.2.3.4-XXX
key: testpkg-1.2.3.4
key: testpkg-1.2.3.4-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -44,10 +45,11 @@ exposed: True
exposed-modules:
A
hidden-modules: B C.D
abi:
trusted: False
import-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
hs-libraries: testpkg-1.2.3.4
hs-libraries: testpkg-1.2.3.4-XXX
include-dirs: /usr/local/include/testpkg "c:/Program Files/testpkg"
pkgroot:
......@@ -60,7 +62,7 @@ local01.package.conf:
name: testpkg
version: 2.0
id: testpkg-2.0-XXX
key: testpkg-2.0
key: testpkg-2.0-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -75,17 +77,18 @@ exposed: False
exposed-modules:
A
hidden-modules: B C.D C.E
abi:
trusted: False
import-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
hs-libraries: testpkg-2.0
hs-libraries: testpkg-2.0-XXX
include-dirs: /usr/local/include/testpkg "c:/Program Files/testpkg"
pkgroot:
name: testpkg
version: 2.0
id: testpkg-2.0-XXX
key: testpkg-2.0
key: testpkg-2.0-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -100,17 +103,18 @@ exposed: False
exposed-modules:
A
hidden-modules: B C.D C.E
abi:
trusted: False
import-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
hs-libraries: testpkg-2.0
hs-libraries: testpkg-2.0-XXX
include-dirs: /usr/local/include/testpkg "c:/Program Files/testpkg"
pkgroot:
---
name: testpkg
version: 1.2.3.4
id: testpkg-1.2.3.4-XXX
key: testpkg-1.2.3.4
key: testpkg-1.2.3.4-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -125,10 +129,11 @@ exposed: True
exposed-modules:
A
hidden-modules: B C.D
abi:
trusted: False
import-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
hs-libraries: testpkg-1.2.3.4
hs-libraries: testpkg-1.2.3.4-XXX
include-dirs: /usr/local/include/testpkg "c:/Program Files/testpkg"
pkgroot:
......@@ -142,7 +147,7 @@ Reading package info from "test3.pkg" ... done.
name: testpkg
version: 1.2.3.4
id: testpkg-1.2.3.4-XXX
key: testpkg-1.2.3.4
key: testpkg-1.2.3.4-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -157,10 +162,11 @@ exposed: False
exposed-modules:
A
hidden-modules: B C.D
abi:
trusted: False
import-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg "c:/Program Files/testpkg"
hs-libraries: testpkg-1.2.3.4
hs-libraries: testpkg-1.2.3.4-XXX
include-dirs: /usr/local/include/testpkg "c:/Program Files/testpkg"
pkgroot:
......
......@@ -7,7 +7,7 @@ testpkg-1.2.3.4: include-dirs: c:/Program Files/testpkg is a relative path which
testpkg-1.2.3.4: cannot find any of ["A.hi","A.p_hi","A.dyn_hi"] (ignoring)
testpkg-1.2.3.4: cannot find any of ["B.hi","B.p_hi","B.dyn_hi"] (ignoring)
testpkg-1.2.3.4: cannot find any of ["C/D.hi","C/D.p_hi","C/D.dyn_hi"] (ignoring)
testpkg-1.2.3.4: cannot find any of ["libtestpkg-1.2.3.4.a","libtestpkg-1.2.3.4.p_a","libtestpkg-1.2.3.4-ghc<VERSION>.so","libtestpkg-1.2.3.4-ghc<VERSION>.dylib","testpkg-1.2.3.4-ghc<VERSION>.dll"] on library path (ignoring)
testpkg-1.2.3.4: cannot find any of ["libtestpkg-1.2.3.4-XXX.a","libtestpkg-1.2.3.4-XXX.p_a","libtestpkg-1.2.3.4-XXX-ghc7.11.20150825.so","libtestpkg-1.2.3.4-XXX-ghc7.11.20150825.dylib","testpkg-1.2.3.4-XXX-ghc7.11.20150825.dll"] on library path (ignoring)
testpkg-2.0: Warning: library-dirs: /usr/local/lib/testpkg doesn't exist or isn't a directory
testpkg-2.0: Warning: include-dirs: /usr/local/include/testpkg doesn't exist or isn't a directory
testpkg-2.0: import-dirs: /usr/local/lib/testpkg doesn't exist or isn't a directory (ignoring)
......@@ -18,7 +18,7 @@ testpkg-2.0: cannot find any of ["A.hi","A.p_hi","A.dyn_hi"] (ignoring)
testpkg-2.0: cannot find any of ["B.hi","B.p_hi","B.dyn_hi"] (ignoring)
testpkg-2.0: cannot find any of ["C/D.hi","C/D.p_hi","C/D.dyn_hi"] (ignoring)
testpkg-2.0: cannot find any of ["C/E.hi","C/E.p_hi","C/E.dyn_hi"] (ignoring)
testpkg-2.0: cannot find any of ["libtestpkg-2.0.a","libtestpkg-2.0.p_a","libtestpkg-2.0-ghc<VERSION>.so","libtestpkg-2.0-ghc<VERSION>.dylib","testpkg-2.0-ghc<VERSION>.dll"] on library path (ignoring)
testpkg-2.0: cannot find any of ["libtestpkg-2.0-XXX.a","libtestpkg-2.0-XXX.p_a","libtestpkg-2.0-XXX-ghc7.11.20150825.so","libtestpkg-2.0-XXX-ghc7.11.20150825.dylib","testpkg-2.0-XXX-ghc7.11.20150825.dll"] on library path (ignoring)
testpkg-1.2.3.4: Warning: library-dirs: /usr/local/lib/testpkg doesn't exist or isn't a directory
testpkg-1.2.3.4: Warning: include-dirs: /usr/local/include/testpkg doesn't exist or isn't a directory
testpkg-1.2.3.4: import-dirs: /usr/local/lib/testpkg doesn't exist or isn't a directory (ignoring)
......@@ -28,4 +28,4 @@ testpkg-1.2.3.4: include-dirs: c:/Program Files/testpkg is a relative path which
testpkg-1.2.3.4: cannot find any of ["A.hi","A.p_hi","A.dyn_hi"] (ignoring)
testpkg-1.2.3.4: cannot find any of ["B.hi","B.p_hi","B.dyn_hi"] (ignoring)
testpkg-1.2.3.4: cannot find any of ["C/D.hi","C/D.p_hi","C/D.dyn_hi"] (ignoring)
testpkg-1.2.3.4: cannot find any of ["libtestpkg-1.2.3.4.a","libtestpkg-1.2.3.4.p_a","libtestpkg-1.2.3.4-ghc<VERSION>.so","libtestpkg-1.2.3.4-ghc<VERSION>.dylib","testpkg-1.2.3.4-ghc<VERSION>.dll"] on library path (ignoring)
testpkg-1.2.3.4: cannot find any of ["libtestpkg-1.2.3.4-XXX.a","libtestpkg-1.2.3.4-XXX.p_a","libtestpkg-1.2.3.4-XXX-ghc7.11.20150825.so","libtestpkg-1.2.3.4-XXX-ghc7.11.20150825.dylib","testpkg-1.2.3.4-XXX-ghc7.11.20150825.dll"] on library path (ignoring)
......@@ -9,7 +9,30 @@ There are problems in package testpkg-2.0:
cannot find any of ["B.hi","B.p_hi","B.dyn_hi"]
cannot find any of ["C/D.hi","C/D.p_hi","C/D.dyn_hi"]
cannot find any of ["C/E.hi","C/E.p_hi","C/E.dyn_hi"]
cannot find any of ["libtestpkg-2.0.a","libtestpkg-2.0.p_a","libtestpkg-2.0-ghc<VERSION>.so","libtestpkg-2.0-ghc<VERSION>.dylib","testpkg-2.0-ghc<VERSION>.dll"] on library path
cannot find any of ["libtestpkg-2.0-XXX.a","libtestpkg-2.0-XXX.p_a","libtestpkg-2.0-XXX-ghc7.11.20150825.so","libtestpkg-2.0-XXX-ghc7.11.20150825.dylib","testpkg-2.0-XXX-ghc7.11.20150825.dll"] on library path
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/compiler/stage2/doc/html/ghc/ghc.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/haskeline/dist-install/doc/html/haskeline/haskeline.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/terminfo/dist-install/doc/html/terminfo/terminfo.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/transformers/dist-install/doc/html/transformers/transformers.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/hoopl/dist-install/doc/html/hoopl/hoopl.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/bin-package-db/dist-install/doc/html/bin-package-db/bin-package-db.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/Cabal/Cabal/dist-install/doc/html/Cabal/Cabal.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/binary/dist-install/doc/html/binary/binary.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/template-haskell/dist-install/doc/html/template-haskell/template-haskell.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/pretty/dist-install/doc/html/pretty/pretty.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/hpc/dist-install/doc/html/hpc/hpc.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/process/dist-install/doc/html/process/process.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/directory/dist-install/doc/html/directory/directory.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/unix/dist-install/doc/html/unix/unix.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/time/dist-install/doc/html/time/time.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/containers/dist-install/doc/html/containers/containers.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/bytestring/dist-install/doc/html/bytestring/bytestring.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/deepseq/dist-install/doc/html/deepseq/deepseq.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/array/dist-install/doc/html/array/array.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/filepath/dist-install/doc/html/filepath/filepath.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/base/dist-install/doc/html/base/base.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/integer-gmp/dist-install/doc/html/integer-gmp/integer-gmp.haddock doesn't exist or isn't a file
Warning: haddock-interfaces: /home/hs01/ezyang/ghc-quick2/libraries/ghc-prim/dist-install/doc/html/ghc-prim/ghc-prim.haddock doesn't exist or isn't a file
The following packages are broken, either because they have a problem
listed above, or because they depend on a broken package.
......
<command line>: cannot satisfy -package shadowdep:
shadowdep-1-XXX is unusable due to missing or recursive dependencies:
shadow-1-XXX
(use -v for more information)
<command line>: package db: duplicate packages with incompatible ABIs:
shadow-1-XXX has ABIs: aaa, bbb
<command line>: package db: duplicate packages with incompatible ABIs:
shadow-1-XXX has ABIs: aaa, bbb
databases 1 and 2:
localshadow1.package.conf:
(shadow-1)
(shadowdep-1)
......@@ -5,6 +6,14 @@ localshadow1.package.conf:
localshadow2.package.conf:
(shadow-1)
databases 1 and 3:
localshadow1.package.conf:
(shadow-1)
(shadowdep-1)
localshadow3.package.conf:
(shadow-1)
should FAIL:
should FAIL:
should SUCCEED:
should SUCCEED:
name: shadow
version: 1
id: shadow-1-XXX
key: shadow-1
key: shadow-1-XXX
abi: aaa
depends:
name: shadowdep
version: 1
id: shadowdep-1-XXX
key: shadowdep-1
key: shadowdep-1-XXX
depends: shadow-1-XXX
name: shadow
version: 1
id: shadow-1-YYY
key: shadow-1
id: shadow-1-XXX
key: shadow-1-XXX
abi: bbb
depends:
name: shadow
version: 2
id: shadow-2-ZZZ
key: shadow-2-ZZZ
abi: zzz
depends:
name: testpkg
version: 1.2.3.4
id: testpkg-1.2.3.4-XXX
key: testpkg-1.2.3.4
key: testpkg-1.2.3.4-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -17,4 +17,4 @@ hidden-modules: B, "C.D"
import-dirs: /usr/local/lib/testpkg, "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg, "c:/Program Files/testpkg"
include-dirs: /usr/local/include/testpkg, "c:/Program Files/testpkg"
hs-libraries: testpkg-1.2.3.4
hs-libraries: testpkg-1.2.3.4-XXX
name: "testpkg"
version: 2.0
id: testpkg-2.0-XXX
key: testpkg-2.0
key: testpkg-2.0-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......@@ -17,4 +17,4 @@ hidden-modules: B, "C.D", "C.E"
import-dirs: /usr/local/lib/testpkg, "c:/Program Files/testpkg"
library-dirs: /usr/local/lib/testpkg, "c:/Program Files/testpkg"
include-dirs: /usr/local/include/testpkg, "c:/Program Files/testpkg"
hs-libraries: testpkg-2.0
hs-libraries: testpkg-2.0-XXX
name: "testpkg"
version: 3.0
id: testpkg-3.0-XXX
key: testpkg-3.0
key: testpkg-3.0-XXX
license: BSD3
copyright: (c) The Univsersity of Glasgow 2004
maintainer: glasgow-haskell-users@haskell.org
......
name: "testpkg"
version: 4.0
id: testpkg-4.0-XXX
key: testpkg-4.0
key: testpkg-4.0-XXX