all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: "Juan José García-Ripoll" <juanjose.garciaripoll@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: Interest in nt_load_image?
Date: Tue, 31 Mar 2020 16:31:00 +0300	[thread overview]
Message-ID: <83y2rg1wiz.fsf@gnu.org> (raw)
In-Reply-To: <86zhbx6jh1.fsf@csic.es> (juanjose.garciaripoll@gmail.com)

> From: Juan José García-Ripoll
>  <juanjose.garciaripoll@gmail.com>
> Date: Tue, 31 Mar 2020 10:01:46 +0200
> 
> I have build GDI+ as a built-in back-end with which to compile Emacs. An
> Emacs built with GDI+ requires UTF-16 support and thus will not run on
> Windows 98, but it will run on Windows XP on later. GDI+ support is
> optional because it can be selected at build time, not because it can be
> chosen at compilation time.

The problem with such selection of features at build time is that the
resulting binary will flatly refuse to start on systems where the
optional functionality (in this case, GDI+) is not available, even if
there's no call at runtime to any of the optional functions.  Windows
refuses to run a program which has a function in its import table that
cannot be found in the shared libraries against which the program was
linked, or if the program was linked against a shared library that is
not available on the target system.  And on Windows we frequently see
that people are using binaries someone else compiled, so we cannot
rely on the end-user to build Emacs according to what will be
available on the end-user's system.

That is why we never link Emacs on Windows against any optional
libraries, but instead load them at runtime when the corresponding
feature is first requested.  The features whose DLL couldn't be
loaded, or where the DLL doesn't have the required functions -- those
features will not become available, but at least Emacs will start and
allow you to use it for other jobs.

In the case of GDI+, I'm quite sure we will want to have runtime
control on whether it is used even if available, at least initially,
until it becomes the default (if it ever does).  This is good for
maintenance (debugging problems people report), if nothing else.  I
could even envision users who'd prefer libpng etc. for some other
reason, whether technical or otherwise.

Therefore, catering to systems without GDI+ is very simple: the
respective variable(s) should be set up at startup to indicate that
GDI+ shouldn't be used.



  parent reply	other threads:[~2020-03-31 13:31 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-29 19:33 Interest in nt_load_image? Juan José García-Ripoll
2020-03-29 21:55 ` Juan José García-Ripoll
2020-03-30  2:21 ` Eli Zaretskii
2020-03-30  7:54   ` Juan José García-Ripoll
2020-03-30 13:46     ` Eli Zaretskii
2020-03-30 14:36       ` Juan José García-Ripoll
2020-03-30 14:44         ` Juan José García-Ripoll
2020-03-30 15:50         ` Eli Zaretskii
2020-03-30 16:15           ` Juan José García-Ripoll
2020-03-30 16:37             ` Eli Zaretskii
2020-03-30 17:16               ` Stefan Monnier
2020-03-30 18:32                 ` Eli Zaretskii
2020-03-30 18:41                   ` Stefan Monnier
2020-03-30 18:57                     ` Eli Zaretskii
2020-03-30 19:39                       ` Stefan Monnier
2020-03-31 14:19                         ` Eli Zaretskii
2020-03-30 18:06               ` Juan José García-Ripoll
2020-03-30 18:47                 ` Eli Zaretskii
2020-03-30 18:53                   ` Eli Zaretskii
2020-03-30 23:21             ` Juanma Barranquero
2020-03-31  8:01               ` Juan José García-Ripoll
2020-03-31 13:14                 ` Juanma Barranquero
2020-03-31 14:50                   ` Stefan Monnier
2020-03-31 15:25                     ` Juanma Barranquero
2020-03-31 16:54                       ` Stefan Monnier
2020-03-31 15:13                   ` Juan José García-Ripoll
2020-03-31 15:28                     ` Juanma Barranquero
2020-03-31 13:31                 ` Eli Zaretskii [this message]
2020-03-30 15:14       ` Stefan Monnier
2020-03-30 15:57         ` Eli Zaretskii
2020-03-30 17:10           ` Stefan Monnier
2020-03-30 18:23             ` Eli Zaretskii

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=83y2rg1wiz.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=juanjose.garciaripoll@gmail.com \
    /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.