Cleanup and add extras
This commit is contained in:
parent
7e3006c10e
commit
fd2ba6c852
|
@ -4,13 +4,23 @@
|
|||
*.vert.xxd
|
||||
*.frag.xxd
|
||||
*.ttf.xxd
|
||||
*.png.xxd
|
||||
*.h.xxd
|
||||
|
||||
Makefile
|
||||
|
||||
mkxp
|
||||
mkxp.wasm
|
||||
mkxp.html
|
||||
mkxp.js
|
||||
xxd+
|
||||
|
||||
/build
|
||||
/deps
|
||||
/CMakeFiles
|
||||
|
||||
CMakeCache.txt
|
||||
cmake_install.cmake
|
||||
|
||||
# Codeblocks
|
||||
mkxp.layout
|
||||
|
|
|
@ -379,15 +379,11 @@ if(APPLE)
|
|||
endif()
|
||||
|
||||
link_directories(
|
||||
../libsigc++-2.10.3/sigc++/.libs
|
||||
../pixman-0.40.0/pixman/.libs
|
||||
../physfs-3.0.2
|
||||
../ruby
|
||||
#../mruby/build/host/lib
|
||||
../mruby/build/x86_64-pc-linux-gnu/lib
|
||||
libs
|
||||
deps/libsigc++/sigc++/.libs
|
||||
deps/pixman/pixman/.libs
|
||||
deps/physfs
|
||||
deps/mruby/build/wasm32-unknown-gnu/lib
|
||||
|
||||
#../SDL_sound/.libs
|
||||
${SDL2_LIBRARY_DIRS}
|
||||
)
|
||||
|
||||
|
@ -405,34 +401,18 @@ target_compile_definitions(${PROJECT_NAME} PRIVATE
|
|||
target_include_directories(${PROJECT_NAME} PRIVATE
|
||||
src
|
||||
windows
|
||||
../libsigc++-2.10.3
|
||||
../pixman-0.40.0/pixman
|
||||
../physfs-3.0.2/src
|
||||
../mruby/include
|
||||
|
||||
|
||||
#../SDL_sound
|
||||
deps/libsigc++
|
||||
deps/pixman/pixman
|
||||
deps/physfs/src
|
||||
deps/mruby/include
|
||||
|
||||
${SDL2_INCLUDE_DIRS}
|
||||
#${VORBISFILE_INCLUDE_DIRS}
|
||||
${FLUID_INCLUDE_DIRS}
|
||||
${OPENAL_INCLUDE_DIR}
|
||||
)
|
||||
|
||||
target_link_libraries(${PROJECT_NAME}
|
||||
#ruby-static.a
|
||||
|
||||
sigc-2.0.a physfs.a pixman-1.a
|
||||
#sigc-2.0.x86.a physfs.x86.a SDL_sound.x86.a pixman-1.x86.a
|
||||
|
||||
mruby.a
|
||||
|
||||
#SDL_sound.a
|
||||
#ruby-static.x86.a
|
||||
#crypt
|
||||
#dl
|
||||
#pthread
|
||||
#rt
|
||||
sigc-2.0.a physfs.a pixman-1.a mruby.a
|
||||
|
||||
${SDL2_LIBRARIES}
|
||||
${SDL2_IMAGE_LIBRARIES}
|
||||
|
@ -462,7 +442,6 @@ set_target_properties(
|
|||
PROPERTIES
|
||||
OUTPUT_NAME "mkxp"
|
||||
SUFFIX ".html"
|
||||
# SUFFIX ".out"
|
||||
)
|
||||
|
||||
PostBuildMacBundle(${PROJECT_NAME} "" "${PLATFORM_COPY_LIBS}")
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
MRuby::Build.new do |conf|
|
||||
toolchain :gcc
|
||||
conf.gembox 'default'
|
||||
end
|
||||
|
||||
MRuby::CrossBuild.new('wasm32-unknown-gnu') do |conf|
|
||||
toolchain :clang
|
||||
|
||||
conf.gembox 'default'
|
||||
conf.gem :github => 'take-cheeze/mruby-marshal'
|
||||
conf.gem :github => 'monochromegane/mruby-time-strftime'
|
||||
conf.gem :core => 'mruby-eval'
|
||||
conf.cc.command = 'emcc'
|
||||
conf.cc.flags = %W(-O3 -g0)
|
||||
conf.cxx.command = 'em++'
|
||||
conf.cxx.flags = %W(-O3 -g0)
|
||||
|
||||
conf.linker.command = 'emcc'
|
||||
conf.archiver.command = 'emar'
|
||||
end
|
|
@ -7,7 +7,13 @@ do
|
|||
|
||||
filename="${file%.*}"
|
||||
fl="$(echo "$filename" | tr '[:upper:]' '[:lower:]')"
|
||||
|
||||
if [ -f $file ]
|
||||
then
|
||||
md5=`md5sum "${file}" | awk '{ print $1 }'`
|
||||
else
|
||||
md5=''
|
||||
fi
|
||||
|
||||
echo "\"$fl\": \"${file}?h=${md5}\"," >> mapping.js
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,19 @@
|
|||
--- src/vm.c 2020-10-18 23:00:12.865875587 +0530
|
||||
+++ src/vm.c 2020-10-18 23:06:10.887618558 +0530
|
||||
@@ -2262,13 +2262,15 @@
|
||||
switch (TYPES2(mrb_type(regs[a]),mrb_type(regs[a+1]))) {
|
||||
case TYPES2(MRB_TT_FIXNUM,MRB_TT_FIXNUM):
|
||||
#ifdef MRB_WITHOUT_FLOAT
|
||||
+#else
|
||||
{
|
||||
mrb_int x = mrb_fixnum(regs[a]);
|
||||
mrb_int y = mrb_fixnum(regs[a+1]);
|
||||
SET_INT_VALUE(regs[a], y ? x / y : 0);
|
||||
}
|
||||
+ NEXT;
|
||||
break;
|
||||
-#else
|
||||
+
|
||||
x = (mrb_float)mrb_fixnum(regs[a]);
|
||||
y = (mrb_float)mrb_fixnum(regs[a+1]);
|
||||
break;
|
Loading…
Reference in New Issue