test-bug-612099-multiarch-conflicts 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213
  1. #!/bin/sh
  2. set -e
  3. TESTDIR=$(readlink -f $(dirname $0))
  4. . $TESTDIR/framework
  5. setupenvironment
  6. configarchitecture "i386" "amd64"
  7. buildsimplenativepackage 'peace-dpkg' 'all' '1.0' 'stable'
  8. buildsimplenativepackage 'libc6' 'i386' '1.0' 'stable'
  9. buildsimplenativepackage 'libc6' 'amd64' '1.0' 'stable'
  10. buildsimplenativepackage 'libc6' 'all' '2.0' 'testing'
  11. buildsimplenativepackage 'foobar' 'i386' '1.0' 'stable' 'Depends: libc6'
  12. buildsimplenativepackage 'foobar' 'amd64' '1.0' 'stable' 'Depends: libc6'
  13. setupaptarchive
  14. aptget install peace-dpkg:i386 -y -qq 2>&1 > /dev/null
  15. testdpkginstalled peace-dpkg
  16. aptget install libc6:i386 -t stable -y -qq 2>&1 > /dev/null
  17. testdpkginstalled libc6
  18. testequal 'Reading package lists...
  19. Building dependency tree...
  20. Reading state information...
  21. The following packages will be REMOVED:
  22. libc6
  23. The following NEW packages will be installed:
  24. libc6:amd64
  25. 0 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
  26. Remv libc6 [1.0]
  27. Inst libc6:amd64 (1.0 stable [amd64])
  28. Conf libc6:amd64 (1.0 stable [amd64])' aptget install libc6:amd64 -s -t stable
  29. testequal 'Reading package lists...
  30. Building dependency tree...
  31. Reading state information...
  32. The following NEW packages will be installed:
  33. foobar
  34. 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
  35. Inst foobar (1.0 stable [i386])
  36. Conf foobar (1.0 stable [i386])' aptget install foobar -st stable
  37. testequal 'Reading package lists...
  38. Building dependency tree...
  39. Reading state information...
  40. The following extra packages will be installed:
  41. libc6:amd64
  42. The following packages will be REMOVED:
  43. libc6
  44. The following NEW packages will be installed:
  45. foobar:amd64 libc6:amd64
  46. 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
  47. Remv libc6 [1.0]
  48. Inst libc6:amd64 (1.0 stable [amd64])
  49. Inst foobar:amd64 (1.0 stable [amd64])
  50. Conf libc6:amd64 (1.0 stable [amd64])
  51. Conf foobar:amd64 (1.0 stable [amd64])' aptget install foobar:amd64 -st stable
  52. testequal 'Reading package lists...
  53. Building dependency tree...
  54. Reading state information...
  55. The following NEW packages will be installed:
  56. foobar
  57. The following packages will be upgraded:
  58. libc6
  59. 1 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
  60. Inst libc6 [1.0] (2.0 testing [all])
  61. Inst foobar (1.0 stable [i386])
  62. Conf libc6 (2.0 testing [all])
  63. Conf foobar (1.0 stable [i386])' aptget install foobar/stable libc6 -st testing
  64. testequal 'Reading package lists...
  65. Building dependency tree...
  66. Reading state information...
  67. The following packages will be upgraded:
  68. libc6
  69. 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
  70. Inst libc6 [1.0] (2.0 testing [all])
  71. Conf libc6 (2.0 testing [all])' aptget upgrade -t testing -s
  72. aptget upgrade -y -qq 2>&1 > /dev/null
  73. testdpkginstalled libc6
  74. testequal 'Reading package lists...
  75. Building dependency tree...
  76. Reading state information...
  77. The following NEW packages will be installed:
  78. foobar
  79. 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
  80. Inst foobar (1.0 stable [i386])
  81. Conf foobar (1.0 stable [i386])' aptget install foobar/stable -st testing
  82. testequal 'Reading package lists...
  83. Building dependency tree...
  84. Reading state information...
  85. The following extra packages will be installed:
  86. libc6:amd64
  87. The following packages will be REMOVED:
  88. libc6
  89. The following NEW packages will be installed:
  90. foobar:amd64 libc6:amd64
  91. 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
  92. Remv libc6 [2.0]
  93. Inst libc6:amd64 (1.0 stable [amd64])
  94. Inst foobar:amd64 (1.0 stable [amd64])
  95. Conf libc6:amd64 (1.0 stable [amd64])
  96. Conf foobar:amd64 (1.0 stable [amd64])' aptget install foobar:amd64/stable -st testing
  97. testequal "Reading package lists...
  98. Building dependency tree...
  99. Reading state information...
  100. Selected version '1.0' (stable [i386]) for 'libc6'
  101. The following packages will be DOWNGRADED:
  102. libc6
  103. 0 upgraded, 0 newly installed, 1 downgraded, 0 to remove and 0 not upgraded.
  104. Inst libc6 [2.0] (1.0 stable [i386])
  105. Conf libc6 (1.0 stable [i386])" aptget install libc6/stable -s -q=0
  106. buildsimplenativepackage 'libc6-same' 'i386' '1.0' 'stable' 'Multi-Arch: same'
  107. buildsimplenativepackage 'libc6-same' 'amd64' '1.0' 'stable' 'Multi-Arch: same'
  108. buildsimplenativepackage 'libc6-same' 'all' '2.0' 'testing'
  109. buildsimplenativepackage 'foobar-same' 'i386' '1.0' 'stable' 'Depends: libc6-same'
  110. buildsimplenativepackage 'foobar-same' 'amd64' '1.0' 'stable' 'Depends: libc6-same'
  111. setupaptarchive
  112. aptget install libc6-same:i386 -t stable -y -qq 2>&1 > /dev/null
  113. testdpkginstalled libc6-same
  114. testequal 'Reading package lists...
  115. Building dependency tree...
  116. Reading state information...
  117. The following NEW packages will be installed:
  118. foobar-same
  119. 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
  120. Inst foobar-same (1.0 stable [i386])
  121. Conf foobar-same (1.0 stable [i386])' aptget install foobar-same -st stable
  122. testequal 'Reading package lists...
  123. Building dependency tree...
  124. Reading state information...
  125. The following extra packages will be installed:
  126. libc6-same:amd64
  127. The following NEW packages will be installed:
  128. foobar-same:amd64 libc6-same:amd64
  129. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  130. Inst libc6-same:amd64 (1.0 stable [amd64])
  131. Inst foobar-same:amd64 (1.0 stable [amd64])
  132. Conf libc6-same:amd64 (1.0 stable [amd64])
  133. Conf foobar-same:amd64 (1.0 stable [amd64])' aptget install foobar-same:amd64 -st stable
  134. testequal 'Reading package lists...
  135. Building dependency tree...
  136. Reading state information...
  137. The following NEW packages will be installed:
  138. libc6-same:amd64
  139. 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
  140. Inst libc6-same:amd64 (1.0 stable [amd64])
  141. Conf libc6-same:amd64 (1.0 stable [amd64])' aptget install libc6-same:amd64 -s -t stable
  142. # FIXME: We should test installing libc6-same:amd64 here, but dpkg doesn't allow it currently
  143. testequal 'Reading package lists...
  144. Building dependency tree...
  145. Reading state information...
  146. The following packages will be upgraded:
  147. libc6-same
  148. 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
  149. Inst libc6-same [1.0] (2.0 testing [all])
  150. Conf libc6-same (2.0 testing [all])' aptget upgrade -t testing -s
  151. aptget upgrade -y -qq 2>&1 > /dev/null
  152. testdpkginstalled libc6-same
  153. testequal "Reading package lists...
  154. Building dependency tree...
  155. Reading state information...
  156. Selected version '1.0' (stable [i386]) for 'libc6-same'
  157. The following packages will be DOWNGRADED:
  158. libc6-same
  159. 0 upgraded, 0 newly installed, 1 downgraded, 0 to remove and 0 not upgraded.
  160. Inst libc6-same [2.0] (1.0 stable [i386])
  161. Conf libc6-same (1.0 stable [i386])" aptget install libc6-same/stable -s -q=0
  162. testequal 'Reading package lists...
  163. Building dependency tree...
  164. Reading state information...
  165. The following NEW packages will be installed:
  166. foobar-same
  167. 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
  168. Inst foobar-same (1.0 stable [i386])
  169. Conf foobar-same (1.0 stable [i386])' aptget install foobar-same/stable -st testing
  170. testequal 'Reading package lists...
  171. Building dependency tree...
  172. Reading state information...
  173. The following extra packages will be installed:
  174. libc6-same:amd64
  175. The following packages will be REMOVED:
  176. libc6-same
  177. The following NEW packages will be installed:
  178. foobar-same:amd64 libc6-same:amd64
  179. 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
  180. Remv libc6-same [2.0]
  181. Inst libc6-same:amd64 (1.0 stable [amd64])
  182. Inst foobar-same:amd64 (1.0 stable [amd64])
  183. Conf libc6-same:amd64 (1.0 stable [amd64])
  184. Conf foobar-same:amd64 (1.0 stable [amd64])' aptget install foobar-same:amd64/stable -st testing