ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 1 | <?xml version="1.0"?> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 2 | <project |
| 3 | name="test" |
| 4 | default="get"> |
david_williams | d622a5b | 2010-09-14 05:46:36 +0000 | [diff] [blame] | 5 | <description>get and install dependencies</description> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 6 | |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 7 | |
david_williams | 42f9b24 | 2006-11-27 18:45:14 +0000 | [diff] [blame] | 8 | <!-- Note to be cross-platform, "environment variables" are only appropriate for |
| 9 | some variables, e.g. ones we set, since properties are case sensitive, even if |
| 10 | the environment variables on your operating system are not, e.g. it will |
| 11 | be ${env.Path} not ${env.PATH} on Windows --> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 12 | <property environment="env"/> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 13 | |
david_williams | 42f9b24 | 2006-11-27 18:45:14 +0000 | [diff] [blame] | 14 | <!-- |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 15 | Note: if baseos, basews, and basearch are "passed in" to this |
| 16 | file, then they take priority, and retain their value. Otherwise, |
| 17 | use the current environment. Normally, the current environment is |
| 18 | desired, but sometimes, such as for creating the "all in ones", it may |
| 19 | be desired to "get" packages for other combinations. |
david_williams | 42f9b24 | 2006-11-27 18:45:14 +0000 | [diff] [blame] | 20 | --> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 21 | <property |
| 22 | name="baseos" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 23 | value="${env.BASEOS}"/> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 24 | <property |
| 25 | name="basews" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 26 | value="${env.BASEWS}"/> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 27 | <property |
| 28 | name="basearch" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 29 | value="${env.BASEARCH}"/> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 30 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 31 | <!-- ================================= |
| 32 | target: get |
| 33 | ================================= --> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 34 | <property file="@dependencyProperties@"/> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 35 | |
| 36 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 37 | <!-- - - - - - - - - - - - - - - - - - |
| 38 | target: init |
| 39 | - - - - - - - - - - - - - - - - - --> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 40 | <target name="init"> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 41 | <property |
| 42 | name="dependency.name" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 43 | value="${@dependencyGroupId@name}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 44 | <property |
| 45 | name="dependency.description" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 46 | value="${@dependencyGroupId@descriptions}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 47 | <property |
| 48 | name="dependency.url" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 49 | value="${@dependencyGroupId@url}"/> |
david_williams | 98bb214 | 2010-08-05 04:10:36 +0000 | [diff] [blame] | 50 | |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 51 | <property |
| 52 | name="dependency.tobeinstalledfeaturegroups" |
| 53 | value="${@dependencyGroupId@tobeinstalledfeaturegroups}"/> |
david_williams | d1b8352 | 2010-10-03 05:22:04 +0000 | [diff] [blame] | 54 | |
| 55 | <condition |
| 56 | property="dependency.repo" |
| 57 | value="${@dependencyGroupId@repo}"> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 58 | <isset property="@dependencyGroupId@repo"/> |
david_williams | d1b8352 | 2010-10-03 05:22:04 +0000 | [diff] [blame] | 59 | </condition> |
| 60 | |
david_williams | c0c2b97 | 2010-10-03 03:21:44 +0000 | [diff] [blame] | 61 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 62 | <property |
| 63 | name="local.cache.dir" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 64 | value="."/> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 65 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 66 | <condition |
| 67 | property="dependency.file" |
| 68 | value="${@dependencyGroupId@file}"> |
david_williams | e521fb5 | 2010-10-03 08:25:25 +0000 | [diff] [blame] | 69 | <and> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 70 | <isset property="@dependencyGroupId@file"/> |
david_williams | e521fb5 | 2010-10-03 08:25:25 +0000 | [diff] [blame] | 71 | <not> |
| 72 | <or> |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 73 | <isset property="@dependencyGroupId@file.linux-gtk-x86_64"/> |
| 74 | <isset property="@dependencyGroupId@file.linux-gtk-ppc64"/> |
| 75 | <isset property="@dependencyGroupId@file.win32-win32-x86_64"/> |
| 76 | <isset property="@dependencyGroupId@file.macosx-cocoa-x86_64"/> |
david_williams | e521fb5 | 2010-10-03 08:25:25 +0000 | [diff] [blame] | 77 | </or> |
| 78 | </not> |
| 79 | </and> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 80 | </condition> |
| 81 | <condition |
| 82 | property="dependency.file" |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 83 | value="${@dependencyGroupId@file.win32-win32-x86_64}"> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 84 | <and> |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 85 | <isset property="@dependencyGroupId@file.win32-win32-x86_64"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 86 | <equals |
| 87 | arg1="win32" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 88 | arg2="${baseos}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 89 | <equals |
| 90 | arg1="win32" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 91 | arg2="${basews}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 92 | <equals |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 93 | arg1="x86_64" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 94 | arg2="${basearch}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 95 | </and> |
| 96 | </condition> |
| 97 | <condition |
| 98 | property="dependency.file" |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 99 | value="${@dependencyGroupId@file.linux-gtk-x86_64}"> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 100 | <and> |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 101 | <isset property="@dependencyGroupId@file.linux-gtk-x86_64"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 102 | <equals |
| 103 | arg1="linux" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 104 | arg2="${baseos}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 105 | <equals |
| 106 | arg1="gtk" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 107 | arg2="${basews}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 108 | <equals |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 109 | arg1="x86_64" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 110 | arg2="${basearch}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 111 | </and> |
| 112 | </condition> |
| 113 | <condition |
| 114 | property="dependency.file" |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 115 | value="${@dependencyGroupId@file.linux-gtk-ppc64}"> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 116 | <and> |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 117 | <isset property="@dependencyGroupId@file.linux-gtk-ppc64"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 118 | <equals |
| 119 | arg1="linux" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 120 | arg2="${baseos}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 121 | <equals |
| 122 | arg1="gtk" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 123 | arg2="${basews}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 124 | <equals |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 125 | arg1="ppc64" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 126 | arg2="${basearch}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 127 | </and> |
| 128 | </condition> |
| 129 | <condition |
| 130 | property="dependency.file" |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 131 | value="${@dependencyGroupId@file.macosx-cocoa-x86_64}"> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 132 | <and> |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 133 | <isset property="@dependencyGroupId@file.macosx-cocoa-x86_64"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 134 | <equals |
| 135 | arg1="macosx" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 136 | arg2="${baseos}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 137 | <equals |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 138 | arg1="cocoa" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 139 | arg2="${basews}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 140 | <equals |
nickboldt | 4871dd7 | 2017-12-06 10:57:37 -0500 | [diff] [blame^] | 141 | arg1="x86_64" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 142 | arg2="${basearch}"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 143 | </and> |
| 144 | </condition> |
| 145 | <condition |
| 146 | property="dependency.autodownload" |
| 147 | value="${@dependencyGroupId@autodownload}"> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 148 | <isset property="@dependencyGroupId@autodownload"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 149 | </condition> |
| 150 | <condition |
| 151 | property="dependency.releng.url" |
| 152 | value="${@dependencyGroupId@releng.url}"> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 153 | <isset property="@dependencyGroupId@releng.url"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 154 | </condition> |
| 155 | </target> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 156 | |
| 157 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 158 | <target |
| 159 | name="get" |
| 160 | depends="init"> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 161 | |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 162 | <echo |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 163 | level="debug" |
david_williams | 4ed7196 | 2010-10-03 21:00:32 +0000 | [diff] [blame] | 164 | message="Getting ${dependency.file} or ${dependency.repo}"/> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 165 | <echo |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 166 | level="debug" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 167 | message="Url: ${dependency.url}"/> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 168 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 169 | <ant |
| 170 | antfile="@dependencyDir@/build.xml" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 171 | target="default"/> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 172 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 173 | </target> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 174 | |
| 175 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 176 | <!-- ================================= |
| 177 | target: install |
| 178 | ================================= --> |
| 179 | <target |
| 180 | name="install" |
| 181 | depends="init"> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 182 | <echo |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 183 | level="debug" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 184 | message="Installing ${dependency.file}"/> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 185 | <echo |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 186 | level="debug" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 187 | message="destination: ${install.destination}"/> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 188 | <antcall target="cleanInstall"/> |
| 189 | <property file="${installWorkingDirectory}/installmanifest.properties"/> |
| 190 | <antcall target="callInstall"/> |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 191 | <echo |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 192 | level="debug" |
david_williams | 4a19a54 | 2010-09-27 06:10:16 +0000 | [diff] [blame] | 193 | message="installmanifest.properties: ${installWorkingDirectory}/installmanifest.properties"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 194 | <echo |
david_williams | 4a19a54 | 2010-09-27 06:10:16 +0000 | [diff] [blame] | 195 | file="${installWorkingDirectory}/installmanifest.properties" |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 196 | append="true"> |
| 197 | @dependencyGroupId@${dependency.file}.installed=true |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 198 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 199 | @dependencyGroupId@dir=${local.cache.dir} |
| 200 | @dependencyGroupId@file=${dependency.file} |
david_williams | 403beae | 2007-12-09 02:10:40 +0000 | [diff] [blame] | 201 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 202 | </echo> |
| 203 | </target> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 204 | |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 205 | <target |
| 206 | name="installRepo" |
| 207 | depends="init"> |
| 208 | <echo |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 209 | level="debug" |
david_williams | c0c2b97 | 2010-10-03 03:21:44 +0000 | [diff] [blame] | 210 | message="Installing ${dependency.repo}"/> |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 211 | <echo |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 212 | level="debug" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 213 | message="destination: ${install.destination}"/> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 214 | <antcall target="cleanInstall"/> |
| 215 | <property file="${installWorkingDirectory}/installmanifest.properties"/> |
david_williams | d622a5b | 2010-09-14 05:46:36 +0000 | [diff] [blame] | 216 | <!-- |
| 217 | We first unzip the repo, then use p2 directory app to install into the eclispe |
| 218 | location. |
david_williams | 65de9bd | 2010-09-14 06:21:21 +0000 | [diff] [blame] | 219 | TODO: could we just make p2runnable in "transformed" repository? for build case. |
david_williams | d622a5b | 2010-09-14 05:46:36 +0000 | [diff] [blame] | 220 | --> |
david_williams | 29cb019 | 2010-08-05 03:00:09 +0000 | [diff] [blame] | 221 | <!-- |
| 222 | We use the exec method for unzip, so we won't fail if a |
| 223 | prereq can not be unzipped for some reason. See |
| 224 | https://bugs.eclipse.org/bugs/show_bug.cgi?id=283968 |
| 225 | --> |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 226 | |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 227 | <property |
| 228 | name="tobeinstalledrepo" |
david_williams | 4a19a54 | 2010-09-27 06:10:16 +0000 | [diff] [blame] | 229 | value="${installWorkingDirectory}/temprepos/${groupId}"/> |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 230 | <echo |
| 231 | level="debug" |
| 232 | message="install repo for groupId: ${groupId}"/> |
| 233 | <echo |
| 234 | level="debug" |
| 235 | message="tobeinstalledrepo: ${tobeinstalledrepo}"/> |
| 236 | <echo |
| 237 | level="debug" |
| 238 | message="tobeInstalledfeaturegroups: ${dependency.tobeinstalledfeaturegroups}"/> |
david_williams | c0c2b97 | 2010-10-03 03:21:44 +0000 | [diff] [blame] | 239 | |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 240 | <delete failonerror="false" quiet="true"> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 241 | <dirset dir="${tobeinstalledrepo}"/> |
david_williams | 55df8e4 | 2010-09-14 18:35:25 +0000 | [diff] [blame] | 242 | </delete> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 243 | <mkdir dir="${tobeinstalledrepo}"/> |
| 244 | |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 245 | <exec |
| 246 | dir="." |
| 247 | executable="unzip"> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 248 | <arg line="-o -qq ${local.cache.dir}/${dependency.repo} -d ${tobeinstalledrepo}"/> |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 249 | </exec> |
david_williams | 9e7f584 | 2011-03-06 03:32:03 +0000 | [diff] [blame] | 250 | |
| 251 | |
david_williams | 4a19a54 | 2010-09-27 06:10:16 +0000 | [diff] [blame] | 252 | <!-- note we are deliberately running the eclipse we are installing into --> |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 253 | <java |
| 254 | taskname="p2Director Install" |
| 255 | fork="true" |
| 256 | resultProperty="p2DirectorInstallResult" |
| 257 | failonerror="true" |
Carl Anderson | f1859b7 | 2013-10-07 14:01:59 -0400 | [diff] [blame] | 258 | jvm="${env.JAVA_7_HOME}/bin/java" |
david_williams | 55df8e4 | 2010-09-14 18:35:25 +0000 | [diff] [blame] | 259 | dir="${install.destination}" |
| 260 | classname="org.eclipse.equinox.launcher.Main"> |
| 261 | <classpath> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 262 | <fileset dir="${install.destination}/eclipse/plugins"> |
| 263 | <include name="org.eclipse.equinox.launcher_*.jar"/> |
david_williams | 55df8e4 | 2010-09-14 18:35:25 +0000 | [diff] [blame] | 264 | </fileset> |
| 265 | </classpath> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 266 | <jvmarg value="-Djava.io.tmpdir=${env.RECOMMENDED_TMP_DIR}"/> |
| 267 | <arg value="-nosplash"/> |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 268 | <!-- <arg value="-debug"/> --> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 269 | <arg value="-consolelog"/> |
| 270 | <arg value="-data"/> |
| 271 | <arg value="${installWorkingDirectory}/p2DirectorInstall"/> |
| 272 | <arg value="-application"/> |
| 273 | <arg value="org.eclipse.equinox.p2.director"/> |
david_williams | 55df8e4 | 2010-09-14 18:35:25 +0000 | [diff] [blame] | 274 | |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 275 | <arg value="-repository"/> |
| 276 | <arg value="file:/${tobeinstalledrepo}"/> |
david_williams | 61ac438 | 2010-10-04 17:04:43 +0000 | [diff] [blame] | 277 | |
david_williams | d1b8352 | 2010-10-03 05:22:04 +0000 | [diff] [blame] | 278 | |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 279 | <arg value="-installIU"/> |
| 280 | <arg value="${dependency.tobeinstalledfeaturegroups}"/> |
david_williams | f7c38c9 | 2010-10-02 17:17:51 +0000 | [diff] [blame] | 281 | |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 282 | <arg value="-list"/> |
david_williams | 9e7f584 | 2011-03-06 03:32:03 +0000 | [diff] [blame] | 283 | |
| 284 | |
david_williams | 455f615 | 2010-10-02 05:52:19 +0000 | [diff] [blame] | 285 | <!-- make sure our forked env has a DISPLAY? --> |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 286 | <env |
| 287 | key="DISPLAY" |
| 288 | value="${env.DISPLAY}"/> |
david_williams | 55df8e4 | 2010-09-14 18:35:25 +0000 | [diff] [blame] | 289 | |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 290 | <arg value="-vmArgs"/> |
david_williams | 55df8e4 | 2010-09-14 18:35:25 +0000 | [diff] [blame] | 291 | |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 292 | </java> |
david_williams | 14cadd1 | 2011-03-23 06:43:39 +0000 | [diff] [blame] | 293 | <echo |
| 294 | level="debug" |
| 295 | message="p2DirectorInstallResult: ${p2DirectorInstallResult}"/> |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 296 | |
| 297 | |
| 298 | |
| 299 | |
| 300 | |
| 301 | </target> |
| 302 | |
| 303 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 304 | <target |
| 305 | name="cleanInstall" |
| 306 | if="clean"> |
| 307 | <available |
david_williams | 4a19a54 | 2010-09-27 06:10:16 +0000 | [diff] [blame] | 308 | file="${installWorkingDirectory}/installmanifest.properties" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 309 | property="installmanifest.exists"/> |
david_williams | 2398e36 | 2011-03-05 02:45:39 +0000 | [diff] [blame] | 310 | <antcall target="cleanInstall2"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 311 | </target> |
jeffliu | d0eb4a7 | 2005-09-28 14:58:59 +0000 | [diff] [blame] | 312 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 313 | <target |
| 314 | name="cleanInstall2" |
| 315 | if="installmanifest.exists"> |
| 316 | <replace |
david_williams | 4a19a54 | 2010-09-27 06:10:16 +0000 | [diff] [blame] | 317 | file="${installWorkingDirectory}/installmanifest.properties" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 318 | token="@dependencyGroupId@${dependency.file}.installed=true"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 319 | </target> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 320 | |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 321 | <target |
| 322 | name="callInstall" |
| 323 | unless="@dependencyGroupId@${dependency.file}.installed"> |
| 324 | <ant |
| 325 | antfile="@dependencyDir@/build.xml" |
david_williams | 7e568c7 | 2010-09-12 09:04:15 +0000 | [diff] [blame] | 326 | target="install"/> |
david_williams | 1cff0e9 | 2006-11-23 00:40:29 +0000 | [diff] [blame] | 327 | </target> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 328 | |
Carl Anderson | 3cf4340 | 2012-08-15 12:27:17 -0400 | [diff] [blame] | 329 | <target |
| 330 | name="installRepoFromURL" |
| 331 | depends="init"> |
| 332 | <echo message="Installing ${dependency.repo}"/> |
| 333 | <echo message="destination: ${install.destination}"/> |
| 334 | <antcall target="cleanInstall"/> |
| 335 | <property file="${installWorkingDirectory}/installmanifest.properties"/> |
| 336 | <echo message="install repo for groupId: ${groupId}"/> |
| 337 | <echo message="URL: ${dependency.url}"/> |
| 338 | <echo message="tobeInstalledfeaturegroups: ${dependency.tobeinstalledfeaturegroups}"/> |
| 339 | <!-- note we are deliberately running the eclipse we are installing into --> |
| 340 | <java |
| 341 | taskname="p2Director Install" |
| 342 | fork="true" |
| 343 | resultProperty="p2DirectorInstallResult" |
| 344 | failonerror="true" |
Carl Anderson | f1859b7 | 2013-10-07 14:01:59 -0400 | [diff] [blame] | 345 | jvm="${env.JAVA_7_HOME}/bin/java" |
Carl Anderson | 3cf4340 | 2012-08-15 12:27:17 -0400 | [diff] [blame] | 346 | dir="${install.destination}" |
| 347 | classname="org.eclipse.equinox.launcher.Main"> |
| 348 | <classpath> |
| 349 | <fileset dir="${install.destination}/eclipse/plugins"> |
| 350 | <include name="org.eclipse.equinox.launcher_*.jar"/> |
| 351 | </fileset> |
| 352 | </classpath> |
| 353 | <jvmarg value="-Djava.io.tmpdir=${env.RECOMMENDED_TMP_DIR}"/> |
| 354 | <arg value="-nosplash"/> |
| 355 | <arg value="-debug"/> |
| 356 | <arg value="-consolelog"/> |
| 357 | <arg value="-data"/> |
| 358 | <arg value="${installWorkingDirectory}/p2DirectorInstall"/> |
| 359 | <arg value="-application"/> |
| 360 | <arg value="org.eclipse.equinox.p2.director"/> |
| 361 | |
| 362 | <arg value="-repository"/> |
| 363 | <arg value="${dependency.url}"/> |
| 364 | |
| 365 | |
| 366 | <arg value="-installIU"/> |
| 367 | <arg value="${dependency.tobeinstalledfeaturegroups}"/> |
| 368 | |
| 369 | <arg value="-list"/> |
| 370 | |
| 371 | |
| 372 | <!-- make sure our forked env has a DISPLAY? --> |
| 373 | <env |
| 374 | key="DISPLAY" |
| 375 | value="${env.DISPLAY}"/> |
| 376 | |
| 377 | <arg value="-vmArgs"/> |
| 378 | |
| 379 | </java> |
| 380 | <echo message="p2DirectorInstallResult: ${p2DirectorInstallResult}"/> |
| 381 | </target> |
ndai | dab24cb | 2006-07-28 15:22:38 +0000 | [diff] [blame] | 382 | </project> |