1. 30 Nov, 2017 1 commit
  2. 22 Nov, 2017 1 commit
  3. 21 Nov, 2017 1 commit
    • Martin Kustermann's avatar
      Add support for NDK discovery and add --prefer-shared-library option (#12788) · 545ec9ef
      Martin Kustermann authored
      * Add support for NDK discovery and add --prefer-shared-library option
      
      We would like to be able to use native tools (e.g. simpleperf, gdb) with
      precompiled flutter apps.  The native tools work much better with *.so
      files instead of the custom formats the Dart VM uses by default.
      
      The reason for using blobs / instruction snapshots is that we do not
      want to force flutter users to install the Android NDK.
      
      This CL adds a `--prefer-shared-library` flag to e.g. `flutter build
      apk` which will use the NDK compiler (if available) to turn the
      precompiled app assembly file to an `*.so` file.  If the NDK compiler is
      not available it will default to the default behavior.
      
      * Rebase, add test for NDK detection, augment flutter.gradle with @Input for flag
      
      * Use InMemoryFileSystem for test
      
      * Remove unused import
      
      * Address some analyzer warnings
      545ec9ef
  4. 22 Oct, 2017 1 commit
  5. 17 Oct, 2017 1 commit
  6. 06 Oct, 2017 1 commit
  7. 03 Oct, 2017 1 commit
    • Alexander Markov's avatar
      Add hidden options --extra-front-end-options and --extra-gen-snapshot-options... · 7153dea2
      Alexander Markov authored
      Add hidden options --extra-front-end-options and --extra-gen-snapshot-options to flutter tool (#12219)
      
      This CL introduces 2 hidden options to 'flutter build aot' and 'flutter run' for passing arbitrary arguments to front-end server and to gen_snapshot tool when building and running flutter app in --profile or --release modes.
      
      The ability to pass arbitrary options simplifies various experiments, as it removes the need to change defaults and rebuild flutter engine for every tested configuration.
      7153dea2
  8. 07 Sep, 2017 1 commit
  9. 06 Sep, 2017 1 commit
    • Chris Bracken's avatar
      Log checksum validation errors at trace level (#11944) · ce08bf9a
      Chris Bracken authored
      Checksum validation is intended only as a performance improvement.
      Checksum de-serialization errors (typically framework version mismatch) are
      expected on framework updates and shouldn't be user-visible except for
      informational purposes when --verbose is set.
      ce08bf9a
  10. 05 Sep, 2017 1 commit
    • Chris Bracken's avatar
      Invalidate snapshot when entrypoint changes (#11913) · c896fe2f
      Chris Bracken authored
      Adds the app entrypoint as a key in the checksum file.
      
      This change eliminates the assumption that checksummed files change when
      the main entrypoint changes. In the case where there are two
      entrypoints, a.dart and b.dart and a.dart imports b.dart and b.dart
      imports a.dart, building the app with entrypoint a.dart followed by a
      build of the app with entrypoint b.dart would result in the same
      files list and checksums, but should invalidate the build.
      c896fe2f
  11. 31 Aug, 2017 1 commit
  12. 29 Aug, 2017 1 commit
    • Chris Bracken's avatar
      Extract snapshotting logic to Snapshotter class (#11820) · 27d3e8a4
      Chris Bracken authored
      Extract a Snapshotter class that can be shared between FLX snapshotting,
      AOT snapshotting, and assembly AOT snapshotting. Allows for better
      testability of snapshotting logic.
      
      * Extracts script snapshotting used in FLX build.
      * Adds tests for snapshot checksumming, build invalidation/skipping.
      
      Remaining work: disentangle + extract AOT snapshotting and Assembly AOT
      snapshotting logic from build_aot.dart.
      27d3e8a4
  13. 28 Aug, 2017 1 commit
    • Chris Bracken's avatar
      Avoid rebuilding snapshots if no change to source (#11551) (#11793) · 1ee94001
      Chris Bracken authored
      This change re-introduces skipping AOT snapshot builds if input sources
      and outputs have not changed since the last snapshot build, assuming a
      build for the same platform in the same build mode.
      
      This reverts commit 3d5afb5a.
      It includes the following changes relative to the original:
        1. Include the entrypoint source in the checksums
        2. include the build mode in the checksums
        3. include the target platform in the checksums
      1ee94001
  14. 16 Aug, 2017 3 commits
  15. 08 Aug, 2017 1 commit
    • Chris Bracken's avatar
      Avoid rebuilding snapshots if no change to source (#11551) · 74835db5
      Chris Bracken authored
      This change re-introduces skipping snapshot builds if input sources (and
      outputs) have not changed since the last snapshot build, with a bugfix
      to include the entry-point source in the checksum used to check whether
      rebuild can be skipped. This ensures that the following sequence
      invalidates the cached build, resulting in two snapshot builds:
      
        flutter build ios lib/foo.dart
        flutter build ios lib/bar.dart
      
      This reverts commit 3d5afb5a.
      74835db5
  16. 07 Aug, 2017 1 commit
  17. 01 Aug, 2017 1 commit
  18. 05 Jul, 2017 1 commit
    • Chris Bracken's avatar
      Skip AOT snapshot build if inputs are unchanged (#11084) · b5e522e2
      Chris Bracken authored
      Previously, the snapshot file was recomputed on every build. We now
      record checksums for all snapshot inputs (which are catalogued in the
      snapshot dependencies file output alongside the snapshot) and only
      rebuild if the checksum for any input file (or the previous output file) has
      changed.
      b5e522e2
  19. 09 Jun, 2017 1 commit
  20. 26 Apr, 2017 1 commit
    • Todd Volkert's avatar
      Switch many `Device` methods to be async (#9587) · 60c5ffc1
      Todd Volkert authored
      `adb` can sometimes hang, which will in turn hang the Dart isolate if
      we're using `Process.runSync()`. This changes many of the `Device` methods
      to return `Future<T>` in order to allow them to use the async process
      methods. A future change will add timeouts to the associated calls so
      that we can properly alert the user to the hung `adb` process.
      
      This is work towards #7102, #9567
      60c5ffc1
  21. 19 Apr, 2017 1 commit
  22. 31 Mar, 2017 1 commit
  23. 23 Mar, 2017 2 commits
    • Chris Bracken's avatar
      25999678
    • Chris Bracken's avatar
      Build Flutter app as a framework on iOS (#8971) · 0ee3f57a
      Chris Bracken authored
      **THIS IS A BREAKING CHANGE.** See below for migration steps for
      existing projects.
      
      Previously, Flutter app code was built as a raw dylib on iOS.  Dynamic
      libraries outside of a framework bundle are not supported on iOS, except
      for the system Swift libraries provided by Xcode.
      
      See:
      https://developer.apple.com/library/content/technotes/tn2435/_index.html#//apple_ref/doc/uid/DTS40017543-CH1-TROUBLESHOOTING_BUNDLE_ERRORS-EMBEDDED__DYLIB_FILES
      
      * Migrates Xcode build from app.dylib to App.framework
      * Migrates flutter create template
      * Migrates example projects
      
      Migration steps for existing projects
      =====================================
      
      The following steps should be taken from the root of your Flutter
      project:
      
      1. Edit `ios/.gitignore`: add `/Flutter/App.framework` on a new line.
      2. In the Xcode project navigator, remove `app.dylib` from the Flutter
         folder. Delete this file from the `ios/Flutter` directory in your project.
      3. Run a build to generate `ios/Flutter/App.framework`. From the command
         line, run `flutter build ios`. If you have not configured app signing
         in Xcode, an alternative method is to open the simulator, then run
         `flutter run -d iP`.
      4. In the Xcode project navigator, select the `Runner` project. In the
         project settings that are displayed in the main view, ensure that the
         `Runner` target is selected. You can verify this by exposing the
         sidebar using the [| ] icon in the upper-left corner of the main
         view.
      5. Select the *General* tab in the project settings. Under the
         *Embedded Binaries* section, click '+' to add `App.framework`. In the
         sheet that drops down, click the *Add Other...* button. Navigate to
         the `ios/Flutter` directory and select `App.framework`. Click *Open*.
         In the sheet that drops down, select *Create folder references*, then
         click *Finish*.
      6. In the project settings, verify that `App.framework` has been added to the
         *Embedded Binaries* and *Linked Frameworks and Libraries* lists.
      7. In the Xcode project navigator, drag `App.framework` under the
         Flutter folder.
      8. In the Xcode project navigator, select `Flutter` then from the
         *File* menu, select *Add Files to "Runner"...*. Navigate to the
         `ios/Flutter` directory, select `AppFrameworkInfo.plist` and click
         the *Add* button.
      9. From the command line, in your project directory, run
         `flutter build clean`, then `flutter run`.
      
      At this point your project should be fully migrated.
      0ee3f57a
  24. 15 Mar, 2017 1 commit
    • Jakob Andersen's avatar
      Put Gradle output in build/ (#8759) · 1457f3db
      Jakob Andersen authored
      Changed the default build output directory in the new project template
      to build/, instead of android/build/ and android/app/build/.
      
      Updated tools to ask the Gradle scripts what the build directory is,
      since this is configurable in the build scripts, and we need to know
      where the build output actually is.
      
      Silenced output from 'flutter build aot' when invoked from Gradle, since
      the output was confusing in this case.
      
      Fixes #8723
      Fixes #8656
      Fixes #8138
      1457f3db
  25. 14 Mar, 2017 2 commits
    • Zachary Anderson's avatar
    • Jakob Andersen's avatar
      Use snapshot's .d file as source inputs in Gradle build. (#8756) · 9c6ffc82
      Jakob Andersen authored
      * Use snapshot's .d file as source inputs in Gradle build.
      
      If we don't yet have a .d file (first build), fall back to using the
      .dart files in the current directory. This enables us to detect changes
      in dependent source files (Flutter framework, packages outside the
      source directory, etc.), and re-generate the snapshots as needed.
      
      Unfortunately, Gradle requires knowing the source files before executing
      the task, and can't update them after building, so Gradle considers the
      second build to be out-of-date (because it has more input files than the
      first build). Sub-sequent builds have the correct dependency
      information, and will be skipped if the source files haven't changed.
      
      Also added a dependency on gen_snapshot. The snapshot ABI isn't stable,
      so we need to re-generate the snapshots when we roll the Dart SDK
      dependency.
      
      Fixes #8315
      Fixes #8687
      Fixes #8607
      9c6ffc82
  26. 04 Mar, 2017 1 commit
  27. 02 Mar, 2017 1 commit
  28. 17 Feb, 2017 2 commits
  29. 14 Feb, 2017 1 commit
  30. 13 Feb, 2017 1 commit
  31. 11 Feb, 2017 1 commit
  32. 10 Feb, 2017 1 commit
  33. 08 Feb, 2017 1 commit
  34. 27 Jan, 2017 1 commit
  35. 24 Jan, 2017 1 commit