Documentation

Lake.Build.Context

Configuration options for a Lake build.

  • oldMode : Bool

    Whether to use modification times for trace checking.

  • trustHash : Bool

    Whether to trust .hash files.

  • noBuild : Bool

    Early exit if a target has to be rebuilt.

  • verbosity : Verbosity

    Verbosity level (-q, -v, or neither).

  • showSuccess : Bool

    Whether to print a message when the build finishes successfully (if not quiet).

  • outputsFile? : Option System.FilePath

    File to save input-to-output mappings from the build of the workspace's root

  • leanOptOverrides : Lean.NameMap Lean.LeanOptions

    Per-package Lean option overrides, applied to every module whose owning package's baseName appears as a key. When recFetchSetup builds module M, the LeanOptions associated with M.pkg.baseName (if any) are appended to M.leanOptions, overriding clashing entries.

    Used by lake lint to inject linter.extra/linter.all into every module of a target package (so transitively-imported first-party modules capture linter-tagged warnings), without touching dependencies.

  • macosxDeploymentTarget? : Option String

    The miniumum OS version to target on MacOS.

    If a minimum is not set, linkers default the minimum to the host major version and will emit warnings if any lineed libraries (including system libraries) exceed the minium. Thus, the linker will complain when building on a system with an unset minimum and system libraries which require a higher minor version.

    ld64.lld: warning: /usr/lib/system/libsystem_kernel.dylib has version 13.5.0, which is newer than target minimum of 13.0.0
    

    To silence such warnings, Lake sets this far into the future by default (e.g., 99.0). However, that itself can be wrong if a consumer of Lean library uses the minimum OS version to determine compatibility (e.g., Python does this). The far-flung version would then imply zero compatibility.

    In such cases, the desired deployment target can be manually specified . Depending on the desired scope, it can be set per-target, for all targets within a buld (with this), or across all builds with the environment variable MACOSX_DEPLOYMENT_TARGET.

Instances For

    Whether the build should show progress information.

    Verbosity.quiet hides progress and, for a noBuild, Verbosity.verbose shows progress.

    Equations
    Instances For

      Mutable reference of registered build jobs.

      Equations
      Instances For
        @[inline]

        Returns a new empty job queue.

        Equations
        Instances For

          A Lake context with a build configuration and additional build data.

          Instances For
            @[reducible, inline]
            abbrev Lake.BuildT (m : TypeType u_1) (α : Type) :
            Type u_1

            A transformer to equip a monad with a BuildContext.

            Equations
            Instances For
              @[reducible, inline]
              abbrev Lake.MonadBuild (m : TypeType u) :

              A monad equipped with a Lake build context.

              Equations
              Instances For
                @[instance_reducible]
                Equations
                @[inline]
                Equations
                Instances For
                  @[inline]
                  def Lake.getIsOldMode {m : TypeType u_1} [Functor m] [MonadBuild m] :

                  Whether to use modification times for trace checking.

                  Equations
                  Instances For
                    @[inline]
                    def Lake.getTrustHash {m : TypeType u_1} [Functor m] [MonadBuild m] :

                    Whether to trust .hash files.

                    Equations
                    Instances For
                      @[inline]
                      def Lake.getNoBuild {m : TypeType u_1} [Functor m] [MonadBuild m] :

                      Early exit if a target has to be rebuilt.

                      Equations
                      Instances For
                        @[inline]
                        def Lake.getVerbosity {m : TypeType u_1} [Functor m] [MonadBuild m] :

                        Verbosity level (-q, -v, or neither).

                        Equations
                        Instances For
                          @[inline]
                          def Lake.getIsVerbose {m : TypeType u_1} [Functor m] [MonadBuild m] :
                          Equations
                          Instances For
                            @[inline]
                            def Lake.getIsQuiet {m : TypeType u_1} [Functor m] [MonadBuild m] :
                            Equations
                            Instances For
                              @[inline]

                              Per-package Lean option overrides, applied to every module whose owning package's baseName appears as a key. When recFetchSetup builds module M, the LeanOptions associated with M.pkg.baseName (if any) are appended to M.leanOptions, overriding clashing entries.

                              Used by lake lint to inject linter.extra/linter.all into every module of a target package (so transitively-imported first-party modules capture linter-tagged warnings), without touching dependencies.

                              Equations
                              Instances For
                                @[inline]

                                The miniumum OS version to target on MacOS.

                                If a minimum is not set, linkers default the minimum to the host major version and will emit warnings if any lineed libraries (including system libraries) exceed the minium. Thus, the linker will complain when building on a system with an unset minimum and system libraries which require a higher minor version.

                                ld64.lld: warning: /usr/lib/system/libsystem_kernel.dylib has version 13.5.0, which is newer than target minimum of 13.0.0
                                

                                To silence such warnings, Lake sets this far into the future by default (e.g., 99.0). However, that itself can be wrong if a consumer of Lean library uses the minimum OS version to determine compatibility (e.g., Python does this). The far-flung version would then imply zero compatibility.

                                In such cases, the desired deployment target can be manually specified . Depending on the desired scope, it can be set per-target, for all targets within a buld (with this), or across all builds with the environment variable MACOSX_DEPLOYMENT_TARGET.

                                Equations
                                Instances For