diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 13a6e35..0b5ca7b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -47,6 +47,8 @@ jobs: - name: Patch config (non-PR) if: ${{ github.event_name != 'pull_request' }} run: | + # Replace a set of _name variables (that have # [osx] comments with + # an particular string (is this the certificate ID?) sed -i "" "s/_name: *# \[osx\]/_name: 9779L28NP8 # \[osx\]/" ${RECIPE_DIR}/construct.yaml - run: ./tools/run_constructor.sh timeout-minutes: 20 @@ -108,6 +110,7 @@ jobs: - uses: mamba-org/setup-micromamba@v2 with: environment-file: environment.yml + # https://nsis.sourceforge.io/Download - run: conda install -c conda-forge -y "nsis==3.08" - run: ./tools/extract_version.sh - run: ./tools/run_constructor.sh @@ -147,6 +150,7 @@ jobs: run: | sudo installer -verbose -pkg ${MNE_INSTALLER_NAME} -target / \ || ( tail -n 30 /var/log/install.log && exit 1 ) # display last log messages on error + # Check the list of packages that were actually installed by the installer. - run: ./tools/export_frozen_env_def.sh - uses: actions/upload-artifact@v4 with: @@ -159,6 +163,8 @@ jobs: qt: true pyvista: false wm: false + # Checking architecture is correct, files went to correct directories, + # checks packages via JSON file above ... - run: ./tools/check_installation.sh test_linux: diff --git a/notes.md b/notes.md new file mode 100644 index 0000000..ef1963a --- /dev/null +++ b/notes.md @@ -0,0 +1,58 @@ +# Notes on installer mechanics + +Fundamental engine is , a tool for +creating double-click installers from a collection of Conda packages. + +The README above has: + +> The constructor command takes an installer specification directory as its +argument. This directory needs to contain a file construct.yaml, which +specifies the name of the installer, the conda channels to pull packages from, +the conda packages included in the installer, etc. + +In this repo, that file is `recipes/mne-python/construct.yaml`. It specifies, +among other things, that `conda-forge` is the only `channel` for fetching packages to provide installer. + +```yaml +channels: + - conda-forge +``` + +Later, it specifies that `conda-forge` is the only channel for the provided environment: + + +```yaml +condarc: + channels: + - conda-forge + channel_priority: strict + allow_other_channels: false + env_prompt: "(mne-1.9.0_0) " +``` + +From [the contructor README](https://github.com/conda/constructor): + +> ## condarc +> +> If set, a .condarc file is written to the base environment containing the +contents of this value. The value can either be a string (likely a multi-line +string) or a dictionary, which will be converted to a YAML string for writing. +Note: if this option is used, then all other options related to the +construction of a .condarc file (write_condarc, conda_default_channels, etc.) +are ignored. + +Mac (Intel, ARM) build instructions are in `.github/workflows/build.yaml`. + +## Build recipes + +These are all in `.github/workflows/build.yml`. + +### Mac build recipe + +Summary of steps: + +* `tools/extract_version.sh`: this is a shell script that extracts information + from the environment, and puts this information into environment variables. + Within a Github action, it also sets Github environment for subsequent steps. +* `tools/run_constructor.sh` runs the `constructor` executable to build the + package from the recipe above.