all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Arash Esbati <arash.esbati@gmail.com>
To: phillip.lord@russet.org.uk (Phillip Lord)
Cc: emacs-devel@gnu.org
Subject: Re: Emacs binaries for Windows
Date: Fri, 19 Aug 2016 19:24:23 +0200	[thread overview]
Message-ID: <86fuq07jug.fsf@gmail.com> (raw)
In-Reply-To: <877fbc3ion.fsf@russet.org.uk> (Phillip Lord's message of "Fri, 19 Aug 2016 16:03:04 +0100")

[-- Attachment #1: Type: text/plain, Size: 3845 bytes --]

phillip.lord@russet.org.uk (Phillip Lord) writes:

> Arash Esbati <arash.esbati@gmail.com> writes:
>> I know this topic has been discussed in past and my apologies in advance
>> if I'm beating the dead horse again and a longish message.
>
> It's not a dead horse at all. It's an issue which, to my mind, needs
> solving.

Thanks for the thumbs-up Phil, glad I'm not the only person not happy
with the current state :-)

>> I wrote a simple script to determine the dependencies of the required
>> packages mentioned here:
>>
>>     http://git.savannah.gnu.org/cgit/emacs.git/tree/nt/INSTALL.W64#n60
>
>
> I'd be interested to see this script.

It is really a brain-dead one.  I started with this one to find out the
dependencies of the relevant package:

--8<---------------cut here---------------start------------->8---
#! /usr/bin/bash

# Run this script only in a msys2 shell and not in mingw64:
if [[ $MSYSTEM != "MSYS" ]] ; then
    echo "Run this script in a MSYS-shell -- I stop now!"
    exit 1
fi

# This list derives from the features we want Emacs to compile with.
PKG_REQ="mingw-w64-x86_64-giflib
mingw-w64-x86_64-gnutls
mingw-w64-x86_64-libjpeg-turbo
mingw-w64-x86_64-libpng
mingw-w64-x86_64-librsvg
mingw-w64-x86_64-libtiff
mingw-w64-x86_64-libxml2
mingw-w64-x86_64-xpm-nox"

# tmp file to store the dependencies:
if [ -f "./tmp-pkg-list" ] ; then
    rm ./tmp-pkg-list
fi

touch ./tmp-pkg-list

# Get a list of all dependencies needed for packages mentioned above.
# Run `pactree -lu' for each elment of $PKG_REQ
for x in $PKG_REQ ; do
    pactree -lu $x >> tmp-pkg-list
done

# Sort und uniq the list
cat tmp-pkg-list | sort -u -o tmp-pkg-list
cat tmp-pkg-list | sed 's/x86_64-//' > final-pkg-list
--8<---------------cut here---------------end--------------->8---

Then I found out that some package names differ from the name of
original directory on Github, e.g. `mingw-w64-x86_64-gcc-libs' is built
within the directory `mingw-w64-gcc'.  Long story short, if you clone

    https://github.com/Alexpux/MINGW-packages.git

and run

--8<---------------cut here---------------start------------->8---
#! /usr/bin/bash

PKGS="mingw-w64-bzip2
mingw-w64-cairo
mingw-w64-expat
mingw-w64-fontconfig
mingw-w64-freetype
mingw-w64-gdk-pixbuf2
mingw-w64-gcc
mingw-w64-gettext
mingw-w64-giflib
mingw-w64-glib2
mingw-w64-gmp
mingw-w64-gnutls
mingw-w64-graphite2
mingw-w64-harfbuzz
mingw-w64-jasper
mingw-w64-libcroco
mingw-w64-libffi
mingw-w64-libiconv
mingw-w64-libidn
mingw-w64-libjpeg-turbo
mingw-w64-libpng
mingw-w64-librsvg
mingw-w64-libsystre
mingw-w64-libtasn1
mingw-w64-libtiff
mingw-w64-libtre-git
mingw-w64-libxml2
mingw-w64-lzo2
mingw-w64-nettle
mingw-w64-p11-kit
mingw-w64-pango
mingw-w64-pcre
mingw-w64-pixman
mingw-w64-wineditline
mingw-w64-winpthreads-git
mingw-w64-xpm-nox
mingw-w64-xz
mingw-w64-zlib"

for pkg in $PKGS
do
    pushd ./MINGW-packages/$pkg
    makepkg-mingw --allsource --skipinteg -sLf && \
	mv $pkg-*.tar.gz ../../
    popd
done
--8<---------------cut here---------------end--------------->8---

you have all the sources and patches (239M total) ready.

>> This is actually what my script does.  Collecting all directories for
>> the packages above gives:
>>
>>     -> du -h emacs-25.1-rc1-libs.tar.xz
>>     464K    emacs-25.1-rc1-libs.tar.xz
>>
>> Does this approach comply with GPL?
>
> I don't know enough about msys2 to understand the difference in your
> approaches, but AFAICT, -libs.tar.xv contains all the source, so that
> you could build the libraries, then it does, yes.

No, "all the sources" are in the 239M package.  You could build the
libraries with those files.  My second thought was only to provide the
relevant Msys2/MinGW directives (PKGBUILD files) and patch files, all in
one archive which I called `emacs-25.1-rc1-libs.tar.xz'.  As an
example, I am attaching such a file for `expat'.


[-- Attachment #2: mingw-w64-expat.tar.xz --]
[-- Type: application/octet-stream, Size: 1136 bytes --]

[-- Attachment #3: Type: text/plain, Size: 507 bytes --]


> At the moment, Emacs ships with a single binary (libnox4) otherwise it
> looks terrible. But, I think that the basic windows download cannot do
> an HTTP call and display the results is unfortunate.
>
> Current builds are for 32 bit as well as 64 bit. Can that be replicated
> also?

The way I get it both arch's are built from the same directives
(PKGBUILD files).  Have a look at this page, section `Building
packages':

    https://sourceforge.net/p/msys2/wiki/Contributing%20to%20MSYS2/

Best, Arash

      reply	other threads:[~2016-08-19 17:24 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-19  7:45 Emacs binaries for Windows Arash Esbati
2016-08-19 14:50 ` Eli Zaretskii
2016-08-19 16:33   ` Arash Esbati
2016-08-19 17:51     ` Eli Zaretskii
2016-08-19 20:27       ` Óscar Fuentes
2016-08-20 15:49       ` Arash Esbati
2016-08-20 15:58         ` Eli Zaretskii
2016-08-22 10:37           ` Phillip Lord
2016-08-22 14:54             ` Eli Zaretskii
2016-08-23 11:26               ` Phillip Lord
2016-08-23 14:35                 ` Eli Zaretskii
2016-08-23 17:02                   ` Arash Esbati
2016-08-23 17:21                     ` Eli Zaretskii
2016-08-24 10:42                   ` Phillip Lord
2016-08-19 15:03 ` Phillip Lord
2016-08-19 17:24   ` Arash Esbati [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86fuq07jug.fsf@gmail.com \
    --to=arash.esbati@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=phillip.lord@russet.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.