← Back to team overview

kicad-developers team mailing list archive

Re: Global fp-lib-table path

 

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Am 22.02.2015 um 17:40 schrieb Bernhard Stegmaier:

> Wouldn’t it make more sense or be more consistent to have it in 
> $KISYSMOD where all models are?

No, the fp-lib-table introduces $KISYSMOD -- ideally there shouldn't
be any hard dependencies on it.

- From a software distribution point of view, environment variables are
a nightmare:

There are users who don't know how to manipulate them, which means we
need a mechanism to set up the environment variable.

On Windows, there is an API for that, but we need to take into account
that users could change the variable, which adds complexity into the
installer.

On Unix, there is no way to make a variable persistent, so we need a
wrapper script (and even if there was a way to make the change
permanent, it would mean that the user would have to log out and back
in after installing the package).

In my opinion, we should get rid of the variables sooner than later,
and provide a mechanism for a system-wide default (that uses an
absolute path to point to some models that came with the same
installer), a per-user override (as we have now, but which becomes
optional then), and a per-project override (currently we can only add
paths, but not remove them).

We don't really gain much flexibility from the environment variables
either. Right now, the Windows installer creates a batch file that
(incorrectly) sets up the variables and runs the main program, and
correcting a path (e.g. when something in GitHub changes) still
requires either user action or an update script (that becomes more
complicated now, as we've moved from a descriptive configuration
format to an imperative one, so the updater is faced with the halting
problem).

> Using $KISYSMOD as base for the global fp-lib-table would also 
> allow to switch between different libraries just by changing 
> $KISYSMOD.

Ideally, the project's fp-lib-table would be used, and the system
fp-lib-table is just a reasonable default.

Simon
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iJwEAQECAAYFAlTqJv4ACgkQ0sfeulffv7s0TgP/b9sbFoHRYeVPOnFjhpyy1unE
O+IJW9x63UV9zeW/h+u/Z3wCMlmzs7rFoc/hwxqsesg6QtDvsdx/9FC9ZnLWdshi
8IPAXANU+PvMJPhYRJj3qGnYaIu9Istck3GVC60zG6Ze9LLP/6xszNGEn2cBAtQ3
cACyXYhKwlc713fOdzE=
=lnRf
-----END PGP SIGNATURE-----


Follow ups

References