Skip to content

Commit 0ab35b2

Browse files
committed
patch 8.0.1182: cannot see or change mzscheme dll name
Problem: Cannot see or change mzscheme dll name. Solution: Add 'mzschemedll' and 'mzschemegcdll'.
1 parent 4635e11 commit 0ab35b2

6 files changed

Lines changed: 56 additions & 4 deletions

File tree

runtime/doc/if_mzsch.txt

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*if_mzsch.txt* For Vim version 8.0. Last change: 2016 Jan 24
1+
*if_mzsch.txt* For Vim version 8.0. Last change: 2017 Oct 08
22

33

44
VIM REFERENCE MANUAL by Sergey Khorev
@@ -278,12 +278,15 @@ When you don't use the MzScheme interface you don't need them, thus you can
278278
use Vim without these DLL files.
279279
NOTE: Newer version of MzScheme (Racket) require earlier (trampolined)
280280
initialisation via scheme_main_setup. So Vim always loads the MzScheme DLL at
281-
startup if possible.
281+
startup if possible. This may make Vim startup slower.
282282

283283
To use the MzScheme interface the MzScheme DLLs must be in your search path.
284284
In a console window type "path" to see what directories are used.
285285

286-
The names of the DLLs must match the MzScheme version Vim was compiled with.
286+
On MS-Windows the options 'mzschemedll' and 'mzschemegcdll' are used for the
287+
name of the library to load. The initial value is specified at build time.
288+
289+
The version of the DLL must match the MzScheme version Vim was compiled with.
287290
For MzScheme version 209 they will be "libmzsch209_000.dll" and
288291
"libmzgc209_000.dll". To know for sure look at the output of the ":version"
289292
command, look for -DDYNAMIC_MZSCH_DLL="something" and

runtime/doc/options.txt

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5468,6 +5468,31 @@ A jump table for the options with a short description can be found at |Q_op|.
54685468
time in msec between two mouse clicks for the second click to be
54695469
recognized as a multi click.
54705470

5471+
*'mzschemedll'*
5472+
'mzschemedll' string (default depends on the build)
5473+
global
5474+
{not in Vi}
5475+
{only available when compiled with the |+mzscheme/dyn|
5476+
feature}
5477+
Specifies the name of the MzScheme shared library. The default is
5478+
DYNAMIC_MZSCH_DLL which was specified at compile time.
5479+
Environment variables are expanded |:set_env|.
5480+
This option cannot be set from a |modeline| or in the |sandbox|, for
5481+
security reasons.
5482+
5483+
*'mzschemegcdll'*
5484+
'mzschemegcdll' string (default depends on the build)
5485+
global
5486+
{not in Vi}
5487+
{only available when compiled with the |+mzscheme/dyn|
5488+
feature}
5489+
Specifies the name of the MzScheme GC shared library. The default is
5490+
DYNAMIC_MZGC_DLL which was specified at compile time.
5491+
The value can be equal to 'mzschemedll' if it includes the GC code.
5492+
Environment variables are expanded |:set_env|.
5493+
This option cannot be set from a |modeline| or in the |sandbox|, for
5494+
security reasons.
5495+
54715496
*'mzquantum'* *'mzq'*
54725497
'mzquantum' 'mzq' number (default 100)
54735498
global

src/if_mzsch.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -757,7 +757,7 @@ mzscheme_runtime_link_init(char *sch_dll, char *gc_dll, int verbose)
757757
mzscheme_enabled(int verbose)
758758
{
759759
return mzscheme_runtime_link_init(
760-
DYNAMIC_MZSCH_DLL, DYNAMIC_MZGC_DLL, verbose) == OK;
760+
(char *)p_mzschemedll, (char *)p_mzschemegcdll, verbose) == OK;
761761
}
762762

763763
static void

src/option.c

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2008,6 +2008,24 @@ static struct vimoption options[] =
20082008
{"mousetime", "mouset", P_NUM|P_VI_DEF,
20092009
(char_u *)&p_mouset, PV_NONE,
20102010
{(char_u *)500L, (char_u *)0L} SCRIPTID_INIT},
2011+
{"mzschemedll", NULL, P_STRING|P_EXPAND|P_VI_DEF|P_SECURE,
2012+
#if defined(DYNAMIC_MZSCHEME)
2013+
(char_u *)&p_mzschemedll, PV_NONE,
2014+
{(char_u *)DYNAMIC_MZSCH_DLL, (char_u *)0L}
2015+
#else
2016+
(char_u *)NULL, PV_NONE,
2017+
{(char_u *)"", (char_u *)0L}
2018+
#endif
2019+
SCRIPTID_INIT},
2020+
{"mzschemegcdll", NULL, P_STRING|P_EXPAND|P_VI_DEF|P_SECURE,
2021+
#if defined(DYNAMIC_MZSCHEME)
2022+
(char_u *)&p_mzschemegcdll, PV_NONE,
2023+
{(char_u *)DYNAMIC_MZGC_DLL, (char_u *)0L}
2024+
#else
2025+
(char_u *)NULL, PV_NONE,
2026+
{(char_u *)"", (char_u *)0L}
2027+
#endif
2028+
SCRIPTID_INIT},
20112029
{"mzquantum", "mzq", P_NUM,
20122030
#ifdef FEAT_MZSCHEME
20132031
(char_u *)&p_mzq, PV_NONE,

src/option.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -662,6 +662,10 @@ EXTERN long p_mouset; /* 'mousetime' */
662662
EXTERN int p_more; /* 'more' */
663663
#ifdef FEAT_MZSCHEME
664664
EXTERN long p_mzq; /* 'mzquantum */
665+
# if defined(DYNAMIC_MZSCHEME)
666+
EXTERN char_u *p_mzschemedll; /* 'mzschemedll' */
667+
EXTERN char_u *p_mzschemegcdll; /* 'mzschemegcdll' */
668+
# endif
665669
#endif
666670
#if defined(MSWIN)
667671
EXTERN int p_odev; /* 'opendevice' */

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -761,6 +761,8 @@ static char *(features[]) =
761761

762762
static int included_patches[] =
763763
{ /* Add new patch number below this line */
764+
/**/
765+
1182,
764766
/**/
765767
1181,
766768
/**/

0 commit comments

Comments
 (0)