mirror of
https://github.com/nunuhara/xsystem4.git
synced 2026-10-13 09:48:23 +03:00
Install debugger.scm to XSYS4_DATA_DIR
This commit is contained in:
+4
-3
@@ -1,7 +1,7 @@
|
||||
project('system4', 'c',
|
||||
default_options : ['c_std=c11'])
|
||||
add_project_arguments('-D_DEFAULT_SOURCE', language : 'c')
|
||||
add_project_arguments('-DXSYS4_DATA_DIR="' + get_option('prefix') / 'share' / 'xsystem4"', language : 'c')
|
||||
add_project_arguments('-DXSYS4_DATA_DIR="' + get_option('prefix') / get_option('datadir') / 'xsystem4"', language : 'c')
|
||||
|
||||
zlib = dependency('zlib')
|
||||
libm = meson.get_compiler('c').find_library('m', required: false)
|
||||
@@ -36,5 +36,6 @@ libsys4_dep = libsys4_proj.get_variable('libsys4_dep')
|
||||
|
||||
subdir('src')
|
||||
|
||||
install_subdir('shaders', install_dir : 'share' / 'xsystem4')
|
||||
install_subdir('fonts', install_dir : 'share' / 'xsystem4')
|
||||
install_subdir('shaders', install_dir : get_option('datadir') / 'xsystem4')
|
||||
install_subdir('fonts', install_dir : get_option('datadir') / 'xsystem4')
|
||||
install_data('debugger.scm', install_dir : get_option('datadir') / 'xsystem4')
|
||||
|
||||
+6
-1
@@ -20,6 +20,7 @@
|
||||
#include <assert.h>
|
||||
#include <chibi/eval.h>
|
||||
|
||||
#include "system4/file.h"
|
||||
#include "system4/instructions.h"
|
||||
#include "system4/string.h"
|
||||
#include "system4/utfsjis.h"
|
||||
@@ -239,7 +240,11 @@ void dbg_init(void)
|
||||
sexp_eval_string(dbg_ctx, "(define *prompt* (make-parameter \"dbg> \"))", -1, NULL);
|
||||
sexp_eval_string(dbg_ctx, "(define breakpoint-count (make-parameter 0))", -1, NULL);
|
||||
sexp_eval_string(dbg_ctx, "(define (repl-make-prompt m) (*prompt*))", -1, NULL);
|
||||
sexp_eval_string(dbg_ctx, "(load \"./debugger.scm\")", -1, NULL);
|
||||
|
||||
if (file_exists("./debugger.scm"))
|
||||
sexp_eval_string(dbg_ctx, "(load \"./debugger.scm\")", -1, NULL);
|
||||
else
|
||||
sexp_eval_string(dbg_ctx, "(load \"" XSYS4_DATA_DIR "/debugger.scm\")", -1, NULL);
|
||||
}
|
||||
|
||||
void dbg_fini(void)
|
||||
|
||||
Reference in New Issue
Block a user