Permalink
Browse files

Migrate build and project configuration to IntelliJ IDEA 12 (Leda) EAP

Major changes: ASM is switched from vanilla 3.3 to a 4.0 with renamed packages,
because this is done inside IDEA and we depend on that transitively.
Thus the jarjar renaming in build.xml, old library binaries deleted.

Also we now depend on exact IDEA build (EAP), not "last successful".
  • Loading branch information...
1 parent 2cf411e commit 839c39c70dcfa7bd945597c30215e51601bed87e @abreslav abreslav committed Jul 24, 2012
@@ -4,7 +4,7 @@
<root id="root">
<element id="directory" name="Kotlin">
<element id="directory" name="lib">
- <element id="library" level="project" name="asm" />
+ <element id="library" level="project" name="asm-util" />
<element id="archive" name="kotlin-plugin.jar">
<element id="module-output" name="backend" />
<element id="module-output" name="frontend" />
@@ -1,13 +0,0 @@
-<component name="libraryTable">
- <library name="asm">
- <CLASSES>
- <root url="jar://$PROJECT_DIR$/lib/asm-analysis-3.3.jar!/" />
- <root url="jar://$PROJECT_DIR$/lib/asm-tree-3.3.jar!/" />
- <root url="jar://$PROJECT_DIR$/lib/asm-util-3.3.jar!/" />
- </CLASSES>
- <JAVADOC />
- <SOURCES>
- <root url="jar://$PROJECT_DIR$/lib/asm-3.3-src.zip!/" />
- </SOURCES>
- </library>
-</component>
@@ -0,0 +1,11 @@
+<component name="libraryTable">
+ <library name="asm-util">
+ <CLASSES>
+ <root url="jar://$PROJECT_DIR$/dependencies/jetbrains-asm-util-4.0.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES>
+ <root url="jar://$PROJECT_DIR$/dependencies/jetbrains-asm-all-4.0-src.zip!/" />
+ </SOURCES>
+ </library>
+</component>
@@ -140,16 +140,13 @@
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/forms-compiler/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/impl/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/javac2/src" />
- <root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/notNull/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/openapi/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/idea-ui/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/openapi/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/jps/testSrc" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/jps/model/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/jps/antLayout/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/jps/jps-builders/src" />
- <root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/jps/src" />
- <root url="jar://$PROJECT_DIR$/lib/asm-3.3-src.zip!/" />
</SOURCES>
<jarDirectory url="file://$PROJECT_DIR$/ideaSDK/lib" recursive="false" />
</library>
@@ -2,6 +2,7 @@
<library name="intellij-core">
<CLASSES>
<root url="file://$PROJECT_DIR$/ideaSDK/core" />
+ <root url="jar://$PROJECT_DIR$/dependencies/jetbrains-asm-all-4.0.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES>
@@ -53,13 +54,10 @@
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/forms-compiler/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/impl/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/javac2/src" />
- <root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/notNull/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/compiler/openapi/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/idea-ui/src" />
<root url="jar://$PROJECT_DIR$/ideaSDK/sources/sources.zip!/java/openapi/src" />
- <root url="jar://$USER_HOME$/Downloads/picocontainer-2.10-20100209.093751-5-sources.jar!/" />
- <root url="jar://$USER_HOME$/Downloads/picocontainer-1.3-20061227.142936-4-sources.jar!/" />
- <root url="jar://$PROJECT_DIR$/lib/asm-3.3-src.zip!/" />
+ <root url="jar://$PROJECT_DIR$/dependencies/jetbrains-asm-all-4.0-src.zip!/" />
</SOURCES>
<jarDirectory url="file://$PROJECT_DIR$/ideaSDK/core" recursive="false" />
</library>
View
@@ -24,6 +24,8 @@
<fileset dir="${basedir}/lib" includes="**/*.jar"/>
<fileset dir="${basedir}/dependencies" includes="jline.jar"/>
<fileset dir="${basedir}/dependencies" includes="jansi.jar"/>
+ <fileset dir="${basedir}/dependencies" includes="jetbrains-asm-all-4.0.jar"/>
+ <fileset dir="${basedir}/dependencies" includes="jetbrains-asm-util-4.0.jar"/>
<fileset dir="${basedir}/js/js.translator/lib" includes="*.jar"/>
</path>
@@ -208,9 +210,14 @@
<zipgroupfileset dir="${basedir}/lib" includes="*.jar"/>
<zipgroupfileset dir="${basedir}/ideaSDK/core" includes="*.jar"/>
+ <zipgroupfileset dir="${basedir}/ideaSDK/lib" includes="jna-utils.jar"/>
+ <zipgroupfileset dir="${basedir}/ideaSDK/lib" includes="oromatcher.jar"/>
<zipgroupfileset dir="${basedir}/js/js.translator/lib" includes="*.jar"/>
<zipgroupfileset dir="${basedir}/dependencies" includes="jline.jar"/>
<zipgroupfileset dir="${basedir}/dependencies" includes="jansi.jar"/>
+ <zipgroupfileset dir="${basedir}/dependencies" includes="jetbrains-asm-all-4.0.jar"/>
+ <zipgroupfileset dir="${basedir}/dependencies" includes="jetbrains-asm-util-4.0.jar"/>
+ <zipgroupfileset dir="${basedir}/dependencies" includes="jetbrains-asm-analysis-4.0.jar"/>
<zap pattern="com.thoughtworks.xstream.converters.extended.ISO8601*"/>
<zap pattern="com.thoughtworks.xstream.converters.reflection.CGLIBEnhancedConverter*"/>
@@ -293,6 +300,8 @@
-injars '${output}/kotlin-compiler-before-proguard.jar'
-outjars '${kotlin-home}/lib/kotlin-compiler.jar'
+ -dontwarn org.jetbrains.jet.internal.com.intellij.util.**
+
-libraryjars '${rtjar}'
-target 1.6
@@ -9,7 +9,7 @@
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="module" module-name="frontend" />
<orderEntry type="module" module-name="frontend.java" />
- <orderEntry type="library" name="asm" level="project" />
+ <orderEntry type="library" name="asm-util" level="project" />
<orderEntry type="module" module-name="runtime" />
<orderEntry type="library" scope="PROVIDED" name="intellij-core" level="project" />
<orderEntry type="library" name="javax.inject" level="project" />
@@ -13,7 +13,7 @@
<orderEntry type="module" module-name="runtime" />
<orderEntry type="module" module-name="jet.as.java.psi" />
<orderEntry type="library" name="intellij-core" level="project" />
- <orderEntry type="library" name="asm" level="project" />
+ <orderEntry type="library" name="asm-util" level="project" />
<orderEntry type="module" module-name="js.translator" />
<orderEntry type="library" name="jline" level="project" />
</component>
@@ -13,7 +13,7 @@
<orderEntry type="module" module-name="runtime" />
<orderEntry type="module" module-name="cli" />
<orderEntry type="library" name="idea-full" level="project" />
- <orderEntry type="library" name="asm" level="project" />
+ <orderEntry type="library" name="asm-util" level="project" />
<orderEntry type="library" name="dx-android" level="project" />
</component>
</module>
View
Binary file not shown.
Binary file not shown.
View
Binary file not shown.
View
Binary file not shown.
@@ -1,12 +1,17 @@
<project name="Update Dependencies" default="update">
- <property name="build.zip" value="ideaIC-117.SNAPSHOT.win.zip"/>
<target name="update" depends="fetch-third-party">
- <execute_update/>
+ <execute_update
+ base.url="http://teamcity.jetbrains.com/guestAuth/repository/download/bt343/67291:id"
+ build.zip="ideaIC-120.SNAPSHOT.win.zip"
+ />
</target>
<target name="jb_update" depends="fetch-third-party">
- <execute_update teamcity="http://buildserver.labs.intellij.net" teamcity.build="bt2560"/>
+ <execute_update
+ base.url="http://buildserver.labs.intellij.net/guestAuth/repository/download/bt24/1481384:id"
+ build.zip="ideaIC-120.214.win.zip"
+ />
</target>
<target name="update-no-third-party">
@@ -92,36 +97,96 @@
<get src="http://repository.jetbrains.com/remote-repos/org/fusesource/jansi/jansi/1.9/jansi-1.9-sources.jar"
dest="dependencies/download/jansi-1.9-sources.jar" usetimestamp="true"/>
<copy file="dependencies/download/jansi-1.9-sources.jar" tofile="dependencies/jansi-sources.jar" overwrite="true"/>
+
+
+ <!-- ASM 4 -->
+ <asm4/>
</target>
- <macrodef name="execute_update">
- <attribute name="teamcity" default="http://teamcity.jetbrains.com"/>
+ <macrodef name="asm4">
+ <sequential>
+ <get src="http://download.forge.objectweb.org/asm/asm-4.0-bin.zip"
+ dest="dependencies/download/asm-4.0-bin.zip" usetimestamp="true"/>
+
+ <delete dir="dependencies/download/asm" failonerror="false"/>
+ <unzip src="dependencies/download/asm-4.0-bin.zip" dest="dependencies/download/asm">
+ <patternset>
+ <include name="asm-4.0/lib/asm-util-4.0.jar"/>
+ <include name="asm-4.0/lib/asm-tree-4.0.jar"/>
+ <include name="asm-4.0/lib/asm-commons-4.0.jar"/>
+ <include name="asm-4.0/lib/asm-analysis-4.0.jar"/>
+ <include name="asm-4.0/lib/asm-4.0.jar"/>
+ <include name="asm-4.0/src.zip"/>
+ </patternset>
+ <mapper type="flatten"/>
+ </unzip>
+ <unzip src="dependencies/download/asm/src.zip" dest="dependencies/download/asm/src">
+ <patternset>
+ <include name="**/*"/>
+ </patternset>
+ </unzip>
+
+ <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="${basedir}/dependencies/jarjar.jar"/>
+
+ <jarjar jarfile="dependencies/jetbrains-asm-all-4.0.jar">
+ <zipfileset src="dependencies/download/asm/asm-tree-4.0.jar"/>
+ <zipfileset src="dependencies/download/asm/asm-commons-4.0.jar"/>
+ <zipfileset src="dependencies/download/asm/asm-4.0.jar"/>
+
+ <rule pattern="org.objectweb.asm.**" result="org.jetbrains.asm4.@1"/>
+ </jarjar>
+
+ <jarjar jarfile="dependencies/jetbrains-asm-util-4.0.jar">
+ <zipfileset src="dependencies/download/asm/asm-util-4.0.jar"/>
+
+ <rule pattern="org.objectweb.asm.**" result="org.jetbrains.asm4.@1"/>
+ </jarjar>
+
+ <jarjar jarfile="dependencies/jetbrains-asm-analysis-4.0.jar">
+ <zipfileset src="dependencies/download/asm/asm-analysis-4.0.jar"/>
+
+ <rule pattern="org.objectweb.asm.**" result="org.jetbrains.asm4.@1"/>
+ </jarjar>
+
+ <replaceregexp
+ match="org.objectweb.asm"
+ replace="org.jetbrains.asm4"
+ >
+ <fileset dir="dependencies/download/asm/src/">
+ <include name="**/*.java"/>
+ </fileset>
+ </replaceregexp>
+
+ <move file="dependencies/download/asm/src/org/objectweb/asm"
+ tofile="dependencies/download/asm/src/org/jetbrains/asm4"/>
+
+ <zip destfile="dependencies/jetbrains-asm-all-4.0-src.zip" basedir="dependencies/download/asm/src"/>
+ </sequential>
+ </macrodef>
- <!-- IDEA CE 11.1 branch 117 -->
- <attribute name="teamcity.build" default="bt365"/>
+ <macrodef name="execute_update">
+ <attribute name="base.url" default="http://teamcity.example.com"/>
+ <attribute name="build.zip" default="http://teamcity.example.com"/>
<sequential>
<property name="core" value="ideaSDK/core"/>
- <property name="tc" value="@{teamcity}/guestAuth/repository/download/@{teamcity.build}/.lastSuccessful"/>
<delete dir="ideaSDK" failonerror="false">
<exclude name="config/**"/>
<exclude name="system/**"/>
</delete>
<mkdir dir="${core}"/>
- <get src="${tc}/core/intellij-core.jar" dest="${core}/intellij-core.jar"/>
- <get src="${tc}/core/annotations.jar" dest="${core}/annotations.jar"/>
- <get src="${tc}/core/asm.jar" dest="${core}/asm.jar"/>
- <get src="${tc}/core/asm-commons.jar" dest="${core}/asm-commons.jar"/>
- <get src="${tc}/core/cli-10.jar" dest="${core}/cli-10.jar"/>
- <get src="${tc}/core/guava-11.0.1.jar" dest="${core}/guava-11.0.1.jar"/>
- <get src="${tc}/core/picocontainer.jar" dest="${core}/picocontainer.jar"/>
- <get src="${tc}/core/trove4j.jar" dest="${core}/trove4j.jar"/>
-
- <get src="${tc}/${build.zip}" dest="ideaSDK/${build.zip}"/>
- <unzip src="ideaSDK/${build.zip}" dest="ideaSDK"/>
- <delete file="ideaSDK/${build.zip}"/>
+ <get src="@{base.url}/core/intellij-core.jar" dest="${core}/intellij-core.jar" usetimestamp="true"/>
+ <get src="@{base.url}/core/annotations.jar" dest="${core}/annotations.jar" usetimestamp="true"/>
+ <get src="@{base.url}/core/cli-parser-1.1.jar" dest="${core}/cli-parser-1.1.jar" usetimestamp="true"/>
+ <get src="@{base.url}/core/guava-12.0.jar" dest="${core}/guava-12.0.jar" usetimestamp="true"/>
+ <get src="@{base.url}/core/picocontainer.jar" dest="${core}/picocontainer.jar" usetimestamp="true"/>
+ <get src="@{base.url}/core/trove4j.jar" dest="${core}/trove4j.jar" usetimestamp="true"/>
+
+ <get src="@{base.url}/@{build.zip}" dest="ideaSDK/@{build.zip}" usetimestamp="true"/>
+ <unzip src="ideaSDK/@{build.zip}" dest="ideaSDK"/>
+ <delete file="ideaSDK/@{build.zip}"/>
<copy file="ideaSDK/lib/jdom.jar" todir="${core}"/>
<copy file="ideaSDK/lib/jna.jar" todir="${core}"/>
@@ -140,7 +205,7 @@
<delete file="ideaSDK/lib/junit.jar"/>
<mkdir dir="ideaSDK/sources"/>
- <get src="${tc}/sources.zip" dest="ideaSDK/sources/sources.zip"/>
+ <get src="@{base.url}/sources.zip" dest="ideaSDK/sources/sources.zip" usetimestamp="true"/>
</sequential>
</macrodef>
</project>

0 comments on commit 839c39c

Please sign in to comment.