diff options
author | Gaius Mulley <gaiusmod2@gmail.com> | 2023-01-05 14:13:43 +0000 |
---|---|---|
committer | Gaius Mulley <gaiusmod2@gmail.com> | 2023-01-05 14:13:43 +0000 |
commit | a24888388bab339cf8a8726ca67a0b4947a2d9ce (patch) | |
tree | c53284daa55670030eff5d543c87d56f84103a50 /gcc/testsuite/lib | |
parent | dd77b04999534f61825cc810a5bc428707b8106b (diff) | |
download | gcc-a24888388bab339cf8a8726ca67a0b4947a2d9ce.zip gcc-a24888388bab339cf8a8726ca67a0b4947a2d9ce.tar.gz gcc-a24888388bab339cf8a8726ca67a0b4947a2d9ce.tar.bz2 |
Add missing declarations to gcc/m2/gm2-libs-min/M2RTS.{def,mod}
This patch adds two missing procedures to
gcc/m2/gm2-libs-min/M2RTS.{def,mod} required for linking. The
patch also includes test code, changes to
gcc/testsuite/lib/gm2.exp and an expect tcl script to test the
min libraries.
gcc/m2/ChangeLog:
* gm2-libs-min/M2RTS.def (ConstructModules): New procedure
declaration.
(DeconstructModules): New procedure declaration.
* gm2-libs-min/M2RTS.mod (ConstructModules): New procedure
dummy implementation.
(DeconstructModules): New procedure dummy implementation.
gcc/testsuite:
* lib/gm2.exp (gm2_init_minx): New procedure.
(gm2_init_min): New procedure calls gm2_init_min with
dialect flags.
* gm2/link/min/pass/tiny.mod: New test case.
* gm2/link/min/pass/link-min-pass.exp: New file.
Signed-off-by: Gaius Mulley <gaiusmod2@gmail.com>
Diffstat (limited to 'gcc/testsuite/lib')
-rw-r--r-- | gcc/testsuite/lib/gm2.exp | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/gcc/testsuite/lib/gm2.exp b/gcc/testsuite/lib/gm2.exp index 450cb4c..9eba195 100644 --- a/gcc/testsuite/lib/gm2.exp +++ b/gcc/testsuite/lib/gm2.exp @@ -496,3 +496,42 @@ proc gm2_init_cor { {path ""} args } { gm2_link_lib "m2cor m2pim m2iso" gm2_init {*}${theIpath} -fpim {*}${theLpath} {*}${args}; } + + +# +# gm2_init_minx - set the default libraries to choose MIN library and +# choose Modula-2, dialect. +# +# + +proc gm2_init_minx { dialect {path ""} args } { + global srcdir; + global gccpath; + + set gm2src ${srcdir}/../m2; + + send_log "srcdir is $srcdir\n" + send_log "gccpath is $gccpath\n" + send_log "gm2src is $gm2src\n" + + set minIpath "${gccpath}/libgm2/libm2min"; + set minLpath "${gccpath}/libgm2/libm2min/.libs"; + + set theIpath "-I${minIpath}"; + set theLpath "-L${minLpath}"; + + if { $path != "" } then { + append theIpath " -I" + append theIpath ${path} + } + gm2_init {*}${theIpath} {*}${dialect} {*}${theLpath} {*}${args}; +} + +# +# gm2_init_min - set the default libraries to choose MIN libraries +# and pim dialect. +# + +proc gm2_init_min { {path ""} args } { + gm2_init_minx -fpim {*}${path} {*}${args}; +} |