Initial checkin of Pika from heckimp
This commit is contained in:
37
build/buildbot/suppressed-warnings.txt
Normal file
37
build/buildbot/suppressed-warnings.txt
Normal file
@ -0,0 +1,37 @@
|
||||
# This is a 'suppressionFile' for buildbot warnings
|
||||
# We use isn.*t because UTF-8 ’ might be interpreted as ASCII...
|
||||
|
||||
# Ignore warning from gtk-doc during make
|
||||
: .*html:.*: warning: no link for: .*
|
||||
: .*warning: .* unused declarations.*They should be added to .* in the appropriate place.*
|
||||
: .*warning: Field description for .* is missing in source code comment block.*
|
||||
: .*warning: Field descriptions for .* are missing in source code comment block.*
|
||||
: .*warning: Property .* has no documentation.*
|
||||
: .*warning: Section .* is not defined in the .* file.*
|
||||
: .*warning: Value descriptions for .* are missing in source code comment block.*
|
||||
|
||||
# This will die in PIKA 3.0, don't bother fixing...
|
||||
: .*pika-composite-.* warning: function declaration isn.*t a prototype.*
|
||||
: .*pika-composite-.* warning: unused variable .*
|
||||
|
||||
# Well-known harmless warnings
|
||||
: .*gtkitemfactory.h:47: warning: function declaration isn.*t a prototype.*
|
||||
|
||||
# Who cares
|
||||
: .*pika.desktop: warning: value .* contains .* more than once.*
|
||||
: ^libtool: install: warning:.*
|
||||
|
||||
# Annoying plug-ins/imagemap warnings in generated files, not easily
|
||||
# fixed properly
|
||||
: <stdout>.* warning: .*yyunput.* defined but not used
|
||||
: <stdout>.* warning: .*input.* defined but not used
|
||||
|
||||
# Comes from AM_PROG_LIBTOOL, not much we can do
|
||||
: ^configure.ac:157: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body$
|
||||
|
||||
# jas_config.h redefines PACKAGE_NAME etc
|
||||
: .*jas_config.h:.*:1: warning: .* redefined$
|
||||
: .*config.h:.*:1: warning: this is the location of the previous definition$
|
||||
|
||||
# Tons of deprecation warnings, hopefully we never have to fix these...
|
||||
: .*file-.*: warning: .* is deprecated \(declared at .*/png.h:.*\)$
|
24
build/docker/pikabuilder-base/Dockerfile
Normal file
24
build/docker/pikabuilder-base/Dockerfile
Normal file
@ -0,0 +1,24 @@
|
||||
# This file is an outdated incomplete experiment for a Docker-based build environment and won't get you a working build environment. It was created just before our switch to GitLab CI and became mostly obsolete due to this.
|
||||
|
||||
# pikabuilder-base
|
||||
|
||||
FROM debian:testing
|
||||
|
||||
ENV PREFIX=/export/output
|
||||
ENV PATH=$PREFIX/bin:$PATH
|
||||
ENV PKG_CONFIG_PATH=$PREFIX/lib/pkgconfig:$PKG_CONFIG_PATH
|
||||
ENV APT_GET_OPTIONS="-o APT::Install-Recommends=0 -y"
|
||||
|
||||
RUN apt-get update
|
||||
|
||||
# Installing the build environment
|
||||
RUN apt-get install $APT_GET_OPTIONS build-essential devscripts fakeroot quilt dh-make automake libdistro-info-perl less nano
|
||||
|
||||
# Installing additional dependencies for babl
|
||||
# none needed
|
||||
|
||||
# Installing additional dependencies for GEGL
|
||||
RUN apt-get install $APT_GET_OPTIONS libglib2.0-dev libjson-c-dev libjson-glib-dev libgexiv2-dev libcairo2-dev libpango1.0-dev libjpeg62-turbo-dev libsuitesparse-dev libspiro-dev libopenexr-dev libwebp-dev
|
||||
|
||||
# Installing additional dependencies for PIKA
|
||||
RUN apt-get install $APT_GET_OPTIONS xsltproc gtk-doc-tools libgtk2.0-dev libtiff5-dev libbz2-dev liblzma-dev librsvg2-dev liblcms2-dev python-cairo-dev python-gtk2-dev glib-networking libaa1-dev libgs-dev libpoppler-glib-dev libmng-dev libwmf-dev libxpm-dev libasound2-dev
|
233
build/flatpak/README.md
Normal file
233
build/flatpak/README.md
Normal file
@ -0,0 +1,233 @@
|
||||
# PIKA Flatpak HowTo
|
||||
|
||||
## Stable and Development releases
|
||||
|
||||
The Flathub repository hosts our stable and development point releases:
|
||||
https://github.com/flathub/technology.heckin.PIKA
|
||||
|
||||
We recommend to look at the `README.md` file in respectively the `master` or
|
||||
`beta` branches of this repository to know more about release procedures.
|
||||
|
||||
## Nightly builds
|
||||
|
||||
Flathub does not host nightly builds, therefore we publish them on GNOME's
|
||||
Nightly repository. Our "nightlies" are actually "weeklies" through a [Gitlab job
|
||||
schedule named "Flatpak
|
||||
nightly"](https://gitlab.gnome.org/GNOME/pika/-/pipeline_schedules).
|
||||
|
||||
This job will build whatever is on PIKA's repository `master` branch (this
|
||||
branch should be kept buildable and usable at all time, not only for scheduled
|
||||
jobs, but also for all contributors to be able to improve PIKA at all time).
|
||||
|
||||
The nightly manifest file is: `build/flatpak/technology.heckin.PIKA-nightly.json`
|
||||
|
||||
This file should remain as close as possible to the development manifest
|
||||
(`technology.heckin.PIKA.json` file on the `beta` branch of the Flathub repository) which
|
||||
itself should remain as close as possible to the stable manifest
|
||||
(`technology.heckin.PIKA.json` file on the `master` branch of the Flathub repository),
|
||||
since the nightly manifest is meant to become beta eventually, which itself is
|
||||
meant to become stable eventually.
|
||||
|
||||
Base rule to update the nightly build manifest:
|
||||
|
||||
* Regularly `technology.heckin.PIKA-nightly.json` should be diffed and synced with
|
||||
development and stable `technology.heckin.PIKA.json`, in particular for all the
|
||||
dependencies (which are mostly the same across all 3 builds).
|
||||
* A merge request with the label `5. Flatpak package` will contain the `flatpak`
|
||||
job, hence allowing theoretically to build a standalone flatpak (without being
|
||||
published to the nightly repository) for MR code. In practice, jobs have an
|
||||
1-hour timeout and our flatpak takes longer than 1 hour to build (there is an
|
||||
exception in our repository, but only for the `master` branch), so we often
|
||||
need to publish to `master` after mostly a visual review.
|
||||
|
||||
## Custom Flatpak builds (for development)
|
||||
|
||||
Most contributors simply build PIKA the "old-school" way, nevertheless some
|
||||
projects are starting to use `flatpak` as a development environment. Here is how
|
||||
this can be done, as far as our knowledge goes.
|
||||
|
||||
Note 1
|
||||
: The below process is about using flatpak as a development environment, not for
|
||||
proper [releases to a
|
||||
repository](https://docs.flatpak.org/en/latest/flatpak-builder.html), neither
|
||||
for creating [standalone
|
||||
bundles](https://docs.flatpak.org/en/latest/single-file-bundles.html)
|
||||
|
||||
Note 2
|
||||
: since we usually only use flatpak for releases, not for development, there may
|
||||
be better ways to make a flatpak development environment. We welcome any
|
||||
proposed improvement to this file.
|
||||
|
||||
* Dependencies:
|
||||
- flatpak (at least 0.9.5)
|
||||
- flatpak-builder (at least 0.9.5, when the option `--export-only` has been
|
||||
added to `flatpak-builder` so that the build and the export can be made in 2
|
||||
separate steps while using the high level procedure.)
|
||||
- appstream-compose
|
||||
|
||||
Note 1
|
||||
: there are packages of `flatpak` and `flatpak-builder` for [most
|
||||
distributions](http://flatpak.org/getting.html).
|
||||
|
||||
Note 2
|
||||
: `appstream-compose` is used to parse the appdata file and generate the
|
||||
appstream (metadata like comments, etc.).
|
||||
On Fedora, this is provided by the package `libappstream-glib`, on Ubuntu by
|
||||
`appstream-util`…
|
||||
|
||||
* Install the runtimes and the corresponding SDKs if you haven't already:
|
||||
|
||||
```sh
|
||||
flatpak remote-add --user --from gnome https://nightly.gnome.org/gnome-nightly.flatpakrepo
|
||||
flatpak install --user gnome org.gnome.Platform/x86_64/master org.gnome.Sdk/x86_64/master
|
||||
flatpak install --user gnome org.gnome.Platform/aarch64/master org.gnome.Sdk/aarch64/master
|
||||
```
|
||||
|
||||
Or simply update them if you have already installed them:
|
||||
|
||||
```sh
|
||||
flatpak update
|
||||
```
|
||||
|
||||
* Setup some recommended build options:
|
||||
|
||||
```sh
|
||||
export BUILD_OPTIONS="--ccache --keep-build-dirs --force-clean"
|
||||
```
|
||||
|
||||
We recommend using `ccache` to improve build speed, and to keep build dirs
|
||||
(these will be found in `.flatpak-builder/build/` relatively to the work
|
||||
directory; you may manually delete these once you are done to save space) for
|
||||
later debugging if ever any configuration or build issue arises.
|
||||
|
||||
* Choose what architecture to build and where you will "install" your flatpak:
|
||||
|
||||
```sh
|
||||
# Architectures supported with PIKA flatpak are one of 'x86_64' or 'aarch64':
|
||||
export ARCH="x86_64"
|
||||
# Path where build files are stored
|
||||
export INSTALLDIR="`pwd`/${ARCH}"
|
||||
```
|
||||
|
||||
* Build the flatpak up to PIKA itself (not included):
|
||||
|
||||
```sh
|
||||
flatpak-builder $BUILD_OPTIONS --arch="$ARCH" --stop-at=pika \
|
||||
"${INSTALLDIR}" technology.heckin.PIKA-nightly.json 2>&1 \
|
||||
| tee pika-nightly-flatpak.log
|
||||
```
|
||||
|
||||
The build log will be outputted on `stdout` as well as being stored in a file
|
||||
`pika-nightly-flatpak.log`.
|
||||
|
||||
* Now we'll want to build PIKA itself, yet not from a clean repository clone
|
||||
(which is what the manifest provides) but from your local checkout, so that
|
||||
you can include any custom code:
|
||||
|
||||
```sh
|
||||
flatpak build "${INSTALLDIR}" meson setup --prefix=/app/ --libdir=/app/lib/ _pika ../../ 2>&1 | tee -a pika-nightly-flatpak.log
|
||||
flatpak build "${INSTALLDIR}" ninja -C _pika 2>&1 | tee -a pika-nightly-flatpak.log
|
||||
flatpak build "${INSTALLDIR}" ninja -C _pika install 2>&1 | tee -a pika-nightly-flatpak.log
|
||||
```
|
||||
|
||||
This assumes you are currently within `build/flatpak/`, therefore the
|
||||
repository source is 2 parent-folders away (`../../`). The build artifacts
|
||||
will be inside the `_pika/` subfolders, and finally it will be installed with
|
||||
the rest of the flatpak inside `$INSTALLDIR`.
|
||||
|
||||
* For development purpose, you don't need to export the flatpak to a repository
|
||||
or even install it. Just run it directly from your build directory:
|
||||
|
||||
```sh
|
||||
flatpak-builder --run "${INSTALLDIR}" technology.heckin.PIKA-nightly.json pika-2.99
|
||||
```
|
||||
|
||||
## Maintaining the manifests
|
||||
|
||||
* PIKA uses Flatpak's [GNOME runtime](http://flatpak.org/runtimes.html), which
|
||||
contains a base of libraries, some of which are dependencies of PIKA.
|
||||
While both the stable and development versions should use the latest stable
|
||||
runtime version, the nightly manifest uses the `master` version, which is more
|
||||
of a *rolling release*.
|
||||
|
||||
* Other PIKA dependencies which are not available in the GNOME runtime
|
||||
should be built along as modules within PIKA's flatpak.
|
||||
Check format in `technology.heckin.PIKA-nightly.json` and add modules if
|
||||
necessary. For more options, check [flatpak builder's manifest
|
||||
format](http://flatpak.org/flatpak/flatpak-docs.html#flatpak-builder).
|
||||
|
||||
* On the other hand, if we increased the runtime version in particular (or when
|
||||
the `master` runtime evolves), some modules may no longer be necessary and can
|
||||
be removed from our manifest.
|
||||
|
||||
A flatpak is a layered set of modules. Our PIKA build in particular is
|
||||
built over the GNOME runtime, itself built over the Freedesktop
|
||||
runtime, itself based on a yocto-built image.
|
||||
Other than by trial and error, you can find the installed dependencies
|
||||
by running:
|
||||
|
||||
```sh
|
||||
flatpak run --devel --command=bash org.gnome.Sdk//master
|
||||
```
|
||||
|
||||
Or if you already have a build:
|
||||
|
||||
```
|
||||
flatpak run --devel --command=bash technology.heckin.PIKA//master
|
||||
```
|
||||
|
||||
Inside the flatpak sandbox, PIKA's manifest can be read with:
|
||||
|
||||
```sh
|
||||
less /app/manifest.json
|
||||
```
|
||||
|
||||
GNOME and Freedesktop's module lists (generated manifest as the SDK is built
|
||||
from BuildStream):
|
||||
|
||||
```sh
|
||||
less /usr/manifest.json
|
||||
```
|
||||
|
||||
* Some sources have set a `x-checker-data` property which makes it possible to
|
||||
check for updates using
|
||||
[flatpak-external-data-checker](https://github.com/flathub/flatpak-external-data-checker).
|
||||
To run the tool either install it locally, via flatpak or via OCI image.
|
||||
|
||||
The OCI image is not straightforward at first but is the least intrusive
|
||||
if you already have docker or podman installed:
|
||||
|
||||
```sh
|
||||
cd <path-to-pika-repo>/flatpak/build
|
||||
podman run --rm --privileged -v "$(pwd):/run/host:rw" ghcr.io/flathub/flatpak-external-data-checker:latest /run/host/technology.heckin.PIKA-nightly.json
|
||||
```
|
||||
|
||||
Our prefered backend for the checker is Anitya, a database maintained
|
||||
by the Fedora project. To set up a new dependency check by Anitya:
|
||||
|
||||
1. verify it is available in the database: https://release-monitoring.org/
|
||||
2. then copy the project ID which is the number in the project URI
|
||||
within the database.
|
||||
3. Finally add a "x-checker-data" field within the "source" dictionary
|
||||
in the manifest with type "anitya", the "project-id" and a
|
||||
"url-template".
|
||||
4. We usually want to depend on stable releases only, i.e. set
|
||||
"stable-only to `true`. On exceptional cases, for very valid
|
||||
reasons only, we might bypass this limitation, adding a comment
|
||||
explaining why we use an unstable release.
|
||||
|
||||
* For the development releases and nightly builds, we added the
|
||||
`desktop-file-name-prefix` property. For a stable release, the property line
|
||||
can be removed from the manifest.
|
||||
|
||||
* For a stable release, set top `"branch":"stable"`, and inside the
|
||||
"pika", "babl" and "gegl" modules, set "tag" to the git tag (ex:
|
||||
`PIKA_2_10_34`) and "commit" to the git commit hash for this tag.
|
||||
|
||||
* For a development release, set top `"branch":"beta"`, and inside the
|
||||
"pika", "babl" and "gegl" modules, set "tag" to the git tag (ex:
|
||||
`PIKA_2_99_14`) and "commit" to the git commit hash for this tag.
|
||||
|
||||
* For a nightly build, set top "branch":"master", and inside the
|
||||
"pika", "babl" and "gegl" modules, set "branch" to "master", and
|
||||
remove any "commit" line.
|
119
build/flatpak/patches/suitesparse-reduce-build.patch
Normal file
119
build/flatpak/patches/suitesparse-reduce-build.patch
Normal file
@ -0,0 +1,119 @@
|
||||
diff -Naur SuiteSparse-5.11.0/Makefile SuiteSparse-5.11.0.patched/Makefile
|
||||
--- SuiteSparse-5.11.0/Makefile 2021-05-18 15:01:16.000000000 +0200
|
||||
+++ SuiteSparse-5.11.0.patched/Makefile 2021-07-22 02:03:40.698984882 +0200
|
||||
@@ -35,7 +35,7 @@
|
||||
endif
|
||||
( cd SPQR && $(MAKE) )
|
||||
( cd GraphBLAS && $(MAKE) JOBS=$(JOBS) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' )
|
||||
- ( cd SLIP_LU && $(MAKE) )
|
||||
+# ( cd SLIP_LU && $(MAKE) )
|
||||
# ( cd PIRO_BAND && $(MAKE) )
|
||||
# ( cd SKYLINE_SVD && $(MAKE) )
|
||||
|
||||
@@ -46,27 +46,27 @@
|
||||
# (note that CSparse is not installed; CXSparse is installed instead)
|
||||
install: metisinstall gbinstall moninstall
|
||||
( cd SuiteSparse_config && $(MAKE) install )
|
||||
# ( cd Mongoose && $(MAKE) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' install )
|
||||
( cd AMD && $(MAKE) install )
|
||||
- ( cd BTF && $(MAKE) install )
|
||||
+# ( cd BTF && $(MAKE) install )
|
||||
( cd CAMD && $(MAKE) install )
|
||||
( cd CCOLAMD && $(MAKE) install )
|
||||
( cd COLAMD && $(MAKE) install )
|
||||
( cd CHOLMOD && $(MAKE) install )
|
||||
- ( cd CXSparse && $(MAKE) install )
|
||||
- ( cd LDL && $(MAKE) install )
|
||||
- ( cd KLU && $(MAKE) install )
|
||||
+# ( cd CXSparse && $(MAKE) install )
|
||||
+# ( cd LDL && $(MAKE) install )
|
||||
+# ( cd KLU && $(MAKE) install )
|
||||
( cd UMFPACK && $(MAKE) install )
|
||||
- ( cd RBio && $(MAKE) install )
|
||||
+# ( cd RBio && $(MAKE) install )
|
||||
ifneq (,$(GPU_CONFIG))
|
||||
( cd SuiteSparse_GPURuntime && $(MAKE) install )
|
||||
( cd GPUQREngine && $(MAKE) install )
|
||||
endif
|
||||
- ( cd SPQR && $(MAKE) install )
|
||||
+# ( cd SPQR && $(MAKE) install )
|
||||
# ( cd GraphBLAS && $(MAKE) JOBS=$(JOBS) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' install )
|
||||
# ( cd PIRO_BAND && $(MAKE) install )
|
||||
# ( cd SKYLINE_SVD && $(MAKE) install )
|
||||
- ( cd SLIP_LU && $(MAKE) install )
|
||||
+# ( cd SLIP_LU && $(MAKE) install )
|
||||
$(CP) README.md $(INSTALL_DOC)/SuiteSparse_README.md
|
||||
chmod 644 $(INSTALL_DOC)/SuiteSparse_README.md
|
||||
|
||||
@@ -110,7 +110,7 @@
|
||||
( cd SuiteSparse_GPURuntime && $(MAKE) uninstall )
|
||||
( cd GPUQREngine && $(MAKE) uninstall )
|
||||
( cd SPQR && $(MAKE) uninstall )
|
||||
- ( cd SLIP_LU && $(MAKE) uninstall )
|
||||
+# ( cd SLIP_LU && $(MAKE) uninstall )
|
||||
# ( cd PIRO_BAND && $(MAKE) uninstall )
|
||||
# ( cd SKYLINE_SVD && $(MAKE) uninstall )
|
||||
ifeq (,$(MY_METIS_LIB))
|
||||
@@ -126,26 +126,26 @@
|
||||
# the static library
|
||||
library: metis
|
||||
( cd SuiteSparse_config && $(MAKE) )
|
||||
- ( cd Mongoose && $(MAKE) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' library )
|
||||
+# ( cd Mongoose && $(MAKE) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' library )
|
||||
( cd AMD && $(MAKE) library )
|
||||
- ( cd BTF && $(MAKE) library )
|
||||
+# ( cd BTF && $(MAKE) library )
|
||||
( cd CAMD && $(MAKE) library )
|
||||
( cd CCOLAMD && $(MAKE) library )
|
||||
( cd COLAMD && $(MAKE) library )
|
||||
( cd CHOLMOD && $(MAKE) library )
|
||||
- ( cd KLU && $(MAKE) library )
|
||||
- ( cd LDL && $(MAKE) library )
|
||||
+# ( cd KLU && $(MAKE) library )
|
||||
+# ( cd LDL && $(MAKE) library )
|
||||
( cd UMFPACK && $(MAKE) library )
|
||||
( cd CSparse && $(MAKE) library )
|
||||
- ( cd CXSparse && $(MAKE) library )
|
||||
- ( cd RBio && $(MAKE) library )
|
||||
+# ( cd CXSparse && $(MAKE) library )
|
||||
+# ( cd RBio && $(MAKE) library )
|
||||
ifneq (,$(GPU_CONFIG))
|
||||
( cd SuiteSparse_GPURuntime && $(MAKE) library )
|
||||
( cd GPUQREngine && $(MAKE) library )
|
||||
endif
|
||||
- ( cd SPQR && $(MAKE) library )
|
||||
- ( cd GraphBLAS && $(MAKE) JOBS=$(JOBS) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' library )
|
||||
- ( cd SLIP_LU && $(MAKE) library )
|
||||
+# ( cd SPQR && $(MAKE) library )
|
||||
+# ( cd GraphBLAS && $(MAKE) JOBS=$(JOBS) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' library )
|
||||
+# ( cd SLIP_LU && $(MAKE) library )
|
||||
# ( cd PIRO_BAND && $(MAKE) library )
|
||||
# ( cd SKYLINE_SVD && $(MAKE) library )
|
||||
|
||||
@@ -173,7 +173,7 @@
|
||||
endif
|
||||
( cd SPQR && $(MAKE) static )
|
||||
( cd GraphBLAS && $(MAKE) JOBS=$(JOBS) CMAKE_OPTIONS='$(CMAKE_OPTIONS)' static )
|
||||
- ( cd SLIP_LU && $(MAKE) static )
|
||||
+# ( cd SLIP_LU && $(MAKE) static )
|
||||
# ( cd PIRO_BAND && $(MAKE) static )
|
||||
# ( cd SKYLINE_SVD && $(MAKE) static )
|
||||
|
||||
@@ -200,7 +200,7 @@
|
||||
- ( cd SuiteSparse_GPURuntime && $(MAKE) purge )
|
||||
- ( cd GPUQREngine && $(MAKE) purge )
|
||||
- ( cd SPQR && $(MAKE) purge )
|
||||
- - ( cd SLIP_LU && $(MAKE) purge )
|
||||
+# - ( cd SLIP_LU && $(MAKE) purge )
|
||||
# - ( cd PIRO_BAND && $(MAKE) purge )
|
||||
# - ( cd SKYLINE_SVD && $(MAKE) purge )
|
||||
- $(RM) MATLAB_Tools/*/*.mex* MATLAB_Tools/spok/private/*.mex*
|
||||
@@ -227,7 +227,7 @@
|
||||
- ( cd SuiteSparse_GPURuntime && $(MAKE) clean )
|
||||
- ( cd GPUQREngine && $(MAKE) clean )
|
||||
- ( cd SPQR && $(MAKE) clean )
|
||||
- - ( cd SLIP_LU && $(MAKE) clean )
|
||||
+# - ( cd SLIP_LU && $(MAKE) clean )
|
||||
# - ( cd PIRO_BAND && $(MAKE) clean )
|
||||
# - ( cd SKYLINE_SVD && $(MAKE) clean )
|
||||
|
13
build/flatpak/remove-future-appdata-release.xslt
Normal file
13
build/flatpak/remove-future-appdata-release.xslt
Normal file
@ -0,0 +1,13 @@
|
||||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||
|
||||
<xsl:output method="xml" omit-xml-declaration="no" encoding="UTF-8"/>
|
||||
|
||||
<xsl:template match="node()|@*">
|
||||
<xsl:copy>
|
||||
<xsl:apply-templates select="node()|@*"/>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="//release[@date='TODO']"/>
|
||||
|
||||
</xsl:stylesheet>
|
846
build/flatpak/technology.heckin.PIKA-nightly.json
Normal file
846
build/flatpak/technology.heckin.PIKA-nightly.json
Normal file
@ -0,0 +1,846 @@
|
||||
{
|
||||
"app-id": "technology.heckin.PIKA",
|
||||
"branch": "master",
|
||||
"runtime": "org.gnome.Platform",
|
||||
"runtime-version": "master",
|
||||
"sdk": "org.gnome.Sdk",
|
||||
"command": "pika-2.99",
|
||||
"separate-locales": false,
|
||||
"rename-desktop-file": "pika.desktop",
|
||||
"rename-icon": "pika",
|
||||
"copy-icon": true,
|
||||
"finish-args": [
|
||||
"--share=ipc",
|
||||
"--share=network",
|
||||
"--socket=fallback-x11",
|
||||
"--socket=wayland",
|
||||
"--device=dri",
|
||||
"--filesystem=host",
|
||||
"--filesystem=xdg-config/PIKA",
|
||||
"--filesystem=xdg-config/gtk-3.0",
|
||||
"--filesystem=/tmp",
|
||||
"--filesystem=xdg-run/gvfs",
|
||||
"--filesystem=xdg-run/gvfsd",
|
||||
"--talk-name=org.gtk.vfs",
|
||||
"--talk-name=org.gtk.vfs.*",
|
||||
"--talk-name=org.freedesktop.FileManager1",
|
||||
"--talk-name=org.gnome.Shell.Screenshot",
|
||||
"--talk-name=org.kde.kwin.Screenshot"
|
||||
],
|
||||
"tags": [
|
||||
"GTK+3",
|
||||
"nightly"
|
||||
],
|
||||
"desktop-file-name-prefix": "(Nightly) ",
|
||||
"cleanup": [
|
||||
"/include",
|
||||
"/lib/pkgconfig",
|
||||
"/share/pkgconfig",
|
||||
"/share/aclocal",
|
||||
"/man",
|
||||
"/share/man",
|
||||
"/share/gtk-doc",
|
||||
"/share/vala",
|
||||
"*.la",
|
||||
"*.a"
|
||||
],
|
||||
"modules": [
|
||||
{
|
||||
"name": "appstream-glib",
|
||||
"buildsystem": "meson",
|
||||
"config-opts": [
|
||||
"-Dstemmer=false",
|
||||
"-Drpm=false",
|
||||
"-Dfonts=false",
|
||||
"-Ddep11=false"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://people.freedesktop.org/~hughsient/appstream-glib/releases/appstream-glib-0.8.2.tar.xz",
|
||||
"sha256": "71256500add5048d6f08878904708b3d0c3875f402e0adcd358e91d47dcd8b96",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 14018,
|
||||
"stable-only": true,
|
||||
"url-template": "https://people.freedesktop.org/~hughsient/appstream-glib/releases/appstream-glib-$version.tar.xz"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "gexiv2",
|
||||
"modules": [
|
||||
{
|
||||
"name": "exiv2",
|
||||
"buildsystem": "cmake-ninja",
|
||||
"config-opts": [
|
||||
"-DEXIV2_ENABLE_BMFF=ON",
|
||||
"-DEXIV2_ENABLE_INIH=OFF"
|
||||
],
|
||||
"builddir": true,
|
||||
"cleanup": [
|
||||
"/bin",
|
||||
"/share"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/Exiv2/exiv2/releases/download/v0.28.0/exiv2-0.28.0-Source.tar.gz",
|
||||
"sha256": "89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 769,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/Exiv2/exiv2/releases/download/v$version/exiv2-$version-Source.tar.gz"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"buildsystem": "meson",
|
||||
"config-opts": [
|
||||
"-Dintrospection=false",
|
||||
"-Dpython3=false",
|
||||
"-Dvapi=false"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://download.gnome.org/sources/gexiv2/0.14/gexiv2-0.14.2.tar.xz",
|
||||
"sha256": "2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 1626,
|
||||
"stable-only": true,
|
||||
"url-template": "https://download.gnome.org/sources/gexiv2/$major.$minor/gexiv2-$version.tar.xz"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name" : "openexr",
|
||||
"config-opts": [
|
||||
"-DBUILD_SHARED_LIBS=ON",
|
||||
"-DOPENEXR_INSTALL_EXAMPLES=OFF",
|
||||
"-DBUILD_TESTING=OFF",
|
||||
"-DOPENEXR_INSTALL_PKG_CONFIG=ON"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin",
|
||||
"/share/doc",
|
||||
"/lib/libIlmImfUtil*"
|
||||
],
|
||||
"builddir" : true,
|
||||
"buildsystem" : "cmake-ninja",
|
||||
"sources" : [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/AcademySoftwareFoundation/openexr/archive/refs/tags/v3.1.10.tar.gz",
|
||||
"sha256": "6e0fd3f0eb1cb907bd3593830ea2b3431b85f22a6f18f99f8cfa099fec70067d",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 13289,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/AcademySoftwareFoundation/openexr/archive/refs/tags/v$version.tar.gz"
|
||||
}
|
||||
}
|
||||
],
|
||||
"modules": [
|
||||
{
|
||||
"name" : "imath",
|
||||
"config-opts": [
|
||||
"-DBUILD_SHARED_LIBS=ON",
|
||||
"-DBUILD_TESTING=OFF",
|
||||
"-DIMATH_INSTALL_PKG_CONFIG=ON"
|
||||
],
|
||||
|
||||
"builddir" : true,
|
||||
"buildsystem" : "cmake-ninja",
|
||||
"sources" : [
|
||||
{
|
||||
"type": "archive",
|
||||
"url" : "https://github.com/AcademySoftwareFoundation/Imath/archive/refs/tags/v3.1.9.tar.gz",
|
||||
"sha256": "f1d8aacd46afed958babfced3190d2d3c8209b66da451f556abd6da94c165cf3",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 223366,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/AcademySoftwareFoundation/Imath/archive/refs/tags/v$version.tar.gz"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "poppler",
|
||||
"modules": [
|
||||
{
|
||||
"name": "popplerdata",
|
||||
"buildsystem": "cmake-ninja",
|
||||
"builddir": true,
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://poppler.freedesktop.org/poppler-data-0.4.12.tar.gz",
|
||||
"sha256": "c835b640a40ce357e1b83666aabd95edffa24ddddd49b8daff63adb851cdab74",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 3687,
|
||||
"stable-only": true,
|
||||
"url-template": "https://poppler.freedesktop.org/poppler-data-$version.tar.gz"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"config-opts": [
|
||||
"-DENABLE_GOBJECT_INTROSPECTION=OFF",
|
||||
"-DENABLE_CPP=OFF",
|
||||
"-DOpenJPEG_DIR=/usr/lib64/openjpeg-2.3",
|
||||
"-DENABLE_BOOST=OFF",
|
||||
"-DWITH_NSS3:BOOL=OFF",
|
||||
"-DENABLE_QT5:BOOL=OFF"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin",
|
||||
"/share"
|
||||
],
|
||||
"buildsystem": "cmake-ninja",
|
||||
"builddir": true,
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://poppler.freedesktop.org/poppler-23.08.0.tar.xz",
|
||||
"sha256": "4a4bf7fc903b9f1a2ab7d04b7c5d8220db9bc6261cc73fdb9a826dc272f49aa8",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 3686,
|
||||
"stable-only": true,
|
||||
"url-template": "https://poppler.freedesktop.org/poppler-$version.tar.xz"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "aalib",
|
||||
"config-opts": [
|
||||
"--disable-static",
|
||||
"--with-slang-driver=no"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin",
|
||||
"/info",
|
||||
"/man"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://src.fedoraproject.org/repo/pkgs/rpms/aalib/aalib-1.4rc5.tar.gz/9801095c42bba12edebd1902bcf0a990/aalib-1.4rc5.tar.gz",
|
||||
"sha256": "fbddda9230cf6ee2a4f5706b4b11e2190ae45f5eda1f0409dc4f99b35e0a70ee"
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"commands": [
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} ."
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "libmng",
|
||||
"config-opts": [
|
||||
"--disable-static"
|
||||
],
|
||||
"cleanup": [
|
||||
"/share"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://src.fedoraproject.org/repo/pkgs/rpms/libmng/libmng-2.0.3.tar.gz/7e9a12ba2a99dff7e736902ea07383d4/libmng-2.0.3.tar.gz",
|
||||
"sha256": "cf112a1fb02f5b1c0fce5cab11ea8243852c139e669c44014125874b14b7dfaa"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "libwmf",
|
||||
"config-opts": [
|
||||
"--disable-static",
|
||||
"--disable-dependency-tracking"
|
||||
],
|
||||
"cleanup": [
|
||||
"/share/doc",
|
||||
"/bin"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/caolanm/libwmf/archive/refs/tags/v0.2.13.tar.gz",
|
||||
"sha512": "f45a936c9bc98fc1a5f2b0808b497119e4dcd3c132615fdddb7583e5719c7d1d7f85c16ebf313cad453e5b7ae3508bf6b80c4ed2b42322b7dec295d8f4eb86ce",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 230209,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/caolanm/libwmf/archive/refs/tags/v$version.tar.gz"
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"commands": [
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} .",
|
||||
"autoreconf -vfi"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "ghostscript",
|
||||
"config-opts": [
|
||||
"--disable-cups"
|
||||
],
|
||||
"make-args": [
|
||||
"so"
|
||||
],
|
||||
"make-install-args": [
|
||||
"soinstall"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin",
|
||||
"/share/man",
|
||||
"/share/doc"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs10012/ghostscript-10.01.2.tar.gz",
|
||||
"sha512": "11887850d440b8bbd8b83b8b58df8c743cf94be8fdbcfbda1a5fce55ce7c6a963d94b41a4ebcf1ba48f64f8af01e76dec789e2711212b1f7a32f98c42d75e0ff",
|
||||
"x-checker-data": {
|
||||
"//": "Bypass broken url-template with anitya checker - See https://github.com/flathub/flatpak-external-data-checker/issues/360",
|
||||
"type": "json",
|
||||
"url": "https://api.github.com/repos/ArtifexSoftware/ghostpdl-downloads/releases/latest",
|
||||
"version-query": ".name | split(\" \") | .[1]",
|
||||
"url-query": ".assets[] | select(.name|test(\"^ghostscript-(.*).tar.gz$\")) | .browser_download_url"
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"commands": [
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} freetype/builds/unix/",
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} ijs/",
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} jpeg/",
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} libpng/",
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} lcms2mt/",
|
||||
"cp -p /usr/share/automake-*/config.{sub,guess} tiff/config/",
|
||||
"rm -rf libpng/pngread.c"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "libmypaint",
|
||||
"config-opts": [
|
||||
"--disable-gegl",
|
||||
"--disable-introspection"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/mypaint/libmypaint/releases/download/v1.6.1/libmypaint-1.6.1.tar.xz",
|
||||
"sha256": "741754f293f6b7668f941506da07cd7725629a793108bb31633fb6c3eae5315f",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 12974,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/mypaint/libmypaint/releases/download/v$version/libmypaint-$version.tar.xz"
|
||||
}
|
||||
}
|
||||
],
|
||||
"modules": [
|
||||
{
|
||||
"name": "json-c",
|
||||
"buildsystem": "cmake-ninja",
|
||||
"sources": [
|
||||
{
|
||||
"type": "git",
|
||||
"url": "https://github.com/json-c/json-c.git",
|
||||
"tag": "json-c-0.16-20220414",
|
||||
"commit": "2f2ddc1f2dbca56c874e8f9c31b5b963202d80e7",
|
||||
"x-checker-data": {
|
||||
"type": "git",
|
||||
"tag-pattern": "^json-c-([\\d.]+)-[\\d]+$"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"//": "Copy from shared-modules to avoid submodules on dev repo.",
|
||||
"name": "intltool",
|
||||
"cleanup": [
|
||||
"*"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://launchpad.net/intltool/trunk/0.51.0/+download/intltool-0.51.0.tar.gz",
|
||||
"sha256": "67c74d94196b153b774ab9f89b2fa6c6ba79352407037c8c14d5aeb334e959cd",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 1385,
|
||||
"stable-only": true,
|
||||
"url-template": "https://launchpad.net/intltool/trunk/$version/+download/intltool-$version.tar.gz"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "mypaint-brushes",
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/mypaint/mypaint-brushes/releases/download/v1.3.1/mypaint-brushes-1.3.1.tar.xz",
|
||||
"sha256": "fef66ffc241b7c5cd29e9c518e933c739618cb51c4ed4d745bf648a1afc3fe70",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 17096,
|
||||
"stable-only": true,
|
||||
"versions": {
|
||||
"<": "2.0.0"
|
||||
},
|
||||
"url-template": "https://github.com/mypaint/mypaint-brushes/releases/download/v$version/mypaint-brushes-$version.tar.xz"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"//": "Shamelessly taken from org.octave.Octave manifest!",
|
||||
"name": "SuiteSparse",
|
||||
"no-autogen": true,
|
||||
"make-args": [
|
||||
"BLAS=-lopenblas",
|
||||
"LAPACK=",
|
||||
"library"
|
||||
],
|
||||
"make-install-args": [
|
||||
"BLAS=-lopenblas",
|
||||
"LAPACK=",
|
||||
"INSTALL_LIB=/app/lib",
|
||||
"INSTALL_INCLUDE=/app/include/suitesparse",
|
||||
"library"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/DrTimothyAldenDavis/SuiteSparse/archive/v5.13.0.tar.gz",
|
||||
"sha256": "59c6ca2959623f0c69226cf9afb9a018d12a37fab3a8869db5f6d7f83b6b147d",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 4908,
|
||||
"stable-only": true,
|
||||
"//": "patches don't apply. Avoiding flathubbot to spam us with broken updates",
|
||||
"versions": {
|
||||
"<": "6.0.0"
|
||||
},
|
||||
"url-template": "https://github.com/DrTimothyAldenDavis/SuiteSparse/archive/v$version.tar.gz"
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "patch",
|
||||
"path": "patches/suitesparse-reduce-build.patch"
|
||||
}
|
||||
],
|
||||
"modules": [
|
||||
{
|
||||
"name": "openblas",
|
||||
"no-autogen": true,
|
||||
"make-args": [
|
||||
"DYNAMIC_ARCH=1",
|
||||
"FC=gfortran",
|
||||
"NO_CBLAS=1",
|
||||
"NO_LAPACKE=1",
|
||||
"USE_OPENMP=0"
|
||||
],
|
||||
"make-install-args": [
|
||||
"PREFIX=/app"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/xianyi/OpenBLAS/archive/v0.3.23.tar.gz",
|
||||
"sha256": "5d9491d07168a5d00116cdc068a40022c3455bf9293c7cb86a65b1054d7e5114",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 2540,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/xianyi/OpenBLAS/archive/v$version.tar.gz"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "libheif",
|
||||
"buildsystem": "cmake-ninja",
|
||||
"builddir": true,
|
||||
"config-opts": [
|
||||
"-DWITH_GDK_PIXBUF=OFF"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin",
|
||||
"/share/thumbnailers"
|
||||
],
|
||||
"modules": [
|
||||
{
|
||||
"name": "libde265",
|
||||
"config-opts": [
|
||||
"--disable-dec265",
|
||||
"--disable-encoder",
|
||||
"--disable-sherlock265"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/strukturag/libde265/releases/download/v1.0.12/libde265-1.0.12.tar.gz",
|
||||
"sha256": "62185ea2182e68cf68bba20cc6eb4c287407b509cf0a827d7ddb75614db77b5c",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 11239,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/strukturag/libde265/releases/download/v$version/libde265-$version.tar.gz"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "libx265",
|
||||
"buildsystem": "cmake",
|
||||
"subdir": "source",
|
||||
"config-opts": [
|
||||
"-DEXTRA_LIB='libx265-10.a;libx265-12.a'",
|
||||
"-DEXTRA_LINK_FLAGS=-L.",
|
||||
"-DLINKED_10BIT=ON",
|
||||
"-DLINKED_12BIT=ON"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://bitbucket.org/multicoreware/x265_git/downloads/x265_3.5.tar.gz",
|
||||
"sha256": "e70a3335cacacbba0b3a20ec6fecd6783932288ebc8163ad74bcc9606477cae8",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 7275,
|
||||
"stable-only": true,
|
||||
"url-template": "https://bitbucket.org/multicoreware/x265_git/downloads/x265_$version.tar.gz"
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"commands": [
|
||||
"ln -s ${FLATPAK_DEST}/lib/libx265-10.a",
|
||||
"ln -s ${FLATPAK_DEST}/lib/libx265-12.a",
|
||||
"rm -fr ${FLATPAK_DEST}/lib/libx265.so*"
|
||||
]
|
||||
}
|
||||
],
|
||||
"modules": [
|
||||
{
|
||||
"name": "libx265-10bpc",
|
||||
"buildsystem": "cmake",
|
||||
"subdir": "source",
|
||||
"config-opts": [
|
||||
"-DHIGH_BIT_DEPTH=ON",
|
||||
"-DEXPORT_C_API=OFF",
|
||||
"-DENABLE_SHARED=OFF",
|
||||
"-DENABLE_CLI=OFF",
|
||||
"-DENABLE_ASSEMBLY=OFF"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://bitbucket.org/multicoreware/x265_git/downloads/x265_3.5.tar.gz",
|
||||
"sha256": "e70a3335cacacbba0b3a20ec6fecd6783932288ebc8163ad74bcc9606477cae8",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 7275,
|
||||
"stable-only": true,
|
||||
"url-template": "https://bitbucket.org/multicoreware/x265_git/downloads/x265_$version.tar.gz"
|
||||
}
|
||||
}
|
||||
],
|
||||
"post-install": [
|
||||
"mv ${FLATPAK_DEST}/lib/libx265.a ${FLATPAK_DEST}/lib/libx265-10.a"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "libx265-12bpc",
|
||||
"buildsystem": "cmake",
|
||||
"subdir": "source",
|
||||
"config-opts": [
|
||||
"-DHIGH_BIT_DEPTH=ON",
|
||||
"-DEXPORT_C_API=OFF",
|
||||
"-DENABLE_SHARED=OFF",
|
||||
"-DENABLE_CLI=OFF",
|
||||
"-DENABLE_ASSEMBLY=OFF",
|
||||
"-DMAIN12=ON"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://bitbucket.org/multicoreware/x265_git/downloads/x265_3.5.tar.gz",
|
||||
"sha256": "e70a3335cacacbba0b3a20ec6fecd6783932288ebc8163ad74bcc9606477cae8",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 7275,
|
||||
"stable-only": true,
|
||||
"url-template": "https://bitbucket.org/multicoreware/x265_git/downloads/x265_$version.tar.gz"
|
||||
}
|
||||
}
|
||||
],
|
||||
"post-install": [
|
||||
"mv ${FLATPAK_DEST}/lib/libx265.a ${FLATPAK_DEST}/lib/libx265-12.a"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://github.com/strukturag/libheif/releases/download/v1.16.2/libheif-1.16.2.tar.gz",
|
||||
"sha256": "7f97e4205c0bd9f9b8560536c8bd2e841d1c9a6d610401eb3eb87ed9cdfe78ea",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 64439,
|
||||
"stable-only": true,
|
||||
"url-template": "https://github.com/strukturag/libheif/releases/download/v$version/libheif-$version.tar.gz"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "luajit",
|
||||
"no-autogen": true,
|
||||
"cleanup": [
|
||||
"/lib/*.a",
|
||||
"/include",
|
||||
"/lib/pkgconfig",
|
||||
"/share/man"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://luajit.org/download/LuaJIT-2.1.0-beta3.tar.gz",
|
||||
"sha256": "1ad2e34b111c802f9d0cdf019e986909123237a28c746b21295b63c9e785d9c3",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 6444,
|
||||
"stable-only": false,
|
||||
"url-template": "https://luajit.org/download/LuaJIT-$version.tar.gz"
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"commands": [
|
||||
"sed -i 's|/usr/local|/app|' ./Makefile"
|
||||
]
|
||||
}
|
||||
],
|
||||
"post-install": [
|
||||
"ln -s /app/bin/luajit-2.1.0-beta3 /app/bin/luajit"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "lua-lgi",
|
||||
"buildsystem": "meson",
|
||||
"sources": [
|
||||
{
|
||||
"type": "git",
|
||||
"url": "https://github.com/pavouk/lgi.git",
|
||||
"commit": "c21f35fccae87fd4e3625d4c878f584b7255d6f6"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "xmu",
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://xorg.freedesktop.org/releases/individual/lib/libXmu-1.1.3.tar.bz2",
|
||||
"sha256": "9c343225e7c3dc0904f2122b562278da5fed639b1b5e880d25111561bac5b731"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "cairo",
|
||||
"buildsystem": "meson",
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://cairographics.org/snapshots/cairo-1.17.8.tar.xz",
|
||||
"sha256": "5b10c8892d1b58d70d3f0ba5b47863a061262fa56b9dc7944161f8c8b783bc64",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 247,
|
||||
"stable-only": true,
|
||||
"url-template": "https://cairographics.org/snapshots/cairo-$version.tar.xz"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "qoi",
|
||||
"buildsystem": "simple",
|
||||
"build-commands": [
|
||||
"install -D qoi.h /app/include/qoi.h"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "git",
|
||||
"url": "https://github.com/phoboslab/qoi.git",
|
||||
"commit": "f6dffaf1e8170cdd79945a4fb60f6403e447e020"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "cfitsio",
|
||||
"config-opts": [
|
||||
"--enable-reentrant"
|
||||
],
|
||||
"make-args": ["shared"],
|
||||
"cleanup": [
|
||||
"/include",
|
||||
"/lib/*.a",
|
||||
"/lib/*.la",
|
||||
"/lib/pkgconfig"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "http://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/cfitsio-4.2.0.tar.gz",
|
||||
"sha256": "eba53d1b3f6e345632bb09a7b752ec7ced3d63ec5153a848380f3880c5d61889"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "babl",
|
||||
"buildsystem": "meson",
|
||||
"config-opts": [
|
||||
"-Dwith-docs=false"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "git",
|
||||
"url": "https://gitlab.gnome.org/GNOME/babl.git",
|
||||
"branch": "master"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "gegl",
|
||||
"buildsystem": "meson",
|
||||
"config-opts": [
|
||||
"-Ddocs=false",
|
||||
"-Dworkshop=true"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "git",
|
||||
"url": "https://gitlab.gnome.org/GNOME/gegl.git",
|
||||
"branch": "master"
|
||||
}
|
||||
],
|
||||
"modules": [
|
||||
{
|
||||
"name": "maxflow",
|
||||
"buildsystem": "cmake-ninja",
|
||||
"cleanup": [
|
||||
"/bin"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "git",
|
||||
"url": "https://github.com/gerddie/maxflow.git",
|
||||
"commit": "6ac148f164b9567ac81fbb4ebb36112f850c902b"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "graphviz",
|
||||
"buildsystem": "autotools",
|
||||
"sources": [
|
||||
{
|
||||
"type": "archive",
|
||||
"url": "https://gitlab.com/graphviz/graphviz/-/archive/8.0.5/graphviz-8.0.5.tar.gz",
|
||||
"sha256": "dd06f45f5bbcb1c7cbc67adab5359da2cd4b40533dc7c7424b3fc0e998bbd6c9",
|
||||
"x-checker-data": {
|
||||
"type": "anitya",
|
||||
"project-id": 1249,
|
||||
"stable-only": true,
|
||||
"url-template": "https://gitlab.com/graphviz/graphviz/-/archive/$version/graphviz-$version.tar.gz"
|
||||
}
|
||||
}
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin/??",
|
||||
"/bin/????*",
|
||||
"/bin/fdp",
|
||||
"/bin/nop",
|
||||
"/lib/libgvpr*",
|
||||
"/lib/liblab*",
|
||||
"*.la",
|
||||
"/lib/graphviz/libgvplugin_core*",
|
||||
"/lib/graphviz/libgvplugin_g*",
|
||||
"/lib/graphviz/libgvplugin_neato_layout*",
|
||||
"/lib/graphviz/libgvplugin_poppler*",
|
||||
"/lib/graphviz/libgvplugin_rsvg*",
|
||||
"/lib/graphviz/libgvplugin_visio*",
|
||||
"/lib/graphviz/libgvplugin_webp*",
|
||||
"/lib/graphviz/libgvplugin_xlib*",
|
||||
"/share"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "pika",
|
||||
"buildsystem": "meson",
|
||||
"config-opts": [
|
||||
"-Dg-ir-doc=false",
|
||||
"-Dgi-docgen=disabled",
|
||||
"-Dicc-directory=/run/host/usr/share/color/icc/",
|
||||
"-Dbuild-id=technology.heckin.PIKA.flatpak.nightly",
|
||||
"-Dcheck-update=no"
|
||||
],
|
||||
"cleanup": [
|
||||
"/bin/pikatool-2.99",
|
||||
"/bin/pika-console-2.99"
|
||||
],
|
||||
"sources": [
|
||||
{
|
||||
"type": "git",
|
||||
"url": "https://gitlab.gnome.org/GNOME/pika.git",
|
||||
"branch": "master"
|
||||
},
|
||||
{
|
||||
"type": "shell",
|
||||
"commands": [
|
||||
"xsltproc -o desktop/technology.heckin.PIKA.appdata.xml.in.in build/flatpak/remove-future-appdata-release.xslt desktop/technology.heckin.PIKA.appdata.xml.in.in"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
43
build/meson/run_test_env.sh
Normal file
43
build/meson/run_test_env.sh
Normal file
@ -0,0 +1,43 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Wrapper script to use for the Meson test setup.
|
||||
#
|
||||
# Define the "UI_TEST" for all tests that should run headless
|
||||
|
||||
if [ -n "${UI_TEST}" ]; then
|
||||
# Use Xvfb to simulate a graphical session; note that this needs
|
||||
# a new enough version which has the -d option.
|
||||
#
|
||||
# Also use dbus-run-session to make sure parallel tests aren't failing
|
||||
# as they simultaneously try to own the "technology.heckin.PIKA.UI" D-Bus name
|
||||
|
||||
# This is weird but basically on a Debian testing/bookworm, apparently
|
||||
# the --auto-display (neither the short version -d) option does not
|
||||
# exist and ends up in error:
|
||||
# > xvfb-run: unrecognized option '--auto-display'
|
||||
# There only --auto-servernum works fine.
|
||||
#
|
||||
# On a recent Fedora (33 in my case), the later exists but a few of
|
||||
# the tests fail with some weirder:
|
||||
# > /usr/bin/xvfb-run: line 186: kill: (53539) - No such process
|
||||
# There using --auto-display instead (supposed to deprecate
|
||||
# --auto-servernum) works instead, but only in its short form (-d).
|
||||
# The long form --auto-display also results in the "unrecognized
|
||||
# option" error even though the help output lists it.
|
||||
# Yep it's a huge mess.
|
||||
xvfb-run 2>&1|grep --quiet auto-display
|
||||
HAS_AUTO_DISPLAY="$?"
|
||||
if [ "$HAS_AUTO_DISPLAY" -eq 0 ]; then
|
||||
OPT="-d"
|
||||
else
|
||||
OPT="--auto-servernum"
|
||||
fi
|
||||
xvfb-run $OPT --server-args="-screen 0 1280x1024x24" \
|
||||
dbus-run-session -- "$@"
|
||||
|
||||
else
|
||||
# Run the executable directly,
|
||||
# i.e. no need to run Xvfb (which will have a timeout)
|
||||
|
||||
"$@"
|
||||
fi
|
44
build/patches/cairo-mr114-pika-issue-6210.patch
Normal file
44
build/patches/cairo-mr114-pika-issue-6210.patch
Normal file
@ -0,0 +1,44 @@
|
||||
From 4f4d89506f58a64b4829b1bb239bab9e46d63727 Mon Sep 17 00:00:00 2001
|
||||
From: Jehan <jehan@girinstud.io>
|
||||
Date: Tue, 19 Jan 2021 12:42:31 +0100
|
||||
Subject: [PATCH] src: do not override explicitly requested grayscale
|
||||
antialiasing.
|
||||
|
||||
If CAIRO_ANTIALIAS_DEFAULT is selected and system is set to subpixel, it
|
||||
is perfectly normal to switch to CAIRO_ANTIALIAS_SUBPIXEL.
|
||||
But when the calling application specifically requested
|
||||
CAIRO_ANTIALIAS_GRAY then Cairo should honor the request.
|
||||
|
||||
This is an issue we have had for years in PIKA, where text on images
|
||||
would render differently depending on the system the file is opened on.
|
||||
This is obviously not right as a graphics work should be system
|
||||
independant and allow the creator to decide if one wants a text to have
|
||||
grayscale or subpixel rendering (a settings which would stick when
|
||||
sharing the work file). Cairo should not override this.
|
||||
The CAIRO_ANTIALIAS_DEFAULT settings exists exactly for this (when we
|
||||
want Cairo to choose for us, in a system-dependant way); other settings
|
||||
are when we need system independance.
|
||||
|
||||
Thanks to Adam Fontenot for initial investigations and tests on this and
|
||||
other contributors before this.
|
||||
---
|
||||
src/cairo-ft-font.c | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/cairo-ft-font.c b/src/cairo-ft-font.c
|
||||
index d2221edec..1f5befec3 100644
|
||||
--- a/src/cairo-ft-font.c
|
||||
+++ b/src/cairo-ft-font.c
|
||||
@@ -1945,8 +1945,7 @@ _cairo_ft_options_merge (cairo_ft_options_t *options,
|
||||
}
|
||||
|
||||
if (other->base.antialias == CAIRO_ANTIALIAS_SUBPIXEL &&
|
||||
- (options->base.antialias == CAIRO_ANTIALIAS_DEFAULT ||
|
||||
- options->base.antialias == CAIRO_ANTIALIAS_GRAY)) {
|
||||
+ options->base.antialias == CAIRO_ANTIALIAS_DEFAULT) {
|
||||
options->base.antialias = CAIRO_ANTIALIAS_SUBPIXEL;
|
||||
options->base.subpixel_order = other->base.subpixel_order;
|
||||
}
|
||||
--
|
||||
GitLab
|
||||
|
22
build/patches/cairo-mr245-issue325.patch
Normal file
22
build/patches/cairo-mr245-issue325.patch
Normal file
@ -0,0 +1,22 @@
|
||||
diff -Naur cairo-1.16.0/src/cairo-composite-rectangles.c cairo-1.16.0.patched/src/cairo-composite-rectangles.c
|
||||
--- cairo-1.16.0/src/cairo-composite-rectangles.c 2018-08-17 03:10:53.000000000 +0200
|
||||
+++ cairo-1.16.0.patched/src/cairo-composite-rectangles.c 2021-09-26 15:52:04.410502567 +0200
|
||||
@@ -431,18 +431,6 @@
|
||||
if (! _cairo_composite_rectangles_init (extents, surface, op, source, clip))
|
||||
return CAIRO_INT_STATUS_NOTHING_TO_DO;
|
||||
|
||||
- /* Computing the exact bbox and the overlap is expensive.
|
||||
- * First perform a cheap test to see if the glyphs are all clipped out.
|
||||
- */
|
||||
- if (extents->is_bounded & CAIRO_OPERATOR_BOUND_BY_MASK &&
|
||||
- _cairo_scaled_font_glyph_approximate_extents (scaled_font,
|
||||
- glyphs, num_glyphs,
|
||||
- &extents->mask))
|
||||
- {
|
||||
- if (! _cairo_rectangle_intersect (&extents->bounded, &extents->mask))
|
||||
- return CAIRO_INT_STATUS_NOTHING_TO_DO;
|
||||
- }
|
||||
-
|
||||
status = _cairo_scaled_font_glyph_device_extents (scaled_font,
|
||||
glyphs, num_glyphs,
|
||||
&extents->mask,
|
BIN
build/windows/fileicon.ico
Executable file
BIN
build/windows/fileicon.ico
Executable file
Binary file not shown.
After Width: | Height: | Size: 157 KiB |
70
build/windows/gitlab-ci/build-deps-crossroad.sh
Normal file
70
build/windows/gitlab-ci/build-deps-crossroad.sh
Normal file
@ -0,0 +1,70 @@
|
||||
crossroad source msys2
|
||||
mkdir _deps && cd _deps
|
||||
|
||||
# babl
|
||||
|
||||
crossroad install lcms2 && \
|
||||
git clone --depth 1 https://gitlab.gnome.org/GNOME/babl.git && cd babl && \
|
||||
crossroad meson setup _build/ -Denable-gir=false -Dlibdir=lib && \
|
||||
ninja -C _build install || exit 1
|
||||
cd ..
|
||||
|
||||
# GEGL
|
||||
|
||||
crossroad install cairo graphviz json-glib && \
|
||||
git clone --depth 1 https://gitlab.gnome.org/GNOME/gegl.git && cd gegl && \
|
||||
crossroad meson setup _build/ -Dintrospection=false -Dsdl2=disabled -Dlibdir=lib && \
|
||||
ninja -C _build install || exit 1
|
||||
cd ..
|
||||
|
||||
# preparing PIKA
|
||||
|
||||
LIBMNG=
|
||||
if [ "x$CROSSROAD_PLATFORM" = "xw64" ]; then
|
||||
# For some reason, file-mng plug-in fails to link in its i686 build.
|
||||
# Just disable it for now on i686 only.
|
||||
LIBMNG="libmng"
|
||||
fi
|
||||
|
||||
crossroad install appstream-glib \
|
||||
aalib \
|
||||
atk \
|
||||
cfitsio \
|
||||
drmingw \
|
||||
gexiv2 \
|
||||
glib2 \
|
||||
glib-networking \
|
||||
json-c \
|
||||
ghostscript \
|
||||
gobject-introspection \
|
||||
gobject-introspection-runtime \
|
||||
iso-codes \
|
||||
libheif \
|
||||
libiff \
|
||||
libilbm \
|
||||
libjxl \
|
||||
$LIBMNG \
|
||||
libmypaint mypaint-brushes \
|
||||
libwebp \
|
||||
libwmf \
|
||||
openexr \
|
||||
poppler poppler-data \
|
||||
qoi \
|
||||
xpm-nox
|
||||
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "Installation of pre-built dependencies failed.";
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
if [ "x$CROSSROAD_PLATFORM" = "xw64" ]; then
|
||||
# Generate the loaders.cache file for GUI image support.
|
||||
# Note: this is mostly for distribution so I initially wanted to
|
||||
# have these in "win64-nightly" job but "win32-nightly" also
|
||||
# requires the same file (and I fail to install wine32) whereas
|
||||
# Gitlab "needs" field requires jobs to be from a prior stage. So I
|
||||
# generate this here, with dependencies.
|
||||
wine ${CROSSROAD_PREFIX}/bin/gdk-pixbuf-query-loaders.exe ${CROSSROAD_PREFIX}/lib/gdk-pixbuf-2.0/2.10.0/loaders/*.dll > ${CROSSROAD_PREFIX}/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache
|
||||
sed -i "s&$CROSSROAD_PREFIX/&&" ${CROSSROAD_PREFIX}/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache
|
||||
sed -i '/.dll\"/s*/*\\\\*g' ${CROSSROAD_PREFIX}/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache
|
||||
fi
|
74
build/windows/gitlab-ci/build-deps-msys2.sh
Normal file
74
build/windows/gitlab-ci/build-deps-msys2.sh
Normal file
@ -0,0 +1,74 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
if [[ "$MSYSTEM" == "MINGW32" ]]; then
|
||||
export ARTIFACTS_SUFFIX="-w32"
|
||||
export MSYS2_ARCH="i686"
|
||||
# vapi build fails on 32-bit, with no error output. Let's just drop
|
||||
# it for this architecture.
|
||||
export BABL_OPTIONS="-Denable-vapi=false"
|
||||
export GEGL_OPTIONS="-Dvapigen=disabled"
|
||||
export MSYS_PREFIX="/c/msys64/mingw32/"
|
||||
else
|
||||
export ARTIFACTS_SUFFIX="-w64"
|
||||
export MSYS2_ARCH="x86_64"
|
||||
export BABL_OPTIONS=""
|
||||
export GEGL_OPTIONS=""
|
||||
export MSYS_PREFIX="/c/msys64/mingw64/"
|
||||
fi
|
||||
|
||||
# Update everything
|
||||
pacman --noconfirm -Suy
|
||||
|
||||
# Install the required packages
|
||||
pacman --noconfirm -S --needed \
|
||||
base-devel \
|
||||
mingw-w64-$MSYS2_ARCH-toolchain \
|
||||
mingw-w64-$MSYS2_ARCH-autotools \
|
||||
mingw-w64-$MSYS2_ARCH-meson \
|
||||
\
|
||||
mingw-w64-$MSYS2_ARCH-cairo \
|
||||
mingw-w64-$MSYS2_ARCH-crt-git \
|
||||
mingw-w64-$MSYS2_ARCH-glib-networking \
|
||||
mingw-w64-$MSYS2_ARCH-gobject-introspection \
|
||||
mingw-w64-$MSYS2_ARCH-json-glib \
|
||||
mingw-w64-$MSYS2_ARCH-lcms2 \
|
||||
mingw-w64-$MSYS2_ARCH-lensfun \
|
||||
mingw-w64-$MSYS2_ARCH-libspiro \
|
||||
mingw-w64-$MSYS2_ARCH-maxflow \
|
||||
mingw-w64-$MSYS2_ARCH-openexr \
|
||||
mingw-w64-$MSYS2_ARCH-pango \
|
||||
mingw-w64-$MSYS2_ARCH-suitesparse \
|
||||
mingw-w64-$MSYS2_ARCH-vala
|
||||
|
||||
export GIT_DEPTH=1
|
||||
export PIKA_PREFIX="`realpath ./_install`${ARTIFACTS_SUFFIX}"
|
||||
export PATH="$PIKA_PREFIX/bin:$PATH"
|
||||
export PKG_CONFIG_PATH="${PIKA_PREFIX}/lib/pkgconfig:$PKG_CONFIG_PATH"
|
||||
export PKG_CONFIG_PATH="${PIKA_PREFIX}/share/pkgconfig:$PKG_CONFIG_PATH"
|
||||
export LD_LIBRARY_PATH="${PIKA_PREFIX}/lib:${LD_LIBRARY_PATH}"
|
||||
export ACLOCAL_FLAGS="-I/c/msys64/mingw64/share/aclocal"
|
||||
export XDG_DATA_DIRS="${PIKA_PREFIX}/share:/mingw64/share/"
|
||||
|
||||
## babl and GEGL (follow master branch) ##
|
||||
|
||||
git clone --depth=${GIT_DEPTH} https://gitlab.gnome.org/GNOME/babl.git _babl
|
||||
git clone --depth=${GIT_DEPTH} https://gitlab.gnome.org/GNOME/gegl.git _gegl
|
||||
|
||||
mkdir _babl/_build
|
||||
cd _babl/_build
|
||||
meson setup -Dprefix="${PIKA_PREFIX}" -Dwith-docs=false \
|
||||
${BABL_OPTIONS} ..
|
||||
ninja
|
||||
ninja install
|
||||
|
||||
mkdir ../../_gegl/_build
|
||||
cd ../../_gegl/_build
|
||||
meson setup -Dprefix="${PIKA_PREFIX}" -Ddocs=false \
|
||||
-Dcairo=enabled -Dumfpack=enabled \
|
||||
-Dopenexr=enabled -Dworkshop=true \
|
||||
${GEGL_OPTIONS} ..
|
||||
ninja
|
||||
ninja install
|
||||
cd ../..
|
120
build/windows/gitlab-ci/build-pika-msys2.sh
Normal file
120
build/windows/gitlab-ci/build-pika-msys2.sh
Normal file
@ -0,0 +1,120 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
if [[ "$MSYSTEM" == "MINGW32" ]]; then
|
||||
export ARTIFACTS_SUFFIX="-w32"
|
||||
export MSYS2_ARCH="i686"
|
||||
export MSYS2_PREFIX="/c/msys64/mingw32"
|
||||
export PIKA_OPTIONS="-Dvala=disabled"
|
||||
else
|
||||
export ARTIFACTS_SUFFIX="-w64"
|
||||
export MSYS2_ARCH="x86_64"
|
||||
export MSYS2_PREFIX="/c/msys64/mingw64/"
|
||||
fi
|
||||
|
||||
export ACLOCAL_FLAGS="-I${MSYS2_PREFIX}/share/aclocal"
|
||||
export PATH="${MSYS2_PREFIX}/bin:$PATH"
|
||||
|
||||
# Update everything
|
||||
pacman --noconfirm -Suy
|
||||
|
||||
# Install the required packages
|
||||
pacman --noconfirm -S --needed \
|
||||
base-devel \
|
||||
mingw-w64-$MSYS2_ARCH-toolchain \
|
||||
mingw-w64-$MSYS2_ARCH-autotools \
|
||||
mingw-w64-$MSYS2_ARCH-ccache \
|
||||
mingw-w64-$MSYS2_ARCH-meson \
|
||||
\
|
||||
mingw-w64-$MSYS2_ARCH-aalib \
|
||||
mingw-w64-$MSYS2_ARCH-appstream-glib \
|
||||
mingw-w64-$MSYS2_ARCH-atk \
|
||||
mingw-w64-$MSYS2_ARCH-brotli \
|
||||
mingw-w64-$MSYS2_ARCH-cairo \
|
||||
mingw-w64-$MSYS2_ARCH-cfitsio \
|
||||
mingw-w64-$MSYS2_ARCH-drmingw \
|
||||
mingw-w64-$MSYS2_ARCH-gexiv2 \
|
||||
mingw-w64-$MSYS2_ARCH-ghostscript \
|
||||
mingw-w64-$MSYS2_ARCH-gi-docgen \
|
||||
mingw-w64-$MSYS2_ARCH-glib-networking \
|
||||
mingw-w64-$MSYS2_ARCH-gobject-introspection \
|
||||
mingw-w64-$MSYS2_ARCH-gobject-introspection-runtime \
|
||||
mingw-w64-$MSYS2_ARCH-graphviz \
|
||||
mingw-w64-$MSYS2_ARCH-gtk3 \
|
||||
mingw-w64-$MSYS2_ARCH-headers-git \
|
||||
mingw-w64-$MSYS2_ARCH-iso-codes \
|
||||
mingw-w64-$MSYS2_ARCH-json-c \
|
||||
mingw-w64-$MSYS2_ARCH-json-glib \
|
||||
mingw-w64-$MSYS2_ARCH-lcms2 \
|
||||
mingw-w64-$MSYS2_ARCH-lensfun \
|
||||
mingw-w64-$MSYS2_ARCH-libarchive \
|
||||
mingw-w64-$MSYS2_ARCH-libheif \
|
||||
mingw-w64-$MSYS2_ARCH-libiff \
|
||||
mingw-w64-$MSYS2_ARCH-libilbm \
|
||||
mingw-w64-$MSYS2_ARCH-libjxl \
|
||||
mingw-w64-$MSYS2_ARCH-libmypaint \
|
||||
mingw-w64-$MSYS2_ARCH-libspiro \
|
||||
mingw-w64-$MSYS2_ARCH-libwebp \
|
||||
mingw-w64-$MSYS2_ARCH-libwmf \
|
||||
mingw-w64-$MSYS2_ARCH-luajit \
|
||||
mingw-w64-$MSYS2_ARCH-maxflow \
|
||||
mingw-w64-$MSYS2_ARCH-mypaint-brushes \
|
||||
mingw-w64-$MSYS2_ARCH-openexr \
|
||||
mingw-w64-$MSYS2_ARCH-pango \
|
||||
mingw-w64-$MSYS2_ARCH-poppler \
|
||||
mingw-w64-$MSYS2_ARCH-poppler-data \
|
||||
mingw-w64-$MSYS2_ARCH-python \
|
||||
mingw-w64-$MSYS2_ARCH-python-gobject \
|
||||
mingw-w64-$MSYS2_ARCH-qoi \
|
||||
mingw-w64-$MSYS2_ARCH-shared-mime-info \
|
||||
mingw-w64-$MSYS2_ARCH-suitesparse \
|
||||
mingw-w64-$MSYS2_ARCH-vala \
|
||||
mingw-w64-$MSYS2_ARCH-xpm-nox
|
||||
|
||||
# XXX We've got a weird error when the prefix is in the current dir.
|
||||
# Until we figure it out, this trick seems to work, even though it's
|
||||
# completely ridiculous.
|
||||
mv "_install${ARTIFACTS_SUFFIX}" ~
|
||||
|
||||
export PIKA_PREFIX="`realpath ~/_install`${ARTIFACTS_SUFFIX}"
|
||||
export PATH="$PIKA_PREFIX/bin:$PATH"
|
||||
export PKG_CONFIG_PATH="${PIKA_PREFIX}/lib/pkgconfig:$PKG_CONFIG_PATH"
|
||||
export PKG_CONFIG_PATH="${PIKA_PREFIX}/share/pkgconfig:$PKG_CONFIG_PATH"
|
||||
export LD_LIBRARY_PATH="${PIKA_PREFIX}/lib:${LD_LIBRARY_PATH}"
|
||||
export ACLOCAL_FLAGS="-I/c/msys64/mingw32/share/aclocal"
|
||||
export XDG_DATA_DIRS="${PIKA_PREFIX}/share:/mingw64/share/"
|
||||
|
||||
mkdir -p _ccache
|
||||
export CCACHE_BASEDIR="$(pwd)"
|
||||
export CCACHE_DIR="${CCACHE_BASEDIR}/_ccache"
|
||||
|
||||
# XXX Do not enable ccache this way because it breaks
|
||||
# gobject-introspection rules. Let's see later for ccache.
|
||||
# See: https://github.com/msys2/MINGW-packages/issues/9677
|
||||
#export CC="ccache gcc"
|
||||
|
||||
#ccache --zero-stats
|
||||
#ccache --show-stats
|
||||
|
||||
mkdir "_build${ARTIFACTS_SUFFIX}"
|
||||
cd "_build${ARTIFACTS_SUFFIX}"
|
||||
# We disable javascript as we are not able for the time being to add a
|
||||
# javascript interpreter with GObject Introspection (GJS/spidermonkey
|
||||
# and Seed/Webkit are the 2 contenders so far, but they are not
|
||||
# available on MSYS2 and we are told it's very hard to build them).
|
||||
# TODO: re-enable javascript plug-ins when we can figure this out.
|
||||
meson .. -Dprefix="${PIKA_PREFIX}" \
|
||||
-Ddirectx-sdk-dir="${MSYS2_PREFIX}" \
|
||||
-Djavascript=disabled \
|
||||
-Dbuild-id=technology.heckin.PIKA_official \
|
||||
-Dgi-docgen=disabled \
|
||||
${PIKA_OPTIONS}
|
||||
ninja
|
||||
ninja install
|
||||
cd ..
|
||||
|
||||
#ccache --show-stats
|
||||
|
||||
# XXX Moving back the prefix to be used as artifacts.
|
||||
mv "${PIKA_PREFIX}" .
|
169
build/windows/gitlab-ci/dll_link.py
Normal file
169
build/windows/gitlab-ci/dll_link.py
Normal file
@ -0,0 +1,169 @@
|
||||
#!/usr/bin/python3
|
||||
|
||||
################################################################################
|
||||
# Small python script to retrieve DLL dependencies with objdump
|
||||
################################################################################
|
||||
|
||||
################################################################################
|
||||
# Usage example
|
||||
#
|
||||
# python3 dll_link.py /path/to/run.exe /winenv/ /path/install
|
||||
#
|
||||
# In this case, the DLL dependencies for executable run.exe will be extracted
|
||||
# and copied into /path/install/bin folder. To copy the DLL, the root path to
|
||||
# Windows environnment should be passed, here /winenv/.
|
||||
|
||||
import argparse
|
||||
import os
|
||||
import subprocess
|
||||
import re
|
||||
import shutil
|
||||
import sys
|
||||
|
||||
################################################################################
|
||||
# Global variables
|
||||
|
||||
# Sets for executable and system DLL
|
||||
dlls = set()
|
||||
sys_dlls = set()
|
||||
|
||||
# Previously done DLLs in previous runs
|
||||
done_dlls = set()
|
||||
|
||||
# Common paths
|
||||
bindir = 'bin'
|
||||
|
||||
################################################################################
|
||||
# Functions
|
||||
|
||||
# Main function
|
||||
def main(binary, srcdirs, destdir, debug, dll_file):
|
||||
global done_dlls
|
||||
try:
|
||||
if dll_file is not None:
|
||||
with open(dll_file, 'r') as f:
|
||||
done_dlls = { line.strip() for line in f if len(line.strip()) != 0 }
|
||||
except FileNotFoundError:
|
||||
pass
|
||||
|
||||
sys.stdout.write("{} (INFO): searching for dependencies of {} in {}.\n".format(os.path.basename(__file__),
|
||||
binary, ', '.join(srcdirs)))
|
||||
find_dependencies(os.path.abspath(binary), srcdirs)
|
||||
if debug in ['debug-only', 'debug-run']:
|
||||
if debug == 'debug-only':
|
||||
print("Running in debug-only mode (no DLL moved) for '{}'".format(binary))
|
||||
else:
|
||||
print("Running with debug output for '{}'".format(binary))
|
||||
|
||||
if len(dlls) > 0:
|
||||
sys.stdout.write("Needed DLLs:\n\t- ")
|
||||
sys.stdout.write("\n\t- ".join(list(dlls)))
|
||||
print()
|
||||
if len(sys_dlls) > 0:
|
||||
sys.stdout.write('System DLLs:\n\t- ')
|
||||
sys.stdout.write("\n\t- ".join(sys_dlls))
|
||||
print()
|
||||
removed_dlls = sys_dlls & dlls
|
||||
if len(removed_dlls) > 0:
|
||||
sys.stdout.write('Non installed DLLs:\n\t- ')
|
||||
sys.stdout.write("\n\t- ".join(removed_dlls))
|
||||
print()
|
||||
installed_dlls = dlls - sys_dlls
|
||||
if len(installed_dlls) > 0:
|
||||
sys.stdout.write('Installed DLLs:\n\t- ')
|
||||
sys.stdout.write("\n\t- ".join(installed_dlls))
|
||||
print()
|
||||
|
||||
if debug == 'debug-run':
|
||||
copy_dlls(dlls - sys_dlls, srcdirs, destdir)
|
||||
else:
|
||||
copy_dlls(dlls - sys_dlls, srcdirs, destdir)
|
||||
|
||||
if dll_file is not None:
|
||||
with open(dll_file, 'w') as f:
|
||||
f.write("\n".join(set.union(done_dlls, dlls, sys_dlls)))
|
||||
|
||||
def find_dependencies(obj, srcdirs):
|
||||
'''
|
||||
List DLLs of an object file in a recursive way.
|
||||
'''
|
||||
if obj in set.union(done_dlls, sys_dlls):
|
||||
# Already processed, either in a previous run of the script
|
||||
# (done_dlls) or in this one.
|
||||
return True
|
||||
|
||||
if not os.path.isabs(obj):
|
||||
for srcdir in srcdirs:
|
||||
abs_dll = os.path.join(srcdir, bindir, obj)
|
||||
abs_dll = os.path.abspath(abs_dll)
|
||||
if find_dependencies(abs_dll, srcdirs):
|
||||
return True
|
||||
else:
|
||||
# Found in none of the srcdirs: consider it a system DLL
|
||||
sys_dlls.add(os.path.basename(obj))
|
||||
return False
|
||||
elif os.path.exists(obj):
|
||||
# If DLL exists, extract dependencies.
|
||||
objdump = None
|
||||
|
||||
result = subprocess.run(['file', obj], stdout=subprocess.PIPE)
|
||||
file_type = result.stdout.decode('utf-8')
|
||||
if 'PE32+' in file_type:
|
||||
objdump = 'x86_64-w64-mingw32-objdump'
|
||||
elif 'PE32' in file_type:
|
||||
objdump = 'i686-w64-mingw32-objdump'
|
||||
|
||||
if objdump is None:
|
||||
sys.stderr.write('File type of {} unknown: {}\n'.format(obj, file_type))
|
||||
sys.exit(1)
|
||||
elif shutil.which(objdump) is None:
|
||||
# For native objdump case.
|
||||
objdump = 'objdump.exe'
|
||||
|
||||
if shutil.which(objdump) is None:
|
||||
sys.stderr.write("Executable doesn't exist: {}\n".format(objdump))
|
||||
sys.exit(1)
|
||||
|
||||
result = subprocess.run([objdump, '-p', obj], stdout=subprocess.PIPE)
|
||||
out = result.stdout.decode('utf-8')
|
||||
# Parse lines with DLL Name instead of lib*.dll directly
|
||||
for match in re.finditer(r"DLL Name: *(\S+.dll)", out, re.MULTILINE):
|
||||
dll = match.group(1)
|
||||
if dll not in set.union(done_dlls, dlls, sys_dlls):
|
||||
dlls.add(dll)
|
||||
find_dependencies(dll, srcdirs)
|
||||
|
||||
return True
|
||||
else:
|
||||
return False
|
||||
|
||||
# Copy a DLL set into the /destdir/bin directory
|
||||
def copy_dlls(dll_list, srcdirs, destdir):
|
||||
destbin = os.path.join(destdir, bindir)
|
||||
os.makedirs(destbin, exist_ok=True)
|
||||
for dll in dll_list:
|
||||
if not os.path.exists(os.path.join(destbin, dll)):
|
||||
# Do not overwrite existing files.
|
||||
for srcdir in srcdirs:
|
||||
full_file_name = os.path.join(srcdir, bindir, dll)
|
||||
if os.path.isfile(full_file_name):
|
||||
sys.stdout.write("{} (INFO): copying {} to {}\n".format(os.path.basename(__file__), full_file_name, destbin))
|
||||
shutil.copy(full_file_name, destbin)
|
||||
break
|
||||
else:
|
||||
# This should not happen. We determined that the dll is in one
|
||||
# of the srcdirs.
|
||||
sys.stderr.write("Missing DLL: {}\n".format(dll))
|
||||
sys.exit(1)
|
||||
|
||||
if __name__ == "__main__":
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument('--debug', dest='debug',
|
||||
choices=['debug-only', 'debug-run', 'run-only'], default = 'run-only')
|
||||
parser.add_argument('--output-dll-list', dest='dll_file', action = 'store', default = None)
|
||||
parser.add_argument('bin')
|
||||
parser.add_argument('src', nargs='+')
|
||||
parser.add_argument('dest')
|
||||
args = parser.parse_args(sys.argv[1:])
|
||||
|
||||
main(args.bin, args.src, args.dest, args.debug, args.dll_file)
|
97
build/windows/gitlab-ci/installer-pika-msys2.sh
Normal file
97
build/windows/gitlab-ci/installer-pika-msys2.sh
Normal file
@ -0,0 +1,97 @@
|
||||
# Install Inno Setup.
|
||||
wget https://jrsoftware.org/download.php/is.exe
|
||||
./is.exe //SILENT //SUPPRESSMSGBOXES //CURRENTUSER //SP- //LOG="innosetup.log"
|
||||
|
||||
# Install unofficial language files. These are translations of "unknown
|
||||
# translation quality or might not be maintained actively".
|
||||
# Cf. https://jrsoftware.org/files/istrans/
|
||||
ISCCDIR=`grep "Dest filename:.*ISCC.exe" innosetup.log | sed 's/.*Dest filename: *\|ISCC.exe//g'`
|
||||
ISCCDIR=`cygpath -u "$ISCCDIR"`
|
||||
mkdir -p "${ISCCDIR}/Languages/Unofficial"
|
||||
cd "${ISCCDIR}/Languages/Unofficial"
|
||||
|
||||
download_lang ()
|
||||
{
|
||||
langfile="$1"
|
||||
rm -f "$langfile"
|
||||
wget "https://raw.githubusercontent.com/jrsoftware/issrc/main/Files/Languages/Unofficial/$langfile"
|
||||
downloaded="$?"
|
||||
if [ $downloaded -ne 0 ]; then
|
||||
echo "Download of '$langfile' failed."
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
download_lang_official ()
|
||||
{
|
||||
langfile="$1"
|
||||
rm -f "$langfile"
|
||||
wget "https://raw.githubusercontent.com/jrsoftware/issrc/main/Files/Languages/$langfile"
|
||||
downloaded="$?"
|
||||
if [ $downloaded -ne 0 ]; then
|
||||
echo "Download of '$langfile' failed."
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
add_bom ()
|
||||
{
|
||||
langfile="$1"
|
||||
file "$langfile" |grep "with BOM" 2>&1 > /dev/null
|
||||
has_bom="$?"
|
||||
if [ $has_bom -ne 0 ]; then
|
||||
sed -i "1s/^/\xEF\xBB\xBF/" "$langfile"
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
download_lang Basque.isl
|
||||
download_lang ChineseSimplified.isl
|
||||
download_lang ChineseTraditional.isl
|
||||
# Supposed to be UTF-8 yet missing BOM.
|
||||
add_bom ChineseTraditional.isl
|
||||
download_lang EnglishBritish.isl
|
||||
download_lang Esperanto.isl
|
||||
download_lang Galician.isl
|
||||
download_lang Georgian.isl
|
||||
download_lang Greek.isl
|
||||
download_lang Indonesian.isl
|
||||
download_lang Korean.isl
|
||||
download_lang Latvian.isl
|
||||
download_lang Lithuanian.isl
|
||||
download_lang Malaysian.isl
|
||||
download_lang Marathi.islu
|
||||
download_lang Romanian.isl
|
||||
download_lang Swedish.isl
|
||||
download_lang Vietnamese.isl
|
||||
cd -
|
||||
|
||||
# Hungarian is not in a release yet, but was moved from Unofficial
|
||||
cd "${ISCCDIR}/Languages/"
|
||||
download_lang_official Hungarian.isl
|
||||
cd -
|
||||
|
||||
# Copy generated language files into the source directory.
|
||||
cp _build/build/windows/installer/lang/*isl build/windows/installer/lang
|
||||
|
||||
# Copy generated welcome images into the source directory.
|
||||
cp _build/build/windows/installer/*bmp build/windows/installer/
|
||||
|
||||
# Construct now the installer.
|
||||
VERSION=`grep -rI '\<version *:' meson.build | head -1 | sed "s/^.*version *: *'\([0-9]\+\.[0-9]\+\.[0-9]\+\)' *,.*$/\1/"`
|
||||
#MAJOR_VERSION=`echo $VERSION | sed "s/^\([0-9]\+\)\.\([0-9]\+\)\.\([0-9]\+\)$/\1/"`
|
||||
#MINOR_VERSION=`echo $VERSION | sed "s/^\([0-9]\+\)\.\([0-9]\+\)\.\([0-9]\+\)$/\2/"`
|
||||
#MICRO_VERSION=`echo $VERSION | sed "s/^\([0-9]\+\)\.\([0-9]\+\)\.\([0-9]\+\)$/\3/"`
|
||||
cd build/windows/installer
|
||||
./compile.bat ${VERSION} ../../.. pika-w32 pika-w64 ../../.. pika-w32 pika-w64
|
||||
|
||||
# Test if the installer was created and return success/failure.
|
||||
if [ -f "_Output/pika-${VERSION}-setup.exe" ]; then
|
||||
cd _Output/
|
||||
INSTALLER="pika-${VERSION}-setup.exe"
|
||||
sha256sum $INSTALLER > ${INSTALLER}.SHA256SUMS
|
||||
sha512sum $INSTALLER > ${INSTALLER}.SHA512SUMS
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
218
build/windows/gitlab-ci/package-pika-msys2.sh
Normal file
218
build/windows/gitlab-ci/package-pika-msys2.sh
Normal file
@ -0,0 +1,218 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
if [[ "$MSYSTEM" == "MINGW32" ]]; then
|
||||
export ARTIFACTS_SUFFIX="-w32"
|
||||
export MSYS2_ARCH="i686"
|
||||
export MSYS_PREFIX="/c/msys64/mingw32/"
|
||||
export PATH="/mingw32/bin:$PATH"
|
||||
export PIKA_DISTRIB=`realpath ./pika-w32`
|
||||
else
|
||||
export ARTIFACTS_SUFFIX="-w64"
|
||||
export MSYS2_ARCH="x86_64"
|
||||
export MSYS_PREFIX="/c/msys64/mingw64/"
|
||||
export PATH="/mingw64/bin:$PATH"
|
||||
export PIKA_DISTRIB=`realpath ./pika-w64`
|
||||
fi
|
||||
|
||||
# Update everything
|
||||
pacman --noconfirm -Suy
|
||||
|
||||
# Install the required packages
|
||||
pacman --noconfirm -S --needed \
|
||||
base-devel \
|
||||
mingw-w64-$MSYS2_ARCH-binutils \
|
||||
mingw-w64-$MSYS2_ARCH-toolchain \
|
||||
mingw-w64-$MSYS2_ARCH-ccache \
|
||||
\
|
||||
mingw-w64-$MSYS2_ARCH-aalib \
|
||||
mingw-w64-$MSYS2_ARCH-appstream-glib \
|
||||
mingw-w64-$MSYS2_ARCH-atk \
|
||||
mingw-w64-$MSYS2_ARCH-brotli \
|
||||
mingw-w64-$MSYS2_ARCH-cairo \
|
||||
mingw-w64-$MSYS2_ARCH-cfitsio \
|
||||
mingw-w64-$MSYS2_ARCH-drmingw \
|
||||
mingw-w64-$MSYS2_ARCH-gexiv2 \
|
||||
mingw-w64-$MSYS2_ARCH-ghostscript \
|
||||
mingw-w64-$MSYS2_ARCH-glib2 \
|
||||
mingw-w64-$MSYS2_ARCH-glib-networking \
|
||||
mingw-w64-$MSYS2_ARCH-gobject-introspection \
|
||||
mingw-w64-$MSYS2_ARCH-gobject-introspection-runtime \
|
||||
mingw-w64-$MSYS2_ARCH-graphviz \
|
||||
mingw-w64-$MSYS2_ARCH-gtk3 \
|
||||
mingw-w64-$MSYS2_ARCH-iso-codes \
|
||||
mingw-w64-$MSYS2_ARCH-json-c \
|
||||
mingw-w64-$MSYS2_ARCH-json-glib \
|
||||
mingw-w64-$MSYS2_ARCH-lcms2 \
|
||||
mingw-w64-$MSYS2_ARCH-lensfun \
|
||||
mingw-w64-$MSYS2_ARCH-libarchive \
|
||||
mingw-w64-$MSYS2_ARCH-libheif \
|
||||
mingw-w64-$MSYS2_ARCH-libjxl \
|
||||
mingw-w64-$MSYS2_ARCH-libmypaint \
|
||||
mingw-w64-$MSYS2_ARCH-libspiro \
|
||||
mingw-w64-$MSYS2_ARCH-libwebp \
|
||||
mingw-w64-$MSYS2_ARCH-libwmf \
|
||||
mingw-w64-$MSYS2_ARCH-lua51-lgi \
|
||||
mingw-w64-$MSYS2_ARCH-luajit \
|
||||
mingw-w64-$MSYS2_ARCH-maxflow \
|
||||
mingw-w64-$MSYS2_ARCH-mypaint-brushes \
|
||||
mingw-w64-$MSYS2_ARCH-openexr \
|
||||
mingw-w64-$MSYS2_ARCH-pango \
|
||||
mingw-w64-$MSYS2_ARCH-poppler \
|
||||
mingw-w64-$MSYS2_ARCH-poppler-data \
|
||||
mingw-w64-$MSYS2_ARCH-python \
|
||||
mingw-w64-$MSYS2_ARCH-python3-gobject \
|
||||
mingw-w64-$MSYS2_ARCH-qoi \
|
||||
mingw-w64-$MSYS2_ARCH-shared-mime-info \
|
||||
mingw-w64-$MSYS2_ARCH-suitesparse \
|
||||
mingw-w64-$MSYS2_ARCH-vala \
|
||||
mingw-w64-$MSYS2_ARCH-xpm-nox
|
||||
|
||||
export PIKA_PREFIX="`realpath ./_install`${ARTIFACTS_SUFFIX}"
|
||||
export PATH="$PIKA_PREFIX/bin:$PATH"
|
||||
|
||||
# Package ressources.
|
||||
mkdir -p ${PIKA_DISTRIB}
|
||||
cp -fr ${PIKA_PREFIX}/etc ${PIKA_DISTRIB}
|
||||
cp -fr ${PIKA_PREFIX}/include ${PIKA_DISTRIB}
|
||||
#cp -fr ${PIKA_PREFIX}/ssl ${PIKA_DISTRIB}
|
||||
cp -fr ${PIKA_PREFIX}/share ${PIKA_DISTRIB}
|
||||
|
||||
# Package executables.
|
||||
mkdir ${PIKA_DISTRIB}/bin
|
||||
cp -fr ${PIKA_PREFIX}/bin/pika*.exe ${PIKA_DISTRIB}/bin/
|
||||
|
||||
# With the native Windows build, it's directly in bin/
|
||||
#mkdir ${PIKA_DISTRIB}/libexec
|
||||
#cp -fr ${PIKA_PREFIX}/libexec/pika*.exe ${PIKA_DISTRIB}/libexec/
|
||||
|
||||
# Add a wrapper at tree root, less messy than having to look for the
|
||||
# binary inside bin/, in the middle of all the DLLs.
|
||||
echo "bin\pika-2.99.exe" > ${PIKA_DISTRIB}/pika.cmd
|
||||
|
||||
# Package library data and modules.
|
||||
cp -fr ${MSYS_PREFIX}/etc/fonts ${PIKA_DISTRIB}/etc/
|
||||
cp -fr ${MSYS_PREFIX}/etc/gtk-3.0 ${PIKA_DISTRIB}/etc/
|
||||
|
||||
mkdir ${PIKA_DISTRIB}/lib/
|
||||
cp -fr ${PIKA_PREFIX}/lib/pika ${PIKA_DISTRIB}/lib/
|
||||
cp -fr ${PIKA_PREFIX}/lib/gegl-0.4 ${PIKA_DISTRIB}/lib/
|
||||
cp -fr ${PIKA_PREFIX}/lib/babl-0.1 ${PIKA_DISTRIB}/lib/
|
||||
|
||||
cp -fr ${MSYS_PREFIX}/lib/girepository-1.0 ${PIKA_DISTRIB}/lib/
|
||||
cp -fr ${PIKA_PREFIX}/lib/girepository-1.0/* ${PIKA_DISTRIB}/lib/girepository-1.0/
|
||||
|
||||
cp -fr ${MSYS_PREFIX}/lib/gio ${PIKA_DISTRIB}/lib/
|
||||
cp -fr ${MSYS_PREFIX}/lib/gdk-pixbuf-2.0 ${PIKA_DISTRIB}/lib/
|
||||
cp -fr ${MSYS_PREFIX}/lib/gtk-3.0 ${PIKA_DISTRIB}/lib/
|
||||
|
||||
cp -fr ${MSYS_PREFIX}/lib/python3.11 ${PIKA_DISTRIB}/lib/
|
||||
|
||||
cp -fr ${MSYS_PREFIX}/share/ghostscript ${PIKA_DISTRIB}/share/
|
||||
cp -fr ${MSYS_PREFIX}/share/glib-2.0 ${PIKA_DISTRIB}/share/
|
||||
cp -fr ${MSYS_PREFIX}/share/libthai ${PIKA_DISTRIB}/share/
|
||||
cp -fr ${MSYS_PREFIX}/share/libwmf ${PIKA_DISTRIB}/share/
|
||||
cp -fr ${MSYS_PREFIX}/share/mypaint-data ${PIKA_DISTRIB}/share/
|
||||
cp -fr ${MSYS_PREFIX}/share/poppler ${PIKA_DISTRIB}/share/
|
||||
|
||||
cp -fr ${MSYS_PREFIX}/share/lua/ ${PIKA_DISTRIB}/share/
|
||||
cp -fr ${MSYS_PREFIX}/lib/lua/ ${PIKA_DISTRIB}/lib/
|
||||
|
||||
# XXX Are these themes really needed?
|
||||
cp -fr ${MSYS_PREFIX}/share/themes ${PIKA_DISTRIB}/share/
|
||||
|
||||
# Only copy from langs supported in PIKA.
|
||||
for dir in ${PIKA_DISTRIB}/share/locale/*/; do
|
||||
lang=`basename "$dir"`;
|
||||
# TODO: ideally we could be a bit more accurate and copy only the
|
||||
# language files from our dependencies and iso_639.mo. But let's go
|
||||
# with this for now, especially as each lang may have different
|
||||
# translation availability.
|
||||
if [ -d "${MSYS_PREFIX}/share/locale/${lang}/LC_MESSAGES/" ]; then
|
||||
cp -fr "${MSYS_PREFIX}/share/locale/${lang}/LC_MESSAGES/"*.mo "${PIKA_DISTRIB}/share/locale/${lang}/LC_MESSAGES/"
|
||||
fi
|
||||
done;
|
||||
|
||||
# Only one iso-codes file is useful.
|
||||
mkdir -p ${PIKA_DISTRIB}/share/xml/iso-codes
|
||||
cp -fr ${MSYS_PREFIX}/share/xml/iso-codes/iso_639.xml ${PIKA_DISTRIB}/share/xml/iso-codes/
|
||||
|
||||
# Adwaita can be used as the base icon set.
|
||||
cp -fr ${MSYS_PREFIX}/share/icons/Adwaita ${PIKA_DISTRIB}/share/icons/
|
||||
|
||||
# XXX Why are these for exactly?
|
||||
cp -fr ${MSYS_PREFIX}/bin/gspawn*.exe ${PIKA_DISTRIB}/bin/
|
||||
|
||||
# We save the list of already copied DLLs to keep a state between dll_link runs.
|
||||
rm -f done-dll.list
|
||||
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/gspawn-win*-helper.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX} ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/gspawn-win*-helper-console.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
# XXX Does not look like it's needed anymore. Check?
|
||||
cp -fr ${MSYS_PREFIX}/bin/gdk-pixbuf-query-loaders.exe ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/gdk-pixbuf-query-loaders.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
# XXX Why is bzip2.exe needed?
|
||||
cp -fr ${MSYS_PREFIX}/bin/bzip2.exe ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/bzip2.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
# Executables for supported interpreters.
|
||||
cp -fr ${MSYS_PREFIX}/bin/pythonw.exe ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/pythonw.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
cp -fr ${MSYS_PREFIX}/bin/python3w.exe ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/python3w.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
cp -fr ${MSYS_PREFIX}/bin/python3.exe ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/python3.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
cp -fr ${MSYS_PREFIX}/bin/luajit.exe ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/luajit.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
# Executable for "gegl:introspect" from graphviz package.
|
||||
cp -fr ${MSYS_PREFIX}/bin/dot.exe ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/dot.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
# Generate share/glib-2.0/schemas/gschemas.compiled
|
||||
glib-compile-schemas --targetdir=${PIKA_DISTRIB}/share/glib-2.0/schemas ${PIKA_DISTRIB}/share/glib-2.0/schemas
|
||||
|
||||
# Package needed DLLs only
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/pika-2.99.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/pika-console-2.99.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/pika-debug-resume.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/pika-debug-tool-2.99.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/pika-test-clipboard-2.99.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/pikatool-2.99.exe ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
for dll in ${PIKA_DISTRIB}/lib/babl-0.1/*.dll; do
|
||||
python3 build/windows/gitlab-ci/dll_link.py $dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list;
|
||||
done
|
||||
for dll in ${PIKA_DISTRIB}/lib/gegl-0.4/*.dll; do
|
||||
python3 build/windows/gitlab-ci/dll_link.py $dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list;
|
||||
done
|
||||
for dll in ${PIKA_DISTRIB}/lib/gio/modules/*.dll; do
|
||||
python3 build/windows/gitlab-ci/dll_link.py $dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list;
|
||||
done
|
||||
for dll in ${PIKA_DISTRIB}/lib/gdk-pixbuf-2.0/2.10.0/loaders/*.dll; do
|
||||
python3 build/windows/gitlab-ci/dll_link.py $dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list;
|
||||
done
|
||||
for dll in ${PIKA_DISTRIB}/lib/pika/2.99/modules/*.dll; do
|
||||
python3 build/windows/gitlab-ci/dll_link.py $dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list;
|
||||
done
|
||||
for dll in ${PIKA_DISTRIB}/lib/pika/2.99/plug-ins/*/*.exe; do
|
||||
python3 build/windows/gitlab-ci/dll_link.py $dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list;
|
||||
done
|
||||
|
||||
# Libraries for GObject Introspection.
|
||||
|
||||
cp -fr ${MSYS_PREFIX}/bin/libgirepository-1.0-1.dll ${PIKA_DISTRIB}/bin/
|
||||
python3 build/windows/gitlab-ci/dll_link.py ${PIKA_DISTRIB}/bin/libgirepository-1.0-1.dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list
|
||||
|
||||
for dll in ${PIKA_DISTRIB}/lib/python3.11/site-packages/*/*.dll; do
|
||||
python3 build/windows/gitlab-ci/dll_link.py $dll ${PIKA_PREFIX}/ ${MSYS_PREFIX}/ ${PIKA_DISTRIB} --output-dll-list done-dll.list;
|
||||
done
|
22
build/windows/gitlab-ci/split-debug-msys2.sh
Normal file
22
build/windows/gitlab-ci/split-debug-msys2.sh
Normal file
@ -0,0 +1,22 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ -z "$1" ]
|
||||
then
|
||||
find . \( -iname '*.dll' -or -iname '*.exe' -or -iname '*.pyd' \) -type f -exec objcopy -v --only-keep-debug '{}' '{}'.debug \;
|
||||
find . \( -iname '*.dll' -or -iname '*.exe' -or -iname '*.pyd' \) -type f -exec objcopy -v --add-gnu-debuglink='{}'.debug '{}' --strip-unneeded \;
|
||||
find . -iname '*.debug' -exec "$0" {} +
|
||||
else
|
||||
while [ -n "$1" ]
|
||||
do
|
||||
FP="$1"
|
||||
NAME="${FP##*/}"
|
||||
DIR="${FP%/*}"
|
||||
echo "$FP -> $DIR/.debug"
|
||||
if [ ! -d "$DIR/.debug" ]
|
||||
then
|
||||
mkdir "$DIR/.debug"
|
||||
fi
|
||||
mv "$FP" "$DIR/.debug"
|
||||
shift
|
||||
done
|
||||
fi
|
60
build/windows/installer/32on64.isi
Normal file
60
build/windows/installer/32on64.isi
Normal file
@ -0,0 +1,60 @@
|
||||
#if 0
|
||||
[Files]
|
||||
#endif
|
||||
//process list of 32bit PIKA files that are installed on x64 (for TWAIN support)
|
||||
#pragma option -e-
|
||||
|
||||
#define protected
|
||||
|
||||
#define FileHandle
|
||||
#define FileLine
|
||||
|
||||
#define ReplPos
|
||||
#define ReplStr
|
||||
|
||||
#define Line=0
|
||||
#define SRC_DIR PIKA_DIR32
|
||||
|
||||
//avoid too much nesting
|
||||
#sub DoActualWork
|
||||
#if Copy(FileLine,Len(FileLine),1)=="\"
|
||||
//include whole directory
|
||||
Source: "{#SRC_DIR}\{#FileLine}*"; DestDir: "{app}\32\{#Copy(FileLine,1,Len(FileLine)-1)}"; Components: pika32on64; Flags: recursesubdirs restartreplace replacesameversion uninsrestartdelete ignoreversion
|
||||
#else
|
||||
//include files from a certain directory
|
||||
#define OutputDir Copy(FileLine,1,RPos("\",FileLine)-1)
|
||||
Source: "{#SRC_DIR}\{#FileLine}"; DestDir: "{app}\32\{#OutputDir}"; Components: pika32on64; Flags: restartreplace replacesameversion uninsrestartdelete ignoreversion
|
||||
#endif
|
||||
#endsub
|
||||
|
||||
#sub Process32on64Line
|
||||
#if !defined(Finished)
|
||||
//show that something's happening
|
||||
#expr Line=Line+1
|
||||
#pragma message "Processing 32on64.list line " + Str(Line)
|
||||
|
||||
#if Copy(FileLine,1,1)=="#" || FileLine==""
|
||||
//skip comments and empty lines
|
||||
#elif Copy(FileLine,1,1)=="!"
|
||||
#if Copy(FileLine,2)=="PIKA"
|
||||
#expr SRC_DIR=PIKA_DIR32
|
||||
#elif Copy(FileLine,2)=="GTK"
|
||||
#expr SRC_DIR=DEPS_DIR32
|
||||
#elif Copy(FileLine,2)=="end"
|
||||
#define public Finished 1
|
||||
//finished
|
||||
#else
|
||||
#error "Unknown command: "+FileLine
|
||||
#endif
|
||||
#else
|
||||
#expr DoActualWork
|
||||
#endif
|
||||
#endif
|
||||
#endsub
|
||||
|
||||
#for {FileHandle = FileOpen(AddBackslash(SourcePath)+"32on64.list"); \
|
||||
FileHandle && !FileEof(FileHandle); FileLine = FileRead(FileHandle)} \
|
||||
Process32on64Line
|
||||
#if FileHandle
|
||||
#expr FileClose(FileHandle)
|
||||
#endif
|
15
build/windows/installer/32on64.list
Normal file
15
build/windows/installer/32on64.list
Normal file
@ -0,0 +1,15 @@
|
||||
#list of 32bit files to install on x64
|
||||
!GTK
|
||||
etc\fonts\
|
||||
#lib\gtk-2.0\2.10.0\loaders\*.dll
|
||||
#lib\gtk-2.0\modules\*.dll
|
||||
lib\gdk-pixbuf-2.0\2.10.0\loaders\*.dll
|
||||
lib\gdk-pixbuf-2.0\2.10.0\loaders.cache
|
||||
lib\babl-0.1\*.dll
|
||||
lib\gegl-0.4\*.dll
|
||||
share\themes\
|
||||
bin\gspawn*.exe
|
||||
bin\*.dll
|
||||
!PIKA
|
||||
bin\*.dll
|
||||
!end
|
504
build/windows/installer/MessageWithURL.isi
Normal file
504
build/windows/installer/MessageWithURL.isi
Normal file
@ -0,0 +1,504 @@
|
||||
[Code]
|
||||
(* MessageWithURL
|
||||
*
|
||||
* Copyright (c) 2010-2011 Jernej Simončič
|
||||
*
|
||||
* This software is provided 'as-is', without any express or implied
|
||||
* warranty. In no event will the authors be held liable for any damages
|
||||
* arising from the use of this software.
|
||||
*
|
||||
* Permission is granted to anyone to use this software for any purpose,
|
||||
* including commercial applications, and to alter it and redistribute it
|
||||
* freely, subject to the following restrictions:
|
||||
*
|
||||
* 1. The origin of this software must not be misrepresented; you must
|
||||
* not claim that you wrote the original software. If you use this
|
||||
* software in a product, an acknowledgment in the product
|
||||
* documentation would be appreciated but is not required.
|
||||
*
|
||||
* 2. Altered source versions must be plainly marked as such, and must
|
||||
* not be misrepresented as being the original software.
|
||||
*
|
||||
* 3. This notice may not be removed or altered from any source
|
||||
* distribution.
|
||||
*)
|
||||
|
||||
(* * * * * * * * * *
|
||||
* MessageWithURL(Message: TArrayOfString; Title: String: ButtonText: TArrayOfString; Typ: TMsgBoxType;
|
||||
* DefaultButton, CancelButton: Integer): Integer;
|
||||
*
|
||||
* Parameters:
|
||||
* Title dialog box caption
|
||||
* Message messages to display; if a message starts with _, the text following it up to the first space character
|
||||
* is interpreted as URL, and the rest of the message is used as clickable text for that URL
|
||||
* Typ icon to show
|
||||
* ButtonText buttons to show under the text
|
||||
* DefaultButton default button (first button = 1)
|
||||
* CancelButton cancel button (first button = 1)
|
||||
*
|
||||
* Return value button that was clicked (first button = 1); if running in silent mode, DefaultButton is returned
|
||||
*)
|
||||
function MessageWithURL(Message: TArrayOfString; const Title: String; ButtonText: TArrayOfString; const Typ: TMsgBoxType;
|
||||
const DefaultButton, CancelButton: Integer): Integer; forward;
|
||||
|
||||
function GetSystemMetrics(nIndex: Integer): Integer; external 'GetSystemMetrics@User32 stdcall';
|
||||
function GetDialogBaseUnits(): Integer; external 'GetDialogBaseUnits@User32 stdcall';
|
||||
|
||||
//function GetSysColor(nIndex: Integer): DWORD; external 'GetSysColor@user32.dll stdcall';
|
||||
|
||||
function LoadIcon(hInstance: Integer; lpIconName: Integer): Integer; external 'LoadIconW@user32 stdcall';
|
||||
//function LoadImage(hinst: Integer; lpszName: Integer; uType: Cardinal; cxDesired, cyDesired: Integer; fuLoad: Cardinal): Integer; external 'LoadImageW@user32 stdcall';
|
||||
function DrawIcon(hdc: HBitmap; x,y: Integer; hIcon: Integer): Integer; external 'DrawIcon@user32 stdcall';
|
||||
//function DrawIconEx(hdc: HBitmap; xLeft,yTop: Integer; hIcon: Integer; cxWidth, cyWidth: Integer; istepIfAniCur: Cardinal; hbrFlickerFreeDraw: Integer; diFlags: Cardinal): Integer; external 'DrawIconEx@user32 stdcall';
|
||||
//function DestroyIcon(hIcon: Integer): Integer; external 'DestroyIcon@user32 stdcall';
|
||||
|
||||
function DrawFocusRect(hDC: Integer; var lprc: TRect): BOOL; external 'DrawFocusRect@user32 stdcall';
|
||||
|
||||
type
|
||||
TArrayOfButton = Array of TNewButton;
|
||||
|
||||
const
|
||||
//borders around message
|
||||
MWU_LEFTBORDER = 25;
|
||||
MWU_RIGHTBORDER = MWU_LEFTBORDER;
|
||||
MWU_TOPBORDER = 26;
|
||||
MWU_BOTTOMBORDER = MWU_TOPBORDER;
|
||||
//space between elements (icon-text and between buttons)
|
||||
MWU_HORZSPACING = 8;
|
||||
//space between labels
|
||||
MWU_VERTSPACING = 4;
|
||||
//button sizes
|
||||
MWU_BUTTONHEIGHT = 24;
|
||||
MWU_MINBUTTONWIDTH = 86;
|
||||
//height of area where buttons are placed
|
||||
MWU_BUTTONAREAHEIGHT = 45;
|
||||
|
||||
SM_CXSCREEN = 0;
|
||||
SM_CXICON = 11;
|
||||
SM_CYICON = 12;
|
||||
SM_CXICONSPACING = 38;
|
||||
SM_CYICONSPACING = 39;
|
||||
|
||||
//COLOR_HOTLIGHT = 26;
|
||||
|
||||
OIC_HAND = 32513;
|
||||
OIC_QUES = 32514;
|
||||
OIC_BANG = 32515;
|
||||
OIC_NOTE = 32516;
|
||||
|
||||
LR_DEFAULTSIZE = $00000040;
|
||||
LR_SHARED = $00008000;
|
||||
|
||||
IMAGE_BITMAP = 0;
|
||||
IMAGE_ICON = 1;
|
||||
IMAGE_CURSOR = 2;
|
||||
|
||||
DI_IMAGE = 1;
|
||||
DI_MASK = 2;
|
||||
DI_NORMAL = DI_IMAGE or DI_MASK;
|
||||
DI_DEFAULTSIZE = 8;
|
||||
|
||||
var
|
||||
URLList: TArrayOfString;
|
||||
TextLabel: Array of TNewStaticText;
|
||||
URLFocusImg: Array of TBitmapImage;
|
||||
SingleLineHeight: Integer;
|
||||
|
||||
|
||||
procedure UrlClick(Sender: TObject);
|
||||
var ErrorCode: Integer;
|
||||
begin
|
||||
ShellExecAsOriginalUser('open',URLList[TNewStaticText(Sender).Tag],'','',SW_SHOWNORMAL,ewNoWait,ErrorCode);
|
||||
end;
|
||||
|
||||
|
||||
// calculates maximum width of text labels
|
||||
// also counts URLs, and sets the length of URLList accordingly
|
||||
function Message_CalcLabelWidth(var Message: TArrayOfString; MessageForm: TSetupForm): Integer;
|
||||
var MeasureLabel: TNewStaticText;
|
||||
i,URLCount,DlgUnit,ScreenWidth: Integer;
|
||||
begin
|
||||
MeasureLabel := TNewStaticText.Create(MessageForm);
|
||||
with MeasureLabel do
|
||||
begin
|
||||
Parent := MessageForm;
|
||||
Left := 0;
|
||||
Top := 0;
|
||||
AutoSize := True;
|
||||
end;
|
||||
|
||||
MeasureLabel.Caption := 'X';
|
||||
SingleLineHeight := MeasureLabel.Height;
|
||||
|
||||
Result := 0; //minimum width
|
||||
URLCount := 0;
|
||||
for i := 0 to GetArrayLength(Message) - 1 do
|
||||
begin
|
||||
if Length(Message[i]) < 1 then //simplifies things
|
||||
Message[i] := ' ';
|
||||
|
||||
if Message[i][1] <> '_' then
|
||||
MeasureLabel.Caption := Message[i] //not an URL
|
||||
else
|
||||
begin //URL - check only the displayed text
|
||||
if Pos(' ',Message[i]) > 0 then
|
||||
MeasureLabel.Caption := Copy(Message[i],Pos(' ',Message[i])+1,Length(Message[i]))
|
||||
else
|
||||
MeasureLabel.Caption := Copy(Message[i],2,Length(Message[i]));
|
||||
|
||||
URLCount := URLCount + 1;
|
||||
end;
|
||||
|
||||
if MeasureLabel.Width > Result then
|
||||
Result := MeasureLabel.Width;
|
||||
end;
|
||||
MeasureLabel.Free;
|
||||
|
||||
SetArrayLength(URLList,URLCount); //needed later - no need to do a special loop just for this
|
||||
SetArrayLength(URLFocusImg,URLCount);
|
||||
|
||||
DlgUnit := GetDialogBaseUnits() and $FFFF; //ensure the dialog isn't too wide
|
||||
ScreenWidth := GetSystemMetrics(SM_CXSCREEN);
|
||||
if Result > ((278 * DlgUnit) div 4) then //278 is from http://blogs.msdn.com/b/oldnewthing/archive/2011/06/24/10178386.aspx
|
||||
Result := ((278 * DlgUnit) div 4);
|
||||
if Result > (ScreenWidth * 3) div 4 then
|
||||
Result := (ScreenWidth * 3) div 4;
|
||||
|
||||
end;
|
||||
|
||||
|
||||
//find the longest button
|
||||
function Message_CalcButtonWidth(const ButtonText: TArrayOfString; MessageForm: TSetupForm): Integer;
|
||||
var MeasureLabel: TNewStaticText;
|
||||
i: Integer;
|
||||
begin
|
||||
MeasureLabel := TNewStaticText.Create(MessageForm);
|
||||
with MeasureLabel do
|
||||
begin
|
||||
Parent := MessageForm;
|
||||
Left := 0;
|
||||
Top := 0;
|
||||
AutoSize := True;
|
||||
end;
|
||||
|
||||
Result := ScaleX(MWU_MINBUTTONWIDTH - MWU_HORZSPACING * 2); //minimum width
|
||||
for i := 0 to GetArrayLength(ButtonText) - 1 do
|
||||
begin
|
||||
MeasureLabel.Caption := ButtonText[i]
|
||||
|
||||
if MeasureLabel.Width > Result then
|
||||
Result := MeasureLabel.Width;
|
||||
end;
|
||||
MeasureLabel.Free;
|
||||
|
||||
Result := Result + ScaleX(MWU_HORZSPACING * 2); //account for borders
|
||||
end;
|
||||
|
||||
|
||||
procedure Message_Icon(const Typ: TMsgBoxType; TypImg: TBitmapImage);
|
||||
var TypRect: TRect;
|
||||
Icon: THandle;
|
||||
TypIcon: Integer;
|
||||
begin
|
||||
TypRect.Left := 0;
|
||||
TypRect.Top := 0;
|
||||
TypRect.Right := GetSystemMetrics(SM_CXICON);
|
||||
TypRect.Bottom := GetSystemMetrics(SM_CYICON);
|
||||
|
||||
case Typ of
|
||||
mbInformation:
|
||||
TypIcon := OIC_NOTE;
|
||||
mbConfirmation:
|
||||
TypIcon := OIC_QUES;
|
||||
mbError:
|
||||
TypIcon := OIC_BANG;
|
||||
else
|
||||
TypIcon := OIC_HAND;
|
||||
end;
|
||||
|
||||
//TODO: icon loads with wrong size when using Large Fonts (SM_CXICON/CYICON is 40, but 32x32 icon loads - find out how to get the right size)
|
||||
Icon := LoadIcon(0,TypIcon);
|
||||
//Icon := LoadImage(0,TypIcon,IMAGE_ICON,0,0,LR_SHARED or LR_DEFAULTSIZE);
|
||||
with TypImg do
|
||||
begin
|
||||
Left := ScaleX(MWU_LEFTBORDER);
|
||||
Top := ScaleY(MWU_TOPBORDER);
|
||||
Center := False;
|
||||
Stretch := False;
|
||||
AutoSize := True;
|
||||
Bitmap.Width := GetSystemMetrics(SM_CXICON);
|
||||
Bitmap.Height := GetSystemMetrics(SM_CYICON);
|
||||
Bitmap.Canvas.Brush.Color := TPanel(Parent).Color;
|
||||
Bitmap.Canvas.FillRect(TypRect);
|
||||
DrawIcon(Bitmap.Canvas.Handle,0,0,Icon); //draws icon scaled
|
||||
//DrawIconEx(Bitmap.Canvas.Handle,0,0,Icon,0,0,0,0,DI_NORMAL {or DI_DEFAULTSIZE}); //draws icon without scaling
|
||||
end;
|
||||
//DestroyIcon(Icon); //not needed with LR_SHARED or with LoadIcon
|
||||
end;
|
||||
|
||||
|
||||
procedure Message_SetUpURLLabel(URLLabel: TNewStaticText; const Msg: String; const URLNum: Integer);
|
||||
var Blank: TRect;
|
||||
begin
|
||||
with URLLabel do
|
||||
begin
|
||||
if Pos(' ',Msg) > 0 then
|
||||
begin
|
||||
Caption := Copy(Msg,Pos(' ',Msg)+1,Length(Msg));
|
||||
URLList[URLNum] := Copy(Msg, 2, Pos(' ',Msg)-1);
|
||||
end
|
||||
else
|
||||
begin //no text after URL - display just URL
|
||||
URLList[URLNum] := Copy(Msg, 2, Length(Msg));
|
||||
Caption := URLList[URLNum];
|
||||
end;
|
||||
|
||||
Hint := URLList[URLNum];
|
||||
ShowHint := True;
|
||||
|
||||
Font.Color := GetSysColor(COLOR_HOTLIGHT);
|
||||
Font.Style := [fsUnderline];
|
||||
Cursor := crHand;
|
||||
OnClick := @UrlClick;
|
||||
|
||||
Tag := URLNum; //used to find the URL to open and bitmap to draw focus rectangle on
|
||||
|
||||
if Height = SingleLineHeight then //shrink label to actual text width
|
||||
WordWrap := False;
|
||||
|
||||
TabStop := True; //keyboard accessibility
|
||||
TabOrder := URLNum;
|
||||
end;
|
||||
|
||||
URLFocusImg[URLNum] := TBitmapImage.Create(URLLabel.Parent); //focus rectangle needs a bitmap - prepare it here
|
||||
with URLFocusImg[URLNum] do
|
||||
begin
|
||||
Left := URLLabel.Left - 1;
|
||||
Top := URLLabel.Top - 1;
|
||||
Stretch := False;
|
||||
AutoSize := True;
|
||||
Parent := URLLabel.Parent;
|
||||
Bitmap.Width := URLLabel.Width + 2;
|
||||
Bitmap.Height := URLLabel.Height + 2;
|
||||
|
||||
SendToBack;
|
||||
|
||||
Blank.Left := 0;
|
||||
Blank.Top := 0;
|
||||
Blank.Right := Width;
|
||||
Blank.Bottom := Height;
|
||||
Bitmap.Canvas.Brush.Color := TPanel(Parent).Color;
|
||||
Bitmap.Canvas.FillRect(Blank);
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
procedure Message_SetUpLabels(Message: TArrayOfString; TypImg: TBitmapImage;
|
||||
const DialogTextWidth: Integer; MessagePanel: TPanel);
|
||||
var i,URLNum,dy: Integer;
|
||||
begin
|
||||
SetArrayLength(TextLabel,GetArrayLength(Message));
|
||||
URLNum := 0;
|
||||
for i := 0 to GetArrayLength(TextLabel) - 1 do
|
||||
begin
|
||||
TextLabel[i] := TNewStaticText.Create(MessagePanel);
|
||||
with TextLabel[i] do
|
||||
begin
|
||||
Parent := MessagePanel;
|
||||
Left := TypImg.Left + TypImg.Width + ScaleX(MWU_HORZSPACING);
|
||||
if i = 0 then
|
||||
Top := TypImg.Top
|
||||
else
|
||||
Top := TextLabel[i-1].Top + TextLabel[i-1].Height + ScaleY(MWU_VERTSPACING);
|
||||
|
||||
WordWrap := True;
|
||||
AutoSize := True;
|
||||
Width := DialogTextWidth;
|
||||
|
||||
if Message[i][1] <> '_' then
|
||||
Caption := Message[i]
|
||||
else
|
||||
begin // apply URL formatting
|
||||
Message_SetUpURLLabel(TextLabel[i], Message[i], URLNum);
|
||||
URLNum := URLNum + 1;
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
|
||||
i := GetArrayLength(TextLabel) - 1;
|
||||
if TextLabel[i].Top + TextLabel[i].Height < TypImg.Top + TypImg.Height then //center labels vertically
|
||||
begin
|
||||
dy := (TypImg.Top + TypImg.Height - TextLabel[i].Top - TextLabel[i].Height) div 2;
|
||||
for i := 0 to GetArrayLength(TextLabel) - 1 do
|
||||
TextLabel[i].Top := TextLabel[i].Top + dy;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
procedure Message_SetUpButtons(var Button: TArrayOfButton; ButtonText: TArrayOfString;
|
||||
const ButtonWidth, DefaultButton, CancelButton: Integer; MessageForm: TSetupForm);
|
||||
var i: Integer;
|
||||
begin
|
||||
SetArrayLength(Button,GetArrayLength(ButtonText));
|
||||
for i := 0 to GetArrayLength(Button) - 1 do
|
||||
begin
|
||||
Button[i] := TNewButton.Create(MessageForm);
|
||||
with Button[i] do
|
||||
begin
|
||||
Parent := MessageForm;
|
||||
Width := ButtonWidth;
|
||||
Height := ScaleY(MWU_BUTTONHEIGHT);
|
||||
|
||||
if i = 0 then
|
||||
begin
|
||||
Left := MessageForm.ClientWidth - (ScaleX(MWU_HORZSPACING) + ButtonWidth) * GetArrayLength(ButtonText);
|
||||
Top := MessageForm.ClientHeight - ScaleY(MWU_BUTTONAREAHEIGHT) +
|
||||
ScaleY(MWU_BUTTONAREAHEIGHT - MWU_BUTTONHEIGHT) div 2;
|
||||
end else
|
||||
begin
|
||||
Left := Button[i-1].Left + ScaleX(MWU_HORZSPACING) + ButtonWidth;
|
||||
Top := Button[i-1].Top;
|
||||
end;
|
||||
|
||||
Caption := ButtonText[i];
|
||||
ModalResult := i + 1;
|
||||
|
||||
//set the initial focus to the default button
|
||||
TabOrder := ((i - (DefaultButton - 1)) + GetArrayLength(Button)) mod (GetArrayLength(Button));
|
||||
|
||||
if DefaultButton = i + 1 then
|
||||
Default := True;
|
||||
|
||||
if CancelButton = i + 1 then
|
||||
Cancel := True;
|
||||
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
//find out if URL label has focus
|
||||
//draw focus rectangle around it if so and return index of focused label
|
||||
function Message_FocusLabel(): Integer;
|
||||
var i: Integer;
|
||||
FocusRect: TRect;
|
||||
begin
|
||||
Result := -1;
|
||||
|
||||
for i := 0 to GetArrayLength(URLFocusImg) - 1 do //clear existing focus rectangle
|
||||
begin
|
||||
FocusRect.Left := 0;
|
||||
FocusRect.Top := 0;
|
||||
FocusRect.Right := URLFocusImg[i].Bitmap.Width;
|
||||
FocusRect.Bottom := URLFocusImg[i].Bitmap.Height;
|
||||
URLFocusImg[i].Bitmap.Canvas.FillRect(FocusRect);
|
||||
end;
|
||||
|
||||
for i := 0 to GetArrayLength(TextLabel) - 1 do
|
||||
begin
|
||||
if TextLabel[i].Focused then
|
||||
begin
|
||||
Result := i;
|
||||
|
||||
FocusRect.Left := 0;
|
||||
FocusRect.Top := 0;
|
||||
FocusRect.Right := URLFocusImg[TextLabel[i].Tag].Bitmap.Width;
|
||||
FocusRect.Bottom := URLFocusImg[TextLabel[i].Tag].Bitmap.Height;
|
||||
|
||||
DrawFocusRect(URLFocusImg[TextLabel[i].Tag].Bitmap.Canvas.Handle, FocusRect);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
//TNewStaticText doesn't have OnFocus - handle that here
|
||||
//(not perfect - if you focus label with keyboard, then focus a button with mouse, the label keeps it's underline)
|
||||
procedure Message_KeyUp(Sender: TObject; var Key: Word; Shift: TShiftState);
|
||||
var URLIdx: Integer;
|
||||
begin
|
||||
case Key of
|
||||
9,37..40: //tab, arrow keys
|
||||
begin
|
||||
Message_FocusLabel();
|
||||
end;
|
||||
13,32: //enter, spacebar
|
||||
begin
|
||||
URLIdx := Message_FocusLabel(); //get focused label
|
||||
if URLIdx > -1 then
|
||||
UrlClick(TextLabel[URLIdx]);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
function MessageWithURL(Message: TArrayOfString; const Title: String; ButtonText: TArrayOfString; const Typ: TMsgBoxType;
|
||||
const DefaultButton, CancelButton: Integer): Integer;
|
||||
var MessageForm: TSetupForm;
|
||||
Button: TArrayOfButton;
|
||||
DialogTextWidth, ButtonWidth: Integer;
|
||||
MessagePanel: TPanel;
|
||||
TypImg: TBitmapImage;
|
||||
i: Integer;
|
||||
begin
|
||||
if (not IsUninstaller and WizardSilent) or (IsUninstaller and UninstallSilent) then
|
||||
begin
|
||||
Result := DefaultButton;
|
||||
exit;
|
||||
end;
|
||||
|
||||
MessageForm := CreateCustomForm();
|
||||
|
||||
MessageForm.Caption := Title;
|
||||
if (CancelButton = 0) or (CancelButton > GetArrayLength(ButtonText)) then //no cancel button - remove close button
|
||||
MessageForm.BorderIcons := MessageForm.BorderIcons - [biSystemMenu];
|
||||
|
||||
MessagePanel := TPanel.Create(MessageForm); //Vista-style background
|
||||
with MessagePanel do
|
||||
begin
|
||||
Parent := MessageForm;
|
||||
BevelInner := bvNone;
|
||||
BevelOuter := bvNone;
|
||||
BevelWidth := 0;
|
||||
ParentBackground := False;
|
||||
Color := clWindow;
|
||||
Left := 0;
|
||||
Top := 0;
|
||||
end;
|
||||
|
||||
DialogTextWidth := Message_CalcLabelWidth(Message, MessageForm);
|
||||
ButtonWidth := Message_CalcButtonWidth(ButtonText, MessageForm);
|
||||
|
||||
TypImg := TBitmapImage.Create(MessagePanel);
|
||||
TypImg.Parent := MessagePanel;
|
||||
Message_Icon(Typ, TypImg);
|
||||
|
||||
Message_SetUpLabels(Message, TypImg, DialogTextWidth, MessagePanel);
|
||||
|
||||
i := GetArrayLength(TextLabel) - 1;
|
||||
MessagePanel.ClientHeight := TextLabel[i].Top + TextLabel[i].Height + ScaleY(MWU_BOTTOMBORDER);
|
||||
|
||||
MessagePanel.ClientWidth := DialogTextWidth + TypImg.Width + TypImg.Left + ScaleX(MWU_HORZSPACING + MWU_RIGHTBORDER);
|
||||
if MessagePanel.ClientWidth <
|
||||
(ButtonWidth + ScaleX(MWU_HORZSPACING)) * GetArrayLength(ButtonText) + ScaleX(MWU_HORZSPACING) then //ensure buttons fit
|
||||
MessagePanel.ClientWidth := (ButtonWidth + ScaleX(MWU_HORZSPACING)) * GetArrayLength(ButtonText) + ScaleX(MWU_HORZSPACING);
|
||||
|
||||
MessageForm.ClientWidth := MessagePanel.Width;
|
||||
MessageForm.ClientHeight := MessagePanel.Height + ScaleY(MWU_BUTTONAREAHEIGHT);
|
||||
|
||||
Message_SetUpButtons(Button, ButtonText, ButtonWidth, DefaultButton, CancelButton, MessageForm);
|
||||
|
||||
MessageForm.OnKeyUp := @Message_KeyUp; //needed for keyboard access of URL labels
|
||||
MessageForm.KeyPreView := True;
|
||||
|
||||
Result := MessageForm.ShowModal;
|
||||
|
||||
for i := 0 to GetArrayLength(TextLabel) - 1 do
|
||||
TextLabel[i].Free;
|
||||
SetArrayLength(TextLabel,0);
|
||||
for i := 0 to GetArrayLength(URLFocusImg) - 1 do
|
||||
URLFocusImg[i].Free;
|
||||
SetArrayLength(URLFocusImg,0);
|
||||
|
||||
MessageForm.Release;
|
||||
end;
|
52
build/windows/installer/associations.isi
Normal file
52
build/windows/installer/associations.isi
Normal file
@ -0,0 +1,52 @@
|
||||
[Registry]
|
||||
#pragma option -e-
|
||||
|
||||
#define protected
|
||||
|
||||
Root: HKA; Subkey: "Software\Classes\Applications\pika-{#MAJOR}.{#MINOR}.exe"; Flags: uninsdeletekey
|
||||
Root: HKA; Subkey: "Software\Classes\Applications\pika-{#MAJOR}.{#MINOR}.exe"; ValueType: string; ValueName: "FriendlyAppName"; ValueData: "PIKA"
|
||||
Root: HKA; Subkey: "Software\Classes\Applications\pika-{#MAJOR}.{#MINOR}.exe\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\bin\pika-{#MAJOR}.{#MINOR}.exe,1"
|
||||
Root: HKA; Subkey: "Software\Classes\Applications\pika-{#MAJOR}.{#MINOR}.exe\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\bin\pika-{#MAJOR}.{#MINOR}.exe"" ""%1"""
|
||||
|
||||
Root: HKA; Subkey: "Software\PIKA {#MAJOR}.{#MINOR}"; Flags: uninsdeletekey
|
||||
Root: HKA; Subkey: "Software\PIKA {#MAJOR}.{#MINOR}\Capabilities"; ValueType: string; ValueName: "ApplicationName"; ValueData: "PIKA"
|
||||
Root: HKA; Subkey: "Software\PIKA {#MAJOR}.{#MINOR}\Capabilities"; ValueType: string; ValueName: "ApplicationIcon"; ValueData: "{app}\bin\pika-{#MAJOR}.{#MINOR}.exe,0"
|
||||
Root: HKA; Subkey: "Software\PIKA {#MAJOR}.{#MINOR}\Capabilities"; ValueType: string; ValueName: "ApplicationDescription"; ValueData: "PIKA is a free raster graphics editor used for image retouching and editing, free-form drawing, converting between different image formats, and more specialized tasks."
|
||||
|
||||
Root: HKA; Subkey: "Software\RegisteredApplications"; ValueType: string; ValueName: "PIKA {#MAJOR}.{#MINOR}"; ValueData: "Software\PIKA {#MAJOR}.{#MINOR}\Capabilities"; Flags: uninsdeletevalue
|
||||
|
||||
#define FileHandle
|
||||
#define FileLine
|
||||
|
||||
#define Line=0
|
||||
|
||||
#sub ProcessAssociation
|
||||
#if !defined(Finished)
|
||||
#if Copy(FileLine,1,1)=="#" || FileLine==""
|
||||
//skip comments and empty lines
|
||||
#else
|
||||
#pragma message "Processing associations.list: " + FileLine
|
||||
;
|
||||
Root: HKA; Subkey: "Software\Classes\.{#FileLine}\OpenWithProgids"; ValueType: string; ValueName: "PIKA2.{#FileLine}"; ValueData: ""; Flags: uninsdeletevalue
|
||||
Root: HKA; Subkey: "Software\Classes\PIKA2.{#FileLine}"; ValueType: string; ValueName: ""; ValueData: "PIKA {#ICON_VERSION}"; Flags: uninsdeletekey
|
||||
Root: HKA; Subkey: "Software\Classes\PIKA2.{#FileLine}\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\bin\pika-{#MAJOR}.{#MINOR}.exe,1"
|
||||
Root: HKA; Subkey: "Software\Classes\PIKA2.{#FileLine}\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\bin\pika-{#MAJOR}.{#MINOR}.exe"" ""%1"""
|
||||
Root: HKA; Subkey: "Software\Classes\Applications\pika-{#MAJOR}.{#MINOR}.exe\SupportedTypes"; ValueType: string; ValueName: ".{#FileLine}"; ValueData: ""
|
||||
Root: HKA; Subkey: "Software\PIKA {#MAJOR}.{#MINOR}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".{#FileLine}"; ValueData: "PIKA2.{#FileLine}"
|
||||
#endif
|
||||
#endif
|
||||
#endsub
|
||||
|
||||
#for {FileHandle = FileOpen(AddBackslash(SourcePath)+"associations.list"); \
|
||||
FileHandle && !FileEof(FileHandle); FileLine = FileRead(FileHandle)} \
|
||||
ProcessAssociation
|
||||
#if FileHandle
|
||||
#expr FileClose(FileHandle)
|
||||
#endif
|
||||
;special case for .ico files
|
||||
Root: HKA; Subkey: "Software\Classes\.ico\OpenWithProgids"; ValueType: string; ValueName: "PIKA2.ico"; ValueData: ""; Flags: uninsdeletevalue
|
||||
Root: HKA; Subkey: "Software\Classes\PIKA2.ico"; ValueType: string; ValueName: ""; ValueData: "PIKA {#ICON_VERSION}"; Flags: uninsdeletekey
|
||||
Root: HKA; Subkey: "Software\Classes\PIKA2.ico\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "%1"
|
||||
Root: HKA; Subkey: "Software\Classes\PIKA2.ico\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\bin\pika-{#MAJOR}.{#MINOR}.exe"" ""%1"""
|
||||
Root: HKA; Subkey: "Software\Classes\Applications\pika-{#MAJOR}.{#MINOR}.exe\SupportedTypes"; ValueType: string; ValueName: ".ico"; ValueData: ""
|
||||
Root: HKA; Subkey: "Software\PIKA {#MAJOR}.{#MINOR}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".ico"; ValueData: "PIKA2.{#FileLine}"
|
80
build/windows/installer/associations.list
Normal file
80
build/windows/installer/associations.list
Normal file
@ -0,0 +1,80 @@
|
||||
xcf
|
||||
ani
|
||||
avif
|
||||
bmp
|
||||
dds
|
||||
g3
|
||||
cel
|
||||
cur
|
||||
dcm
|
||||
dcx
|
||||
dicom
|
||||
exr
|
||||
gif
|
||||
heif
|
||||
heic
|
||||
icns
|
||||
jp2
|
||||
j2k
|
||||
j2c
|
||||
jpc
|
||||
jxl
|
||||
pcx
|
||||
pcc
|
||||
pdf
|
||||
png
|
||||
pnm
|
||||
ppm
|
||||
pgm
|
||||
pbm
|
||||
pfm
|
||||
pam
|
||||
ps
|
||||
eps
|
||||
psp
|
||||
tub
|
||||
pspimage
|
||||
im1
|
||||
im8
|
||||
im24
|
||||
im32
|
||||
rs
|
||||
ras
|
||||
svg
|
||||
tga
|
||||
vda
|
||||
icb
|
||||
vst
|
||||
tif
|
||||
tiff
|
||||
webp
|
||||
wmf
|
||||
apm
|
||||
xpm
|
||||
xwd
|
||||
fit
|
||||
fits
|
||||
fli
|
||||
flc
|
||||
jpg
|
||||
jpeg
|
||||
jpe
|
||||
psd
|
||||
sgi
|
||||
rgb
|
||||
rgba
|
||||
bw
|
||||
icon
|
||||
pix
|
||||
matte
|
||||
mask
|
||||
alpha
|
||||
als
|
||||
xbm
|
||||
ora
|
||||
qoi
|
||||
wbmp
|
||||
acbm
|
||||
iff
|
||||
ilbm
|
||||
lbm
|
50
build/windows/installer/compile.bat
Normal file
50
build/windows/installer/compile.bat
Normal file
@ -0,0 +1,50 @@
|
||||
@echo off
|
||||
if [%1]==[] goto help
|
||||
if [%2]==[] goto help
|
||||
if [%3]==[] goto help
|
||||
if [%4]==[] goto help
|
||||
if [%5]==[] goto help
|
||||
if [%6]==[] goto help
|
||||
if [%7]==[] goto help
|
||||
set VER=%~1
|
||||
set PIKA_BASE=%~2
|
||||
set PIKA32=%~3
|
||||
set PIKA64=%~4
|
||||
set DEPS_BASE=%~5
|
||||
set DEPS32=%~6
|
||||
set DEPS64=%~7
|
||||
|
||||
if [%INNOPATH%]==[] (
|
||||
FOR /F "usebackq tokens=5,* skip=2" %%A IN (`REG QUERY "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall\Inno Setup 6_is1" /v "Inno Setup: App Path" /reg:32`) DO set INNOPATH=%%B
|
||||
) else (if [%INNOPATH%]==[] (
|
||||
FOR /F "usebackq tokens=5,* skip=2" %%A IN (`REG QUERY "HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall\Inno Setup 6_is1" /v "Inno Setup: App Path" /reg:32`) DO set INNOPATH=%%B
|
||||
))
|
||||
if not exist "%INNOPATH%\iscc.exe" goto noinno
|
||||
|
||||
::i'd use %*, but shift has no effect on it
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
set PARAMS=
|
||||
:doparams
|
||||
if "%1"=="" goto paramsdone
|
||||
set PARAMS=%PARAMS% %1
|
||||
shift
|
||||
goto doparams
|
||||
:paramsdone
|
||||
|
||||
"%INNOPATH%\iscc.exe" -DVERSION="%VER%" -DPIKA_DIR="%PIKA_BASE%" -DDIR32="%PIKA32%" -DDIR64="%PIKA64%" -DDEPS_DIR="%DEPS_BASE%" -DDDIR32="%DEPS32%" -DDDIR64="%DEPS64%" -DDEBUG_SYMBOLS -DPYTHON -DLUA %PARAMS% pika3264.iss
|
||||
goto :eof
|
||||
|
||||
:help
|
||||
echo Usage: %~n0%~x0 ver.si.on pika_base_dir pika_x86_dir pika_x64_dir deps_base_dir deps_x86_dir deps_x64_dir [iscc_parameters]
|
||||
echo Example: %~n0%~x0 2.9.4 X:\pika-output\2.9-dev x86 x64 x:\pika-deps x86 x64 -DPYTHON -DDEBUG_SYMBOLS
|
||||
goto :eof
|
||||
:noinno
|
||||
echo Inno Setup path could not be read from Registry - install Inno Setup or set INNOPATH environment variable pointing at it's
|
||||
echo install directory
|
||||
goto :eof
|
36
build/windows/installer/configoverride.isi
Normal file
36
build/windows/installer/configoverride.isi
Normal file
@ -0,0 +1,36 @@
|
||||
;allow specific configuration files to be overridden by files in a specific directory
|
||||
#if 0
|
||||
[Files]
|
||||
#endif
|
||||
|
||||
#define FindHandle
|
||||
#define FindResult
|
||||
|
||||
#sub ProcessConfigFile
|
||||
#define FileName FindGetFileName(FindHandle)
|
||||
Source: "{code:GetExternalConfDir}\{#FileName}"; DestDir: "{app}\{#ConfigDir}"; Flags: external restartreplace; Check: CheckExternalConf('{#FileName}')
|
||||
#if BaseDir != PIKA_DIR32
|
||||
Source: "{code:GetExternalConfDir}\{#FileName}"; DestDir: "{app}\32\{#ConfigDir}"; Components: pika32on64; Flags: external restartreplace; Check: CheckExternalConf('{#FileName}')
|
||||
#endif
|
||||
#endsub
|
||||
|
||||
#sub ProcessConfigDir
|
||||
#emit ';; ' + ConfigDir
|
||||
#emit ';; ' + BaseDir
|
||||
#for {FindHandle = FindResult = FindFirst(AddBackslash(BaseDir) + AddBackSlash(ConfigDir) + "*", 0); \
|
||||
FindResult; FindResult = FindNext(FindHandle)} ProcessConfigFile
|
||||
#if FindHandle
|
||||
#expr FindClose(FindHandle)
|
||||
#endif
|
||||
#endsub
|
||||
|
||||
#define public BaseDir PIKA_DIR32
|
||||
#define public ConfigDir "etc\pika\2.0"
|
||||
#expr ProcessConfigDir
|
||||
|
||||
#define public BaseDir DEPS_DIR32
|
||||
#define public ConfigDir "etc\gtk-2.0"
|
||||
#expr ProcessConfigDir
|
||||
|
||||
#define public ConfigDir "etc\fonts"
|
||||
#expr ProcessConfigDir
|
61
build/windows/installer/directories.isi
Normal file
61
build/windows/installer/directories.isi
Normal file
@ -0,0 +1,61 @@
|
||||
//directories to source files from
|
||||
#if !defined(VERSION)
|
||||
#error "VERSION must be defined"
|
||||
#endif
|
||||
|
||||
#define public
|
||||
|
||||
#if !defined(VER_DIR)
|
||||
#if defined(REVISION)
|
||||
#define VER_DIR VERSION + "-" + REVISION
|
||||
#else
|
||||
#define VER_DIR VERSION
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef DIR32
|
||||
#define DIR32 "i686-w64-mingw32"
|
||||
#endif
|
||||
#ifndef DIR64
|
||||
#define DIR64 "x86_64-w64-mingw32"
|
||||
#endif
|
||||
|
||||
#ifndef PIKA_DIR
|
||||
#define PIKA_DIR "N:\pika\output\" + VER_DIR
|
||||
#endif
|
||||
#ifndef DEPS_DIR
|
||||
#define DEPS_DIR "N:\pika\deps"
|
||||
#endif
|
||||
|
||||
//32-bit PIKA base directory (result of make install)
|
||||
#ifndef PIKA_DIR32
|
||||
#define PIKA_DIR32 PIKA_DIR + "\" + DIR32
|
||||
#endif
|
||||
//64-bit PIKA base directory (result of make install)
|
||||
#ifndef PIKA_DIR64
|
||||
#define PIKA_DIR64 PIKA_DIR + "\" + DIR64
|
||||
#endif
|
||||
|
||||
#ifndef DDIR32
|
||||
#define DDIR32 DIR32
|
||||
#endif
|
||||
#ifndef DDIR64
|
||||
#define DDIR64 DIR64
|
||||
#endif
|
||||
|
||||
//32-bit dependencies directory
|
||||
#ifndef DEPS_DIR32
|
||||
#define DEPS_DIR32 DEPS_DIR + "\" + DDIR32
|
||||
#endif
|
||||
//64-bit dependencies directory
|
||||
#ifndef DEPS_DIR64
|
||||
#define DEPS_DIR64 DEPS_DIR + "\" + DDIR64
|
||||
#endif
|
||||
|
||||
#ifdef PYTHON
|
||||
|
||||
//python source directory
|
||||
#ifndef PY_DIR
|
||||
#define PY_DIR "N:\common\python2.7"
|
||||
#endif
|
||||
#endif
|
60
build/windows/installer/files.isi
Normal file
60
build/windows/installer/files.isi
Normal file
@ -0,0 +1,60 @@
|
||||
#if 0
|
||||
[Files]
|
||||
#endif
|
||||
|
||||
#if PLATFORM==32
|
||||
#define DIR DIR32
|
||||
#define DDIR DDIR32
|
||||
#elif PLATFORM==64
|
||||
#define DIR DIR64
|
||||
#define DDIR DDIR64
|
||||
#else
|
||||
#error "Unknown PLATFORM:" + PLATFORM
|
||||
#endif
|
||||
|
||||
Source: "{#PIKA_DIR}\{#DIR}\*.dll"; DestDir: "{app}"; Components: pika{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#PIKA_DIR}\{#DIR}\*.exe"; DestDir: "{app}"; Excludes: "\lib\pika\{#DIR_VER}\plug-ins\twain\twain.exe,\lib\pika\{#DIR_VER}\plug-ins\file-ps\file-ps.exe,\bin\pika.exe,\bin\pika-console.exe"; Components: pika{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
#ifdef DEBUG_SYMBOLS
|
||||
Source: "{#PIKA_DIR}\{#DIR}\*.debug"; DestDir: "{app}"; Components: pika{#PLATFORM} and debug; Flags: recursesubdirs restartreplace uninsrestartdelete ignoreversion
|
||||
#endif
|
||||
Source: "{#PIKA_DIR}\{#DIR}\lib\pika\{#DIR_VER}\extensions\*.*"; Excludes: "*.debug"; DestDir: "{app}\lib\pika\{#DIR_VER}\extensions"; Components: pika{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
#ifdef DEBUG_SYMBOLS
|
||||
Source: "{#PIKA_DIR}\{#DIR}\lib\pika\{#DIR_VER}\extensions\*.debug"; DestDir: "{app}\lib\pika\{#DIR_VER}\extensions"; Components: pika{#PLATFORM} and debug; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
#endif
|
||||
|
||||
Source: "{#PIKA_DIR}\{#DIR}\lib\pika\{#DIR_VER}\plug-ins\file-ps\file-ps.exe"; DestDir: "{app}\lib\pika\{#DIR_VER}\plug-ins\file-ps"; Components: gs and pika{#PLATFORM}; Flags: restartreplace ignoreversion uninsrestartdelete
|
||||
|
||||
Source: "{#PIKA_DIR}\{#DIR}\lib\girepository-1.0\*.*"; DestDir: "{app}\lib\girepository-1.0"; Components: pika{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\girepository-1.0\*.*"; DestDir: "{app}\lib\girepository-1.0"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\*.dll"; DestDir: "{app}\bin"; Excludes: "\bin\libgs*.dll,\bin\lua*.dll"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\libgs*.dll"; DestDir: "{app}\bin"; Components: gs and deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
#ifdef DEBUG_SYMBOLS
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\.debug\*.dll.debug"; DestDir: "{app}\bin\.debug"; Components: deps{#PLATFORM} and debug; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete skipifsourcedoesntexist
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\*.debug"; DestDir: "{app}\lib"; Components: deps{#PLATFORM} and debug; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete skipifsourcedoesntexist
|
||||
#endif
|
||||
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\gspawn-win*.exe"; DestDir: "{app}\bin"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\gdk-pixbuf-query-loaders.exe"; DestDir: "{app}\bin"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\bzip2.exe"; DestDir: "{app}\bin"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace uninsrestartdelete ignoreversion
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\gdk-pixbuf-2.0\2.10.0\loaders.cache"; DestDir: "{app}\lib\gdk-pixbuf-2.0\2.10.0\"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\babl-0.1\*.dll"; DestDir: "{app}\lib\babl-0.1"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\gdk-pixbuf-2.0\*.dll"; DestDir: "{app}\lib\gdk-pixbuf-2.0"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\gegl-0.4\*.dll"; DestDir: "{app}\lib\gegl-0.4"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\gio\*.dll"; DestDir: "{app}\lib\gio"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
;Source: "{#DEPS_DIR}\{#DDIR}\lib\gtk-3.0\*.dll"; DestDir: "{app}\lib\gtk-3.0"; Components: deps{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
|
||||
;python scripts
|
||||
#ifdef PYTHON
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\python3w.exe"; DestDir: "{app}\bin"; DestName: "pythonw.exe"; Components: py and pika{#PLATFORM}; Flags: restartreplace uninsrestartdelete ignoreversion
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\python3.exe"; DestDir: "{app}\bin"; DestName: "python.exe"; Components: py and pika{#PLATFORM}; Flags: restartreplace uninsrestartdelete ignoreversion
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\libpython3.11.dll"; DestDir: "{app}\bin"; Components: py and pika{#PLATFORM}; Flags: restartreplace uninsrestartdelete ignoreversion
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\python3.11\*"; DestDir: "{app}\lib\python3.11"; Components: py and pika{#PLATFORM}; Flags: recursesubdirs restartreplace uninsrestartdelete ignoreversion
|
||||
#endif
|
||||
|
||||
#ifdef LUA
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\luajit.exe"; DestDir: "{app}\bin"; Components: lua and pika{#PLATFORM}; Flags: restartreplace uninsrestartdelete ignoreversion
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\bin\lua51.dll"; DestDir: "{app}\bin"; Components: lua and pika{#PLATFORM}; Flags: restartreplace uninsrestartdelete ignoreversion
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\share\lua\*"; DestDir: "{app}\share\lua"; Components: lua and pika{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
Source: "{#DEPS_DIR}\{#DDIR}\lib\lua\*"; DestDir: "{app}\lib\lua"; Components: lua and pika{#PLATFORM}; Flags: recursesubdirs restartreplace ignoreversion uninsrestartdelete
|
||||
#endif
|
179
build/windows/installer/gpl+python.rtf
Normal file
179
build/windows/installer/gpl+python.rtf
Normal file
@ -0,0 +1,179 @@
|
||||
{\rtf1\ansi\ansicpg1250\deff0\deflang1060\deflangfe1060{\fonttbl{\f0\fswiss\fprq2\fcharset238 Verdana;}{\f1\fmodern\fprq1\fcharset238 Lucida Console;}}
|
||||
{\colortbl ;\red0\green0\blue255;}
|
||||
\viewkind4\uc1\pard\keepn\nowidctlpar\sb100\sa200\qc\b\f0\fs28 GNU GENERAL PUBLIC LICENSE\par
|
||||
\pard\nowidctlpar\sa60\qc\b0\fs16 Version 3, 29 June 2007\par
|
||||
\pard\sa60 Copyright \'a9 2007 Free Software Foundation, Inc. <{\field{\*\fldinst{HYPERLINK "http://fsf.org/"}}{\fldrslt{\ul\cf1 http://fsf.org/}}}\f0\fs16 >\par
|
||||
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\qc\b\fs20 Preamble\par
|
||||
\pard\nowidctlpar\sa60\b0\fs16 The GNU General Public License is a free, copyleft license for software and other kinds of works.\par
|
||||
The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too.\par
|
||||
When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things.\par
|
||||
To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others.\par
|
||||
For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights.\par
|
||||
Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it.\par
|
||||
For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions.\par
|
||||
Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users.\par
|
||||
Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free.\par
|
||||
The precise terms and conditions for copying, distribution and modification follow.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\qc\b\fs20 TERMS AND CONDITIONS\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\fs16 0. Definitions.\par
|
||||
\pard\nowidctlpar\sa60\b0\ldblquote This License\rdblquote refers to version 3 of the GNU General Public License.\par
|
||||
\ldblquote Copyright\rdblquote also means copyright-like laws that apply to other kinds of works, such as semiconductor masks.\par
|
||||
\ldblquote The Program\rdblquote refers to any copyrightable work licensed under this License. Each licensee is addressed as \ldblquote you\rdblquote . \ldblquote Licensees\rdblquote and\ldblquote recipients\rdblquote may be individuals or organizations.\par
|
||||
To \ldblquote modify\rdblquote a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a \ldblquote modified version\rdblquote of the earlier work or a work \ldblquote based on\rdblquote the earlier work.\par
|
||||
A \ldblquote covered work\rdblquote means either the unmodified Program or a work based on the Program.\par
|
||||
To \ldblquote propagate\rdblquote a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well.\par
|
||||
To \ldblquote convey\rdblquote a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying.\par
|
||||
An interactive user interface displays \ldblquote Appropriate Legal Notices\rdblquote to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 1. Source Code.\par
|
||||
\pard\nowidctlpar\sa60\b0 The \ldblquote source code\rdblquote for a work means the preferred form of the work for making modifications to it. \ldblquote Object code\rdblquote means any non-source form of a work.\par
|
||||
A \ldblquote Standard Interface\rdblquote means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language.\par
|
||||
The \ldblquote System Libraries\rdblquote of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A\ldblquote Major Component\rdblquote , in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it.\par
|
||||
The \ldblquote Corresponding Source\rdblquote for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work.\par
|
||||
The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source.\par
|
||||
The Corresponding Source for a work in source code form is that same work.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 2. Basic Permissions.\par
|
||||
\pard\nowidctlpar\sa60\b0 All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law.\par
|
||||
You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you.\par
|
||||
Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 3. Protecting Users' Legal Rights From Anti-Circumvention Law.\par
|
||||
\pard\nowidctlpar\sa60\b0 No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures.\par
|
||||
When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 4. Conveying Verbatim Copies.\par
|
||||
\pard\nowidctlpar\sa60\b0 You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program.\par
|
||||
You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 5. Conveying Modified Source Versions.\par
|
||||
\pard\nowidctlpar\sa60\b0 You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions:\par
|
||||
\pard\nowidctlpar\fi-360\li720\sa60 a)\tab The work must carry prominent notices stating that you modified it, and giving a relevant date. \par
|
||||
b)\tab The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to \ldblquote keep intact all notices\rdblquote . \par
|
||||
c)\tab You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. \par
|
||||
d)\tab If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so.\par
|
||||
\pard\nowidctlpar\sa60 A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an\ldblquote aggregate\rdblquote if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 6. Conveying Non-Source Forms.\par
|
||||
\pard\nowidctlpar\sa60\b0 You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways:\par
|
||||
\pard\nowidctlpar\fi-360\li720\sa60 a)\tab Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. \par
|
||||
b)\tab Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. \par
|
||||
c)\tab Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. \par
|
||||
d)\tab Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. \par
|
||||
e)\tab Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d.\par
|
||||
\pard\nowidctlpar\sa60 A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work.\par
|
||||
A \ldblquote User Product\rdblquote is either (1) a \ldblquote consumer product\rdblquote , which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, \ldblquote normally used\rdblquote refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product.\par
|
||||
\ldblquote Installation Information\rdblquote for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made.\par
|
||||
If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM).\par
|
||||
The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network.\par
|
||||
Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 7. Additional Terms.\par
|
||||
\pard\nowidctlpar\sa60\b0\ldblquote Additional permissions\rdblquote are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions.\par
|
||||
When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission.\par
|
||||
Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms:\par
|
||||
\pard\nowidctlpar\fi-360\li720\sa60 a)\tab Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or \par
|
||||
b)\tab Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or \par
|
||||
c)\tab Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or \par
|
||||
d)\tab Limiting the use for publicity purposes of names of licensors or authors of the material; or \par
|
||||
e)\tab Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or \par
|
||||
f)\tab Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. \par
|
||||
\pard\nowidctlpar\sa60 All other non-permissive additional terms are considered \ldblquote further restrictions\rdblquote within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying.\par
|
||||
If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms.\par
|
||||
Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 8. Termination.\par
|
||||
\pard\nowidctlpar\sa60\b0 You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11).\par
|
||||
However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation.\par
|
||||
Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice.\par
|
||||
Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 9. Acceptance Not Required for Having Copies.\par
|
||||
\pard\nowidctlpar\sa60\b0 You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 10. Automatic Licensing of Downstream Recipients.\par
|
||||
\pard\nowidctlpar\sa60\b0 Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License.\par
|
||||
An \ldblquote entity transaction\rdblquote is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts.\par
|
||||
You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 11. Patents.\par
|
||||
\pard\nowidctlpar\sa60\b0 A \ldblquote contributor\rdblquote is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's \ldblquote contributor version\rdblquote .\par
|
||||
A contributor's \ldblquote essential patent claims\rdblquote are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, \ldblquote control\rdblquote includes the right to grant patent sublicenses in a manner consistent with the requirements of this License.\par
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version.\par
|
||||
In the following three paragraphs, a \ldblquote patent license\rdblquote is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To \ldblquote grant\rdblquote such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party.\par
|
||||
If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. \ldblquote Knowingly relying\rdblquote means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid.\par
|
||||
If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it.\par
|
||||
A patent license is \ldblquote discriminatory\rdblquote if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007.\par
|
||||
Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 12. No Surrender of Others' Freedom.\par
|
||||
\pard\nowidctlpar\sa60\b0 If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 13. Use with the GNU Affero General Public License.\par
|
||||
\pard\nowidctlpar\sa60\b0 Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 14. Revised Versions of this License.\par
|
||||
\pard\nowidctlpar\sa60\b0 The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.\par
|
||||
Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU General Public License \ldblquote or any later version\rdblquote applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation.\par
|
||||
If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program.\par
|
||||
Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 15. Disclaimer of Warranty.\par
|
||||
\pard\nowidctlpar\sa60\b0 THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM \ldblquote AS IS\rdblquote WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 16. Limitation of Liability.\par
|
||||
\pard\nowidctlpar\sa60\b0 IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\b 17. Interpretation of Sections 15 and 16.\par
|
||||
\pard\nowidctlpar\sa120\b0 If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee.\par
|
||||
\pard\nowidctlpar\sb120\sa120\qc END OF TERMS AND CONDITIONS\par
|
||||
\pard\keepn\nowidctlpar\sb100\sa100\qc\b\fs20 How to Apply These Terms to Your New Programs\fs16\par
|
||||
\pard\nowidctlpar\sa60\b0 If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms.\par
|
||||
To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the \ldblquote copyright\rdblquote line and a pointer to where the full notice is found.\par
|
||||
\pard\nowidctlpar\li454\sb120\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631\f1 <one line to give the program's name and a brief idea of what it does.>\par
|
||||
\pard\nowidctlpar\li454\sl480\slmult1\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 Copyright (C) <year> <name of author>\par
|
||||
\pard\nowidctlpar\li454\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 This program is free software: you can redistribute it and/or modify\par
|
||||
it under the terms of the GNU General Public License as published by\par
|
||||
the Free Software Foundation, either version 3 of the License, or\par
|
||||
\pard\nowidctlpar\li454\sl480\slmult1\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 (at your option) any later version.\par
|
||||
\pard\nowidctlpar\li454\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 This program is distributed in the hope that it will be useful,\par
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of\par
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\par
|
||||
\pard\nowidctlpar\li454\sl480\slmult1\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 GNU General Public License for more details.\par
|
||||
\pard\nowidctlpar\li454\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 You should have received a copy of the GNU General Public License\par
|
||||
\pard\li454\sa120\sl240\slmult1 along with this program. If not, see <{\field{\*\fldinst{HYPERLINK "https://www.gnu.org/licenses/"}}{\fldrslt{\ul\cf1 https://www.gnu.org/licenses/}}}\f1\fs16 >.\par
|
||||
\pard\nowidctlpar\sa60\f0 Also add information on how to contact you by electronic and paper mail.\par
|
||||
If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode:\par
|
||||
\pard\nowidctlpar\li454\sb120\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631\f1 <program> Copyright (C) <year> <name of author>\par
|
||||
\pard\nowidctlpar\li454\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.\par
|
||||
This is free software, and you are welcome to redistribute it\par
|
||||
\pard\nowidctlpar\li454\sa120\tx0\tx959\tx1918\tx2877\tx3836\tx4795\tx5754\tx6713\tx7672\tx8631 under certain conditions; type `show c' for details.\par
|
||||
\pard\nowidctlpar\sa60\f0 The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, your program's commands might be different; for a GUI interface, you would use an \ldblquote about box\rdblquote .\par
|
||||
\pard You should also get your employer (if you work as a programmer) or school, if any, to sign a \ldblquote copyright disclaimer\rdblquote for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see <{\field{\*\fldinst{HYPERLINK "https://www.gnu.org/licenses/"}}{\fldrslt{\ul\cf1 https://www.gnu.org/licenses/}}}\f0\fs16 >.\par
|
||||
\pard\sa200\sl240\slmult1 The GNU General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read <{\field{\*\fldinst{HYPERLINK "http://www.gnu.org/philosophy/why-not-lgpl.html"}}{\fldrslt{\ul\cf1 http://www.gnu.org/philosophy/why-not-lgpl.html}}}\f0\fs16 >.\par
|
||||
\pard\nowidctlpar\qj\f1\fs12 PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2\par
|
||||
\pard\nowidctlpar\sa120\qj --------------------------------------------\par
|
||||
\pard\nowidctlpar\qj 1. This LICENSE AGREEMENT is between the Python Software Foundation\par
|
||||
("PSF"), and the Individual or Organization ("Licensee") accessing and\par
|
||||
otherwise using this software ("Python") in source or binary form and\par
|
||||
\pard\nowidctlpar\sa120\qj its associated documentation.\par
|
||||
\pard\nowidctlpar\qj 2. Subject to the terms and conditions of this License Agreement, PSF\par
|
||||
hereby grants Licensee a nonexclusive, royalty-free, world-wide\par
|
||||
license to reproduce, analyze, test, perform and/or display publicly,\par
|
||||
prepare derivative works, distribute, and otherwise use Python\par
|
||||
alone or in any derivative version, provided, however, that PSF's\par
|
||||
License Agreement and PSF's notice of copyright, i.e., "Copyright (c)\par
|
||||
2001, 2002, 2003, 2004, 2005, 2006 Python Software Foundation; All Rights\par
|
||||
Reserved" are retained in Python alone or in any derivative version \par
|
||||
\pard\nowidctlpar\sa120\qj prepared by Licensee.\par
|
||||
\pard\nowidctlpar\qj 3. In the event Licensee prepares a derivative work that is based on\par
|
||||
or incorporates Python or any part thereof, and wants to make\par
|
||||
the derivative work available to others as provided herein, then\par
|
||||
Licensee hereby agrees to include in any such work a brief summary of\par
|
||||
\pard\nowidctlpar\sa120\qj the changes made to Python.\par
|
||||
\pard\nowidctlpar\qj 4. PSF is making Python available to Licensee on an "AS IS"\par
|
||||
basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR\par
|
||||
IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND\par
|
||||
DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS\par
|
||||
FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT\par
|
||||
\pard\nowidctlpar\sa120\qj INFRINGE ANY THIRD PARTY RIGHTS.\par
|
||||
\pard\nowidctlpar\qj 5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON\par
|
||||
FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS\par
|
||||
A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON,\par
|
||||
\pard\nowidctlpar\sa120\qj OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.\par
|
||||
\pard\nowidctlpar\qj 6. This License Agreement will automatically terminate upon a material\par
|
||||
\pard\nowidctlpar\sa120\qj breach of its terms and conditions.\par
|
||||
\pard\nowidctlpar\qj 7. Nothing in this License Agreement shall be deemed to create any\par
|
||||
relationship of agency, partnership, or joint venture between PSF and\par
|
||||
Licensee. This License Agreement does not grant permission to use PSF\par
|
||||
trademarks or trade name in a trademark sense to endorse or promote\par
|
||||
\pard\nowidctlpar\sa120\qj products or services of Licensee, or any third party.\par
|
||||
\pard\nowidctlpar\qj 8. By copying, installing or otherwise using Python, Licensee\par
|
||||
agrees to be bound by the terms and conditions of this License\par
|
||||
Agreement.\fs15\par
|
||||
}
|
||||
|