You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

test-multiarch-allowed 12 KiB

implement dpkgs vision of interpreting pkg:<arch> dependencies How the Multi-Arch field and pkg:<arch> dependencies interact was discussed at DebConf15 in the "MultiArch BoF". dpkg and apt (among other tools like dose) had a different interpretation in certain scenarios which we resolved by agreeing on dpkg view – and this commit realizes this agreement in code. As was the case so far libapt sticks to the idea of trying to hide MultiArch as much as possible from individual frontends and instead translates it to good old SingleArch. There are certainly situations which can be improved in frontends if they know that MultiArch is upon them, but these are improvements – not necessary changes needed to unbreak a frontend. The implementation idea is simple: If we parse a dependency on foo:amd64 the dependency is formed on a package 'foo:amd64' of arch 'any'. This package is provided by package 'foo' of arch 'amd64', but not by 'foo' of arch 'i386'. Both of those foo packages provide each other through (assuming foo is M-A:foreign) to allow a dependency on 'foo' to be satisfied by either foo of amd64 or i386. Packages can also declare to provide 'foo:amd64' which is translated to providing 'foo:amd64:any' as well. This indirection over provides was chosen as the alternative would be to teach dependency resolvers how to deal with architecture specific dependencies – which violates the design idea of avoiding resolver changes, especially as architecture-specific dependencies are a cornercase with quite a few subtil rules. Handling it all over versioned provides as we already did for M-A in general seems much simpler as it just works for them. This switch to :any has actually a "surprising" benefit as well: Even frontends showing a package name via .Name() [which doesn't show the architecture] will display the "architecture" for dependencies in which it was explicitely requested, while we will not show the 'strange' :any arch in FullName(true) [= pretty-print] either. Before you had to specialcase these and by default you wouldn't get these details shown. The only identifiable disadvantage is that this complicates error reporting and handling. apt-get's ShowBroken has existing problems with virtual packages [it just shows the name without any reason], so that has to be worked on eventually. The other case is that detecting if a package is completely unknown or if it was at least referenced somewhere needs to acount for this "split" – not that it makes a practical difference which error is shown… but its one of the improvements possible.
6 years ago
implement dpkgs vision of interpreting pkg:<arch> dependencies How the Multi-Arch field and pkg:<arch> dependencies interact was discussed at DebConf15 in the "MultiArch BoF". dpkg and apt (among other tools like dose) had a different interpretation in certain scenarios which we resolved by agreeing on dpkg view – and this commit realizes this agreement in code. As was the case so far libapt sticks to the idea of trying to hide MultiArch as much as possible from individual frontends and instead translates it to good old SingleArch. There are certainly situations which can be improved in frontends if they know that MultiArch is upon them, but these are improvements – not necessary changes needed to unbreak a frontend. The implementation idea is simple: If we parse a dependency on foo:amd64 the dependency is formed on a package 'foo:amd64' of arch 'any'. This package is provided by package 'foo' of arch 'amd64', but not by 'foo' of arch 'i386'. Both of those foo packages provide each other through (assuming foo is M-A:foreign) to allow a dependency on 'foo' to be satisfied by either foo of amd64 or i386. Packages can also declare to provide 'foo:amd64' which is translated to providing 'foo:amd64:any' as well. This indirection over provides was chosen as the alternative would be to teach dependency resolvers how to deal with architecture specific dependencies – which violates the design idea of avoiding resolver changes, especially as architecture-specific dependencies are a cornercase with quite a few subtil rules. Handling it all over versioned provides as we already did for M-A in general seems much simpler as it just works for them. This switch to :any has actually a "surprising" benefit as well: Even frontends showing a package name via .Name() [which doesn't show the architecture] will display the "architecture" for dependencies in which it was explicitely requested, while we will not show the 'strange' :any arch in FullName(true) [= pretty-print] either. Before you had to specialcase these and by default you wouldn't get these details shown. The only identifiable disadvantage is that this complicates error reporting and handling. apt-get's ShowBroken has existing problems with virtual packages [it just shows the name without any reason], so that has to be worked on eventually. The other case is that detecting if a package is completely unknown or if it was at least referenced somewhere needs to acount for this "split" – not that it makes a practical difference which error is shown… but its one of the improvements possible.
6 years ago
implement dpkgs vision of interpreting pkg:<arch> dependencies How the Multi-Arch field and pkg:<arch> dependencies interact was discussed at DebConf15 in the "MultiArch BoF". dpkg and apt (among other tools like dose) had a different interpretation in certain scenarios which we resolved by agreeing on dpkg view – and this commit realizes this agreement in code. As was the case so far libapt sticks to the idea of trying to hide MultiArch as much as possible from individual frontends and instead translates it to good old SingleArch. There are certainly situations which can be improved in frontends if they know that MultiArch is upon them, but these are improvements – not necessary changes needed to unbreak a frontend. The implementation idea is simple: If we parse a dependency on foo:amd64 the dependency is formed on a package 'foo:amd64' of arch 'any'. This package is provided by package 'foo' of arch 'amd64', but not by 'foo' of arch 'i386'. Both of those foo packages provide each other through (assuming foo is M-A:foreign) to allow a dependency on 'foo' to be satisfied by either foo of amd64 or i386. Packages can also declare to provide 'foo:amd64' which is translated to providing 'foo:amd64:any' as well. This indirection over provides was chosen as the alternative would be to teach dependency resolvers how to deal with architecture specific dependencies – which violates the design idea of avoiding resolver changes, especially as architecture-specific dependencies are a cornercase with quite a few subtil rules. Handling it all over versioned provides as we already did for M-A in general seems much simpler as it just works for them. This switch to :any has actually a "surprising" benefit as well: Even frontends showing a package name via .Name() [which doesn't show the architecture] will display the "architecture" for dependencies in which it was explicitely requested, while we will not show the 'strange' :any arch in FullName(true) [= pretty-print] either. Before you had to specialcase these and by default you wouldn't get these details shown. The only identifiable disadvantage is that this complicates error reporting and handling. apt-get's ShowBroken has existing problems with virtual packages [it just shows the name without any reason], so that has to be worked on eventually. The other case is that detecting if a package is completely unknown or if it was at least referenced somewhere needs to acount for this "split" – not that it makes a practical difference which error is shown… but its one of the improvements possible.
6 years ago
implement dpkgs vision of interpreting pkg:<arch> dependencies How the Multi-Arch field and pkg:<arch> dependencies interact was discussed at DebConf15 in the "MultiArch BoF". dpkg and apt (among other tools like dose) had a different interpretation in certain scenarios which we resolved by agreeing on dpkg view – and this commit realizes this agreement in code. As was the case so far libapt sticks to the idea of trying to hide MultiArch as much as possible from individual frontends and instead translates it to good old SingleArch. There are certainly situations which can be improved in frontends if they know that MultiArch is upon them, but these are improvements – not necessary changes needed to unbreak a frontend. The implementation idea is simple: If we parse a dependency on foo:amd64 the dependency is formed on a package 'foo:amd64' of arch 'any'. This package is provided by package 'foo' of arch 'amd64', but not by 'foo' of arch 'i386'. Both of those foo packages provide each other through (assuming foo is M-A:foreign) to allow a dependency on 'foo' to be satisfied by either foo of amd64 or i386. Packages can also declare to provide 'foo:amd64' which is translated to providing 'foo:amd64:any' as well. This indirection over provides was chosen as the alternative would be to teach dependency resolvers how to deal with architecture specific dependencies – which violates the design idea of avoiding resolver changes, especially as architecture-specific dependencies are a cornercase with quite a few subtil rules. Handling it all over versioned provides as we already did for M-A in general seems much simpler as it just works for them. This switch to :any has actually a "surprising" benefit as well: Even frontends showing a package name via .Name() [which doesn't show the architecture] will display the "architecture" for dependencies in which it was explicitely requested, while we will not show the 'strange' :any arch in FullName(true) [= pretty-print] either. Before you had to specialcase these and by default you wouldn't get these details shown. The only identifiable disadvantage is that this complicates error reporting and handling. apt-get's ShowBroken has existing problems with virtual packages [it just shows the name without any reason], so that has to be worked on eventually. The other case is that detecting if a package is completely unknown or if it was at least referenced somewhere needs to acount for this "split" – not that it makes a practical difference which error is shown… but its one of the improvements possible.
6 years ago
implement dpkgs vision of interpreting pkg:<arch> dependencies How the Multi-Arch field and pkg:<arch> dependencies interact was discussed at DebConf15 in the "MultiArch BoF". dpkg and apt (among other tools like dose) had a different interpretation in certain scenarios which we resolved by agreeing on dpkg view – and this commit realizes this agreement in code. As was the case so far libapt sticks to the idea of trying to hide MultiArch as much as possible from individual frontends and instead translates it to good old SingleArch. There are certainly situations which can be improved in frontends if they know that MultiArch is upon them, but these are improvements – not necessary changes needed to unbreak a frontend. The implementation idea is simple: If we parse a dependency on foo:amd64 the dependency is formed on a package 'foo:amd64' of arch 'any'. This package is provided by package 'foo' of arch 'amd64', but not by 'foo' of arch 'i386'. Both of those foo packages provide each other through (assuming foo is M-A:foreign) to allow a dependency on 'foo' to be satisfied by either foo of amd64 or i386. Packages can also declare to provide 'foo:amd64' which is translated to providing 'foo:amd64:any' as well. This indirection over provides was chosen as the alternative would be to teach dependency resolvers how to deal with architecture specific dependencies – which violates the design idea of avoiding resolver changes, especially as architecture-specific dependencies are a cornercase with quite a few subtil rules. Handling it all over versioned provides as we already did for M-A in general seems much simpler as it just works for them. This switch to :any has actually a "surprising" benefit as well: Even frontends showing a package name via .Name() [which doesn't show the architecture] will display the "architecture" for dependencies in which it was explicitely requested, while we will not show the 'strange' :any arch in FullName(true) [= pretty-print] either. Before you had to specialcase these and by default you wouldn't get these details shown. The only identifiable disadvantage is that this complicates error reporting and handling. apt-get's ShowBroken has existing problems with virtual packages [it just shows the name without any reason], so that has to be worked on eventually. The other case is that detecting if a package is completely unknown or if it was at least referenced somewhere needs to acount for this "split" – not that it makes a practical difference which error is shown… but its one of the improvements possible.
6 years ago
implement dpkgs vision of interpreting pkg:<arch> dependencies How the Multi-Arch field and pkg:<arch> dependencies interact was discussed at DebConf15 in the "MultiArch BoF". dpkg and apt (among other tools like dose) had a different interpretation in certain scenarios which we resolved by agreeing on dpkg view – and this commit realizes this agreement in code. As was the case so far libapt sticks to the idea of trying to hide MultiArch as much as possible from individual frontends and instead translates it to good old SingleArch. There are certainly situations which can be improved in frontends if they know that MultiArch is upon them, but these are improvements – not necessary changes needed to unbreak a frontend. The implementation idea is simple: If we parse a dependency on foo:amd64 the dependency is formed on a package 'foo:amd64' of arch 'any'. This package is provided by package 'foo' of arch 'amd64', but not by 'foo' of arch 'i386'. Both of those foo packages provide each other through (assuming foo is M-A:foreign) to allow a dependency on 'foo' to be satisfied by either foo of amd64 or i386. Packages can also declare to provide 'foo:amd64' which is translated to providing 'foo:amd64:any' as well. This indirection over provides was chosen as the alternative would be to teach dependency resolvers how to deal with architecture specific dependencies – which violates the design idea of avoiding resolver changes, especially as architecture-specific dependencies are a cornercase with quite a few subtil rules. Handling it all over versioned provides as we already did for M-A in general seems much simpler as it just works for them. This switch to :any has actually a "surprising" benefit as well: Even frontends showing a package name via .Name() [which doesn't show the architecture] will display the "architecture" for dependencies in which it was explicitely requested, while we will not show the 'strange' :any arch in FullName(true) [= pretty-print] either. Before you had to specialcase these and by default you wouldn't get these details shown. The only identifiable disadvantage is that this complicates error reporting and handling. apt-get's ShowBroken has existing problems with virtual packages [it just shows the name without any reason], so that has to be worked on eventually. The other case is that detecting if a package is completely unknown or if it was at least referenced somewhere needs to acount for this "split" – not that it makes a practical difference which error is shown… but its one of the improvements possible.
6 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300
  1. #!/bin/sh
  2. set -e
  3. TESTDIR=$(readlink -f $(dirname $0))
  4. . $TESTDIR/framework
  5. setupenvironment
  6. configarchitecture 'amd64' 'i386'
  7. insertpackage 'unstable' 'foo' 'amd64,i386' '1' 'Multi-Arch: allowed'
  8. insertpackage 'unstable' 'needsfoo' 'amd64,i386' '1' 'Depends: foo'
  9. insertpackage 'unstable' 'needsfooany' 'amd64,i386' '1' 'Depends: foo:any'
  10. insertpackage 'unstable' 'needsfoover1' 'amd64,i386' '1' 'Depends: foo:any (>= 1)'
  11. insertpackage 'unstable' 'needsfoover2' 'amd64,i386' '1' 'Depends: foo:any (>= 2)'
  12. insertpackage 'unstable' 'hatesfoo' 'amd64' '1' 'Conflicts: foo'
  13. insertpackage 'unstable' 'hatesfooany' 'amd64' '1' 'Conflicts: foo:any' # this makes no sense…?
  14. insertpackage 'unstable' 'hatesfoonative' 'amd64' '1' 'Conflicts: foo:amd64'
  15. insertpackage 'unstable' 'coolfoo' 'amd64' '1' 'Multi-Arch:allowed
  16. Provides: coolbar'
  17. insertpackage 'unstable' 'coolfoover' 'amd64' '1' 'Multi-Arch:allowed
  18. Provides: coolbar (= 2)'
  19. insertpackage 'unstable' 'needscoolfoo' 'amd64' '1' 'Depends: coolfoo, coolbar'
  20. insertpackage 'unstable' 'needscoolfooany' 'amd64' '1' 'Depends: coolfoo:any, coolbar:any'
  21. insertpackage 'unstable' 'needscoolfoover0' 'amd64' '1' 'Depends: coolfoo:any (>= 1), coolbar:any'
  22. insertpackage 'unstable' 'needscoolfoover1' 'amd64' '1' 'Depends: coolfoo:any (>= 1), coolbar:any (>= 1)'
  23. insertpackage 'unstable' 'needscoolfoover2' 'amd64' '1' 'Depends: coolfoo:any (>= 2), coolbar:any (>= 1)'
  24. insertpackage 'unstable' 'needscoolfoover3' 'amd64' '1' 'Depends: coolfoo:any (>= 2), coolbar:any (>= 3)'
  25. setupaptarchive
  26. BADPREFIX='Reading package lists...
  27. Building dependency tree...
  28. Some packages could not be installed. This may mean that you have
  29. requested an impossible situation or if you are using the unstable
  30. distribution that some required packages have not yet been created
  31. or been moved out of Incoming.
  32. The following information may help to resolve the situation:
  33. '
  34. solveableinsinglearch0() {
  35. testsuccessequal 'Reading package lists...
  36. Building dependency tree...
  37. The following additional packages will be installed:
  38. foo
  39. The following NEW packages will be installed:
  40. foo needsfoo
  41. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  42. Inst foo (1 unstable [amd64])
  43. Inst needsfoo (1 unstable [amd64])
  44. Conf foo (1 unstable [amd64])
  45. Conf needsfoo (1 unstable [amd64])' aptget install needsfoo -s
  46. }
  47. solveableinsinglearch0
  48. testsuccessequal 'Reading package lists...
  49. Building dependency tree...
  50. The following additional packages will be installed:
  51. foo:i386
  52. The following NEW packages will be installed:
  53. foo:i386 needsfoo:i386
  54. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  55. Inst foo:i386 (1 unstable [i386])
  56. Inst needsfoo:i386 (1 unstable [i386])
  57. Conf foo:i386 (1 unstable [i386])
  58. Conf needsfoo:i386 (1 unstable [i386])' aptget install needsfoo:i386 -s
  59. testfailureequal "$BADPREFIX
  60. The following packages have unmet dependencies:
  61. needsfoo:i386 : Depends: foo:i386 but it is not going to be installed
  62. E: Unable to correct problems, you have held broken packages." aptget install needsfoo:i386 foo:amd64 -s
  63. testfailureequal "$BADPREFIX
  64. The following packages have unmet dependencies:
  65. needsfoo : Depends: foo but it is not going to be installed
  66. E: Unable to correct problems, you have held broken packages." aptget install needsfoo foo:i386 -s
  67. solveableinsinglearch1() {
  68. testsuccessequal "Reading package lists...
  69. Building dependency tree...
  70. The following additional packages will be installed:
  71. foo
  72. The following NEW packages will be installed:
  73. foo $1
  74. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  75. Inst foo (1 unstable [amd64])
  76. Inst $1 (1 unstable [amd64])
  77. Conf foo (1 unstable [amd64])
  78. Conf $1 (1 unstable [amd64])" aptget install $1 -s
  79. }
  80. testneedsfooallgood() {
  81. solveableinsinglearch1 $1
  82. testsuccessequal "Reading package lists...
  83. Building dependency tree...
  84. The following additional packages will be installed:
  85. foo
  86. The following NEW packages will be installed:
  87. foo $1:i386
  88. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  89. Inst foo (1 unstable [amd64])
  90. Inst $1:i386 (1 unstable [i386])
  91. Conf foo (1 unstable [amd64])
  92. Conf $1:i386 (1 unstable [i386])" aptget install $1:i386 -s
  93. testsuccessequal "Reading package lists...
  94. Building dependency tree...
  95. The following NEW packages will be installed:
  96. foo:i386 $1:i386
  97. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  98. Inst foo:i386 (1 unstable [i386])
  99. Inst $1:i386 (1 unstable [i386])
  100. Conf foo:i386 (1 unstable [i386])
  101. Conf $1:i386 (1 unstable [i386])" aptget install $1:i386 foo:i386 -s
  102. testsuccessequal "Reading package lists...
  103. Building dependency tree...
  104. The following NEW packages will be installed:
  105. foo:i386 $1
  106. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  107. Inst foo:i386 (1 unstable [i386])
  108. Inst $1 (1 unstable [amd64])
  109. Conf foo:i386 (1 unstable [i386])
  110. Conf $1 (1 unstable [amd64])" aptget install $1 foo:i386 -s
  111. }
  112. testneedsfooallgood 'needsfooany'
  113. testneedsfooallgood 'needsfoover1'
  114. NEEDSFOO2NATIVE="$BADPREFIX
  115. The following packages have unmet dependencies:
  116. needsfoover2 : Depends: foo:any (>= 2)
  117. E: Unable to correct problems, you have held broken packages."
  118. NEEDSFOO2FOREIGN="$BADPREFIX
  119. The following packages have unmet dependencies:
  120. needsfoover2:i386 : Depends: foo:any (>= 2)
  121. E: Unable to correct problems, you have held broken packages."
  122. testfailureequal "$NEEDSFOO2NATIVE" aptget install needsfoover2 -s
  123. testfailureequal "$NEEDSFOO2FOREIGN" aptget install needsfoover2:i386 -s
  124. testfailureequal "$NEEDSFOO2FOREIGN" aptget install needsfoover2:i386 foo:i386 -s
  125. testfailureequal "$NEEDSFOO2NATIVE" aptget install needsfoover2 foo:i386 -s
  126. solveableinsinglearch2() {
  127. testfailureequal "$BADPREFIX
  128. The following packages have unmet dependencies:
  129. hatesfoo : Conflicts: foo but 1 is to be installed
  130. E: Unable to correct problems, you have held broken packages." aptget install foo hatesfoo -s
  131. # the message differs slightly between single and multiarch
  132. testfailuremsg 'E: Unable to correct problems, you have held broken packages.' aptget install foo hatesfooany -s
  133. testfailureequal "$BADPREFIX
  134. The following packages have unmet dependencies:
  135. hatesfoonative : Conflicts: foo:amd64
  136. E: Unable to correct problems, you have held broken packages." aptget install foo hatesfoonative -s
  137. }
  138. solveableinsinglearch2
  139. testfailureequal "$BADPREFIX
  140. The following packages have unmet dependencies:
  141. hatesfoo : Conflicts: foo:i386 but 1 is to be installed
  142. E: Unable to correct problems, you have held broken packages." aptget install foo:i386 hatesfoo -s
  143. testfailureequal "$BADPREFIX
  144. The following packages have unmet dependencies:
  145. hatesfooany : Conflicts: foo:any
  146. E: Unable to correct problems, you have held broken packages." aptget install foo:i386 hatesfooany -s
  147. testsuccessequal 'Reading package lists...
  148. Building dependency tree...
  149. The following NEW packages will be installed:
  150. foo:i386 hatesfoonative
  151. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  152. Inst foo:i386 (1 unstable [i386])
  153. Inst hatesfoonative (1 unstable [amd64])
  154. Conf foo:i386 (1 unstable [i386])
  155. Conf hatesfoonative (1 unstable [amd64])' aptget install foo:i386 hatesfoonative -s
  156. solveableinsinglearch3() {
  157. testsuccessequal "Reading package lists...
  158. Building dependency tree...
  159. The following additional packages will be installed:
  160. coolfoo
  161. The following NEW packages will be installed:
  162. coolfoo needscoolfoo
  163. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  164. Inst coolfoo (1 unstable [amd64])
  165. Inst needscoolfoo (1 unstable [amd64])
  166. Conf coolfoo (1 unstable [amd64])
  167. Conf needscoolfoo (1 unstable [amd64])" aptget install needscoolfoo -s
  168. testsuccessequal "Reading package lists...
  169. Building dependency tree...
  170. The following additional packages will be installed:
  171. coolfoo
  172. The following NEW packages will be installed:
  173. coolfoo coolfoover needscoolfoo
  174. 0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
  175. Inst coolfoo (1 unstable [amd64])
  176. Inst coolfoover (1 unstable [amd64])
  177. Inst needscoolfoo (1 unstable [amd64])
  178. Conf coolfoo (1 unstable [amd64])
  179. Conf coolfoover (1 unstable [amd64])
  180. Conf needscoolfoo (1 unstable [amd64])" aptget install needscoolfoo coolfoover -s
  181. testsuccessequal "Reading package lists...
  182. Building dependency tree...
  183. The following additional packages will be installed:
  184. coolfoo
  185. The following NEW packages will be installed:
  186. coolfoo needscoolfooany
  187. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  188. Inst coolfoo (1 unstable [amd64])
  189. Inst needscoolfooany (1 unstable [amd64])
  190. Conf coolfoo (1 unstable [amd64])
  191. Conf needscoolfooany (1 unstable [amd64])" aptget install needscoolfooany -s
  192. testsuccessequal 'Reading package lists...
  193. Building dependency tree...
  194. The following additional packages will be installed:
  195. coolfoo
  196. The following NEW packages will be installed:
  197. coolfoo needscoolfoover0
  198. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  199. Inst coolfoo (1 unstable [amd64])
  200. Inst needscoolfoover0 (1 unstable [amd64])
  201. Conf coolfoo (1 unstable [amd64])
  202. Conf needscoolfoover0 (1 unstable [amd64])' aptget install needscoolfoover0 -s
  203. testsuccessequal 'Reading package lists...
  204. Building dependency tree...
  205. The following additional packages will be installed:
  206. coolfoo coolfoover
  207. The following NEW packages will be installed:
  208. coolfoo coolfoover needscoolfoover1
  209. 0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
  210. Inst coolfoo (1 unstable [amd64])
  211. Inst coolfoover (1 unstable [amd64])
  212. Inst needscoolfoover1 (1 unstable [amd64])
  213. Conf coolfoo (1 unstable [amd64])
  214. Conf coolfoover (1 unstable [amd64])
  215. Conf needscoolfoover1 (1 unstable [amd64])' aptget install needscoolfoover1 -s
  216. testfailureequal "$BADPREFIX
  217. The following packages have unmet dependencies:
  218. needscoolfoover2 : Depends: coolfoo:any (>= 2)
  219. E: Unable to correct problems, you have held broken packages." aptget install needscoolfoover2 -s
  220. testfailureequal "$BADPREFIX
  221. The following packages have unmet dependencies:
  222. needscoolfoover3 : Depends: coolfoo:any (>= 2)
  223. Depends: coolbar:any (>= 3)
  224. E: Unable to correct problems, you have held broken packages." aptget install needscoolfoover3 -s
  225. }
  226. solveableinsinglearch3
  227. msgmsg 'switch to single architecture'
  228. configarchitecture 'amd64'
  229. solveableinsinglearch0
  230. testfailureequal 'Reading package lists...
  231. Building dependency tree...
  232. E: Unable to locate package needsfoo:i386' aptget install needsfoo:i386 -s
  233. solveableinsinglearch1 'needsfooany'
  234. solveableinsinglearch1 'needsfoover1'
  235. testfailureequal "$NEEDSFOO2NATIVE" aptget install needsfoover2 -s
  236. solveableinsinglearch2
  237. solveableinsinglearch3
  238. msgmsg 'multi-arch with barbarian archs'
  239. configarchitecture 'amd64' 'i386'
  240. insertinstalledpackage 'foo' 'armel' '1' 'Multi-Arch: allowed'
  241. insertinstalledpackage 'coolfoo' 'armel' '1' 'Multi-Arch:allowed
  242. Provides: coolbar'
  243. testsuccessequal 'Reading package lists...
  244. Building dependency tree...
  245. The following additional packages will be installed:
  246. foo
  247. The following packages will be REMOVED:
  248. foo:armel
  249. The following NEW packages will be installed:
  250. foo needsfooany
  251. 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
  252. Remv foo:armel [1]
  253. Inst foo (1 unstable [amd64])
  254. Inst needsfooany (1 unstable [amd64])
  255. Conf foo (1 unstable [amd64])
  256. Conf needsfooany (1 unstable [amd64])' aptget install needsfooany -s
  257. testsuccessequal 'Reading package lists...
  258. Building dependency tree...
  259. The following additional packages will be installed:
  260. foo
  261. The following packages will be REMOVED:
  262. foo:armel
  263. The following NEW packages will be installed:
  264. foo needsfooany:i386
  265. 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
  266. Remv foo:armel [1]
  267. Inst foo (1 unstable [amd64])
  268. Inst needsfooany:i386 (1 unstable [i386])
  269. Conf foo (1 unstable [amd64])
  270. Conf needsfooany:i386 (1 unstable [i386])' aptget install needsfooany:i386 -s
  271. testsuccessequal 'Reading package lists...
  272. Building dependency tree...
  273. The following additional packages will be installed:
  274. coolfoo
  275. The following packages will be REMOVED:
  276. coolfoo:armel
  277. The following NEW packages will be installed:
  278. coolfoo needscoolfoover0
  279. 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
  280. Remv coolfoo:armel [1]
  281. Inst coolfoo (1 unstable [amd64])
  282. Inst needscoolfoover0 (1 unstable [amd64])
  283. Conf coolfoo (1 unstable [amd64])
  284. Conf needscoolfoover0 (1 unstable [amd64])' aptget install needscoolfoover0 -s