v0.3 preparations (#648)

This commit is contained in:
Nikolay Igotti
2017-06-14 16:14:47 +03:00
committed by GitHub
parent 07c8404a5e
commit 0e8a1292a7
7 changed files with 51 additions and 23 deletions
+11 -2
View File
@@ -1,4 +1,13 @@
## v0.2 ## ## v0.3 (Jun 2017) ##
* Preliminary support for x86-64 Windows hosts and targets
* Support for producing native activities on 32- and 64-bit Android targets
* Extended standard library (bitsets, regular expression)
* Preliminary support for Kotlin/Native library format (.klib)
* Preliminary source-level debugging support (stepping only, no variable inspection)
* Compiler switch `-entry` to select entry point
* Symbolic backtrace in runtime for unstripped binaries, for all supported targets
## v0.2 (May 2017) ##
* Added support for coroutines * Added support for coroutines
* Fixed most stdlib incompatibilities * Fixed most stdlib incompatibilities
* Improved memory management performance * Improved memory management performance
@@ -11,5 +20,5 @@
* Very basic debugging support * Very basic debugging support
* Improve compilation and linking performance * Improve compilation and linking performance
## v0.1 ## ## v0.1 (Mar 2017) ##
Initial technical preview of Kotlin/Native. Initial technical preview of Kotlin/Native.
+3
View File
@@ -13,9 +13,12 @@ without need to ship an additional execution runtime.
* `csvparser` - simple CSV file parser and analyzer * `csvparser` - simple CSV file parser and analyzer
* `gitchurn` - program interoperating with `libgit2` for GIT repository analysis * `gitchurn` - program interoperating with `libgit2` for GIT repository analysis
* `libcurl` - using of FTP/HTTP/HTTPS client library `libcurl` * `libcurl` - using of FTP/HTTP/HTTPS client library `libcurl`
* `nonBlockingEchoServer` - multi-client TCP/IP echo server using co-routines
* `opengl` - OpenGL/GLUT teapot example * `opengl` - OpenGL/GLUT teapot example
* `socket` - TCP/IP echo server * `socket` - TCP/IP echo server
* `tensorflow` - simple client for TensorFlow Machine Intelligence library
* `tetris` - Tetris game implementation (using SDL2 for rendering) * `tetris` - Tetris game implementation (using SDL2 for rendering)
* `win32` - trivial Win32 application
See `README.md` in each sample directory for more information and build instructions. See `README.md` in each sample directory for more information and build instructions.
+1 -1
View File
@@ -22,7 +22,7 @@ a build script (see projects in `samples` directory):
The plugin downloads the compiler during its first run. You may specify a version of the compiler using `konan.version` The plugin downloads the compiler during its first run. You may specify a version of the compiler using `konan.version`
project property: project property:
konan.version=0.2 konan.version=0.3
If you already downloaded the compiler manually you may specify the path to it using `konan.home` project property (e.g. If you already downloaded the compiler manually you may specify the path to it using `konan.home` project property (e.g.
in `gradle.properties`). Note: the plugin ignores the `konan.version` property in this case. in `gradle.properties`). Note: the plugin ignores the `konan.version` property in this case.
+4 -2
View File
@@ -18,8 +18,7 @@ Then build the compiler and standard library:
./gradlew dist ./gradlew dist
To build standard library for cross-targets (currently, iOS on Mac OSX and Raspberry Pi on To build standard library for cross-targets use:
Linux hosts) use:
./gradlew cross_dist ./gradlew cross_dist
@@ -42,3 +41,6 @@ To generate interoperability stubs create library definition file
cinterop -def lib.def cinterop -def lib.def
See provided [samples](https://github.com/JetBrains/kotlin-native/tree/master/samples) and [`INTEROP.md`](https://github.com/JetBrains/kotlin-native/blob/master/INTEROP.md) for more details. See provided [samples](https://github.com/JetBrains/kotlin-native/tree/master/samples) and [`INTEROP.md`](https://github.com/JetBrains/kotlin-native/blob/master/INTEROP.md) for more details.
Interop tool generates library in .klib library format, see [`LIBRARY.md`](https://github.com/JetBrains/kotlin-native/blob/master/LIBRARY.md)
for more details on the file format.
+29 -14
View File
@@ -2,8 +2,8 @@
## Introduction ## ## Introduction ##
Kotlin/Native is a LLVM backend for the Kotlin compiler. It consists of a machine code generation facility using the LLVM toolchain _Kotlin/Native_ is a LLVM backend for the Kotlin compiler. It consists of a machine code generation facility using
and a native runtime implementation. the LLVM toolchain and a native runtime implementation.
_Kotlin/Native_ is primarily designed to allow compilation for platforms where _Kotlin/Native_ is primarily designed to allow compilation for platforms where
virtual machines are not desirable or possible (such as iOS or embedded targets), virtual machines are not desirable or possible (such as iOS or embedded targets),
@@ -20,14 +20,14 @@ basic runtime shipped along with the translator, we only support a subset of all
target platforms. Currently _Kotlin/Native_ is being shipped and tested with support for target platforms. Currently _Kotlin/Native_ is being shipped and tested with support for
the following platforms: the following platforms:
* Mac OS X 10.11 and later (x86-64) * Mac OS X 10.11 and later (x86-64), host and target
* x86-64 Ubuntu Linux (14.04, 16.04 and later), other Linux flavours may work as well * Ubuntu Linux x86-64 (14.04, 16.04 and later), other Linux flavours may work as well, host and target
* Apple iOS (arm64), cross-compiled on MacOS X host (`-target iphone`) * Microsoft Windows x86-64 (tested on Windows 7 and Windows 10), host and target
* Raspberry Pi, cross-compiled on Linux host (`-target raspberrypi`) * Apple iOS (arm64), cross-compiled on MacOS X host (`-target iphone`), target, hosted on OS X
* Raspberry Pi, cross-compiled on Linux host (`-target raspberrypi`), target, hosted on Linux
* Android arm32 and arm64 (`-target android_arm32` and `-target android_arm64`), target, hosted on Linux or OS X
Adding support for other target platforms shouldn't be too hard, if LLVM support is available.
Adding support for other target platforms shouldn't be too hard, if LLVM support
is available.
## Compatibility and features ## ## Compatibility and features ##
@@ -68,8 +68,10 @@ for benchmarking and competitive analysis of any kind.
### Standard Library ### ### Standard Library ###
The standard library in _Kotlin/Native_ is known to be incomplete and may not include The standard library in _Kotlin/Native_ is known to be mostly complete, please report us
few methods available in standard library of Kotlin (notably, regular expression-related). missing functionality. Note, that standard Java APIs, such as `java.lang.Math` or `java.io`
is not available in current _Kotlin_ standard library, but using C interoperability, one could
call similar APIs from the POSIX library, see this [`sample`](https://github.com/JetBrains/kotlin-native/blob/master/samples/csvparser).
### Reflection ### ### Reflection ###
@@ -78,6 +80,19 @@ Notice that property delegation (including lazy properties) *does* work.
### Microsoft Windows support ### ### Microsoft Windows support ###
Due to significant differences in exception handling models on MS Windows and Only 64-bit Windows is currently supported as both compilation host and target.
other LLVM targets, current _Kotlin/Native_ may not produce executables working on
MS Windows. This situation could be improved in upcoming releases. ### Debugging ###
_Kotlin/Native_ supports preliminary source-level debugging on produced executables with `lldb` debugger.
Produce your binary with debugging information by specifying `-g` _Kotlin/Native_ compiler switch or
using `-Pbuild_flags=-g` option for Gradle build. Start your application with
lldb my_program.kexe
and then
b kfun:main(kotlin.Array<kotlin.String>)
to set breakpoint in main function of your application. Single stepping and step into shall work,
variable inspection does not work yet. See [`DEBUGGING.md`](https://github.com/JetBrains/kotlin-native/blob/master/DEBUGGING.md)
+1 -1
View File
@@ -123,7 +123,7 @@ void setupCompilationFlags() {
ext.host = "macbook" ext.host = "macbook"
ext.targetArgs << ext.targetArgs <<
[(ext.host): [(ext.host):
["--sysroot=$macbookSysrootDir", "-mmacosx-version-min=$minMacOsVersion"], ["--sysroot=$macbookSysrootDir", "-mmacosx-version-min=10.11"],
"iphone": "iphone":
["-stdlib=libc++", "-arch", "arm64", "-isysroot", "$iphoneSysrootDir", ["-stdlib=libc++", "-arch", "arm64", "-isysroot", "$iphoneSysrootDir",
"-miphoneos-version-min=8.0.0"] "-miphoneos-version-min=8.0.0"]
+2 -3
View File
@@ -16,7 +16,6 @@
kotlin_version=1.1.0 kotlin_version=1.1.0
llvmVersion = 3.9.0 llvmVersion = 3.9.0
minMacOsVersion = 10.11
remoteRoot=konan_tests remoteRoot=konan_tests
#kotlinCompilerModule=org.jetbrains.kotlin:kotlin-compiler:1.1-SNAPSHOT #kotlinCompilerModule=org.jetbrains.kotlin:kotlin-compiler:1.1-SNAPSHOT
# Download artifacts of https://teamcity.jetbrains.com/viewType.html?buildTypeId=bt345 # Download artifacts of https://teamcity.jetbrains.com/viewType.html?buildTypeId=bt345
@@ -25,5 +24,5 @@ kotlinCompilerRepo=http://dl.bintray.com/jetbrains/kotlin-native-dependencies
#kotlinCompilerRepo=http://oss.sonatype.org/content/repositories/snapshots #kotlinCompilerRepo=http://oss.sonatype.org/content/repositories/snapshots
#kotlinCompilerRepo=http://dl.bintray.com/kotlin/kotlin-dev #kotlinCompilerRepo=http://dl.bintray.com/kotlin/kotlin-dev
kotlinCompilerModule=org.jetbrains.kotlin:kotlin-compiler:1.1-20170611.100554-585 kotlinCompilerModule=org.jetbrains.kotlin:kotlin-compiler:1.1-20170611.100554-585
konanVersion=0.2 konanVersion=0.3
org.gradle.jvmargs='-Dfile.encoding=UTF-8' org.gradle.jvmargs='-Dfile.encoding=UTF-8'