mirror of
https://github.com/djhackersdev/bemanitools.git
synced 2026-09-15 03:45:09 -05:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
26d1da8660 | ||
|
|
04310f49fd | ||
|
|
d72996c5d9 |
86
Module.mk
86
Module.mk
@@ -325,6 +325,10 @@ $(zipdir)/iidx-18.zip: \
|
|||||||
dist/iidx/config.bat \
|
dist/iidx/config.bat \
|
||||||
dist/iidx/gamestart-18.bat \
|
dist/iidx/gamestart-18.bat \
|
||||||
dist/iidx/iidxhook-18.conf \
|
dist/iidx/iidxhook-18.conf \
|
||||||
|
dist/iidx/launcher-18.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
dist/iidx/vefx.txt \
|
dist/iidx/vefx.txt \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
@@ -356,6 +360,10 @@ $(zipdir)/iidx-19.zip: \
|
|||||||
dist/iidx/config.bat \
|
dist/iidx/config.bat \
|
||||||
dist/iidx/gamestart-19.bat \
|
dist/iidx/gamestart-19.bat \
|
||||||
dist/iidx/iidxhook-19.conf \
|
dist/iidx/iidxhook-19.conf \
|
||||||
|
dist/iidx/launcher-19.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
dist/iidx/vefx.txt \
|
dist/iidx/vefx.txt \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
@@ -372,6 +380,10 @@ $(zipdir)/iidx-20.zip: \
|
|||||||
dist/iidx/config.bat \
|
dist/iidx/config.bat \
|
||||||
dist/iidx/gamestart-20.bat \
|
dist/iidx/gamestart-20.bat \
|
||||||
dist/iidx/iidxhook-20.conf \
|
dist/iidx/iidxhook-20.conf \
|
||||||
|
dist/iidx/launcher-20.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
dist/iidx/vefx.txt \
|
dist/iidx/vefx.txt \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
@@ -409,6 +421,13 @@ $(zipdir)/iidx-21-to-24.zip: \
|
|||||||
dist/iidx/iidxhook-22.conf \
|
dist/iidx/iidxhook-22.conf \
|
||||||
dist/iidx/iidxhook-23.conf \
|
dist/iidx/iidxhook-23.conf \
|
||||||
dist/iidx/iidxhook-24.conf \
|
dist/iidx/iidxhook-24.conf \
|
||||||
|
dist/iidx/launcher-21.xml \
|
||||||
|
dist/iidx/launcher-22.xml \
|
||||||
|
dist/iidx/launcher-23.xml \
|
||||||
|
dist/iidx/launcher-24.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
dist/iidx/vefx.txt \
|
dist/iidx/vefx.txt \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
@@ -427,6 +446,11 @@ $(zipdir)/iidx-25-to-26.zip: \
|
|||||||
dist/iidx/gamestart-26.bat \
|
dist/iidx/gamestart-26.bat \
|
||||||
dist/iidx/iidxhook-25.conf \
|
dist/iidx/iidxhook-25.conf \
|
||||||
dist/iidx/iidxhook-26.conf \
|
dist/iidx/iidxhook-26.conf \
|
||||||
|
dist/iidx/launcher-25.xml \
|
||||||
|
dist/iidx/launcher-26.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
dist/iidx/vefx.txt \
|
dist/iidx/vefx.txt \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
@@ -449,6 +473,13 @@ $(zipdir)/iidx-27-to-30.zip: \
|
|||||||
dist/iidx/iidxhook-28.conf \
|
dist/iidx/iidxhook-28.conf \
|
||||||
dist/iidx/iidxhook-29.conf \
|
dist/iidx/iidxhook-29.conf \
|
||||||
dist/iidx/iidxhook-30.conf \
|
dist/iidx/iidxhook-30.conf \
|
||||||
|
dist/iidx/launcher-27.xml \
|
||||||
|
dist/iidx/launcher-28.xml \
|
||||||
|
dist/iidx/launcher-29.xml \
|
||||||
|
dist/iidx/launcher-30.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
dist/iidx/vefx.txt \
|
dist/iidx/vefx.txt \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
@@ -517,6 +548,10 @@ $(zipdir)/jb-03.zip: \
|
|||||||
build/bin/indep-32/jbio.dll \
|
build/bin/indep-32/jbio.dll \
|
||||||
dist/jb/config.bat \
|
dist/jb/config.bat \
|
||||||
dist/jb/gamestart-03.bat \
|
dist/jb/gamestart-03.bat \
|
||||||
|
dist/jb/launcher-03.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -530,6 +565,10 @@ $(zipdir)/jb-04.zip: \
|
|||||||
build/bin/indep-32/jbio.dll \
|
build/bin/indep-32/jbio.dll \
|
||||||
dist/jb/config.bat \
|
dist/jb/config.bat \
|
||||||
dist/jb/gamestart-03.bat \
|
dist/jb/gamestart-03.bat \
|
||||||
|
dist/jb/launcher-03.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -543,6 +582,10 @@ $(zipdir)/jb-05-to-07.zip: \
|
|||||||
build/bin/indep-32/jbio.dll \
|
build/bin/indep-32/jbio.dll \
|
||||||
dist/jb/config.bat \
|
dist/jb/config.bat \
|
||||||
dist/jb/gamestart-04.bat \
|
dist/jb/gamestart-04.bat \
|
||||||
|
dist/jb/launcher-04.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -556,6 +599,10 @@ $(zipdir)/jb-08.zip: \
|
|||||||
build/bin/indep-32/jbio.dll \
|
build/bin/indep-32/jbio.dll \
|
||||||
dist/jb/config.bat \
|
dist/jb/config.bat \
|
||||||
dist/jb/gamestart-04.bat \
|
dist/jb/gamestart-04.bat \
|
||||||
|
dist/jb/launcher-04.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -580,6 +627,10 @@ $(zipdir)/sdvx-01-to-04.zip: \
|
|||||||
build/bin/indep-32/sdvxio.dll \
|
build/bin/indep-32/sdvxio.dll \
|
||||||
dist/sdvx/config.bat \
|
dist/sdvx/config.bat \
|
||||||
dist/sdvx/gamestart.bat \
|
dist/sdvx/gamestart.bat \
|
||||||
|
dist/sdvx/launcher.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -594,6 +645,10 @@ $(zipdir)/sdvx-05-to-06.zip: \
|
|||||||
dist/sdvx5/config.bat \
|
dist/sdvx5/config.bat \
|
||||||
dist/sdvx5/gamestart.bat \
|
dist/sdvx5/gamestart.bat \
|
||||||
dist/sdvx5/sdvxhook2.conf \
|
dist/sdvx5/sdvxhook2.conf \
|
||||||
|
dist/sdvx5/launcher.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -608,6 +663,10 @@ $(zipdir)/sdvx-05-cn.zip: \
|
|||||||
dist/sdvx5/config.bat \
|
dist/sdvx5/config.bat \
|
||||||
dist/sdvx5/gamestart-cn.bat \
|
dist/sdvx5/gamestart-cn.bat \
|
||||||
dist/sdvx5/sdvxhook2-cn.conf \
|
dist/sdvx5/sdvxhook2-cn.conf \
|
||||||
|
dist/sdvx5/launcher-cn.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -682,6 +741,10 @@ $(zipdir)/ddr-12.zip: \
|
|||||||
build/bin/indep-32/geninput.dll \
|
build/bin/indep-32/geninput.dll \
|
||||||
dist/ddr/config.bat \
|
dist/ddr/config.bat \
|
||||||
dist/ddr/gamestart-12.bat \
|
dist/ddr/gamestart-12.bat \
|
||||||
|
dist/ddr/launcher-12.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -698,6 +761,10 @@ $(zipdir)/ddr-13.zip: \
|
|||||||
build/bin/indep-32/geninput.dll \
|
build/bin/indep-32/geninput.dll \
|
||||||
dist/ddr/config.bat \
|
dist/ddr/config.bat \
|
||||||
dist/ddr/gamestart-13.bat \
|
dist/ddr/gamestart-13.bat \
|
||||||
|
dist/ddr/launcher-13.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -718,6 +785,14 @@ $(zipdir)/ddr-14-to-18.zip: \
|
|||||||
dist/ddr/gamestart-16.bat \
|
dist/ddr/gamestart-16.bat \
|
||||||
dist/ddr/gamestart-17.bat \
|
dist/ddr/gamestart-17.bat \
|
||||||
dist/ddr/gamestart-18.bat \
|
dist/ddr/gamestart-18.bat \
|
||||||
|
dist/ddr/launcher-14.xml \
|
||||||
|
dist/ddr/launcher-15.xml \
|
||||||
|
dist/ddr/launcher-16.xml \
|
||||||
|
dist/ddr/launcher-17.xml \
|
||||||
|
dist/ddr/launcher-18.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -736,6 +811,12 @@ $(zipdir)/ddr-16-to-18-x64.zip: \
|
|||||||
dist/ddr/gamestart-16.bat \
|
dist/ddr/gamestart-16.bat \
|
||||||
dist/ddr/gamestart-17.bat \
|
dist/ddr/gamestart-17.bat \
|
||||||
dist/ddr/gamestart-18.bat \
|
dist/ddr/gamestart-18.bat \
|
||||||
|
dist/ddr/launcher-16.xml \
|
||||||
|
dist/ddr/launcher-17.xml \
|
||||||
|
dist/ddr/launcher-18.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
@@ -774,6 +855,11 @@ $(zipdir)/bst.zip: \
|
|||||||
dist/bst/config.bat \
|
dist/bst/config.bat \
|
||||||
dist/bst/gamestart1.bat \
|
dist/bst/gamestart1.bat \
|
||||||
dist/bst/gamestart2.bat \
|
dist/bst/gamestart2.bat \
|
||||||
|
dist/bst/launcher-01.xml \
|
||||||
|
dist/bst/launcher-02.xml \
|
||||||
|
dist/shared/ea3-ident.xml \
|
||||||
|
dist/shared/ea3-license.xml \
|
||||||
|
dist/shared/ea3-service.xml \
|
||||||
| $(zipdir)/
|
| $(zipdir)/
|
||||||
$(V)echo ... $@
|
$(V)echo ... $@
|
||||||
$(V)zip -j $@ $^
|
$(V)zip -j $@ $^
|
||||||
|
|||||||
34
dist/bst/gamestart1.bat
vendored
34
dist/bst/gamestart1.bat
vendored
@@ -1,10 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\raw mkdir dev\raw
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -K bsthook.dll -E prop/ea3-config-1.xml beatstream1.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-01.xml %*
|
||||||
34
dist/bst/gamestart2.bat
vendored
34
dist/bst/gamestart2.bat
vendored
@@ -1,10 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\raw mkdir dev\raw
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -K bsthook.dll -E prop/ea3-config-2.xml beatstream2.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-02.xml %*
|
||||||
75
dist/bst/launcher-01.xml
vendored
Normal file
75
dist/bst/launcher-01.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config-1.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>∂
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>beatstream1.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-server.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">bsthook.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/bst/launcher-02.xml
vendored
Normal file
75
dist/bst/launcher-02.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config-2.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>beatstream2.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">bsthook.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
41
dist/ddr/gamestart-12.bat
vendored
41
dist/ddr/gamestart-12.bat
vendored
@@ -1,11 +1,42 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist conf\nvram mkdir conf\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist conf\raw mkdir conf\raw
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set COM_DIR=%CONTENT_DIR%\com
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
regsvr32 /s k-clvsd.dll
|
:: Register video codecs, e.g. required for background videos
|
||||||
regsvr32 /s xactengine2_10.dll
|
regsvr32 /s %COM_DIR%\k-clvsd.dll
|
||||||
|
|
||||||
.\launcher.exe -K .\ddrhook2.dll .\ddr.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-13.xml %*
|
||||||
|
|
||||||
|
:: Unregister video codec to avoid conflicts with other/older video codecs crashing different
|
||||||
|
:: game versions, e.g. DDR X
|
||||||
|
regsvr32 /u /s %COM_DIR%\k-clvsd.dll
|
||||||
41
dist/ddr/gamestart-13.bat
vendored
41
dist/ddr/gamestart-13.bat
vendored
@@ -1,11 +1,42 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist conf\nvram mkdir conf\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist conf\raw mkdir conf\raw
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set COM_DIR=%CONTENT_DIR%\com
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
regsvr32 /s k-clvsd.dll
|
:: Register video codecs, e.g. required for background videos
|
||||||
regsvr32 /s xactengine2_10.dll
|
regsvr32 /s %COM_DIR%\k-clvsd.dll
|
||||||
|
|
||||||
.\launcher.exe -K .\ddrhook2.dll .\ddr.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-13.xml %*
|
||||||
|
|
||||||
|
:: Unregister video codec to avoid conflicts with other/older video codecs crashing different
|
||||||
|
:: game versions, e.g. DDR X
|
||||||
|
regsvr32 /u /s %COM_DIR%\k-clvsd.dll
|
||||||
46
dist/ddr/gamestart-14.bat
vendored
46
dist/ddr/gamestart-14.bat
vendored
@@ -1,14 +1,44 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist conf\nvram mkdir conf\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist conf\nvram\coin.xml copy prop\coin.xml conf\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist conf\nvram\eacoin.xml copy prop\eacoin.xml conf\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist conf\nvram\share-config.xml copy prop\share-config.xml conf\nvram\share-config.xml
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
if not exist conf\raw mkdir conf\raw
|
set COM_DIR=%CONTENT_DIR%\com
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
regsvr32 /s k-clvsd.dll
|
:: Register video codecs, e.g. required for background videos
|
||||||
regsvr32 /s xactengine2_10.dll
|
regsvr32 /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /s %COM_DIR%\xactengine2_10.dll
|
||||||
|
|
||||||
.\launcher.exe -K .\ddrhook2.dll .\mdxja_945.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-14.xml %*
|
||||||
|
|
||||||
|
:: Unregister video codec to avoid conflicts with other/older video codecs crashing different
|
||||||
|
:: game versions, e.g. DDR X
|
||||||
|
regsvr32 /u /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /u /s %COM_DIR%\xactengine2_10.dll
|
||||||
46
dist/ddr/gamestart-15.bat
vendored
46
dist/ddr/gamestart-15.bat
vendored
@@ -1,14 +1,44 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist conf\nvram mkdir conf\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist conf\nvram\coin.xml copy prop\coin.xml conf\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist conf\nvram\eacoin.xml copy prop\eacoin.xml conf\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist conf\nvram\share-config.xml copy prop\share-config.xml conf\nvram\share-config.xml
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
if not exist conf\raw mkdir conf\raw
|
set COM_DIR=%CONTENT_DIR%\com
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
regsvr32 /s k-clvsd.dll
|
:: Register video codecs, e.g. required for background videos
|
||||||
regsvr32 /s xactengine2_10.dll
|
regsvr32 /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /s %COM_DIR%\xactengine2_10.dll
|
||||||
|
|
||||||
.\launcher.exe -K .\ddrhook2.dll .\mdxja_945.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-15.xml %*
|
||||||
|
|
||||||
|
:: Unregister video codec to avoid conflicts with other/older video codecs crashing different
|
||||||
|
:: game versions, e.g. DDR X
|
||||||
|
regsvr32 /u /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /u /s %COM_DIR%\xactengine2_10.dll
|
||||||
47
dist/ddr/gamestart-16.bat
vendored
47
dist/ddr/gamestart-16.bat
vendored
@@ -1,15 +1,44 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist conf\nvram mkdir conf\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist conf\nvram\ea3-config.xml copy prop\eamuse-config.xml conf\nvram\ea3-config.xml
|
:: folders modules, data etc.
|
||||||
if not exist conf\nvram\coin.xml copy prop\coin.xml conf\nvram\coin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist conf\nvram\eacoin.xml copy prop\eacoin.xml conf\nvram\eacoin.xml
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
if not exist conf\nvram\testmode-v.xml copy prop\testmode-v.xml conf\nvram\testmode-v.xml
|
set COM_DIR=%CONTENT_DIR%\com
|
||||||
if not exist conf\raw mkdir conf\raw
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
regsvr32 /s com\k-clvsd.dll
|
:: Register video codecs, e.g. required for background videos
|
||||||
regsvr32 /s com\xactengine2_10.dll
|
regsvr32 /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /s %COM_DIR%\xactengine2_10.dll
|
||||||
|
|
||||||
.\launcher.exe -H 33554432 -K .\ddrhook2.dll .\arkmdxp3.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-17.xml %*
|
||||||
|
|
||||||
|
:: Unregister video codec to avoid conflicts with other/older video codecs crashing different
|
||||||
|
:: game versions, e.g. DDR X
|
||||||
|
regsvr32 /u /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /u /s %COM_DIR%\xactengine2_10.dll
|
||||||
47
dist/ddr/gamestart-17.bat
vendored
47
dist/ddr/gamestart-17.bat
vendored
@@ -1,15 +1,44 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist conf\nvram mkdir conf\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist conf\nvram\ea3-config.xml copy prop\eamuse-config.xml conf\nvram\ea3-config.xml
|
:: folders modules, data etc.
|
||||||
if not exist conf\nvram\coin.xml copy prop\coin.xml conf\nvram\coin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist conf\nvram\eacoin.xml copy prop\eacoin.xml conf\nvram\eacoin.xml
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
if not exist conf\nvram\testmode-v.xml copy prop\testmode-v.xml conf\nvram\testmode-v.xml
|
set COM_DIR=%CONTENT_DIR%\com
|
||||||
if not exist conf\raw mkdir conf\raw
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
regsvr32 /s com\k-clvsd.dll
|
:: Register video codecs, e.g. required for background videos
|
||||||
regsvr32 /s com\xactengine2_10.dll
|
regsvr32 /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /s %COM_DIR%\xactengine2_10.dll
|
||||||
|
|
||||||
.\launcher.exe -H 33554432 -K .\ddrhook2.dll .\arkmdxp3.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-17.xml %*
|
||||||
|
|
||||||
|
:: Unregister video codec to avoid conflicts with other/older video codecs crashing different
|
||||||
|
:: game versions, e.g. DDR X
|
||||||
|
regsvr32 /u /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /u /s %COM_DIR%\xactengine2_10.dll
|
||||||
|
|||||||
47
dist/ddr/gamestart-18.bat
vendored
47
dist/ddr/gamestart-18.bat
vendored
@@ -1,15 +1,44 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist conf\nvram mkdir conf\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist conf\nvram\ea3-config.xml copy prop\eamuse-config.xml conf\nvram\ea3-config.xml
|
:: folders modules, data etc.
|
||||||
if not exist conf\nvram\coin.xml copy prop\coin.xml conf\nvram\coin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist conf\nvram\eacoin.xml copy prop\eacoin.xml conf\nvram\eacoin.xml
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
if not exist conf\nvram\testmode-v.xml copy prop\testmode-v.xml conf\nvram\testmode-v.xml
|
set COM_DIR=%CONTENT_DIR%\com
|
||||||
if not exist conf\raw mkdir conf\raw
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
regsvr32 /s com\k-clvsd.dll
|
:: Register video codecs, e.g. required for background videos
|
||||||
regsvr32 /s com\xactengine2_10.dll
|
regsvr32 /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /s %COM_DIR%\xactengine2_10.dll
|
||||||
|
|
||||||
.\launcher.exe -H 33554432 -K .\ddrhook2.dll .\arkmdxp3.dll %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-18.xml %*
|
||||||
|
|
||||||
|
:: Unregister video codec to avoid conflicts with other/older video codecs crashing different
|
||||||
|
:: game versions, e.g. DDR X
|
||||||
|
regsvr32 /u /s %COM_DIR%\k-clvsd.dll
|
||||||
|
regsvr32 /u /s %COM_DIR%\xactengine2_10.dll
|
||||||
|
|||||||
75
dist/ddr/launcher-12.xml
vendored
Normal file
75
dist/ddr/launcher-12.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">31457280</heap_avs>
|
||||||
|
<heap_std __type="u32">31457280</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>ddr.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">ddrhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/ddr/launcher-13.xml
vendored
Normal file
75
dist/ddr/launcher-13.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">31457280</heap_avs>
|
||||||
|
<heap_std __type="u32">31457280</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>ddr.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">ddrhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/ddr/launcher-14.xml
vendored
Normal file
75
dist/ddr/launcher-14.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">31457280</heap_avs>
|
||||||
|
<heap_std __type="u32">31457280</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>mdxja_945.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">ddrhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/ddr/launcher-15.xml
vendored
Normal file
75
dist/ddr/launcher-15.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">31457280</heap_avs>
|
||||||
|
<heap_std __type="u32">31457280</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>mdxja_945.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">ddrhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
76
dist/ddr/launcher-16.xml
vendored
Normal file
76
dist/ddr/launcher-16.xml
vendored
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
<file dst="/dev/nvram/testmode-v.xml" src="/prop/testmode-v.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">33554432</heap_avs>
|
||||||
|
<heap_std __type="u32">1048576</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>arkmdxp3.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">ddrhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
76
dist/ddr/launcher-17.xml
vendored
Normal file
76
dist/ddr/launcher-17.xml
vendored
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
<file dst="/dev/nvram/testmode-v.xml" src="/prop/testmode-v.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">33554432</heap_avs>
|
||||||
|
<heap_std __type="u32">1048576</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>arkmdxp3.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">ddrhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
76
dist/ddr/launcher-18.xml
vendored
Normal file
76
dist/ddr/launcher-18.xml
vendored
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
<file dst="/dev/nvram/testmode-v.xml" src="/prop/testmode-v.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">33554432</heap_avs>
|
||||||
|
<heap_std __type="u32">1048576</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>arkmdxp3.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">ddrhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
10
dist/iidx/ea3-ident.xml
vendored
Normal file
10
dist/iidx/ea3-ident.xml
vendored
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<soft>
|
||||||
|
<model __type="str">LDJ</model>
|
||||||
|
<dest __type="str">J</dest>
|
||||||
|
<spec __type="str">A</spec>
|
||||||
|
<rev __type="str">A</rev>
|
||||||
|
<ext __type="str">2022082400</ext>
|
||||||
|
</soft>
|
||||||
|
</ea3_conf>
|
||||||
6
dist/iidx/eamuse-server.xml
vendored
Normal file
6
dist/iidx/eamuse-server.xml
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3>
|
||||||
|
<network>
|
||||||
|
<services>http://localhost</services>
|
||||||
|
</network>
|
||||||
|
</ea3>
|
||||||
36
dist/iidx/gamestart-18.bat
vendored
36
dist/iidx/gamestart-18.bat
vendored
@@ -1,14 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist d mkdir d
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist e mkdir e
|
:: folders modules, data etc.
|
||||||
if not exist f mkdir f
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
if not exist dev\raw mkdir dev\raw
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
launcher -K iidxhook4.dll bm2dx.dll --config iidxhook-18.conf %*
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-18.xml --config %BEMANITOOLS_DIR%\iidxhook-18.conf %*
|
||||||
36
dist/iidx/gamestart-19.bat
vendored
36
dist/iidx/gamestart-19.bat
vendored
@@ -1,14 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist d mkdir d
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist e mkdir e
|
:: folders modules, data etc.
|
||||||
if not exist f mkdir f
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
if not exist dev\raw mkdir dev\raw
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
launcher -K iidxhook5.dll bm2dx.dll --config iidxhook-19.conf %*
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-19.xml --config %BEMANITOOLS_DIR%\iidxhook-19.conf %*
|
||||||
34
dist/iidx/gamestart-20.bat
vendored
34
dist/iidx/gamestart-20.bat
vendored
@@ -1,10 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\raw mkdir dev\raw
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -K iidxhook6.dll bm2dx.dll --config iidxhook-20.conf %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-20.xml --config %BEMANITOOLS_DIR%\iidxhook-20.conf %*
|
||||||
34
dist/iidx/gamestart-21.bat
vendored
34
dist/iidx/gamestart-21.bat
vendored
@@ -1,10 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\raw mkdir dev\raw
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -K iidxhook7.dll bm2dx.dll --config iidxhook-21.conf %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-21.xml --config %BEMANITOOLS_DIR%\iidxhook-21.conf %*
|
||||||
34
dist/iidx/gamestart-22.bat
vendored
34
dist/iidx/gamestart-22.bat
vendored
@@ -1,10 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\raw mkdir dev\raw
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -K iidxhook7.dll bm2dx.dll --config iidxhook-22.conf %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-22.xml --config %BEMANITOOLS_DIR%\iidxhook-22.conf %*
|
||||||
34
dist/iidx/gamestart-23.bat
vendored
34
dist/iidx/gamestart-23.bat
vendored
@@ -1,10 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\raw mkdir dev\raw
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -K iidxhook7.dll bm2dx.dll --config iidxhook-23.conf %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-23.xml --config %BEMANITOOLS_DIR%\iidxhook-23.conf %*
|
||||||
34
dist/iidx/gamestart-24.bat
vendored
34
dist/iidx/gamestart-24.bat
vendored
@@ -1,10 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\raw mkdir dev\raw
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -K iidxhook7.dll bm2dx.dll --config iidxhook-24.conf %*
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-24.xml --config %BEMANITOOLS_DIR%\iidxhook-24.conf %*
|
||||||
40
dist/iidx/gamestart-25.bat
vendored
40
dist/iidx/gamestart-25.bat
vendored
@@ -1,16 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
launcher -H 134217728 -K iidxhook8.dll bm2dx.dll --config iidxhook-25.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-25.xml --config %BEMANITOOLS_DIR%\iidxhook-25.conf %*
|
||||||
40
dist/iidx/gamestart-26.bat
vendored
40
dist/iidx/gamestart-26.bat
vendored
@@ -1,16 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
launcher -H 134217728 -K iidxhook8.dll bm2dx.dll --config iidxhook-26.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-26.xml --config %BEMANITOOLS_DIR%\iidxhook-26.conf %*
|
||||||
40
dist/iidx/gamestart-27.bat
vendored
40
dist/iidx/gamestart-27.bat
vendored
@@ -1,16 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
launcher -H 134217728 -B iidxhook9.dll bm2dx.dll --config iidxhook-27.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-27.xml --config %BEMANITOOLS_DIR%\iidxhook-27.conf %*
|
||||||
40
dist/iidx/gamestart-28.bat
vendored
40
dist/iidx/gamestart-28.bat
vendored
@@ -1,16 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
launcher -H 134217728 -B iidxhook9.dll bm2dx.dll --config iidxhook-28.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-28.xml --config %BEMANITOOLS_DIR%\iidxhook-28.conf %*
|
||||||
40
dist/iidx/gamestart-29.bat
vendored
40
dist/iidx/gamestart-29.bat
vendored
@@ -1,16 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
launcher -H 134217728 -B iidxhook9.dll bm2dx.dll --config iidxhook-29.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-29.xml --config %BEMANITOOLS_DIR%\iidxhook-29.conf %*
|
||||||
40
dist/iidx/gamestart-30.bat
vendored
40
dist/iidx/gamestart-30.bat
vendored
@@ -1,16 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
modules\launcher -H 134217728 -B iidxhook9.dll bm2dx.dll --config iidxhook-30.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-30.xml --config %BEMANITOOLS_DIR%\iidxhook-30.conf %*
|
||||||
75
dist/iidx/launcher-18.xml
vendored
Normal file
75
dist/iidx/launcher-18.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook4.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/iidx/launcher-19.xml
vendored
Normal file
75
dist/iidx/launcher-19.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook5.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/iidx/launcher-20.xml
vendored
Normal file
75
dist/iidx/launcher-20.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook6.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/iidx/launcher-21.xml
vendored
Normal file
75
dist/iidx/launcher-21.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook7.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/iidx/launcher-22.xml
vendored
Normal file
75
dist/iidx/launcher-22.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook7.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/iidx/launcher-23.xml
vendored
Normal file
75
dist/iidx/launcher-23.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook7.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/iidx/launcher-24.xml
vendored
Normal file
75
dist/iidx/launcher-24.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook7.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
74
dist/iidx/launcher-25.xml
vendored
Normal file
74
dist/iidx/launcher-25.xml
vendored
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">134217728</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook8.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
74
dist/iidx/launcher-26.xml
vendored
Normal file
74
dist/iidx/launcher-26.xml
vendored
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">134217728</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">iidxhook8.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
69
dist/iidx/launcher-27.xml
vendored
Normal file
69
dist/iidx/launcher-27.xml
vendored
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">134217728</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<mounttable_selector __type="str">boot</mounttable_selector>
|
||||||
|
<mounttable>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/raw" dst="/dev/raw" opt=""/>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/nvram" dst="/dev/nvram" opt=""/>
|
||||||
|
</mounttable>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
<dll __type="str">iidxhook9.dll</dll>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
69
dist/iidx/launcher-28.xml
vendored
Normal file
69
dist/iidx/launcher-28.xml
vendored
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">134217728</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<mounttable_selector __type="str">boot</mounttable_selector>
|
||||||
|
<mounttable>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/raw" dst="/dev/raw" opt=""/>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/nvram" dst="/dev/nvram" opt=""/>
|
||||||
|
</mounttable>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
<dll __type="str">iidxhook9.dll</dll>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
69
dist/iidx/launcher-29.xml
vendored
Normal file
69
dist/iidx/launcher-29.xml
vendored
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">134217728</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<mounttable_selector __type="str">boot</mounttable_selector>
|
||||||
|
<mounttable>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/raw" dst="/dev/raw" opt=""/>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/nvram" dst="/dev/nvram" opt=""/>
|
||||||
|
</mounttable>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
<dll __type="str">iidxhook9.dll</dll>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
69
dist/iidx/launcher-30.xml
vendored
Normal file
69
dist/iidx/launcher-30.xml
vendored
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">134217728</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>bm2dx.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<mounttable_selector __type="str">boot</mounttable_selector>
|
||||||
|
<mounttable>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/raw" dst="/dev/raw" opt=""/>
|
||||||
|
<vfs name="boot" fstype="fs" src="dev/nvram" dst="/dev/nvram" opt=""/>
|
||||||
|
</mounttable>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
<dll __type="str">iidxhook9.dll</dll>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
7
dist/iidx/pcbid.xml
vendored
Normal file
7
dist/iidx/pcbid.xml
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<id>
|
||||||
|
<softid __type="str">0101020304050607083F</softid>
|
||||||
|
<pcbid __type="str">0101020304050607083F</pcbid>
|
||||||
|
</id>
|
||||||
|
</ea3_conf>
|
||||||
10
dist/jb/ea3-ident.xml
vendored
Normal file
10
dist/jb/ea3-ident.xml
vendored
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<soft>
|
||||||
|
<model __type="str">LDJ</model>
|
||||||
|
<dest __type="str">J</dest>
|
||||||
|
<spec __type="str">A</spec>
|
||||||
|
<rev __type="str">A</rev>
|
||||||
|
<ext __type="str">2022082400</ext>
|
||||||
|
</soft>
|
||||||
|
</ea3_conf>
|
||||||
6
dist/jb/eamuse-server.xml
vendored
Normal file
6
dist/jb/eamuse-server.xml
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3>
|
||||||
|
<network>
|
||||||
|
<services>http://localhost</services>
|
||||||
|
</network>
|
||||||
|
</ea3>
|
||||||
35
dist/jb/gamestart-03.bat
vendored
35
dist/jb/gamestart-03.bat
vendored
@@ -1,11 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\ea3-config.xml copy prop\ea3-config.xml dev\nvram\ea3-config.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
if not exist dev\raw mkdir dev\raw
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -H 33554432 -K jbhook2.dll jubeat.dll -v
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-03.xml -v %*
|
||||||
35
dist/jb/gamestart-04.bat
vendored
35
dist/jb/gamestart-04.bat
vendored
@@ -1,11 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
cd /d %~dp0
|
cd /d %~dp0
|
||||||
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
if not exist dev\nvram\ea3-config.xml copy prop\ea3-config.xml dev\nvram\ea3-config.xml
|
:: folders modules, data etc.
|
||||||
if not exist dev\nvram\coin.xml copy prop\defaults\coin.xml dev\nvram\coin.xml
|
set CONTENT_DIR=%CD%\..
|
||||||
if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin.xml
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
if not exist dev\raw mkdir dev\raw
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
launcher -H 33554432 -K jbhook3.dll jubeat.dll
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-04.xml %*
|
||||||
75
dist/jb/launcher-03.xml
vendored
Normal file
75
dist/jb/launcher-03.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">33554432</heap_avs>
|
||||||
|
<heap_std __type="u32">33554432</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>jubeat.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">jbhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
75
dist/jb/launcher-04.xml
vendored
Normal file
75
dist/jb/launcher-04.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">33554432</heap_avs>
|
||||||
|
<heap_std __type="u32">33554432</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>jubeat.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">jbhook3.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
7
dist/jb/pcbid.xml
vendored
Normal file
7
dist/jb/pcbid.xml
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<id>
|
||||||
|
<softid __type="str">0101020304050607083F</softid>
|
||||||
|
<pcbid __type="str">0101020304050607083F</pcbid>
|
||||||
|
</id>
|
||||||
|
</ea3_conf>
|
||||||
10
dist/sdvx/ea3-ident.xml
vendored
Normal file
10
dist/sdvx/ea3-ident.xml
vendored
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<soft>
|
||||||
|
<model __type="str">LDJ</model>
|
||||||
|
<dest __type="str">J</dest>
|
||||||
|
<spec __type="str">A</spec>
|
||||||
|
<rev __type="str">A</rev>
|
||||||
|
<ext __type="str">2022082400</ext>
|
||||||
|
</soft>
|
||||||
|
</ea3_conf>
|
||||||
6
dist/sdvx/eamuse-server.xml
vendored
Normal file
6
dist/sdvx/eamuse-server.xml
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3>
|
||||||
|
<network>
|
||||||
|
<services>http://localhost</services>
|
||||||
|
</network>
|
||||||
|
</ea3>
|
||||||
35
dist/sdvx/gamestart.bat
vendored
35
dist/sdvx/gamestart.bat
vendored
@@ -8,3 +8,38 @@ if not exist dev\nvram\eacoin.xml copy prop\defaults\eacoin.xml dev\nvram\eacoin
|
|||||||
if not exist dev\raw mkdir dev\raw
|
if not exist dev\raw mkdir dev\raw
|
||||||
|
|
||||||
launcher -K sdvxhook.dll soundvoltex.dll %*
|
launcher -K sdvxhook.dll soundvoltex.dll %*
|
||||||
|
|
||||||
|
@echo off
|
||||||
|
|
||||||
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
|
>nul 2>&1 net session
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher.xml %*
|
||||||
75
dist/sdvx/launcher.xml
vendored
Normal file
75
dist/sdvx/launcher.xml
vendored
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">16777216</heap_avs>
|
||||||
|
<heap_std __type="u32">16777216</heap_std>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>soundvoltex.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">sdvxhook.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
7
dist/sdvx/pcbid.xml
vendored
Normal file
7
dist/sdvx/pcbid.xml
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<id>
|
||||||
|
<softid __type="str">0101020304050607083F</softid>
|
||||||
|
<pcbid __type="str">0101020304050607083F</pcbid>
|
||||||
|
</id>
|
||||||
|
</ea3_conf>
|
||||||
10
dist/sdvx5/ea3-ident.xml
vendored
Normal file
10
dist/sdvx5/ea3-ident.xml
vendored
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<soft>
|
||||||
|
<model __type="str">LDJ</model>
|
||||||
|
<dest __type="str">J</dest>
|
||||||
|
<spec __type="str">A</spec>
|
||||||
|
<rev __type="str">A</rev>
|
||||||
|
<ext __type="str">2022082400</ext>
|
||||||
|
</soft>
|
||||||
|
</ea3_conf>
|
||||||
6
dist/sdvx5/eamuse-server.xml
vendored
Normal file
6
dist/sdvx5/eamuse-server.xml
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3>
|
||||||
|
<network>
|
||||||
|
<services>http://localhost</services>
|
||||||
|
</network>
|
||||||
|
</ea3>
|
||||||
41
dist/sdvx5/gamestart-cn.bat
vendored
41
dist/sdvx5/gamestart-cn.bat
vendored
@@ -1,17 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\c.dest echo $null >> dev\raw\c.dest
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
launcher -H 268435456 -K sdvxhook2-cn.dll soundvoltex.dll --config sdvxhook2-cn.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher-cn.xml --config %BEMANITOOLS_DIR%\sdvxhook2-cn.conf %*
|
||||||
40
dist/sdvx5/gamestart.bat
vendored
40
dist/sdvx5/gamestart.bat
vendored
@@ -1,16 +1,34 @@
|
|||||||
@echo off
|
@echo off
|
||||||
cd /d %~dp0
|
|
||||||
|
|
||||||
if not exist dev mkdir dev
|
:: Game doesn't work properly when not run with administrator privileges
|
||||||
if not exist dev\e mkdir dev\e
|
>nul 2>&1 net session
|
||||||
if not exist dev\g mkdir dev\g
|
|
||||||
if not exist dev\nvram mkdir dev\nvram
|
|
||||||
if not exist dev\raw mkdir dev\raw
|
|
||||||
if not exist dev\raw\log mkdir dev\raw\log
|
|
||||||
if not exist dev\raw\fscache mkdir dev\raw\fscache
|
|
||||||
|
|
||||||
for /R prop\defaults %%D in (*.*) do (
|
if %errorlevel% neq 0 (
|
||||||
if not exist dev\nvram\%%~nxD copy /y prop\defaults\%%~nxD dev\nvram
|
echo This script requires administrative privileges.
|
||||||
|
echo Please run the script as an administrator.
|
||||||
|
pause
|
||||||
|
exit 1
|
||||||
)
|
)
|
||||||
|
|
||||||
launcher -H 268435456 -K sdvxhook2.dll soundvoltex.dll --config sdvxhook2.conf %*
|
:: Script expects to be located in a subfolder "bemanitools" in the root folder
|
||||||
|
:: (contents/) next to the folders modules, data etc.
|
||||||
|
cd /d %~dp0
|
||||||
|
|
||||||
|
:: Script expects to be located in the root folder (contents/) next to the
|
||||||
|
:: folders modules, data etc.
|
||||||
|
set CONTENT_DIR=%CD%\..
|
||||||
|
set BEMANITOOLS_DIR=%CONTENT_DIR%\bemanitools
|
||||||
|
set MODULES_DIR=%CONTENT_DIR%\modules
|
||||||
|
|
||||||
|
:: Keep that data vanilla, no need to copy these around anymore
|
||||||
|
:: Just add them to the env PATH so launcher can find the libs and game executable
|
||||||
|
:: Remark: This also requires admin privileges to propage correctly to launcher
|
||||||
|
set PATH=^
|
||||||
|
%MODULES_DIR%;^
|
||||||
|
%BEMANITOOLS_DIR%;^
|
||||||
|
%PATH%
|
||||||
|
|
||||||
|
:: Current working dir is the game's root folder
|
||||||
|
cd /d %CONTENT_DIR%
|
||||||
|
|
||||||
|
%BEMANITOOLS_DIR%\launcher %BEMANITOOLS_DIR%\launcher.xml --config %BEMANITOOLS_DIR%\sdvxhook2.conf %*
|
||||||
74
dist/sdvx5/launcher-cn.xml
vendored
Normal file
74
dist/sdvx5/launcher-cn.xml
vendored
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">268435456</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>soundvoltex.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">sdvxhook2-cn.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
74
dist/sdvx5/launcher.xml
vendored
Normal file
74
dist/sdvx5/launcher.xml
vendored
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<launcher version="1">
|
||||||
|
<bootstrap>
|
||||||
|
<selector __type="str">bemanitools_local_fs</selector>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<startup>
|
||||||
|
<bemanitools_local_fs>
|
||||||
|
<default>
|
||||||
|
<file dst="/dev/nvram/ea3-config.xml" src="/prop/eamuse-config.xml" />
|
||||||
|
<file dst="/dev/nvram/coin.xml" src="/prop/coin.xml" />
|
||||||
|
<file dst="/dev/nvram/eacoin.xml" src="/prop/eacoin.xml" />
|
||||||
|
</default>
|
||||||
|
<boot>
|
||||||
|
<file>prop/avs-config.xml</file>
|
||||||
|
<heap_avs __type="u32">268435456</heap_avs>
|
||||||
|
</boot>
|
||||||
|
<log>
|
||||||
|
<level>info</level>
|
||||||
|
</log>
|
||||||
|
<eamuse>
|
||||||
|
<file>/dev/nvram/ea3-config.xml</file>
|
||||||
|
</eamuse>
|
||||||
|
<component>
|
||||||
|
<file>soundvoltex.dll</file>
|
||||||
|
<param></param>
|
||||||
|
</component>
|
||||||
|
</bemanitools_local_fs>
|
||||||
|
</startup>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</bootstrap>
|
||||||
|
<ea3_ident>
|
||||||
|
<config kind="file">bemanitools/ea3-ident.xml</config>
|
||||||
|
<config kind="file">bemanitools/ea3-license.xml</config>
|
||||||
|
</ea3_ident>
|
||||||
|
<avs>
|
||||||
|
<config kind="inline">
|
||||||
|
<config>
|
||||||
|
<fs>
|
||||||
|
<root>
|
||||||
|
<device __type="str">.</device>
|
||||||
|
</root>
|
||||||
|
<nvram>
|
||||||
|
<device __type="str">dev/nvram</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</nvram>
|
||||||
|
<raw>
|
||||||
|
<device __type="str">dev/raw</device>
|
||||||
|
<fstype __type="str">fs</fstype>
|
||||||
|
<option __type="str">vf=1,posix=1</option>
|
||||||
|
</raw>
|
||||||
|
</fs>
|
||||||
|
</config>
|
||||||
|
</config>
|
||||||
|
</avs>
|
||||||
|
<eamuse>
|
||||||
|
<config kind="file">bemanitools/ea3-service.xml</config>
|
||||||
|
</eamuse>
|
||||||
|
<hook>
|
||||||
|
<hook_dlls>
|
||||||
|
<dll __type="str">sdvxhook2.dll</dll>
|
||||||
|
</hook_dlls>
|
||||||
|
<before_hook_dlls>
|
||||||
|
</before_hook_dlls>
|
||||||
|
<iat_hook_dlls>
|
||||||
|
</iat_hook_dlls>
|
||||||
|
</hook>
|
||||||
|
<debug>
|
||||||
|
<remote_debugger __type="bool">0</remote_debugger>
|
||||||
|
<log_property_configs __type="bool">0</log_property_configs>
|
||||||
|
</debug>
|
||||||
|
</launcher>
|
||||||
7
dist/sdvx5/pcbid.xml
vendored
Normal file
7
dist/sdvx5/pcbid.xml
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<id>
|
||||||
|
<softid __type="str">0101020304050607083F</softid>
|
||||||
|
<pcbid __type="str">0101020304050607083F</pcbid>
|
||||||
|
</id>
|
||||||
|
</ea3_conf>
|
||||||
11
dist/shared/ea3-ident.xml
vendored
Normal file
11
dist/shared/ea3-ident.xml
vendored
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<soft>
|
||||||
|
<!-- USER TODO: Change these accordingly to match the specifications of the game and version you are running -->
|
||||||
|
<model __type="str">000</model>
|
||||||
|
<dest __type="str">A</dest>
|
||||||
|
<spec __type="str">A</spec>
|
||||||
|
<rev __type="str">A</rev>
|
||||||
|
<ext __type="str">1969032100</ext>
|
||||||
|
</soft>
|
||||||
|
</ea3_conf>
|
||||||
8
dist/shared/ea3-license.xml
vendored
Normal file
8
dist/shared/ea3-license.xml
vendored
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3_conf>
|
||||||
|
<id>
|
||||||
|
<!-- USER TODO: Change accordingly to comply with your favorite eamuse service -->
|
||||||
|
<softid __type="str">0101020304050607083F</softid>
|
||||||
|
<pcbid __type="str">0101020304050607083F</pcbid>
|
||||||
|
</id>
|
||||||
|
</ea3_conf>
|
||||||
7
dist/shared/ea3-service.xml
vendored
Normal file
7
dist/shared/ea3-service.xml
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="Shift-JIS"?>
|
||||||
|
<ea3>
|
||||||
|
<network>
|
||||||
|
<!-- USER TODO: Change to your favorite eamuse service URL -->
|
||||||
|
<services>http://localhost</services>
|
||||||
|
</network>
|
||||||
|
</ea3>
|
||||||
@@ -5,12 +5,12 @@ ldflags_inject := \
|
|||||||
-lpsapi \
|
-lpsapi \
|
||||||
|
|
||||||
libs_inject := \
|
libs_inject := \
|
||||||
|
core \
|
||||||
util \
|
util \
|
||||||
|
|
||||||
src_inject := \
|
src_inject := \
|
||||||
main.c \
|
main.c \
|
||||||
debugger.c \
|
debugger.c \
|
||||||
logger.c \
|
|
||||||
options.c \
|
options.c \
|
||||||
version.c \
|
version.c \
|
||||||
|
|
||||||
|
|||||||
@@ -8,10 +8,11 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
#include "inject/debugger.h"
|
#include "core/log-bt.h"
|
||||||
#include "inject/logger.h"
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "inject/debugger.h"
|
||||||
|
|
||||||
#include "util/log.h"
|
|
||||||
#include "util/mem.h"
|
#include "util/mem.h"
|
||||||
#include "util/proc.h"
|
#include "util/proc.h"
|
||||||
#include "util/signal.h"
|
#include "util/signal.h"
|
||||||
@@ -178,6 +179,7 @@ static bool log_debug_str(HANDLE process, const OUTPUT_DEBUG_STRING_INFO *odsi)
|
|||||||
log_assert(odsi);
|
log_assert(odsi);
|
||||||
|
|
||||||
char *debug_str;
|
char *debug_str;
|
||||||
|
size_t debug_str_len;
|
||||||
|
|
||||||
if (odsi->fUnicode) {
|
if (odsi->fUnicode) {
|
||||||
debug_str = read_debug_wstr(process, odsi);
|
debug_str = read_debug_wstr(process, odsi);
|
||||||
@@ -186,7 +188,9 @@ static bool log_debug_str(HANDLE process, const OUTPUT_DEBUG_STRING_INFO *odsi)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (debug_str) {
|
if (debug_str) {
|
||||||
logger_log(debug_str);
|
debug_str_len = strlen(debug_str);
|
||||||
|
|
||||||
|
core_log_bt_direct_sink_write(debug_str, debug_str_len);
|
||||||
|
|
||||||
free(debug_str);
|
free(debug_str);
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
@@ -1,217 +0,0 @@
|
|||||||
#define LOG_MODULE "inject-logger"
|
|
||||||
|
|
||||||
#include <stdbool.h>
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <string.h>
|
|
||||||
#include <time.h>
|
|
||||||
#include <windows.h>
|
|
||||||
|
|
||||||
#include "inject/logger.h"
|
|
||||||
#include "inject/version.h"
|
|
||||||
|
|
||||||
#include "util/log.h"
|
|
||||||
|
|
||||||
static FILE *log_file;
|
|
||||||
static HANDLE log_mutex;
|
|
||||||
|
|
||||||
static const char *logger_get_formatted_timestamp(void)
|
|
||||||
{
|
|
||||||
static char buffer[64];
|
|
||||||
time_t cur = 0;
|
|
||||||
struct tm *tm = NULL;
|
|
||||||
|
|
||||||
cur = time(NULL);
|
|
||||||
tm = localtime(&cur);
|
|
||||||
|
|
||||||
strftime(buffer, sizeof(buffer), "[%Y/%m/%d %H:%M:%S] ", tm);
|
|
||||||
|
|
||||||
return buffer;
|
|
||||||
}
|
|
||||||
|
|
||||||
static char logger_console_determine_color(const char *str)
|
|
||||||
{
|
|
||||||
log_assert(str);
|
|
||||||
|
|
||||||
/* Add some color to make spotting warnings/errors easier.
|
|
||||||
Based on debug output level identifier. */
|
|
||||||
|
|
||||||
/* Avoids colored output on strings like "Windows" */
|
|
||||||
if (str[1] != ':') {
|
|
||||||
return 15;
|
|
||||||
}
|
|
||||||
|
|
||||||
switch (str[0]) {
|
|
||||||
/* green */
|
|
||||||
case 'M':
|
|
||||||
return 10;
|
|
||||||
/* blue */
|
|
||||||
case 'I':
|
|
||||||
return 9;
|
|
||||||
/* yellow */
|
|
||||||
case 'W':
|
|
||||||
return 14;
|
|
||||||
/* red */
|
|
||||||
case 'F':
|
|
||||||
return 12;
|
|
||||||
/* default console color */
|
|
||||||
default:
|
|
||||||
return 15;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static size_t logger_msg_coloring_len(const char *str)
|
|
||||||
{
|
|
||||||
// Expected format example: "I:boot: my log message"
|
|
||||||
|
|
||||||
const char *ptr;
|
|
||||||
size_t len;
|
|
||||||
int colon_count;
|
|
||||||
|
|
||||||
ptr = str;
|
|
||||||
len = 0;
|
|
||||||
colon_count = 0;
|
|
||||||
|
|
||||||
while (true) {
|
|
||||||
// End of string = invalid log format
|
|
||||||
if (*ptr == '\0') {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (*ptr == ':') {
|
|
||||||
colon_count++;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (colon_count == 2) {
|
|
||||||
// Skip current colon, next char is a space
|
|
||||||
return len + 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
len++;
|
|
||||||
ptr++;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void logger_console(
|
|
||||||
void *ctx, const char *chars, size_t nchars, const char *timestamp_str)
|
|
||||||
{
|
|
||||||
char color;
|
|
||||||
size_t color_len;
|
|
||||||
// See "util/log.c", has to align
|
|
||||||
char buffer[65536];
|
|
||||||
char tmp;
|
|
||||||
|
|
||||||
color_len = logger_msg_coloring_len(chars);
|
|
||||||
|
|
||||||
// Check if we could detect which part to color, otherwise just write the
|
|
||||||
// whole log message without any coloring logic
|
|
||||||
if (color_len > 0) {
|
|
||||||
color = logger_console_determine_color(chars);
|
|
||||||
|
|
||||||
strcpy(buffer, chars);
|
|
||||||
|
|
||||||
// Mask start of log message for coloring
|
|
||||||
tmp = buffer[color_len];
|
|
||||||
buffer[color_len] = '\0';
|
|
||||||
|
|
||||||
printf("%s", timestamp_str);
|
|
||||||
SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), color);
|
|
||||||
printf("%s", buffer);
|
|
||||||
SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 15);
|
|
||||||
|
|
||||||
// Write actual message non colored
|
|
||||||
buffer[color_len] = tmp;
|
|
||||||
printf("%s", buffer + color_len);
|
|
||||||
} else {
|
|
||||||
printf("%s", chars);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static void logger_file(
|
|
||||||
void *ctx, const char *chars, size_t nchars, const char *timestamp_str)
|
|
||||||
{
|
|
||||||
if (ctx) {
|
|
||||||
fwrite(timestamp_str, 1, strlen(timestamp_str), (FILE *) ctx);
|
|
||||||
fwrite(chars, 1, nchars, (FILE *) ctx);
|
|
||||||
fflush((FILE *) ctx);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static void logger_writer(void *ctx, const char *chars, size_t nchars)
|
|
||||||
{
|
|
||||||
const char *timestamp_str;
|
|
||||||
|
|
||||||
// Different threads logging the same destination, e.g. debugger thread,
|
|
||||||
// main thread
|
|
||||||
|
|
||||||
WaitForSingleObject(log_mutex, INFINITE);
|
|
||||||
|
|
||||||
timestamp_str = logger_get_formatted_timestamp();
|
|
||||||
|
|
||||||
logger_console(ctx, chars, nchars, timestamp_str);
|
|
||||||
logger_file(ctx, chars, nchars, timestamp_str);
|
|
||||||
|
|
||||||
ReleaseMutex(log_mutex);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void logger_log_header()
|
|
||||||
{
|
|
||||||
log_info(
|
|
||||||
"\n"
|
|
||||||
" _ _ _ \n"
|
|
||||||
" (_)_ __ (_) ___ ___| |_ \n"
|
|
||||||
" | | '_ \\ | |/ _ \\/ __| __|\n"
|
|
||||||
" | | | | || | __/ (__| |_ \n"
|
|
||||||
" |_|_| |_|/ |\\___|\\___|\\__|\n"
|
|
||||||
" |__/ ");
|
|
||||||
|
|
||||||
log_info(
|
|
||||||
"Inject build date %s, gitrev %s", inject_build_date, inject_gitrev);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool logger_init(const char *log_file_path)
|
|
||||||
{
|
|
||||||
if (log_file_path) {
|
|
||||||
log_file = fopen(log_file_path, "w+");
|
|
||||||
} else {
|
|
||||||
log_file = NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
log_to_writer(logger_writer, log_file);
|
|
||||||
|
|
||||||
logger_log_header();
|
|
||||||
|
|
||||||
if (log_file_path) {
|
|
||||||
log_info("Log file: %s", log_file_path);
|
|
||||||
|
|
||||||
if (!log_file) {
|
|
||||||
log_warning(
|
|
||||||
"ERROR: Opening log file %s failed: %s",
|
|
||||||
log_file_path,
|
|
||||||
strerror(errno));
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
log_mutex = CreateMutex(NULL, FALSE, NULL);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
void logger_log(const char *str)
|
|
||||||
{
|
|
||||||
logger_writer(log_file, str, strlen(str));
|
|
||||||
}
|
|
||||||
|
|
||||||
void logger_finit()
|
|
||||||
{
|
|
||||||
log_misc("Logger finit");
|
|
||||||
|
|
||||||
if (log_file) {
|
|
||||||
fclose(log_file);
|
|
||||||
}
|
|
||||||
|
|
||||||
CloseHandle(log_mutex);
|
|
||||||
}
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
#include <stdbool.h>
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Initialize inject's logger backend.
|
|
||||||
*
|
|
||||||
* This takes care of hooking and merging the different log
|
|
||||||
* streams, e.g. inject's local logging and inject's debugger
|
|
||||||
* receiving remote logging events.
|
|
||||||
*
|
|
||||||
* @param log_file_path Path to the file to log to or NULL to
|
|
||||||
* disable.
|
|
||||||
*/
|
|
||||||
bool logger_init(const char *log_file_path);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Write a message to the logging backend.
|
|
||||||
*
|
|
||||||
* This is used by inject's debugger to redirect log messages
|
|
||||||
* recevied from the remote process.
|
|
||||||
*
|
|
||||||
* @param str String to log
|
|
||||||
*/
|
|
||||||
void logger_log(const char *str);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Shutdown and cleanup the logging backend.
|
|
||||||
*/
|
|
||||||
void logger_finit();
|
|
||||||
@@ -1,3 +1,5 @@
|
|||||||
|
#define LOG_MODULE "inject"
|
||||||
|
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
@@ -10,18 +12,67 @@
|
|||||||
#include "cconfig/cconfig-util.h"
|
#include "cconfig/cconfig-util.h"
|
||||||
#include "cconfig/cmd.h"
|
#include "cconfig/cmd.h"
|
||||||
|
|
||||||
|
#include "core/log-bt-ext.h"
|
||||||
|
#include "core/log-bt.h"
|
||||||
|
#include "core/log-sink-file.h"
|
||||||
|
#include "core/log-sink-list.h"
|
||||||
|
#include "core/log-sink-mutex.h"
|
||||||
|
#include "core/log-sink-std.h"
|
||||||
|
#include "core/log.h"
|
||||||
|
#include "core/thread-crt-ext.h"
|
||||||
|
#include "core/thread-crt.h"
|
||||||
|
#include "core/thread.h"
|
||||||
|
|
||||||
#include "inject/debugger.h"
|
#include "inject/debugger.h"
|
||||||
#include "inject/logger.h"
|
|
||||||
#include "inject/options.h"
|
#include "inject/options.h"
|
||||||
#include "inject/version.h"
|
#include "inject/version.h"
|
||||||
|
|
||||||
#include "util/cmdline.h"
|
#include "util/cmdline.h"
|
||||||
#include "util/log.h"
|
|
||||||
#include "util/mem.h"
|
#include "util/mem.h"
|
||||||
#include "util/os.h"
|
#include "util/os.h"
|
||||||
#include "util/signal.h"
|
#include "util/signal.h"
|
||||||
#include "util/str.h"
|
#include "util/str.h"
|
||||||
|
|
||||||
|
static void _inject_log_header()
|
||||||
|
{
|
||||||
|
log_info(
|
||||||
|
"\n"
|
||||||
|
" _ _ _ \n"
|
||||||
|
" (_)_ __ (_) ___ ___| |_ \n"
|
||||||
|
" | | '_ \\ | |/ _ \\/ __| __|\n"
|
||||||
|
" | | | | || | __/ (__| |_ \n"
|
||||||
|
" |_|_| |_|/ |\\___|\\___|\\__|\n"
|
||||||
|
" |__/ ");
|
||||||
|
|
||||||
|
log_info(
|
||||||
|
"inject build date %s, gitrev %s", inject_build_date, inject_gitrev);
|
||||||
|
}
|
||||||
|
|
||||||
|
void _inject_log_init(
|
||||||
|
const char *log_file_path, enum core_log_bt_log_level level)
|
||||||
|
{
|
||||||
|
struct core_log_sink sinks[2];
|
||||||
|
struct core_log_sink sink_composed;
|
||||||
|
struct core_log_sink sink_mutex;
|
||||||
|
|
||||||
|
core_log_bt_ext_impl_set();
|
||||||
|
|
||||||
|
if (log_file_path) {
|
||||||
|
core_log_sink_std_out_open(true, &sinks[0]);
|
||||||
|
core_log_sink_file_open(log_file_path, false, true, 10, &sinks[1]);
|
||||||
|
core_log_sink_list_open(sinks, 2, &sink_composed);
|
||||||
|
} else {
|
||||||
|
core_log_sink_std_out_open(true, &sink_composed);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Different threads logging the same destination, e.g. debugger thread,
|
||||||
|
// main thread
|
||||||
|
core_log_sink_mutex_open(&sink_composed, &sink_mutex);
|
||||||
|
|
||||||
|
core_log_bt_init(&sink_mutex);
|
||||||
|
core_log_bt_level_set(level);
|
||||||
|
}
|
||||||
|
|
||||||
static bool init_options(int argc, char **argv, struct options *options)
|
static bool init_options(int argc, char **argv, struct options *options)
|
||||||
{
|
{
|
||||||
options_init(options);
|
options_init(options);
|
||||||
@@ -145,7 +196,7 @@ static bool inject_hook_dlls(uint32_t hooks, char **argv)
|
|||||||
static void signal_shutdown_handler()
|
static void signal_shutdown_handler()
|
||||||
{
|
{
|
||||||
debugger_finit(true);
|
debugger_finit(true);
|
||||||
logger_finit();
|
core_log_bt_fini();
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int argc, char **argv)
|
int main(int argc, char **argv)
|
||||||
@@ -160,9 +211,14 @@ int main(int argc, char **argv)
|
|||||||
goto init_options_fail;
|
goto init_options_fail;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!logger_init(strlen(options.log_file) > 0 ? options.log_file : NULL)) {
|
core_thread_crt_ext_impl_set();
|
||||||
goto init_logger_fail;
|
// TODO expose log level
|
||||||
}
|
|
||||||
|
_inject_log_init(
|
||||||
|
strlen(options.log_file) > 0 ? options.log_file : NULL,
|
||||||
|
CORE_LOG_BT_LOG_LEVEL_MISC);
|
||||||
|
|
||||||
|
_inject_log_header();
|
||||||
|
|
||||||
os_version_log();
|
os_version_log();
|
||||||
|
|
||||||
@@ -214,7 +270,7 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
debugger_finit(false);
|
debugger_finit(false);
|
||||||
|
|
||||||
logger_finit();
|
core_log_bt_fini();
|
||||||
|
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
|
|
||||||
@@ -226,7 +282,7 @@ inject_hook_dlls_fail:
|
|||||||
debugger_init_fail:
|
debugger_init_fail:
|
||||||
verify_2_fail:
|
verify_2_fail:
|
||||||
verify_fail:
|
verify_fail:
|
||||||
logger_finit();
|
core_log_bt_fini();
|
||||||
|
|
||||||
init_logger_fail:
|
init_logger_fail:
|
||||||
init_options_fail:
|
init_options_fail:
|
||||||
|
|||||||
@@ -3,22 +3,34 @@ rc_launcher := launcher.rc
|
|||||||
|
|
||||||
ldflags_launcher := \
|
ldflags_launcher := \
|
||||||
-mconsole \
|
-mconsole \
|
||||||
|
-ldbghelp \
|
||||||
|
|
||||||
deplibs_launcher := \
|
deplibs_launcher := \
|
||||||
avs \
|
avs \
|
||||||
avs-ea3 \
|
avs-ea3 \
|
||||||
|
|
||||||
libs_launcher := \
|
libs_launcher := \
|
||||||
|
avs-util \
|
||||||
|
core \
|
||||||
hook \
|
hook \
|
||||||
util \
|
util \
|
||||||
|
|
||||||
src_launcher := \
|
src_launcher := \
|
||||||
avs-context.c \
|
avs-config.c \
|
||||||
ea3-config.c \
|
avs.c \
|
||||||
|
bootstrap-config.c \
|
||||||
|
bootstrap.c \
|
||||||
|
debug.c \
|
||||||
|
ea3-ident-config.c \
|
||||||
|
eamuse-config.c \
|
||||||
|
eamuse.c \
|
||||||
|
hook.c \
|
||||||
|
launcher-config.c \
|
||||||
|
launcher.c \
|
||||||
main.c \
|
main.c \
|
||||||
module.c \
|
module.c \
|
||||||
options.c \
|
options.c \
|
||||||
property.c \
|
property-util.c \
|
||||||
stubs.c \
|
stubs.c \
|
||||||
version.c \
|
version.c \
|
||||||
|
|
||||||
|
|||||||
773
src/main/launcher/avs-config.c
Normal file
773
src/main/launcher/avs-config.c
Normal file
@@ -0,0 +1,773 @@
|
|||||||
|
#define LOG_MODULE "avs-config"
|
||||||
|
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
|
#include "avs-util/error.h"
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
#include "launcher/avs-config.h"
|
||||||
|
#include "launcher/property-util.h"
|
||||||
|
|
||||||
|
#include "util/str.h"
|
||||||
|
|
||||||
|
#define AVS_CONFIG_ROOT_NODE "/config"
|
||||||
|
|
||||||
|
static const char *_avs_config_property_mounttable_path =
|
||||||
|
"/config/fs/mounttable";
|
||||||
|
|
||||||
|
static void _avs_config_node_vfs_copy(
|
||||||
|
struct property *parent_property,
|
||||||
|
struct property_node *parent,
|
||||||
|
struct property_node *source)
|
||||||
|
{
|
||||||
|
// Use max path size to fit dst and src fs paths
|
||||||
|
char data[MAX_PATH];
|
||||||
|
|
||||||
|
// Remark: Using property_node_clone doesn't work here
|
||||||
|
// Cloning non-deep only clones the vfs node. Cloning deep doesn't seem
|
||||||
|
// to work with arbitrary attributes that don't follow the general
|
||||||
|
// design of a property structure. This seems to require clear typing for
|
||||||
|
// nodes in order to allow property_node_clone to work
|
||||||
|
|
||||||
|
// Ignore errors and default to empty
|
||||||
|
memset(data, 0, sizeof(data));
|
||||||
|
property_node_refer(
|
||||||
|
NULL, source, "name@", PROPERTY_TYPE_ATTR, data, sizeof(data));
|
||||||
|
property_util_node_attribute_replace(
|
||||||
|
parent_property, parent, "name@", data);
|
||||||
|
|
||||||
|
memset(data, 0, sizeof(data));
|
||||||
|
property_node_refer(
|
||||||
|
NULL, source, "fstype@", PROPERTY_TYPE_ATTR, data, sizeof(data));
|
||||||
|
property_util_node_attribute_replace(
|
||||||
|
parent_property, parent, "fstype@", data);
|
||||||
|
|
||||||
|
memset(data, 0, sizeof(data));
|
||||||
|
property_node_refer(
|
||||||
|
NULL, source, "src@", PROPERTY_TYPE_ATTR, data, sizeof(data));
|
||||||
|
property_util_node_attribute_replace(parent_property, parent, "src@", data);
|
||||||
|
|
||||||
|
memset(data, 0, sizeof(data));
|
||||||
|
property_node_refer(
|
||||||
|
NULL, source, "dst@", PROPERTY_TYPE_ATTR, data, sizeof(data));
|
||||||
|
property_util_node_attribute_replace(parent_property, parent, "dst@", data);
|
||||||
|
|
||||||
|
memset(data, 0, sizeof(data));
|
||||||
|
property_node_refer(
|
||||||
|
NULL, source, "opt@", PROPERTY_TYPE_ATTR, data, sizeof(data));
|
||||||
|
property_util_node_attribute_replace(parent_property, parent, "opt@", data);
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool _avs_config_mounttable_vfs_nodes_merge_strategy_do(
|
||||||
|
struct property *parent_property,
|
||||||
|
struct property_node *parent,
|
||||||
|
struct property_node *source,
|
||||||
|
void *ctx,
|
||||||
|
property_util_node_merge_recursion_do_t node_merge_recursion_do)
|
||||||
|
{
|
||||||
|
struct property_node *parent_child;
|
||||||
|
struct property_node *source_child;
|
||||||
|
|
||||||
|
char parent_child_name[PROPERTY_NODE_NAME_SIZE_MAX];
|
||||||
|
char name_parent[PROPERTY_NODE_ATTR_NAME_SIZE_MAX];
|
||||||
|
char dst_parent[PROPERTY_NODE_ATTR_NAME_SIZE_MAX];
|
||||||
|
|
||||||
|
char source_child_name[PROPERTY_NODE_NAME_SIZE_MAX];
|
||||||
|
char name_source[PROPERTY_NODE_ATTR_NAME_SIZE_MAX];
|
||||||
|
char dst_source[PROPERTY_NODE_ATTR_NAME_SIZE_MAX];
|
||||||
|
|
||||||
|
bool node_consumed;
|
||||||
|
bool found_parent;
|
||||||
|
|
||||||
|
source_child = property_node_traversal(source, TRAVERSE_FIRST_CHILD);
|
||||||
|
|
||||||
|
node_consumed = false;
|
||||||
|
|
||||||
|
while (source_child) {
|
||||||
|
property_node_name(
|
||||||
|
source_child, source_child_name, sizeof(source_child_name));
|
||||||
|
|
||||||
|
if (str_eq(source_child_name, "vfs")) {
|
||||||
|
node_consumed = true;
|
||||||
|
|
||||||
|
parent_child =
|
||||||
|
property_node_traversal(parent, TRAVERSE_FIRST_CHILD);
|
||||||
|
|
||||||
|
found_parent = false;
|
||||||
|
|
||||||
|
while (parent_child) {
|
||||||
|
property_node_name(
|
||||||
|
parent_child, parent_child_name, sizeof(parent_child_name));
|
||||||
|
|
||||||
|
if (str_eq(parent_child_name, "vfs")) {
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
source_child,
|
||||||
|
"name@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
name_source,
|
||||||
|
sizeof(name_source)))) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing 'name' attribute on avs config mounttable "
|
||||||
|
"vfs source node");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
source_child,
|
||||||
|
"dst@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
dst_source,
|
||||||
|
sizeof(dst_source)))) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing 'dst' attribute on avs config mounttable "
|
||||||
|
"vfs source node");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
parent_child,
|
||||||
|
"name@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
name_parent,
|
||||||
|
sizeof(name_parent)))) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing 'name' attribute on avs config mounttable "
|
||||||
|
"vfs parent node");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
parent_child,
|
||||||
|
"dst@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
dst_parent,
|
||||||
|
sizeof(dst_parent)))) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing 'dst' attribute on avs config mounttable "
|
||||||
|
"vfs parent node");
|
||||||
|
}
|
||||||
|
|
||||||
|
// Found existing matching node on parent, replace it
|
||||||
|
if (str_eq(name_source, name_parent) &&
|
||||||
|
str_eq(dst_source, dst_parent)) {
|
||||||
|
_avs_config_node_vfs_copy(
|
||||||
|
parent_property, parent_child, source_child);
|
||||||
|
|
||||||
|
found_parent = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
parent_child = property_node_traversal(
|
||||||
|
parent_child, TRAVERSE_NEXT_SIBLING);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Not found an existing node that got replaced, insert/merge new
|
||||||
|
// data
|
||||||
|
if (!found_parent) {
|
||||||
|
parent_child = property_node_create(
|
||||||
|
parent_property, parent, PROPERTY_TYPE_VOID, "vfs");
|
||||||
|
|
||||||
|
_avs_config_node_vfs_copy(
|
||||||
|
parent_property, parent_child, source_child);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
source_child =
|
||||||
|
property_node_traversal(source_child, TRAVERSE_NEXT_SIBLING);
|
||||||
|
}
|
||||||
|
|
||||||
|
return node_consumed;
|
||||||
|
}
|
||||||
|
|
||||||
|
struct property *avs_config_load(const char *filepath)
|
||||||
|
{
|
||||||
|
struct property *property;
|
||||||
|
|
||||||
|
log_assert(filepath);
|
||||||
|
|
||||||
|
log_info("Loading from file path: %s", filepath);
|
||||||
|
|
||||||
|
property = property_util_load(filepath);
|
||||||
|
|
||||||
|
// Check if root node exists, call already errors if not
|
||||||
|
avs_config_root_get(property);
|
||||||
|
|
||||||
|
return property;
|
||||||
|
}
|
||||||
|
|
||||||
|
struct property_node *avs_config_root_get(struct property *property)
|
||||||
|
{
|
||||||
|
struct property_node *node;
|
||||||
|
|
||||||
|
log_assert(property);
|
||||||
|
|
||||||
|
node = property_search(property, 0, AVS_CONFIG_ROOT_NODE);
|
||||||
|
|
||||||
|
if (node == NULL) {
|
||||||
|
log_fatal("Root node " AVS_CONFIG_ROOT_NODE " in AVS config missing");
|
||||||
|
}
|
||||||
|
|
||||||
|
return node;
|
||||||
|
}
|
||||||
|
|
||||||
|
struct property *
|
||||||
|
avs_config_property_merge(struct property *parent, struct property *source)
|
||||||
|
{
|
||||||
|
struct property_util_node_merge_strategies strategies;
|
||||||
|
|
||||||
|
log_assert(parent);
|
||||||
|
log_assert(source);
|
||||||
|
|
||||||
|
strategies.num = 2;
|
||||||
|
|
||||||
|
strategies.entry[0].path = _avs_config_property_mounttable_path;
|
||||||
|
strategies.entry[0].merge_strategy_do =
|
||||||
|
_avs_config_mounttable_vfs_nodes_merge_strategy_do;
|
||||||
|
|
||||||
|
strategies.entry[1].path = "";
|
||||||
|
strategies.entry[1].merge_strategy_do =
|
||||||
|
property_util_node_merge_default_strategy_do;
|
||||||
|
|
||||||
|
return property_util_merge_with_strategies(parent, source, &strategies);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_fs_root_device_get(
|
||||||
|
struct property_node *node, char *buffer, size_t size)
|
||||||
|
{
|
||||||
|
struct property_node *device_node;
|
||||||
|
avs_error error;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
device_node = property_search(NULL, node, "fs/root/device");
|
||||||
|
|
||||||
|
if (device_node == NULL) {
|
||||||
|
log_fatal("Could not find node fs/root/device AVS config");
|
||||||
|
}
|
||||||
|
|
||||||
|
error = property_node_read(device_node, PROPERTY_TYPE_STR, buffer, size);
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(error)) {
|
||||||
|
log_fatal(
|
||||||
|
"fs/root/device, property read failed: %s",
|
||||||
|
avs_util_error_str(error));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_mode_product_set(struct property_node *node, bool enable)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(NULL, node, "mode/product", enable ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "mode/product", enable);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_net_raw_set(struct property_node *node, bool enable)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(NULL, node, "net/enable_raw", enable ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "net/enable_raw", enable);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_net_eaudp_set(struct property_node *node, bool enable)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(
|
||||||
|
NULL, node, "net/eaudp/enable", enable ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "net/eaudp/enable", enable);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_sntp_ea_set(struct property_node *node, bool on)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(NULL, node, "sntp/ea_on", on ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "sntp/ea_on", on);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_level_set(struct property_node *node, const char *level)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(level);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
uint32_t level_value;
|
||||||
|
|
||||||
|
if (str_eq(level, "fatal")) {
|
||||||
|
level_value = 1;
|
||||||
|
} else if (str_eq(level, "warning")) {
|
||||||
|
level_value = 2;
|
||||||
|
} else if (str_eq(level, "info")) {
|
||||||
|
level_value = 3;
|
||||||
|
} else if (str_eq(level, "misc")) {
|
||||||
|
level_value = 4;
|
||||||
|
} else if (str_eq(level, "all")) {
|
||||||
|
level_value = 4;
|
||||||
|
} else if (str_eq(level, "disable")) {
|
||||||
|
level_value = 0;
|
||||||
|
} else if (str_eq(level, "default")) {
|
||||||
|
level_value = 4;
|
||||||
|
} else {
|
||||||
|
log_fatal("Unknown log level string %s", level);
|
||||||
|
}
|
||||||
|
|
||||||
|
property_util_node_u32_replace(NULL, node, "log/level", level_value);
|
||||||
|
#else
|
||||||
|
property_util_node_str_replace(NULL, node, "log/level", level);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_name_set(struct property_node *node, const char *name)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(name);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "log/name", name);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_file_set(struct property_node *node, const char *file)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(file);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "log/file", file);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_buffer_size_set(struct property_node *node, uint32_t size)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
property_util_node_u32_replace(NULL, node, "log/sz_buf", size);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_output_delay_set(
|
||||||
|
struct property_node *node, uint16_t delay_ms)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
property_util_node_u16_replace(NULL, node, "log/output_delay", delay_ms);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_enable_console_set(struct property_node *node, bool enable)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(
|
||||||
|
NULL, node, "log/enable_console", enable ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "log/enable_console", enable);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_enable_sci_set(struct property_node *node, bool enable)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(
|
||||||
|
NULL, node, "log/enable_netsci", enable ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "log/enable_netsci", enable);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_enable_net_set(struct property_node *node, bool enable)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(
|
||||||
|
NULL, node, "log/enable_netlog", enable ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "log/enable_netlog", enable);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_enable_file_set(struct property_node *node, bool enable)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(
|
||||||
|
NULL, node, "log/enable_file", enable ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "log/enable_file", enable);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_rotate_set(struct property_node *node, bool rotate)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(NULL, node, "log/rotate", rotate ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "log/rotate", rotate);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_append_set(struct property_node *node, bool append)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
#if AVS_VERSION <= 1306
|
||||||
|
property_util_node_u8_replace(NULL, node, "log/append", append ? 1 : 0);
|
||||||
|
#else
|
||||||
|
property_util_node_bool_replace(NULL, node, "log/append", append);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_log_count_set(struct property_node *node, uint16_t count)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
property_util_node_u16_replace(NULL, node, "log/gen", count);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_set_log_level(
|
||||||
|
struct property_node *node, enum core_log_bt_log_level loglevel)
|
||||||
|
{
|
||||||
|
const char *str;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
switch (loglevel) {
|
||||||
|
case CORE_LOG_BT_LOG_LEVEL_OFF:
|
||||||
|
str = "disable";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case CORE_LOG_BT_LOG_LEVEL_FATAL:
|
||||||
|
str = "fatal";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case CORE_LOG_BT_LOG_LEVEL_WARNING:
|
||||||
|
str = "warn";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case CORE_LOG_BT_LOG_LEVEL_INFO:
|
||||||
|
str = "info";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case CORE_LOG_BT_LOG_LEVEL_MISC:
|
||||||
|
str = "misc";
|
||||||
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
log_fatal("Unsupported log level: %d", loglevel);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
avs_config_log_level_set(node, str);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_local_fs_path_dev_nvram_and_raw_set(
|
||||||
|
struct property_node *node, const char *dev_nvram_raw_path)
|
||||||
|
{
|
||||||
|
char path_dev_raw[MAX_PATH];
|
||||||
|
char path_dev_nvram[MAX_PATH];
|
||||||
|
|
||||||
|
struct property_node *fs_node;
|
||||||
|
struct property_node *mounttable_node;
|
||||||
|
struct property_node *vfs_node;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(dev_nvram_raw_path);
|
||||||
|
|
||||||
|
str_cpy(path_dev_raw, sizeof(path_dev_raw), dev_nvram_raw_path);
|
||||||
|
str_cat(path_dev_raw, sizeof(path_dev_raw), "/dev/raw");
|
||||||
|
|
||||||
|
str_cpy(path_dev_nvram, sizeof(path_dev_nvram), dev_nvram_raw_path);
|
||||||
|
str_cat(path_dev_nvram, sizeof(path_dev_nvram), "/dev/nvram");
|
||||||
|
|
||||||
|
fs_node = property_search(NULL, node, "fs");
|
||||||
|
|
||||||
|
if (!fs_node) {
|
||||||
|
log_fatal("Cannot find 'fs' node in avs config");
|
||||||
|
}
|
||||||
|
|
||||||
|
// Check if "new" mounttable config is used for dev/nvram and dev/raw or
|
||||||
|
// legacy config
|
||||||
|
if (property_search(NULL, fs_node, "mounttable")) {
|
||||||
|
property_remove(NULL, fs_node, "mounttable");
|
||||||
|
|
||||||
|
mounttable_node = property_node_create(
|
||||||
|
NULL, fs_node, PROPERTY_TYPE_VOID, "mounttable");
|
||||||
|
|
||||||
|
vfs_node = property_node_create(
|
||||||
|
NULL, mounttable_node, PROPERTY_TYPE_VOID, "vfs");
|
||||||
|
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "name", "boot");
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "fstype", "fs");
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "src", path_dev_raw);
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "dest", "/dev/raw");
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "opt", "vf=1,posix=1");
|
||||||
|
|
||||||
|
vfs_node = property_node_create(
|
||||||
|
NULL, mounttable_node, PROPERTY_TYPE_VOID, "vfs");
|
||||||
|
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "name", "boot");
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "fstype", "fs");
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "src", path_dev_nvram);
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "dest", "/dev/nvram");
|
||||||
|
property_node_create(
|
||||||
|
NULL, vfs_node, PROPERTY_TYPE_ATTR, "opt", "vf=1,posix=1");
|
||||||
|
} else {
|
||||||
|
property_util_node_str_replace(
|
||||||
|
NULL, fs_node, "nvram/device", path_dev_raw);
|
||||||
|
property_util_node_str_replace(NULL, fs_node, "nvram/fstype", "fs");
|
||||||
|
property_util_node_str_replace(
|
||||||
|
NULL, fs_node, "nvram/option", "vf=1,posix=1");
|
||||||
|
|
||||||
|
property_util_node_str_replace(
|
||||||
|
NULL, fs_node, "raw/device", path_dev_nvram);
|
||||||
|
property_util_node_str_replace(NULL, fs_node, "raw/fstype", "fs");
|
||||||
|
property_util_node_str_replace(
|
||||||
|
NULL, fs_node, "raw/option", "vf=1,posix=1");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_config_vfs_mounttable_get(
|
||||||
|
struct property_node *node, struct avs_config_vfs_mounttable *mounttable)
|
||||||
|
{
|
||||||
|
struct property_node *fs_node;
|
||||||
|
struct property_node *mounttable_node;
|
||||||
|
struct property_node *cur;
|
||||||
|
char mounttable_selector[128];
|
||||||
|
char name[128];
|
||||||
|
uint8_t pos;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(mounttable);
|
||||||
|
|
||||||
|
fs_node = property_search(NULL, node, "fs");
|
||||||
|
|
||||||
|
if (!fs_node) {
|
||||||
|
log_fatal("Cannot find 'fs' node in avs config");
|
||||||
|
}
|
||||||
|
|
||||||
|
// Check if new mounttable config is used for dev/nvram and dev/raw or
|
||||||
|
// legacy config
|
||||||
|
mounttable_node = property_search(NULL, fs_node, "mounttable");
|
||||||
|
|
||||||
|
memset(mounttable, 0, sizeof(*mounttable));
|
||||||
|
pos = 0;
|
||||||
|
|
||||||
|
if (mounttable_node) {
|
||||||
|
cur = property_search(NULL, fs_node, "mounttable_selector");
|
||||||
|
|
||||||
|
if (!cur) {
|
||||||
|
log_fatal("Missing 'mounttable_selector' on mounttable");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_read(
|
||||||
|
cur,
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
mounttable_selector,
|
||||||
|
sizeof(mounttable_selector)))) {
|
||||||
|
log_fatal("Reading 'mounttable_selector' failed");
|
||||||
|
}
|
||||||
|
|
||||||
|
log_misc("Mounttable selector: %s", mounttable_selector);
|
||||||
|
|
||||||
|
cur = property_node_traversal(mounttable_node, TRAVERSE_FIRST_CHILD);
|
||||||
|
|
||||||
|
while (cur) {
|
||||||
|
property_node_name(cur, name, sizeof(name));
|
||||||
|
|
||||||
|
if (str_eq(name, "vfs")) {
|
||||||
|
if (pos >= AVS_CONFIG_MOUNTTABLE_MAX_ENTRIES) {
|
||||||
|
log_warning(
|
||||||
|
"Exceeding max number of supported mounttable entries "
|
||||||
|
"(%d), ignoring remaining",
|
||||||
|
pos);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"name@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
name,
|
||||||
|
sizeof(name)))) {
|
||||||
|
log_fatal("Missing 'name' attribute on vfs node");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (str_eq(name, mounttable_selector)) {
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"fstype@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
mounttable->entry[pos].fstype,
|
||||||
|
sizeof(mounttable->entry[pos].fstype)))) {
|
||||||
|
// default
|
||||||
|
str_cpy(
|
||||||
|
mounttable->entry[pos].fstype,
|
||||||
|
sizeof(mounttable->entry[pos].fstype),
|
||||||
|
"fs");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"src@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
mounttable->entry[pos].src,
|
||||||
|
sizeof(mounttable->entry[pos].src)))) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing 'src' attribute on vfs node, name: %s",
|
||||||
|
name);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"dst@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
mounttable->entry[pos].dst,
|
||||||
|
sizeof(mounttable->entry[pos].dst)))) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing 'dst' attribute on vfs node, name: %s",
|
||||||
|
name);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"opt@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
mounttable->entry[pos].opt,
|
||||||
|
sizeof(mounttable->entry[pos].opt)))) {
|
||||||
|
// optional
|
||||||
|
}
|
||||||
|
|
||||||
|
pos++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
cur = property_node_traversal(cur, TRAVERSE_NEXT_SIBLING);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
cur = property_search(NULL, fs_node, "nvram");
|
||||||
|
|
||||||
|
if (cur) {
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"fstype",
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
mounttable->entry[pos].fstype,
|
||||||
|
sizeof(mounttable->entry[pos].fstype)))) {
|
||||||
|
// default
|
||||||
|
str_cpy(
|
||||||
|
mounttable->entry[pos].fstype,
|
||||||
|
sizeof(mounttable->entry[pos].fstype),
|
||||||
|
"fs");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"device",
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
mounttable->entry[pos].src,
|
||||||
|
sizeof(mounttable->entry[pos].src)))) {
|
||||||
|
log_fatal("Missing 'device' attribute on nvram node");
|
||||||
|
}
|
||||||
|
|
||||||
|
str_cpy(
|
||||||
|
mounttable->entry[pos].dst,
|
||||||
|
sizeof(mounttable->entry[pos].dst),
|
||||||
|
"/dev/nvram");
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"opt",
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
mounttable->entry[pos].opt,
|
||||||
|
sizeof(mounttable->entry[pos].opt)))) {
|
||||||
|
// optional
|
||||||
|
}
|
||||||
|
|
||||||
|
pos++;
|
||||||
|
}
|
||||||
|
|
||||||
|
cur = property_search(NULL, fs_node, "raw");
|
||||||
|
|
||||||
|
if (cur) {
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"fstype",
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
mounttable->entry[pos].fstype,
|
||||||
|
sizeof(mounttable->entry[pos].fstype)))) {
|
||||||
|
// default
|
||||||
|
str_cpy(
|
||||||
|
mounttable->entry[pos].fstype,
|
||||||
|
sizeof(mounttable->entry[pos].fstype),
|
||||||
|
"fs");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"device",
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
mounttable->entry[pos].src,
|
||||||
|
sizeof(mounttable->entry[pos].src)))) {
|
||||||
|
log_fatal("Missing 'device' attribute on raw node");
|
||||||
|
}
|
||||||
|
|
||||||
|
str_cpy(
|
||||||
|
mounttable->entry[pos].dst,
|
||||||
|
sizeof(mounttable->entry[pos].dst),
|
||||||
|
"/dev/raw");
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(property_node_refer(
|
||||||
|
NULL,
|
||||||
|
cur,
|
||||||
|
"opt",
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
mounttable->entry[pos].opt,
|
||||||
|
sizeof(mounttable->entry[pos].opt)))) {
|
||||||
|
// optional
|
||||||
|
}
|
||||||
|
|
||||||
|
pos++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
mounttable->num_entries = pos;
|
||||||
|
}
|
||||||
57
src/main/launcher/avs-config.h
Normal file
57
src/main/launcher/avs-config.h
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
#ifndef LAUNCHER_AVS_CONFIG_H
|
||||||
|
#define LAUNCHER_AVS_CONFIG_H
|
||||||
|
|
||||||
|
#include "core/log-bt.h"
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
#include "launcher/bootstrap-config.h"
|
||||||
|
|
||||||
|
#define AVS_CONFIG_MOUNTTABLE_MAX_ENTRIES 16
|
||||||
|
|
||||||
|
struct avs_config_vfs_mounttable {
|
||||||
|
struct {
|
||||||
|
char fstype[64];
|
||||||
|
char src[512];
|
||||||
|
char dst[512];
|
||||||
|
char opt[256];
|
||||||
|
} entry[AVS_CONFIG_MOUNTTABLE_MAX_ENTRIES];
|
||||||
|
|
||||||
|
uint8_t num_entries;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct property *avs_config_load(const char *filepath);
|
||||||
|
struct property_node *avs_config_root_get(struct property *property);
|
||||||
|
struct property *
|
||||||
|
avs_config_property_merge(struct property *parent, struct property *source);
|
||||||
|
|
||||||
|
void avs_config_fs_root_device_get(
|
||||||
|
struct property_node *node, char *buffer, size_t size);
|
||||||
|
|
||||||
|
void avs_config_mode_product_set(struct property_node *node, bool enable);
|
||||||
|
void avs_config_net_raw_set(struct property_node *node, bool enable);
|
||||||
|
void avs_config_net_eaudp_set(struct property_node *node, bool enable);
|
||||||
|
void avs_config_sntp_ea_set(struct property_node *node, bool on);
|
||||||
|
void avs_config_log_level_set(struct property_node *node, const char *level);
|
||||||
|
void avs_config_log_name_set(struct property_node *node, const char *name);
|
||||||
|
void avs_config_log_file_set(struct property_node *node, const char *file);
|
||||||
|
void avs_config_log_buffer_size_set(struct property_node *node, uint32_t size);
|
||||||
|
void avs_config_log_output_delay_set(
|
||||||
|
struct property_node *node, uint16_t delay_ms);
|
||||||
|
void avs_config_log_enable_console_set(struct property_node *node, bool enable);
|
||||||
|
void avs_config_log_enable_sci_set(struct property_node *node, bool enable);
|
||||||
|
void avs_config_log_enable_net_set(struct property_node *node, bool enable);
|
||||||
|
void avs_config_log_enable_file_set(struct property_node *node, bool enable);
|
||||||
|
void avs_config_log_rotate_set(struct property_node *node, bool rotate);
|
||||||
|
void avs_config_log_append_set(struct property_node *node, bool append);
|
||||||
|
void avs_config_log_count_set(struct property_node *node, uint16_t count);
|
||||||
|
|
||||||
|
void avs_config_set_log_level(
|
||||||
|
struct property_node *node, enum core_log_bt_log_level loglevel);
|
||||||
|
void avs_config_local_fs_path_dev_nvram_and_raw_set(
|
||||||
|
struct property_node *node, const char *dev_nvram_raw_path);
|
||||||
|
|
||||||
|
void avs_config_vfs_mounttable_get(
|
||||||
|
struct property_node *node, struct avs_config_vfs_mounttable *mounttable);
|
||||||
|
|
||||||
|
#endif
|
||||||
@@ -1,72 +0,0 @@
|
|||||||
#include <windows.h>
|
|
||||||
|
|
||||||
#include <stddef.h>
|
|
||||||
#include <stdint.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
|
|
||||||
#include "imports/avs.h"
|
|
||||||
|
|
||||||
#include "launcher/avs-context.h"
|
|
||||||
|
|
||||||
#include "util/log.h"
|
|
||||||
|
|
||||||
static void *avs_heap;
|
|
||||||
|
|
||||||
#ifdef AVS_HAS_STD_HEAP
|
|
||||||
static void *std_heap;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
void avs_context_init(
|
|
||||||
struct property_node *config,
|
|
||||||
uint32_t avs_heap_size,
|
|
||||||
uint32_t std_heap_size,
|
|
||||||
avs_log_writer_t log_writer,
|
|
||||||
void *log_writer_ctx)
|
|
||||||
{
|
|
||||||
avs_heap = VirtualAlloc(
|
|
||||||
NULL, avs_heap_size, MEM_RESERVE | MEM_COMMIT, PAGE_READWRITE);
|
|
||||||
|
|
||||||
if (avs_heap == NULL) {
|
|
||||||
log_fatal(
|
|
||||||
"Failed to VirtualAlloc %d byte AVS heap: %08x",
|
|
||||||
avs_heap_size,
|
|
||||||
(unsigned int) GetLastError());
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef AVS_HAS_STD_HEAP
|
|
||||||
std_heap = VirtualAlloc(
|
|
||||||
NULL, std_heap_size, MEM_RESERVE | MEM_COMMIT, PAGE_READWRITE);
|
|
||||||
|
|
||||||
if (std_heap == NULL) {
|
|
||||||
log_fatal(
|
|
||||||
"Failed to VirtualAlloc %d byte \"std\" heap: %08x",
|
|
||||||
std_heap_size,
|
|
||||||
(unsigned int) GetLastError());
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef AVS_HAS_STD_HEAP
|
|
||||||
avs_boot(
|
|
||||||
config,
|
|
||||||
std_heap,
|
|
||||||
std_heap_size,
|
|
||||||
avs_heap,
|
|
||||||
avs_heap_size,
|
|
||||||
log_writer,
|
|
||||||
log_writer_ctx);
|
|
||||||
#else
|
|
||||||
/* AVS v2.16.xx and I suppose onward uses a unified heap */
|
|
||||||
avs_boot(config, avs_heap, avs_heap_size, NULL, log_writer, log_writer_ctx);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
void avs_context_fini(void)
|
|
||||||
{
|
|
||||||
avs_shutdown();
|
|
||||||
|
|
||||||
#ifdef AVS_HAS_STD_HEAP
|
|
||||||
VirtualFree(std_heap, 0, MEM_RELEASE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
VirtualFree(avs_heap, 0, MEM_RELEASE);
|
|
||||||
}
|
|
||||||
@@ -1,20 +0,0 @@
|
|||||||
#ifndef LAUNCHER_AVS_CONTEXT_H
|
|
||||||
#define LAUNCHER_AVS_CONTEXT_H
|
|
||||||
|
|
||||||
#include <stdint.h>
|
|
||||||
|
|
||||||
#include "imports/avs.h"
|
|
||||||
|
|
||||||
#if AVS_VERSION < 1600
|
|
||||||
#define AVS_HAS_STD_HEAP
|
|
||||||
#endif
|
|
||||||
|
|
||||||
void avs_context_init(
|
|
||||||
struct property_node *config,
|
|
||||||
uint32_t avs_heap_size,
|
|
||||||
uint32_t std_heap_size,
|
|
||||||
avs_log_writer_t log_writer,
|
|
||||||
void *log_writer_ctx);
|
|
||||||
void avs_context_fini(void);
|
|
||||||
|
|
||||||
#endif
|
|
||||||
270
src/main/launcher/avs.c
Normal file
270
src/main/launcher/avs.c
Normal file
@@ -0,0 +1,270 @@
|
|||||||
|
#define LOG_MODULE "avs"
|
||||||
|
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
|
#include <stddef.h>
|
||||||
|
#include <stdint.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
|
#include "core/log-bt.h"
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
#include "launcher/avs-config.h"
|
||||||
|
#include "launcher/avs.h"
|
||||||
|
#include "launcher/property-util.h"
|
||||||
|
|
||||||
|
#include "util/codepage.h"
|
||||||
|
#include "util/fs.h"
|
||||||
|
#include "util/mem.h"
|
||||||
|
#include "util/str.h"
|
||||||
|
|
||||||
|
#if AVS_VERSION < 1600
|
||||||
|
#define AVS_HAS_STD_HEAP
|
||||||
|
#endif
|
||||||
|
|
||||||
|
static void *avs_heap;
|
||||||
|
|
||||||
|
#ifdef AVS_HAS_STD_HEAP
|
||||||
|
static void *std_heap;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Gratuitous API changes orz */
|
||||||
|
static AVS_LOG_WRITER(_avs_context_log_writer, chars, nchars, ctx)
|
||||||
|
{
|
||||||
|
wchar_t *utf16;
|
||||||
|
char *utf8;
|
||||||
|
int utf16_len;
|
||||||
|
int utf8_len;
|
||||||
|
int result;
|
||||||
|
|
||||||
|
/* Ignore existing NUL terminator */
|
||||||
|
|
||||||
|
nchars--;
|
||||||
|
|
||||||
|
/* Transcode shit_jis to UTF-8 */
|
||||||
|
|
||||||
|
utf16_len = MultiByteToWideChar(CP_SHIFT_JIS, 0, chars, nchars, NULL, 0);
|
||||||
|
|
||||||
|
if (utf16_len == 0) {
|
||||||
|
abort();
|
||||||
|
}
|
||||||
|
|
||||||
|
utf16 = xmalloc(sizeof(*utf16) * utf16_len);
|
||||||
|
result =
|
||||||
|
MultiByteToWideChar(CP_SHIFT_JIS, 0, chars, nchars, utf16, utf16_len);
|
||||||
|
|
||||||
|
if (result == 0) {
|
||||||
|
abort();
|
||||||
|
}
|
||||||
|
|
||||||
|
utf8_len =
|
||||||
|
WideCharToMultiByte(CP_UTF8, 0, utf16, utf16_len, NULL, 0, NULL, NULL);
|
||||||
|
|
||||||
|
if (utf8_len == 0) {
|
||||||
|
abort();
|
||||||
|
}
|
||||||
|
|
||||||
|
utf8 = xmalloc(utf8_len + 3);
|
||||||
|
result = WideCharToMultiByte(
|
||||||
|
CP_UTF8, 0, utf16, utf16_len, utf8, utf8_len, NULL, NULL);
|
||||||
|
|
||||||
|
if (result == 0) {
|
||||||
|
abort();
|
||||||
|
}
|
||||||
|
|
||||||
|
#if AVS_VERSION >= 1500
|
||||||
|
utf8[utf8_len + 0] = '\r';
|
||||||
|
utf8[utf8_len + 1] = '\n';
|
||||||
|
|
||||||
|
utf8_len += 2;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// Clean string terminate
|
||||||
|
utf8[utf8_len] = '\0';
|
||||||
|
|
||||||
|
// Write to launcher's dedicated logging backend
|
||||||
|
core_log_bt_direct_sink_write(utf8, utf8_len);
|
||||||
|
|
||||||
|
/* Clean up */
|
||||||
|
|
||||||
|
free(utf8);
|
||||||
|
free(utf16);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _avs_switch_log_engine()
|
||||||
|
{
|
||||||
|
// Switch the logging backend now that AVS is booted to use a single logging
|
||||||
|
// engine which avoids concurrency issues as AVS runs it's own async logger
|
||||||
|
// thread
|
||||||
|
core_log_impl_set(
|
||||||
|
log_body_misc, log_body_info, log_body_warning, log_body_fatal);
|
||||||
|
|
||||||
|
log_misc("Switched logging engine to AVS");
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_fs_assert_root_device_exists(struct property_node *node)
|
||||||
|
{
|
||||||
|
char root_device_path[PATH_MAX];
|
||||||
|
char cwd_path[PATH_MAX];
|
||||||
|
|
||||||
|
avs_config_fs_root_device_get(
|
||||||
|
node, root_device_path, sizeof(root_device_path));
|
||||||
|
getcwd(cwd_path, sizeof(cwd_path));
|
||||||
|
|
||||||
|
if (!path_exists(root_device_path)) {
|
||||||
|
log_fatal(
|
||||||
|
"Root device path '%s' does not exist in current working dir '%s'",
|
||||||
|
root_device_path,
|
||||||
|
cwd_path);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_fs_mountpoints_fs_dirs_create(struct property_node *node)
|
||||||
|
{
|
||||||
|
struct avs_config_vfs_mounttable mounttable;
|
||||||
|
uint8_t i;
|
||||||
|
|
||||||
|
avs_config_vfs_mounttable_get(node, &mounttable);
|
||||||
|
|
||||||
|
if (mounttable.num_entries == 0) {
|
||||||
|
log_warning("No mountpoints found in mounttable");
|
||||||
|
}
|
||||||
|
|
||||||
|
for (i = 0; i < mounttable.num_entries; i++) {
|
||||||
|
if (str_eq(mounttable.entry[i].fstype, "fs")) {
|
||||||
|
log_misc(
|
||||||
|
"Creating avs fs directory '%s' for destination/device '%s'...",
|
||||||
|
mounttable.entry[i].src,
|
||||||
|
mounttable.entry[i].dst);
|
||||||
|
|
||||||
|
if (!path_exists(mounttable.entry[i].src)) {
|
||||||
|
if (!path_mkdir(mounttable.entry[i].src)) {
|
||||||
|
log_fatal(
|
||||||
|
"Creating fs directory %s failed",
|
||||||
|
mounttable.entry[i].src);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_init(
|
||||||
|
struct property_node *node, uint32_t avs_heap_size, uint32_t std_heap_size)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(avs_heap_size > 0);
|
||||||
|
// Modern games don't have a separate std heap anymore
|
||||||
|
log_assert(std_heap_size >= 0);
|
||||||
|
|
||||||
|
log_info("init");
|
||||||
|
|
||||||
|
log_misc("Allocating avs heap: %d", avs_heap_size);
|
||||||
|
|
||||||
|
avs_heap = VirtualAlloc(
|
||||||
|
NULL, avs_heap_size, MEM_RESERVE | MEM_COMMIT, PAGE_READWRITE);
|
||||||
|
|
||||||
|
if (avs_heap == NULL) {
|
||||||
|
log_fatal(
|
||||||
|
"Failed to VirtualAlloc %d byte AVS heap: %08x",
|
||||||
|
avs_heap_size,
|
||||||
|
(unsigned int) GetLastError());
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef AVS_HAS_STD_HEAP
|
||||||
|
log_misc("Allocating std heap: %d", std_heap_size);
|
||||||
|
|
||||||
|
std_heap = VirtualAlloc(
|
||||||
|
NULL, std_heap_size, MEM_RESERVE | MEM_COMMIT, PAGE_READWRITE);
|
||||||
|
|
||||||
|
if (std_heap == NULL) {
|
||||||
|
log_fatal(
|
||||||
|
"Failed to VirtualAlloc %d byte \"std\" heap: %08x",
|
||||||
|
std_heap_size,
|
||||||
|
(unsigned int) GetLastError());
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
log_info("Calling avs_boot");
|
||||||
|
|
||||||
|
#ifdef AVS_HAS_STD_HEAP
|
||||||
|
avs_boot(
|
||||||
|
node,
|
||||||
|
std_heap,
|
||||||
|
std_heap_size,
|
||||||
|
avs_heap,
|
||||||
|
avs_heap_size,
|
||||||
|
_avs_context_log_writer,
|
||||||
|
NULL);
|
||||||
|
#else
|
||||||
|
/* AVS v2.16.xx and I suppose onward uses a unified heap */
|
||||||
|
avs_boot(
|
||||||
|
node, avs_heap, avs_heap_size, NULL, _avs_context_log_writer, NULL);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
_avs_switch_log_engine();
|
||||||
|
|
||||||
|
log_misc("init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_fs_file_copy(const char *src, const char *dst)
|
||||||
|
{
|
||||||
|
struct avs_stat st;
|
||||||
|
|
||||||
|
log_assert(src);
|
||||||
|
log_assert(dst);
|
||||||
|
|
||||||
|
log_misc("Copying %s to %s...", src, dst);
|
||||||
|
|
||||||
|
if (!avs_fs_lstat(src, &st)) {
|
||||||
|
log_fatal("File source %s does not exist or is not accessible", src);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (avs_fs_copy(src, dst) < 0) {
|
||||||
|
log_fatal("Failed copying file %s to %s", src, dst);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_fs_dir_log(const char *path)
|
||||||
|
{
|
||||||
|
const char *name;
|
||||||
|
|
||||||
|
log_assert(path);
|
||||||
|
|
||||||
|
avs_desc dir = avs_fs_opendir(path);
|
||||||
|
|
||||||
|
if (dir < 0) {
|
||||||
|
log_warning(
|
||||||
|
"Opening avs dir %s failed, skipping logging contents", path);
|
||||||
|
}
|
||||||
|
|
||||||
|
log_misc("Contents of %s:", path);
|
||||||
|
|
||||||
|
do {
|
||||||
|
name = avs_fs_readdir(dir);
|
||||||
|
|
||||||
|
if (name == NULL) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
log_misc("%s", name);
|
||||||
|
} while (name != NULL);
|
||||||
|
|
||||||
|
avs_fs_closedir(dir);
|
||||||
|
}
|
||||||
|
|
||||||
|
void avs_fini(void)
|
||||||
|
{
|
||||||
|
log_info("fini");
|
||||||
|
|
||||||
|
avs_shutdown();
|
||||||
|
|
||||||
|
#ifdef AVS_HAS_STD_HEAP
|
||||||
|
VirtualFree(std_heap, 0, MEM_RELEASE);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
VirtualFree(avs_heap, 0, MEM_RELEASE);
|
||||||
|
|
||||||
|
log_misc("fini done");
|
||||||
|
}
|
||||||
16
src/main/launcher/avs.h
Normal file
16
src/main/launcher/avs.h
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
#ifndef LAUNCHER_AVS_H
|
||||||
|
#define LAUNCHER_AVS_H
|
||||||
|
|
||||||
|
#include <stdint.h>
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
void avs_fs_assert_root_device_exists(struct property_node *node);
|
||||||
|
void avs_fs_mountpoints_fs_dirs_create(struct property_node *node);
|
||||||
|
void avs_init(
|
||||||
|
struct property_node *node, uint32_t avs_heap_size, uint32_t std_heap_size);
|
||||||
|
void avs_fs_file_copy(const char *src, const char *dst);
|
||||||
|
void avs_fs_dir_log(const char *path);
|
||||||
|
void avs_fini(void);
|
||||||
|
|
||||||
|
#endif
|
||||||
548
src/main/launcher/bootstrap-config.c
Normal file
548
src/main/launcher/bootstrap-config.c
Normal file
@@ -0,0 +1,548 @@
|
|||||||
|
#define LOG_MODULE "bootstrap-config"
|
||||||
|
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
#include "launcher/avs-config.h"
|
||||||
|
#include "launcher/bootstrap-config.h"
|
||||||
|
#include "launcher/property-util.h"
|
||||||
|
|
||||||
|
#include "util/defs.h"
|
||||||
|
#include "util/hex.h"
|
||||||
|
#include "util/str.h"
|
||||||
|
|
||||||
|
// clang-format off
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_boot_psmap)
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct bootstrap_boot_config, config_file,
|
||||||
|
"boot/file")
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_U32, struct bootstrap_boot_config, avs_heap_size,
|
||||||
|
"boot/heap_avs")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_boot_config, std_heap_size,
|
||||||
|
"boot/heap_std", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_boot_config, mount_table_selector,
|
||||||
|
"boot/mounttable_selector", "boot")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_boot_config, watcher_enable,
|
||||||
|
"boot/watcher", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_boot_config, timemachine_enable,
|
||||||
|
"boot/timemachine", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_boot_config, launch_config_file,
|
||||||
|
"boot/launch_path", "/dev/raw/launch.xml")
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_log_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_log_config, level,
|
||||||
|
"log/level", "all")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_log_config, name,
|
||||||
|
"log/name", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_log_config, file,
|
||||||
|
"log/file", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_log_config, bufsz,
|
||||||
|
"log/sz_buf", 4096)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U16, struct bootstrap_log_config, output_delay_ms,
|
||||||
|
"log/output_delay", 10)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_log_config, enable_console,
|
||||||
|
"log/enable_console", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_log_config, enable_sci,
|
||||||
|
"log/enable_netsci", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_log_config, enable_net,
|
||||||
|
"log/enable_netlog", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_log_config, enable_file,
|
||||||
|
"log/enable_file", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_log_config, rotate,
|
||||||
|
"log/rotate", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_log_config, append,
|
||||||
|
"log/append", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U16, struct bootstrap_log_config, count,
|
||||||
|
"log/gen", 10)
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_minidump_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U8, struct bootstrap_minidump_config, count,
|
||||||
|
"minidump/gen", 10)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_minidump_config, continue_,
|
||||||
|
"minidump/cont_debug", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_minidump_config, log,
|
||||||
|
"minidump/echo_log", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U8, struct bootstrap_minidump_config, type,
|
||||||
|
"minidump/dump_type", 2)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_minidump_config, path,
|
||||||
|
"minidump/path", "/dev/raw/minidump")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_minidump_config, symbufsz,
|
||||||
|
"minidump/sz_symbuf", 32768)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_minidump_config, search_path,
|
||||||
|
"minidump/search", ".")
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_module_psmap)
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct bootstrap_module_config, file,
|
||||||
|
"component/file")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_module_config, load_type,
|
||||||
|
"component/load_type", "MEMORY")
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_dlm_psmap)
|
||||||
|
/* disabled until we implement PSMAP_TYPE_BIN
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_startup_config, ntdll_digest,
|
||||||
|
"dlml/ntdll/hash", "")
|
||||||
|
*/
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_dlm_config, size,
|
||||||
|
"dlml/ntdll/size", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_dlm_config, ift_table,
|
||||||
|
"dlml/ntdll/ift_table", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_dlm_config, ift_insert,
|
||||||
|
"dlml/ntdll/insert_ift", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_dlm_config, ift_remove,
|
||||||
|
"dlml/ntdll/remove_ift", 0)
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_shield_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_shield_config, enable,
|
||||||
|
"shield/enable", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_shield_config, verbose,
|
||||||
|
"shield/verbose", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_shield_config, use_loadlibrary,
|
||||||
|
"shield/use_loadlibrary", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_shield_config, logger,
|
||||||
|
"shield/logger", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_shield_config, sleep_min,
|
||||||
|
"shield/sleepmin", 10)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_shield_config, sleep_blur,
|
||||||
|
"shield/sleepblur", 90)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_shield_config, whitelist_file,
|
||||||
|
"shield/whitelist", "prop/whitelist.csv")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_shield_config, tick_sleep,
|
||||||
|
"shield/ticksleep", 100)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_shield_config, tick_error,
|
||||||
|
"shield/tickerror", 1000)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U8, struct bootstrap_shield_config, overwork_threshold,
|
||||||
|
"shield/overwork_threshold", 50)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_shield_config, overwork_delay,
|
||||||
|
"shield/overwork_delay", 100)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_shield_config, pause_delay,
|
||||||
|
"shield/pause_delay", 1000)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_shield_config, unlimited_key,
|
||||||
|
"shield/unlimited_key", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U16, struct bootstrap_shield_config, killer_port,
|
||||||
|
"shield_killer/port", 5001)
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_dongle_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_dongle_config, license_cn,
|
||||||
|
"dongle/license", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_dongle_config, account_cn,
|
||||||
|
"dongle/account", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_dongle_config, driver_dll,
|
||||||
|
"dongle/pkcs11_driver", "eTPKCS11.dll")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_dongle_config, disable_gc,
|
||||||
|
"dongle/disable_gc", 0)
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_drm_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_drm_config, dll,
|
||||||
|
"drm/dll", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_drm_config, fstype,
|
||||||
|
"drm/fstype", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_drm_config, device,
|
||||||
|
"drm/device", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_drm_config, mount,
|
||||||
|
"drm/dst", "/")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_drm_config, options,
|
||||||
|
"drm/option", "")
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_lte_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_lte_config, enable,
|
||||||
|
"lte/enable", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_lte_config, config_file,
|
||||||
|
"lte/file", "/dev/nvram/lte-config.xml")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_lte_config, unlimited_key,
|
||||||
|
"lte/unlimited_key", "")
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_ssl_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_ssl_config, options,
|
||||||
|
"ssl/option", "")
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_esign_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_esign_config, enable,
|
||||||
|
"esign/enable", 0)
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_startup_eamuse_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_eamuse_config, enable,
|
||||||
|
"eamuse/enable", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_eamuse_config, sync,
|
||||||
|
"eamuse/sync", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_eamuse_config, enable_model,
|
||||||
|
"eamuse/enable_model", 0)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_eamuse_config, config_file,
|
||||||
|
"eamuse/file", "/dev/nvram/ea3-config.xml")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct bootstrap_eamuse_config, updatecert_enable,
|
||||||
|
"eamuse/updatecert_enable", 1)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_U32, struct bootstrap_eamuse_config, updatecert_interval,
|
||||||
|
"eamuse/updatecert_interval", 0)
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
PSMAP_BEGIN(bootstrap_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct bootstrap_config, release_code, "/release_code", "")
|
||||||
|
PSMAP_END
|
||||||
|
// clang-format on
|
||||||
|
|
||||||
|
#define ROOT_NODE "/config"
|
||||||
|
#define MODULE_PATH_PREFIX "modules/"
|
||||||
|
|
||||||
|
#define NODE_MISSING_FATAL(subnode) \
|
||||||
|
log_fatal("%s/%s: Node missing", ROOT_NODE, subnode);
|
||||||
|
#define NODE_STARTUP_MISSING_FATAL(profile) \
|
||||||
|
log_fatal("%s/startup/%s: Node missing", ROOT_NODE, profile);
|
||||||
|
#define NODE_PROFILE_MISSING_FATAL(profile, subnode) \
|
||||||
|
log_fatal("%s/%s/%s: Node missing", ROOT_NODE, profile, subnode);
|
||||||
|
#define NODE_PROFILE_LOADING_FATAL(profile, subnode) \
|
||||||
|
log_fatal("%s/startup/%s/%s: Node loading", ROOT_NODE, profile, subnode);
|
||||||
|
|
||||||
|
#define DEFAULT_HEAP_SIZE 16777216
|
||||||
|
|
||||||
|
const char *const inherited_nodes[] = {
|
||||||
|
"develop",
|
||||||
|
"default",
|
||||||
|
"log",
|
||||||
|
"minidump",
|
||||||
|
"boot",
|
||||||
|
"drm",
|
||||||
|
"ssl",
|
||||||
|
"eamuse",
|
||||||
|
"shield",
|
||||||
|
"esign",
|
||||||
|
"dongle",
|
||||||
|
"lte",
|
||||||
|
};
|
||||||
|
|
||||||
|
static void _bootstrap_config_profile_node_verify(
|
||||||
|
struct property_node *node, const char *profile)
|
||||||
|
{
|
||||||
|
struct property_node *profile_node;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(profile);
|
||||||
|
|
||||||
|
profile_node = property_search(NULL, node, profile);
|
||||||
|
|
||||||
|
if (!profile_node) {
|
||||||
|
NODE_STARTUP_MISSING_FATAL(profile);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static struct property_node *
|
||||||
|
_bootstrap_config_root_node_get(struct property *property)
|
||||||
|
{
|
||||||
|
struct property_node *root_node;
|
||||||
|
|
||||||
|
log_assert(property);
|
||||||
|
|
||||||
|
root_node = property_search(property, NULL, ROOT_NODE);
|
||||||
|
|
||||||
|
if (!root_node) {
|
||||||
|
NODE_MISSING_FATAL("");
|
||||||
|
}
|
||||||
|
|
||||||
|
return root_node;
|
||||||
|
}
|
||||||
|
|
||||||
|
static struct property_node *
|
||||||
|
_bootstrap_config_startup_node_get(struct property_node *node)
|
||||||
|
{
|
||||||
|
struct property_node *startup_node;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
startup_node = property_search(NULL, node, "startup");
|
||||||
|
|
||||||
|
if (!startup_node) {
|
||||||
|
NODE_MISSING_FATAL("startup");
|
||||||
|
}
|
||||||
|
|
||||||
|
return startup_node;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _bootstrap_config_inheritance_resolve(
|
||||||
|
struct property_node *startup_node, const char *profile_name)
|
||||||
|
{
|
||||||
|
struct property_node *startup_parent_node;
|
||||||
|
struct property_node *startup_profile_node;
|
||||||
|
struct property_node *tmp_node;
|
||||||
|
|
||||||
|
char inherit_name[64];
|
||||||
|
avs_error error;
|
||||||
|
struct property_node *result;
|
||||||
|
|
||||||
|
startup_profile_node = property_search(NULL, startup_node, profile_name);
|
||||||
|
|
||||||
|
if (!startup_profile_node) {
|
||||||
|
log_fatal(ROOT_NODE "/startup/%s: missing", profile_name);
|
||||||
|
}
|
||||||
|
|
||||||
|
startup_parent_node = startup_profile_node;
|
||||||
|
|
||||||
|
for (;;) {
|
||||||
|
error = property_node_refer(
|
||||||
|
NULL,
|
||||||
|
startup_parent_node,
|
||||||
|
"inherit@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
inherit_name,
|
||||||
|
sizeof(inherit_name));
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(error)) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
startup_parent_node = property_search(NULL, startup_node, inherit_name);
|
||||||
|
|
||||||
|
if (!startup_parent_node) {
|
||||||
|
NODE_STARTUP_MISSING_FATAL(inherit_name);
|
||||||
|
}
|
||||||
|
|
||||||
|
for (int i = 0; i < _countof(inherited_nodes); i++) {
|
||||||
|
if (property_search(NULL, startup_node, inherited_nodes[i])) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
tmp_node =
|
||||||
|
property_search(NULL, startup_parent_node, inherited_nodes[i]);
|
||||||
|
|
||||||
|
if (tmp_node) {
|
||||||
|
log_misc(
|
||||||
|
ROOT_NODE "/startup/%s: merging %s...",
|
||||||
|
inherit_name,
|
||||||
|
inherited_nodes[i]);
|
||||||
|
|
||||||
|
result = property_node_clone(
|
||||||
|
NULL, startup_profile_node, tmp_node, true);
|
||||||
|
|
||||||
|
if (!result) {
|
||||||
|
log_fatal(
|
||||||
|
"Merging '%s' into '%s' failed",
|
||||||
|
inherited_nodes[i],
|
||||||
|
inherit_name);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _bootstrap_config_load_bootstrap_module_app_config(
|
||||||
|
struct property_node *profile_node, struct bootstrap_module_config *config)
|
||||||
|
{
|
||||||
|
struct property_node *app_node;
|
||||||
|
|
||||||
|
log_assert(profile_node);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
app_node = property_search(NULL, profile_node, "component/param");
|
||||||
|
|
||||||
|
config->app_config = property_util_node_extract(app_node);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _bootstrap_config_load_bootstrap_default_files_config(
|
||||||
|
const char *profile_name,
|
||||||
|
struct property_node *profile_node,
|
||||||
|
struct bootstrap_default_file_config *config)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
int result;
|
||||||
|
struct property_node *child;
|
||||||
|
|
||||||
|
log_assert(profile_node);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
child = property_search(NULL, profile_node, "default/file");
|
||||||
|
i = 0;
|
||||||
|
|
||||||
|
while (child) {
|
||||||
|
if (i >= DEFAULT_FILE_MAX) {
|
||||||
|
log_warning(
|
||||||
|
"Currently not supporting more than %d default files, skipping "
|
||||||
|
"remaining",
|
||||||
|
i);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
result = property_node_refer(
|
||||||
|
NULL,
|
||||||
|
child,
|
||||||
|
"src@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
&config->file[i].src,
|
||||||
|
sizeof(config->file[i].src));
|
||||||
|
|
||||||
|
if (result < 0) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing src attribute on default file node of profile %s",
|
||||||
|
profile_name);
|
||||||
|
}
|
||||||
|
|
||||||
|
result = property_node_refer(
|
||||||
|
NULL,
|
||||||
|
child,
|
||||||
|
"dst@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
&config->file[i].dst,
|
||||||
|
sizeof(config->file[i].dst));
|
||||||
|
|
||||||
|
if (result < 0) {
|
||||||
|
log_fatal(
|
||||||
|
"Missing dst attribute on default file node of profile %s",
|
||||||
|
profile_name);
|
||||||
|
}
|
||||||
|
|
||||||
|
child = property_node_traversal(child, TRAVERSE_NEXT_SEARCH_RESULT);
|
||||||
|
i++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _bootstrap_config_load_bootstrap(
|
||||||
|
struct property_node *startup_node,
|
||||||
|
const char *profile,
|
||||||
|
struct bootstrap_startup_config *config)
|
||||||
|
{
|
||||||
|
struct property_node *profile_node;
|
||||||
|
|
||||||
|
profile_node = property_search(NULL, startup_node, profile);
|
||||||
|
|
||||||
|
if (!profile_node) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "");
|
||||||
|
}
|
||||||
|
|
||||||
|
_bootstrap_config_load_bootstrap_default_files_config(
|
||||||
|
profile, profile_node, &config->default_file);
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL, profile_node, &config->boot, bootstrap_startup_boot_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "boot");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL, profile_node, &config->log, bootstrap_startup_log_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "log");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL,
|
||||||
|
profile_node,
|
||||||
|
&config->minidump,
|
||||||
|
bootstrap_startup_minidump_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "minidump");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL,
|
||||||
|
profile_node,
|
||||||
|
&config->module,
|
||||||
|
bootstrap_startup_module_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "component");
|
||||||
|
}
|
||||||
|
|
||||||
|
_bootstrap_config_load_bootstrap_module_app_config(
|
||||||
|
profile_node, &config->module);
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL,
|
||||||
|
profile_node,
|
||||||
|
&config->dlm_ntdll,
|
||||||
|
bootstrap_startup_dlm_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "dlm/ntdll");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL,
|
||||||
|
profile_node,
|
||||||
|
&config->shield,
|
||||||
|
bootstrap_startup_shield_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "shield");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL,
|
||||||
|
profile_node,
|
||||||
|
&config->dongle,
|
||||||
|
bootstrap_startup_dongle_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "dongle");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL, profile_node, &config->drm, bootstrap_startup_drm_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "drm");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL, profile_node, &config->lte, bootstrap_startup_lte_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "lte");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL, profile_node, &config->ssl, bootstrap_startup_ssl_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "ssl");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL,
|
||||||
|
profile_node,
|
||||||
|
&config->esign,
|
||||||
|
bootstrap_startup_esign_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "esign");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
NULL,
|
||||||
|
profile_node,
|
||||||
|
&config->eamuse,
|
||||||
|
bootstrap_startup_eamuse_psmap)) {
|
||||||
|
NODE_PROFILE_LOADING_FATAL(profile, "eamuse");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_config_init(struct bootstrap_config *config)
|
||||||
|
{
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
memset(config, 0, sizeof(*config));
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_config_load(
|
||||||
|
struct property *property,
|
||||||
|
const char *profile,
|
||||||
|
struct bootstrap_config *config)
|
||||||
|
{
|
||||||
|
struct property_node *root_node;
|
||||||
|
struct property_node *startup_node;
|
||||||
|
|
||||||
|
log_assert(property);
|
||||||
|
log_assert(profile);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
log_info(ROOT_NODE ": loading...");
|
||||||
|
|
||||||
|
root_node = _bootstrap_config_root_node_get(property);
|
||||||
|
|
||||||
|
if (!property_psmap_import(NULL, root_node, config, bootstrap_psmap)) {
|
||||||
|
log_fatal(ROOT_NODE ": loading failed");
|
||||||
|
}
|
||||||
|
|
||||||
|
startup_node = _bootstrap_config_startup_node_get(root_node);
|
||||||
|
|
||||||
|
_bootstrap_config_profile_node_verify(startup_node, profile);
|
||||||
|
|
||||||
|
_bootstrap_config_inheritance_resolve(startup_node, profile);
|
||||||
|
|
||||||
|
log_misc(ROOT_NODE "/startup/%s: loading merged result...", profile);
|
||||||
|
|
||||||
|
property_util_node_log(startup_node);
|
||||||
|
|
||||||
|
_bootstrap_config_load_bootstrap(startup_node, profile, &config->startup);
|
||||||
|
|
||||||
|
log_misc("Loading finished");
|
||||||
|
}
|
||||||
139
src/main/launcher/bootstrap-config.h
Normal file
139
src/main/launcher/bootstrap-config.h
Normal file
@@ -0,0 +1,139 @@
|
|||||||
|
#ifndef LAUNCHER_BOOTSTRAP_CONFIG_H
|
||||||
|
#define LAUNCHER_BOOTSTRAP_CONFIG_H
|
||||||
|
|
||||||
|
#include <stdbool.h>
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
// should be enough for a while
|
||||||
|
#define DEFAULT_FILE_MAX 16
|
||||||
|
|
||||||
|
struct bootstrap_startup_config {
|
||||||
|
struct bootstrap_default_file_config {
|
||||||
|
struct bootstrap_default_file {
|
||||||
|
char src[64];
|
||||||
|
char dst[64];
|
||||||
|
} file[DEFAULT_FILE_MAX];
|
||||||
|
} default_file;
|
||||||
|
|
||||||
|
struct bootstrap_boot_config {
|
||||||
|
char config_file[64];
|
||||||
|
uint32_t avs_heap_size;
|
||||||
|
uint32_t std_heap_size;
|
||||||
|
char launch_config_file[64];
|
||||||
|
char mount_table_selector[16];
|
||||||
|
bool watcher_enable;
|
||||||
|
bool timemachine_enable;
|
||||||
|
} boot;
|
||||||
|
|
||||||
|
struct bootstrap_log_config {
|
||||||
|
char level[8];
|
||||||
|
char name[64];
|
||||||
|
char file[64];
|
||||||
|
uint32_t bufsz;
|
||||||
|
uint16_t output_delay_ms;
|
||||||
|
bool enable_console;
|
||||||
|
bool enable_sci;
|
||||||
|
bool enable_net;
|
||||||
|
bool enable_file;
|
||||||
|
bool rotate;
|
||||||
|
bool append;
|
||||||
|
uint16_t count;
|
||||||
|
} log;
|
||||||
|
|
||||||
|
struct bootstrap_minidump_config {
|
||||||
|
uint8_t count;
|
||||||
|
bool continue_;
|
||||||
|
bool log;
|
||||||
|
uint8_t type;
|
||||||
|
char path[64];
|
||||||
|
uint32_t symbufsz;
|
||||||
|
char search_path[64];
|
||||||
|
} minidump;
|
||||||
|
|
||||||
|
struct bootstrap_module_config {
|
||||||
|
char file[64];
|
||||||
|
char load_type[64];
|
||||||
|
struct property *app_config;
|
||||||
|
} module;
|
||||||
|
|
||||||
|
struct bootstrap_dlm_config {
|
||||||
|
char digest[16];
|
||||||
|
uint32_t size;
|
||||||
|
uint32_t ift_table;
|
||||||
|
uint32_t ift_insert;
|
||||||
|
uint32_t ift_remove;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct bootstrap_dlm_config dlm_ntdll;
|
||||||
|
|
||||||
|
struct bootstrap_shield_config {
|
||||||
|
bool enable;
|
||||||
|
bool verbose;
|
||||||
|
bool use_loadlibrary;
|
||||||
|
char logger[64];
|
||||||
|
uint32_t sleep_min;
|
||||||
|
uint32_t sleep_blur;
|
||||||
|
uint32_t tick_sleep;
|
||||||
|
uint32_t tick_error;
|
||||||
|
uint8_t overwork_threshold;
|
||||||
|
uint32_t overwork_delay;
|
||||||
|
uint32_t pause_delay;
|
||||||
|
char whitelist_file[64];
|
||||||
|
char unlimited_key[10];
|
||||||
|
uint16_t killer_port;
|
||||||
|
} shield;
|
||||||
|
|
||||||
|
struct bootstrap_dongle_config {
|
||||||
|
char license_cn[32];
|
||||||
|
char account_cn[32];
|
||||||
|
char driver_dll[16];
|
||||||
|
bool disable_gc;
|
||||||
|
} dongle;
|
||||||
|
|
||||||
|
struct bootstrap_drm_config {
|
||||||
|
char dll[64];
|
||||||
|
char device[64];
|
||||||
|
char mount[64];
|
||||||
|
char fstype[64];
|
||||||
|
char options[64];
|
||||||
|
} drm;
|
||||||
|
|
||||||
|
struct bootstrap_lte_config {
|
||||||
|
bool enable;
|
||||||
|
char config_file[64];
|
||||||
|
char unlimited_key[10];
|
||||||
|
} lte;
|
||||||
|
|
||||||
|
struct bootstrap_ssl_config {
|
||||||
|
char options[64];
|
||||||
|
} ssl;
|
||||||
|
|
||||||
|
struct bootstrap_esign_config {
|
||||||
|
bool enable;
|
||||||
|
} esign;
|
||||||
|
|
||||||
|
struct bootstrap_eamuse_config {
|
||||||
|
bool enable;
|
||||||
|
bool sync;
|
||||||
|
bool enable_model;
|
||||||
|
char config_file[64];
|
||||||
|
bool updatecert_enable;
|
||||||
|
uint32_t updatecert_interval;
|
||||||
|
} eamuse;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct bootstrap_config {
|
||||||
|
char release_code[16];
|
||||||
|
struct bootstrap_startup_config startup;
|
||||||
|
};
|
||||||
|
|
||||||
|
void bootstrap_config_init(struct bootstrap_config *config);
|
||||||
|
|
||||||
|
void bootstrap_config_load(
|
||||||
|
struct property *property,
|
||||||
|
const char *profile,
|
||||||
|
struct bootstrap_config *config);
|
||||||
|
|
||||||
|
#endif /* LAUNCHER_BOOTSTRAP_CONFIG_H */
|
||||||
347
src/main/launcher/bootstrap.c
Normal file
347
src/main/launcher/bootstrap.c
Normal file
@@ -0,0 +1,347 @@
|
|||||||
|
#define LOG_MODULE "bootstrap"
|
||||||
|
|
||||||
|
#include "core/log-bt.h"
|
||||||
|
#include "core/log-sink-file.h"
|
||||||
|
#include "core/log-sink-list.h"
|
||||||
|
#include "core/log-sink-null.h"
|
||||||
|
#include "core/log-sink-std.h"
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "launcher/avs-config.h"
|
||||||
|
#include "launcher/avs.h"
|
||||||
|
#include "launcher/bootstrap-config.h"
|
||||||
|
#include "launcher/ea3-ident-config.h"
|
||||||
|
#include "launcher/eamuse-config.h"
|
||||||
|
#include "launcher/eamuse.h"
|
||||||
|
#include "launcher/launcher-config.h"
|
||||||
|
#include "launcher/module.h"
|
||||||
|
#include "launcher/property-util.h"
|
||||||
|
|
||||||
|
#include "util/str.h"
|
||||||
|
|
||||||
|
static bool _bootstrap_log_property_configs;
|
||||||
|
static struct module_context _bootstrap_module_context;
|
||||||
|
|
||||||
|
static void _bootstrap_eamuse_ea3_ident_config_inject(
|
||||||
|
struct property_node *node, const struct ea3_ident_config *ea3_ident_config)
|
||||||
|
{
|
||||||
|
eamuse_config_id_softid_set(node, ea3_ident_config->softid);
|
||||||
|
eamuse_config_id_hardid_set(node, ea3_ident_config->hardid);
|
||||||
|
eamuse_config_id_pcbid_set(node, ea3_ident_config->pcbid);
|
||||||
|
eamuse_config_soft_model_set(node, ea3_ident_config->model);
|
||||||
|
eamuse_config_soft_dest_set(node, ea3_ident_config->dest);
|
||||||
|
eamuse_config_soft_spec_set(node, ea3_ident_config->spec);
|
||||||
|
eamuse_config_soft_rev_set(node, ea3_ident_config->rev);
|
||||||
|
eamuse_config_soft_ext_set(node, ea3_ident_config->ext);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
_bootstrap_avs_config_force_overrides_apply(struct property_node *node)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
avs_config_mode_product_set(node, true);
|
||||||
|
avs_config_net_raw_set(node, true);
|
||||||
|
avs_config_net_eaudp_set(node, true);
|
||||||
|
avs_config_sntp_ea_set(node, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _bootstrap_avs_config_log_overrides_apply(
|
||||||
|
struct property_node *node, const struct bootstrap_log_config *log_config)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(log_config);
|
||||||
|
|
||||||
|
avs_config_log_level_set(node, log_config->level);
|
||||||
|
avs_config_log_name_set(node, log_config->name);
|
||||||
|
avs_config_log_file_set(node, log_config->file);
|
||||||
|
avs_config_log_buffer_size_set(node, log_config->bufsz);
|
||||||
|
avs_config_log_output_delay_set(node, log_config->output_delay_ms);
|
||||||
|
avs_config_log_enable_console_set(node, log_config->enable_console);
|
||||||
|
avs_config_log_enable_sci_set(node, log_config->enable_sci);
|
||||||
|
avs_config_log_enable_net_set(node, log_config->enable_net);
|
||||||
|
avs_config_log_enable_file_set(node, log_config->enable_file);
|
||||||
|
avs_config_log_rotate_set(node, log_config->rotate);
|
||||||
|
avs_config_log_append_set(node, log_config->append);
|
||||||
|
avs_config_log_count_set(node, log_config->count);
|
||||||
|
}
|
||||||
|
|
||||||
|
static enum core_log_bt_log_level _bootstrap_log_map_level(const char *level)
|
||||||
|
{
|
||||||
|
if (str_eq(level, "fatal")) {
|
||||||
|
return CORE_LOG_BT_LOG_LEVEL_FATAL;
|
||||||
|
} else if (str_eq(level, "warning")) {
|
||||||
|
return CORE_LOG_BT_LOG_LEVEL_WARNING;
|
||||||
|
} else if (str_eq(level, "info")) {
|
||||||
|
return CORE_LOG_BT_LOG_LEVEL_INFO;
|
||||||
|
} else if (str_eq(level, "misc")) {
|
||||||
|
return CORE_LOG_BT_LOG_LEVEL_MISC;
|
||||||
|
} else if (str_eq(level, "all")) {
|
||||||
|
return CORE_LOG_BT_LOG_LEVEL_MISC;
|
||||||
|
} else if (str_eq(level, "disable")) {
|
||||||
|
return CORE_LOG_BT_LOG_LEVEL_OFF;
|
||||||
|
} else if (str_eq(level, "default")) {
|
||||||
|
return CORE_LOG_BT_LOG_LEVEL_WARNING;
|
||||||
|
} else {
|
||||||
|
log_fatal("Unknown log level string %s", level);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_init(bool log_property_configs)
|
||||||
|
{
|
||||||
|
log_info("init");
|
||||||
|
|
||||||
|
_bootstrap_log_property_configs = log_property_configs;
|
||||||
|
|
||||||
|
log_misc("init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_log_init(const struct bootstrap_log_config *config)
|
||||||
|
{
|
||||||
|
struct core_log_sink sinks[2];
|
||||||
|
struct core_log_sink sink_composed;
|
||||||
|
enum core_log_bt_log_level level;
|
||||||
|
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
log_info("log init");
|
||||||
|
|
||||||
|
// Shutdown old setup
|
||||||
|
core_log_bt_fini();
|
||||||
|
|
||||||
|
if (config->enable_file && strlen(config->file) > 0 &&
|
||||||
|
config->enable_console) {
|
||||||
|
core_log_sink_std_out_open(true, &sinks[0]);
|
||||||
|
core_log_sink_file_open(
|
||||||
|
config->file,
|
||||||
|
config->append,
|
||||||
|
config->rotate,
|
||||||
|
config->count,
|
||||||
|
&sinks[1]);
|
||||||
|
core_log_sink_list_open(sinks, 2, &sink_composed);
|
||||||
|
} else if (config->enable_file && strlen(config->file) > 0) {
|
||||||
|
core_log_sink_file_open(
|
||||||
|
config->file,
|
||||||
|
config->append,
|
||||||
|
config->rotate,
|
||||||
|
config->count,
|
||||||
|
&sink_composed);
|
||||||
|
} else if (config->enable_console) {
|
||||||
|
core_log_sink_std_out_open(true, &sink_composed);
|
||||||
|
} else {
|
||||||
|
core_log_sink_null_open(&sink_composed);
|
||||||
|
}
|
||||||
|
|
||||||
|
core_log_bt_init(&sink_composed);
|
||||||
|
|
||||||
|
level = _bootstrap_log_map_level(config->level);
|
||||||
|
core_log_bt_level_set(level);
|
||||||
|
|
||||||
|
log_misc("log init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_default_files_create(
|
||||||
|
const struct bootstrap_default_file_config *config)
|
||||||
|
{
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
log_info("default files create");
|
||||||
|
|
||||||
|
for (int i = 0; i < DEFAULT_FILE_MAX; i++) {
|
||||||
|
if (strlen(config->file[i].src) > 0 &&
|
||||||
|
strlen(config->file[i].dst) > 0) {
|
||||||
|
avs_fs_file_copy(config->file[i].src, config->file[i].dst);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
log_misc("default files create done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_avs_init(
|
||||||
|
const struct bootstrap_boot_config *config,
|
||||||
|
const struct bootstrap_log_config *log_config,
|
||||||
|
struct property *override_property)
|
||||||
|
{
|
||||||
|
struct property *file_property;
|
||||||
|
struct property *merged_property;
|
||||||
|
struct property_node *root_node;
|
||||||
|
|
||||||
|
log_assert(config);
|
||||||
|
log_assert(log_config);
|
||||||
|
log_assert(override_property);
|
||||||
|
|
||||||
|
log_info("avs init");
|
||||||
|
|
||||||
|
file_property = avs_config_load(config->config_file);
|
||||||
|
|
||||||
|
if (_bootstrap_log_property_configs) {
|
||||||
|
log_misc("avs-config from file: %s", config->config_file);
|
||||||
|
property_util_log(file_property);
|
||||||
|
}
|
||||||
|
|
||||||
|
merged_property =
|
||||||
|
avs_config_property_merge(file_property, override_property);
|
||||||
|
|
||||||
|
property_util_free(file_property);
|
||||||
|
|
||||||
|
if (_bootstrap_log_property_configs) {
|
||||||
|
log_misc("avs-config merged with overrides");
|
||||||
|
property_util_log(merged_property);
|
||||||
|
}
|
||||||
|
|
||||||
|
root_node = avs_config_root_get(merged_property);
|
||||||
|
|
||||||
|
_bootstrap_avs_config_force_overrides_apply(root_node);
|
||||||
|
_bootstrap_avs_config_log_overrides_apply(root_node, log_config);
|
||||||
|
|
||||||
|
if (_bootstrap_log_property_configs) {
|
||||||
|
log_misc("avs-config final");
|
||||||
|
property_util_log(merged_property);
|
||||||
|
}
|
||||||
|
|
||||||
|
avs_fs_assert_root_device_exists(root_node);
|
||||||
|
|
||||||
|
log_misc("Creating AVS file system directories...");
|
||||||
|
|
||||||
|
avs_fs_mountpoints_fs_dirs_create(root_node);
|
||||||
|
|
||||||
|
avs_init(root_node, config->avs_heap_size, config->std_heap_size);
|
||||||
|
|
||||||
|
property_util_free(merged_property);
|
||||||
|
|
||||||
|
log_misc("avs init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_eamuse_init(
|
||||||
|
const struct bootstrap_eamuse_config *config,
|
||||||
|
const struct ea3_ident_config *ea3_ident_config,
|
||||||
|
struct property *override_property)
|
||||||
|
{
|
||||||
|
struct property *file_property;
|
||||||
|
struct property *merged_property;
|
||||||
|
struct property_node *root_node;
|
||||||
|
|
||||||
|
log_assert(config);
|
||||||
|
log_assert(ea3_ident_config);
|
||||||
|
log_assert(override_property);
|
||||||
|
|
||||||
|
log_info("eamuse init");
|
||||||
|
|
||||||
|
if (config->enable) {
|
||||||
|
file_property = eamuse_config_avs_load(config->config_file);
|
||||||
|
|
||||||
|
if (_bootstrap_log_property_configs) {
|
||||||
|
log_misc("eamuse-config from file: %s", config->config_file);
|
||||||
|
property_util_log(file_property);
|
||||||
|
}
|
||||||
|
|
||||||
|
merged_property = property_util_merge(file_property, override_property);
|
||||||
|
|
||||||
|
property_util_free(file_property);
|
||||||
|
|
||||||
|
if (_bootstrap_log_property_configs) {
|
||||||
|
log_misc("eamuse-config merged with overrides");
|
||||||
|
property_util_log(merged_property);
|
||||||
|
}
|
||||||
|
|
||||||
|
root_node = eamuse_config_root_get(merged_property);
|
||||||
|
|
||||||
|
_bootstrap_eamuse_ea3_ident_config_inject(root_node, ea3_ident_config);
|
||||||
|
|
||||||
|
if (_bootstrap_log_property_configs) {
|
||||||
|
log_misc("eamuse-config final");
|
||||||
|
property_util_log(merged_property);
|
||||||
|
}
|
||||||
|
|
||||||
|
eamuse_init(root_node);
|
||||||
|
|
||||||
|
property_util_free(merged_property);
|
||||||
|
} else {
|
||||||
|
log_warning("Eamuse disabled");
|
||||||
|
}
|
||||||
|
|
||||||
|
log_misc("eamuse init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_module_init(
|
||||||
|
const struct bootstrap_module_config *module_config,
|
||||||
|
const struct array *iat_hook_dlls)
|
||||||
|
{
|
||||||
|
log_assert(module_config);
|
||||||
|
log_assert(iat_hook_dlls);
|
||||||
|
|
||||||
|
log_info("module init");
|
||||||
|
|
||||||
|
if (iat_hook_dlls->nitems > 0) {
|
||||||
|
log_info(
|
||||||
|
"Load game DLL with IAT hooks (%d): %s",
|
||||||
|
(uint32_t) iat_hook_dlls->nitems,
|
||||||
|
module_config->file);
|
||||||
|
|
||||||
|
module_with_iat_hooks_init(
|
||||||
|
&_bootstrap_module_context, module_config->file, iat_hook_dlls);
|
||||||
|
} else {
|
||||||
|
log_info("Load game DLL: %s", module_config->file);
|
||||||
|
|
||||||
|
module_init(&_bootstrap_module_context, module_config->file);
|
||||||
|
}
|
||||||
|
|
||||||
|
log_misc("module init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_module_game_init(
|
||||||
|
const struct bootstrap_module_config *module_config,
|
||||||
|
struct ea3_ident_config *ea3_ident_config)
|
||||||
|
{
|
||||||
|
struct property_node *node;
|
||||||
|
|
||||||
|
log_assert(module_config);
|
||||||
|
log_assert(ea3_ident_config);
|
||||||
|
|
||||||
|
log_info("module game init");
|
||||||
|
|
||||||
|
node = property_search(module_config->app_config, NULL, "/param");
|
||||||
|
|
||||||
|
if (!node) {
|
||||||
|
log_fatal("Missing param node on app-config");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (_bootstrap_log_property_configs) {
|
||||||
|
log_misc("app-config");
|
||||||
|
property_util_node_log(node);
|
||||||
|
}
|
||||||
|
|
||||||
|
module_init_invoke(&_bootstrap_module_context, ea3_ident_config, node);
|
||||||
|
|
||||||
|
log_misc("module game init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_module_game_run()
|
||||||
|
{
|
||||||
|
log_info("module game run");
|
||||||
|
|
||||||
|
module_main_invoke(&_bootstrap_module_context);
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_module_game_fini()
|
||||||
|
{
|
||||||
|
log_info("module game fini");
|
||||||
|
|
||||||
|
module_fini(&_bootstrap_module_context);
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_avs_fini()
|
||||||
|
{
|
||||||
|
log_info("avs fini");
|
||||||
|
|
||||||
|
avs_fini();
|
||||||
|
}
|
||||||
|
|
||||||
|
void bootstrap_eamuse_fini(const struct bootstrap_eamuse_config *config)
|
||||||
|
{
|
||||||
|
log_info("eamuse fini");
|
||||||
|
|
||||||
|
if (config->enable) {
|
||||||
|
eamuse_fini();
|
||||||
|
}
|
||||||
|
}
|
||||||
32
src/main/launcher/bootstrap.h
Normal file
32
src/main/launcher/bootstrap.h
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
#ifndef LAUNCHER_BOOTSTRAP_H
|
||||||
|
#define LAUNCHER_BOOTSTRAP_H
|
||||||
|
|
||||||
|
#include "launcher/bootstrap-config.h"
|
||||||
|
#include "launcher/ea3-ident-config.h"
|
||||||
|
|
||||||
|
#include "util/array.h"
|
||||||
|
|
||||||
|
void bootstrap_init(bool log_property_configs);
|
||||||
|
void bootstrap_log_init(const struct bootstrap_log_config *config);
|
||||||
|
void bootstrap_default_files_create(
|
||||||
|
const struct bootstrap_default_file_config *config);
|
||||||
|
void bootstrap_avs_init(
|
||||||
|
const struct bootstrap_boot_config *config,
|
||||||
|
const struct bootstrap_log_config *log_config,
|
||||||
|
struct property *override_property);
|
||||||
|
void bootstrap_eamuse_init(
|
||||||
|
const struct bootstrap_eamuse_config *config,
|
||||||
|
const struct ea3_ident_config *ea3_ident_config,
|
||||||
|
struct property *override_property);
|
||||||
|
void bootstrap_module_init(
|
||||||
|
const struct bootstrap_module_config *module_config,
|
||||||
|
const struct array *iat_hook_dlls);
|
||||||
|
void bootstrap_module_game_init(
|
||||||
|
const struct bootstrap_module_config *module_config,
|
||||||
|
struct ea3_ident_config *ea3_ident_config);
|
||||||
|
void bootstrap_module_game_run();
|
||||||
|
void bootstrap_module_game_fini();
|
||||||
|
void bootstrap_avs_fini();
|
||||||
|
void bootstrap_eamuse_fini(const struct bootstrap_eamuse_config *config);
|
||||||
|
|
||||||
|
#endif
|
||||||
33
src/main/launcher/debug.c
Normal file
33
src/main/launcher/debug.c
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
|
||||||
|
#define LOG_MODULE "debug"
|
||||||
|
|
||||||
|
#include <stdbool.h>
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "launcher/debug.h"
|
||||||
|
|
||||||
|
void debug_remote_debugger_trap()
|
||||||
|
{
|
||||||
|
BOOL res;
|
||||||
|
|
||||||
|
log_info("Waiting until debugger attaches to remote process...");
|
||||||
|
|
||||||
|
while (true) {
|
||||||
|
res = FALSE;
|
||||||
|
|
||||||
|
if (!CheckRemoteDebuggerPresent(GetCurrentProcess(), &res)) {
|
||||||
|
log_fatal(
|
||||||
|
"CheckRemoteDebuggerPresent failed: %08x",
|
||||||
|
(unsigned int) GetLastError());
|
||||||
|
}
|
||||||
|
|
||||||
|
if (res) {
|
||||||
|
log_info("Debugger attached, resuming");
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
Sleep(1000);
|
||||||
|
}
|
||||||
|
}
|
||||||
6
src/main/launcher/debug.h
Normal file
6
src/main/launcher/debug.h
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
#ifndef LAUNCHER_DEBUG_H
|
||||||
|
#define LAUNCHER_DEBUG_H
|
||||||
|
|
||||||
|
void debug_remote_debugger_trap();
|
||||||
|
|
||||||
|
#endif
|
||||||
@@ -1,190 +0,0 @@
|
|||||||
#include <string.h>
|
|
||||||
|
|
||||||
#include "imports/avs.h"
|
|
||||||
|
|
||||||
#include "launcher/ea3-config.h"
|
|
||||||
#include "launcher/module.h"
|
|
||||||
|
|
||||||
#include "util/defs.h"
|
|
||||||
#include "util/hex.h"
|
|
||||||
#include "util/log.h"
|
|
||||||
#include "util/str.h"
|
|
||||||
|
|
||||||
PSMAP_BEGIN(ea3_ident_psmap)
|
|
||||||
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct ea3_ident, softid, "/ea3/id/softid", "")
|
|
||||||
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct ea3_ident, hardid, "/ea3/id/hardid", "")
|
|
||||||
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct ea3_ident, pcbid, "/ea3/id/pcbid", "")
|
|
||||||
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident, model, "/ea3/soft/model")
|
|
||||||
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident, dest, "/ea3/soft/dest")
|
|
||||||
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident, spec, "/ea3/soft/spec")
|
|
||||||
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident, rev, "/ea3/soft/rev")
|
|
||||||
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident, ext, "/ea3/soft/ext")
|
|
||||||
PSMAP_END
|
|
||||||
|
|
||||||
void ea3_ident_init(struct ea3_ident *ident)
|
|
||||||
{
|
|
||||||
memset(ident, 0, sizeof(*ident));
|
|
||||||
}
|
|
||||||
|
|
||||||
bool ea3_ident_from_property(
|
|
||||||
struct ea3_ident *ident, struct property *ea3_config)
|
|
||||||
{
|
|
||||||
return property_psmap_import(ea3_config, NULL, ident, ea3_ident_psmap);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ea3_ident_hardid_from_ethernet(struct ea3_ident *ident)
|
|
||||||
{
|
|
||||||
struct avs_net_interface netif;
|
|
||||||
int result;
|
|
||||||
|
|
||||||
result = avs_net_ctrl(1, &netif, sizeof(netif));
|
|
||||||
|
|
||||||
if (result < 0) {
|
|
||||||
log_fatal(
|
|
||||||
"avs_net_ctrl call to get MAC address returned error: %d", result);
|
|
||||||
}
|
|
||||||
|
|
||||||
ident->hardid[0] = '0';
|
|
||||||
ident->hardid[1] = '1';
|
|
||||||
ident->hardid[2] = '0';
|
|
||||||
ident->hardid[3] = '0';
|
|
||||||
|
|
||||||
hex_encode_uc(
|
|
||||||
netif.mac_addr,
|
|
||||||
sizeof(netif.mac_addr),
|
|
||||||
ident->hardid + 4,
|
|
||||||
sizeof(ident->hardid) - 4);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool ea3_ident_invoke_module_init(
|
|
||||||
struct ea3_ident *ident,
|
|
||||||
const struct module_context *module,
|
|
||||||
struct property_node *app_config)
|
|
||||||
{
|
|
||||||
char sidcode_short[17];
|
|
||||||
char sidcode_long[21];
|
|
||||||
char security_code[9];
|
|
||||||
bool ok;
|
|
||||||
|
|
||||||
/* Set up security env vars */
|
|
||||||
|
|
||||||
str_format(
|
|
||||||
security_code,
|
|
||||||
lengthof(security_code),
|
|
||||||
"G*%s%s%s%s",
|
|
||||||
ident->model,
|
|
||||||
ident->dest,
|
|
||||||
ident->spec,
|
|
||||||
ident->rev);
|
|
||||||
|
|
||||||
std_setenv("/env/boot/version", "0.0.0");
|
|
||||||
std_setenv("/env/profile/security_code", security_code);
|
|
||||||
std_setenv("/env/profile/system_id", ident->pcbid);
|
|
||||||
std_setenv("/env/profile/account_id", ident->pcbid);
|
|
||||||
std_setenv("/env/profile/license_id", ident->softid);
|
|
||||||
std_setenv("/env/profile/software_id", ident->softid);
|
|
||||||
std_setenv("/env/profile/hardware_id", ident->hardid);
|
|
||||||
|
|
||||||
/* Set up the short sidcode string, let dll_entry_init mangle it */
|
|
||||||
|
|
||||||
str_format(
|
|
||||||
sidcode_short,
|
|
||||||
lengthof(sidcode_short),
|
|
||||||
"%s%s%s%s%s",
|
|
||||||
ident->model,
|
|
||||||
ident->dest,
|
|
||||||
ident->spec,
|
|
||||||
ident->rev,
|
|
||||||
ident->ext);
|
|
||||||
|
|
||||||
/* Set up long-form sidcode env var */
|
|
||||||
|
|
||||||
str_format(
|
|
||||||
sidcode_long,
|
|
||||||
lengthof(sidcode_long),
|
|
||||||
"%s:%s:%s:%s:%s",
|
|
||||||
ident->model,
|
|
||||||
ident->dest,
|
|
||||||
ident->spec,
|
|
||||||
ident->rev,
|
|
||||||
ident->ext);
|
|
||||||
|
|
||||||
/* Set this up beforehand, as certain games require it in dll_entry_init */
|
|
||||||
|
|
||||||
std_setenv("/env/profile/soft_id_code", sidcode_long);
|
|
||||||
|
|
||||||
ok = module_context_invoke_init(module, sidcode_short, app_config);
|
|
||||||
|
|
||||||
if (!ok) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Back-propagate sidcode, as some games modify it during init */
|
|
||||||
|
|
||||||
memcpy(ident->model, sidcode_short + 0, sizeof(ident->model) - 1);
|
|
||||||
ident->dest[0] = sidcode_short[3];
|
|
||||||
ident->spec[0] = sidcode_short[4];
|
|
||||||
ident->rev[0] = sidcode_short[5];
|
|
||||||
memcpy(ident->ext, sidcode_short + 6, sizeof(ident->ext));
|
|
||||||
|
|
||||||
/* Set up long-form sidcode env var again */
|
|
||||||
|
|
||||||
str_format(
|
|
||||||
sidcode_long,
|
|
||||||
lengthof(sidcode_long),
|
|
||||||
"%s:%s:%s:%s:%s",
|
|
||||||
ident->model,
|
|
||||||
ident->dest,
|
|
||||||
ident->spec,
|
|
||||||
ident->rev,
|
|
||||||
ident->ext);
|
|
||||||
|
|
||||||
std_setenv("/env/profile/soft_id_code", sidcode_long);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
void ea3_ident_to_property(
|
|
||||||
const struct ea3_ident *ident, struct property *ea3_config)
|
|
||||||
{
|
|
||||||
struct property_node *node;
|
|
||||||
int i;
|
|
||||||
|
|
||||||
for (i = 0; ea3_ident_psmap[i].type != 0xFF; i++) {
|
|
||||||
node = property_search(ea3_config, 0, ea3_ident_psmap[i].path);
|
|
||||||
|
|
||||||
if (node != NULL) {
|
|
||||||
property_node_remove(node);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
property_psmap_export(ea3_config, NULL, ident, ea3_ident_psmap);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ea3_ident_replace_property_bool(
|
|
||||||
struct property_node *node, const char *name, uint8_t val)
|
|
||||||
{
|
|
||||||
struct property_node *tmp;
|
|
||||||
|
|
||||||
tmp = property_search(NULL, node, name);
|
|
||||||
|
|
||||||
if (tmp) {
|
|
||||||
property_node_remove(tmp);
|
|
||||||
}
|
|
||||||
|
|
||||||
property_node_create(NULL, node, PROPERTY_TYPE_BOOL, name, val);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ea3_ident_replace_property_str(
|
|
||||||
struct property_node *node, const char *name, const char *val)
|
|
||||||
{
|
|
||||||
struct property_node *tmp;
|
|
||||||
|
|
||||||
tmp = property_search(NULL, node, name);
|
|
||||||
|
|
||||||
if (tmp) {
|
|
||||||
property_node_remove(tmp);
|
|
||||||
}
|
|
||||||
|
|
||||||
tmp = property_node_create(NULL, node, PROPERTY_TYPE_STR, name, val);
|
|
||||||
}
|
|
||||||
@@ -1,46 +0,0 @@
|
|||||||
#ifndef LAUNCHER_EA3_CONFIG_H
|
|
||||||
#define LAUNCHER_EA3_CONFIG_H
|
|
||||||
|
|
||||||
#include "imports/avs.h"
|
|
||||||
|
|
||||||
#include "launcher/module.h"
|
|
||||||
|
|
||||||
/* N.B. even though this might look like a Konami ABI, this is purely an
|
|
||||||
internal data structure. */
|
|
||||||
|
|
||||||
struct ea3_ident {
|
|
||||||
/* psmapped structure offset can't be zero for some stupid reason */
|
|
||||||
|
|
||||||
uint32_t dummy;
|
|
||||||
|
|
||||||
/* Initialized from ea3-config.xml, then fed back from sidcode_short */
|
|
||||||
|
|
||||||
char model[4];
|
|
||||||
char dest[4];
|
|
||||||
char spec[4];
|
|
||||||
char rev[4];
|
|
||||||
char ext[11];
|
|
||||||
|
|
||||||
/* Initialized from ea3-config.xml (hardware_id defaults to MAC addr) */
|
|
||||||
|
|
||||||
char softid[24];
|
|
||||||
char hardid[24];
|
|
||||||
char pcbid[24];
|
|
||||||
};
|
|
||||||
|
|
||||||
void ea3_ident_init(struct ea3_ident *ident);
|
|
||||||
bool ea3_ident_from_property(
|
|
||||||
struct ea3_ident *ident, struct property *ea3_config);
|
|
||||||
void ea3_ident_hardid_from_ethernet(struct ea3_ident *ident);
|
|
||||||
bool ea3_ident_invoke_module_init(
|
|
||||||
struct ea3_ident *ident,
|
|
||||||
const struct module_context *module,
|
|
||||||
struct property_node *app_config);
|
|
||||||
void ea3_ident_to_property(
|
|
||||||
const struct ea3_ident *ident, struct property *ea3_config);
|
|
||||||
void ea3_ident_replace_property_bool(
|
|
||||||
struct property_node *node, const char *name, uint8_t val);
|
|
||||||
void ea3_ident_replace_property_str(
|
|
||||||
struct property_node *node, const char *name, const char *val);
|
|
||||||
|
|
||||||
#endif
|
|
||||||
104
src/main/launcher/ea3-ident-config.c
Normal file
104
src/main/launcher/ea3-ident-config.c
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
#define LOG_MODULE "ea3-ident-config"
|
||||||
|
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
#include "launcher/ea3-ident-config.h"
|
||||||
|
#include "launcher/property-util.h"
|
||||||
|
|
||||||
|
#include "util/defs.h"
|
||||||
|
#include "util/hex.h"
|
||||||
|
#include "util/str.h"
|
||||||
|
|
||||||
|
#define ROOT_NODE "/ea3_conf"
|
||||||
|
|
||||||
|
PSMAP_BEGIN(ea3_ident_config_psmap)
|
||||||
|
PSMAP_OPTIONAL(
|
||||||
|
PSMAP_TYPE_STR, struct ea3_ident_config, softid, "/id/softid", "")
|
||||||
|
PSMAP_OPTIONAL(
|
||||||
|
PSMAP_TYPE_STR, struct ea3_ident_config, hardid, "/id/hardid", "")
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_STR, struct ea3_ident_config, pcbid, "/id/pcbid", "")
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident_config, model, "/soft/model")
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident_config, dest, "/soft/dest")
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident_config, spec, "/soft/spec")
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident_config, rev, "/soft/rev")
|
||||||
|
PSMAP_REQUIRED(PSMAP_TYPE_STR, struct ea3_ident_config, ext, "/soft/ext")
|
||||||
|
PSMAP_END
|
||||||
|
|
||||||
|
void ea3_ident_config_init(struct ea3_ident_config *config)
|
||||||
|
{
|
||||||
|
memset(config, 0, sizeof(*config));
|
||||||
|
}
|
||||||
|
|
||||||
|
void ea3_ident_config_from_file_load(
|
||||||
|
const char *path, struct ea3_ident_config *config)
|
||||||
|
{
|
||||||
|
struct property *property;
|
||||||
|
|
||||||
|
log_assert(path);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
log_info("Loading from file path: %s", path);
|
||||||
|
|
||||||
|
property = property_util_load(path);
|
||||||
|
|
||||||
|
ea3_ident_config_load(property, config);
|
||||||
|
|
||||||
|
property_util_free(property);
|
||||||
|
}
|
||||||
|
|
||||||
|
void ea3_ident_config_load(
|
||||||
|
struct property *property, struct ea3_ident_config *config)
|
||||||
|
{
|
||||||
|
struct property_node *node;
|
||||||
|
|
||||||
|
log_assert(property);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
node = property_search(property, NULL, ROOT_NODE);
|
||||||
|
|
||||||
|
if (node == NULL) {
|
||||||
|
log_fatal("Root node '" ROOT_NODE "' missing");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!property_psmap_import(
|
||||||
|
property, node, config, ea3_ident_config_psmap)) {
|
||||||
|
log_fatal("Error reading config file");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool ea3_ident_config_hardid_is_defined(struct ea3_ident_config *config)
|
||||||
|
{
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
return strlen(config->hardid) > 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ea3_ident_config_hardid_from_ethernet_set(struct ea3_ident_config *config)
|
||||||
|
{
|
||||||
|
struct avs_net_interface netif;
|
||||||
|
int result;
|
||||||
|
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
result = avs_net_ctrl(1, &netif, sizeof(netif));
|
||||||
|
|
||||||
|
if (result < 0) {
|
||||||
|
log_fatal(
|
||||||
|
"avs_net_ctrl call to get MAC address returned error: %d", result);
|
||||||
|
}
|
||||||
|
|
||||||
|
config->hardid[0] = '0';
|
||||||
|
config->hardid[1] = '1';
|
||||||
|
config->hardid[2] = '0';
|
||||||
|
config->hardid[3] = '0';
|
||||||
|
|
||||||
|
hex_encode_uc(
|
||||||
|
netif.mac_addr,
|
||||||
|
sizeof(netif.mac_addr),
|
||||||
|
config->hardid + 4,
|
||||||
|
sizeof(config->hardid) - 4);
|
||||||
|
}
|
||||||
37
src/main/launcher/ea3-ident-config.h
Normal file
37
src/main/launcher/ea3-ident-config.h
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
#ifndef LAUNCHER_EA3_IDENT_CONFIG_H
|
||||||
|
#define LAUNCHER_EA3_IDENT_CONFIG_H
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
/* N.B. even though this might look like a Konami ABI, this is purely an
|
||||||
|
internal data structure. */
|
||||||
|
|
||||||
|
struct ea3_ident_config {
|
||||||
|
/* psmapped structure offset can't be zero for some stupid reason */
|
||||||
|
|
||||||
|
uint32_t dummy;
|
||||||
|
|
||||||
|
/* Initialized from ea3-config.xml, then fed back from sidcode_short */
|
||||||
|
|
||||||
|
char model[4];
|
||||||
|
char dest[4];
|
||||||
|
char spec[4];
|
||||||
|
char rev[4];
|
||||||
|
char ext[11];
|
||||||
|
|
||||||
|
/* Initialized from ea3-config.xml (hardware_id defaults to MAC addr) */
|
||||||
|
|
||||||
|
char softid[24];
|
||||||
|
char hardid[24];
|
||||||
|
char pcbid[24];
|
||||||
|
};
|
||||||
|
|
||||||
|
void ea3_ident_config_init(struct ea3_ident_config *config);
|
||||||
|
void ea3_ident_config_from_file_load(
|
||||||
|
const char *path, struct ea3_ident_config *config);
|
||||||
|
void ea3_ident_config_load(
|
||||||
|
struct property *property, struct ea3_ident_config *config);
|
||||||
|
bool ea3_ident_config_hardid_is_defined(struct ea3_ident_config *config);
|
||||||
|
void ea3_ident_config_hardid_from_ethernet_set(struct ea3_ident_config *config);
|
||||||
|
|
||||||
|
#endif
|
||||||
125
src/main/launcher/eamuse-config.c
Normal file
125
src/main/launcher/eamuse-config.c
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
#define LOG_MODULE "eamuse-config"
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
#include "launcher/ea3-ident-config.h"
|
||||||
|
#include "launcher/eamuse-config.h"
|
||||||
|
#include "launcher/property-util.h"
|
||||||
|
|
||||||
|
#define EAMUSE_CONFIG_ROOT_NODE "/ea3"
|
||||||
|
|
||||||
|
struct property *eamuse_config_avs_load(const char *path)
|
||||||
|
{
|
||||||
|
struct property *property;
|
||||||
|
|
||||||
|
log_assert(path);
|
||||||
|
|
||||||
|
log_misc("Loading from avs path: %s", path);
|
||||||
|
|
||||||
|
property = property_util_avs_fs_load(path);
|
||||||
|
|
||||||
|
// Check if root node exists, call already errors if not
|
||||||
|
eamuse_config_root_get(property);
|
||||||
|
|
||||||
|
return property;
|
||||||
|
}
|
||||||
|
|
||||||
|
struct property_node *eamuse_config_root_get(struct property *property)
|
||||||
|
{
|
||||||
|
struct property_node *node;
|
||||||
|
|
||||||
|
log_assert(property);
|
||||||
|
|
||||||
|
node = property_search(property, 0, EAMUSE_CONFIG_ROOT_NODE);
|
||||||
|
|
||||||
|
if (node == NULL) {
|
||||||
|
log_fatal("Root node " EAMUSE_CONFIG_ROOT_NODE
|
||||||
|
" in eamuse config missing");
|
||||||
|
}
|
||||||
|
|
||||||
|
return node;
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_id_softid_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "id/softid", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_id_hardid_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "id/hardid", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_id_pcbid_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "id/pcbid", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_soft_model_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "soft/model", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_soft_dest_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "soft/dest", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_soft_spec_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "soft/spec", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_soft_rev_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "soft/rev", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_soft_ext_set(struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "soft/ext", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_network_url_slash_set(struct property_node *node, bool value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
property_util_node_bool_replace(NULL, node, "network/url_slash", value);
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_config_network_service_url_set(
|
||||||
|
struct property_node *node, const char *value)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(value);
|
||||||
|
|
||||||
|
property_util_node_str_replace(NULL, node, "network/services", value);
|
||||||
|
}
|
||||||
23
src/main/launcher/eamuse-config.h
Normal file
23
src/main/launcher/eamuse-config.h
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
#ifndef LAUNCHER_EAMUSE_CONFIG_H
|
||||||
|
#define LAUNCHER_EAMUSE_CONFIG_H
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
struct property *eamuse_config_avs_load(const char *path);
|
||||||
|
struct property_node *eamuse_config_root_get(struct property *property);
|
||||||
|
|
||||||
|
void eamuse_config_id_softid_set(struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_id_hardid_set(struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_id_pcbid_set(struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_soft_model_set(
|
||||||
|
struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_soft_dest_set(struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_soft_spec_set(struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_soft_rev_set(struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_soft_ext_set(struct property_node *node, const char *value);
|
||||||
|
void eamuse_config_network_url_slash_set(
|
||||||
|
struct property_node *node, bool value);
|
||||||
|
void eamuse_config_network_service_url_set(
|
||||||
|
struct property_node *node, const char *value);
|
||||||
|
|
||||||
|
#endif
|
||||||
25
src/main/launcher/eamuse.c
Normal file
25
src/main/launcher/eamuse.c
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
#define LOG_MODULE "eamuse"
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "imports/avs-ea3.h"
|
||||||
|
|
||||||
|
void eamuse_init(struct property_node *node)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
log_info("init");
|
||||||
|
|
||||||
|
ea3_boot(node);
|
||||||
|
|
||||||
|
log_misc("init done");
|
||||||
|
}
|
||||||
|
|
||||||
|
void eamuse_fini()
|
||||||
|
{
|
||||||
|
log_info("fini");
|
||||||
|
|
||||||
|
ea3_shutdown();
|
||||||
|
|
||||||
|
log_misc("fini done");
|
||||||
|
}
|
||||||
9
src/main/launcher/eamuse.h
Normal file
9
src/main/launcher/eamuse.h
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
#ifndef LAUNCHER_EAMUSE_H
|
||||||
|
#define LAUNCHER_EAMUSE_H
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
void eamuse_init(struct property_node *node);
|
||||||
|
void eamuse_fini();
|
||||||
|
|
||||||
|
#endif
|
||||||
34
src/main/launcher/hook.c
Normal file
34
src/main/launcher/hook.c
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
#define LOG_MODULE "hook"
|
||||||
|
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "launcher/hook.h"
|
||||||
|
|
||||||
|
void hook_load_dll(const char *path)
|
||||||
|
{
|
||||||
|
log_assert(path);
|
||||||
|
|
||||||
|
log_info("Load hook dll: %s", path);
|
||||||
|
|
||||||
|
if (LoadLibraryA(path) == NULL) {
|
||||||
|
LPSTR buffer;
|
||||||
|
|
||||||
|
FormatMessageA(
|
||||||
|
FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM |
|
||||||
|
FORMAT_MESSAGE_IGNORE_INSERTS,
|
||||||
|
NULL,
|
||||||
|
GetLastError(),
|
||||||
|
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
|
||||||
|
(LPSTR) &buffer,
|
||||||
|
0,
|
||||||
|
NULL);
|
||||||
|
|
||||||
|
log_fatal("%s: Failed to load hook DLL: %s", path, buffer);
|
||||||
|
|
||||||
|
LocalFree(buffer);
|
||||||
|
}
|
||||||
|
|
||||||
|
log_misc("Load hook dll done");
|
||||||
|
}
|
||||||
6
src/main/launcher/hook.h
Normal file
6
src/main/launcher/hook.h
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
#ifndef LAUNCHER_HOOK_H
|
||||||
|
#define LAUNCHER_HOOK_H
|
||||||
|
|
||||||
|
void hook_load_dll(const char *path);
|
||||||
|
|
||||||
|
#endif
|
||||||
371
src/main/launcher/launcher-config.c
Normal file
371
src/main/launcher/launcher-config.c
Normal file
@@ -0,0 +1,371 @@
|
|||||||
|
#define LOG_MODULE "launcher-config"
|
||||||
|
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
#include "core/log.h"
|
||||||
|
|
||||||
|
#include "imports/avs.h"
|
||||||
|
|
||||||
|
#include "launcher/launcher-config.h"
|
||||||
|
#include "launcher/property-util.h"
|
||||||
|
|
||||||
|
#include "util/mem.h"
|
||||||
|
#include "util/str.h"
|
||||||
|
|
||||||
|
// clang-format off
|
||||||
|
PSMAP_BEGIN(launcher_debug_psmap)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct launcher_debug_config, remote_debugger,
|
||||||
|
"debug/remote_debugger", false)
|
||||||
|
PSMAP_OPTIONAL(PSMAP_TYPE_BOOL, struct launcher_debug_config, log_property_configs,
|
||||||
|
"debug/log_property_configs", false)
|
||||||
|
PSMAP_END
|
||||||
|
// clang-format on
|
||||||
|
|
||||||
|
#define ROOT_NODE "/launcher"
|
||||||
|
#define MAX_LAYER_CONFIG_NODES 8
|
||||||
|
|
||||||
|
#define NODE_MISSING_FATAL(subnode) \
|
||||||
|
log_fatal("%s/%s: Node missing", ROOT_NODE, subnode);
|
||||||
|
#define NODE_LOADING_FATAL(subnode) \
|
||||||
|
log_fatal("%s/%s: Node loading", ROOT_NODE, subnode);
|
||||||
|
|
||||||
|
static struct property *
|
||||||
|
_launcher_config_layered_config_nodes_load(struct property_node *node)
|
||||||
|
{
|
||||||
|
char kind[64];
|
||||||
|
char file[MAX_PATH];
|
||||||
|
int res;
|
||||||
|
int cnt;
|
||||||
|
|
||||||
|
struct property_node *cur;
|
||||||
|
struct property *config_property[MAX_LAYER_CONFIG_NODES];
|
||||||
|
struct property *merged_property;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
|
||||||
|
cnt = 0;
|
||||||
|
cur = property_search(NULL, node, "config");
|
||||||
|
|
||||||
|
while (cur) {
|
||||||
|
if (cnt >= MAX_LAYER_CONFIG_NODES) {
|
||||||
|
log_fatal(
|
||||||
|
"Exceeding max supported config nodes for layering, max is %d",
|
||||||
|
MAX_LAYER_CONFIG_NODES);
|
||||||
|
}
|
||||||
|
|
||||||
|
res = property_node_refer(
|
||||||
|
NULL, cur, "kind@", PROPERTY_TYPE_ATTR, kind, sizeof(kind));
|
||||||
|
|
||||||
|
if (res < 0) {
|
||||||
|
log_fatal("Failed reading 'kind' attribute value of config node");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!strcmp(kind, "file")) {
|
||||||
|
property_node_read(cur, PROPERTY_TYPE_STR, file, sizeof(file));
|
||||||
|
|
||||||
|
config_property[cnt] = property_util_load(file);
|
||||||
|
} else if (!strcmp(kind, "inline")) {
|
||||||
|
// The nested child is the actual root of the inline, not the outer
|
||||||
|
// <config> node
|
||||||
|
cur = property_node_traversal(cur, TRAVERSE_FIRST_CHILD);
|
||||||
|
|
||||||
|
config_property[cnt] = property_util_node_extract(cur);
|
||||||
|
} else {
|
||||||
|
log_fatal(
|
||||||
|
"Unsupported 'kind' attribute value '%s' of config node", kind);
|
||||||
|
}
|
||||||
|
|
||||||
|
cnt++;
|
||||||
|
cur = property_node_traversal(cur, TRAVERSE_NEXT_SEARCH_RESULT);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (cnt == 0) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
merged_property = property_util_many_merge(config_property, cnt);
|
||||||
|
|
||||||
|
for (int i = 0; i < cnt; i++) {
|
||||||
|
property_util_free(config_property[i]);
|
||||||
|
}
|
||||||
|
|
||||||
|
return merged_property;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _launcher_config_hook_dlls_parse(
|
||||||
|
struct property_node *node,
|
||||||
|
const char *node_path,
|
||||||
|
char dlls[LAUNCHER_CONFIG_MAX_HOOK_DLL][MAX_PATH])
|
||||||
|
{
|
||||||
|
int cnt;
|
||||||
|
struct property_node *cur;
|
||||||
|
|
||||||
|
cnt = 0;
|
||||||
|
cur = property_search(NULL, node, node_path);
|
||||||
|
|
||||||
|
while (cur) {
|
||||||
|
if (cnt >= LAUNCHER_CONFIG_MAX_HOOK_DLL) {
|
||||||
|
log_warning(
|
||||||
|
"Currently not supporting more than %d dlls, skipping "
|
||||||
|
"remaining",
|
||||||
|
cnt);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
property_node_read(cur, PROPERTY_TYPE_STR, dlls[cnt], MAX_PATH);
|
||||||
|
|
||||||
|
cnt++;
|
||||||
|
cur = property_node_traversal(cur, TRAVERSE_NEXT_SEARCH_RESULT);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _launcher_config_bootstrap_load(
|
||||||
|
struct property_node *node, struct launcher_bootstrap_config *config)
|
||||||
|
{
|
||||||
|
int res;
|
||||||
|
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
res = property_node_refer(
|
||||||
|
NULL,
|
||||||
|
node,
|
||||||
|
"selector",
|
||||||
|
PROPERTY_TYPE_STR,
|
||||||
|
config->selector,
|
||||||
|
sizeof(config->selector));
|
||||||
|
|
||||||
|
if (res < 0) {
|
||||||
|
NODE_MISSING_FATAL("bootstrap/selector");
|
||||||
|
}
|
||||||
|
|
||||||
|
config->property = _launcher_config_layered_config_nodes_load(node);
|
||||||
|
|
||||||
|
if (config->property == NULL) {
|
||||||
|
NODE_MISSING_FATAL("bootstrap/config");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _launcher_config_hook_load(
|
||||||
|
struct property_node *node, struct launcher_hook_config *config)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
_launcher_config_hook_dlls_parse(node, "hook_dlls/dll", config->hook_dlls);
|
||||||
|
_launcher_config_hook_dlls_parse(
|
||||||
|
node, "before_hook_dlls/dll", config->before_hook_dlls);
|
||||||
|
_launcher_config_hook_dlls_parse(
|
||||||
|
node, "iat_hook_dlls/dll", config->iat_hook_dlls);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void _launcher_config_debug_load(
|
||||||
|
struct property_node *node, struct launcher_debug_config *config)
|
||||||
|
{
|
||||||
|
log_assert(node);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
if (!property_psmap_import(NULL, node, config, launcher_debug_psmap)) {
|
||||||
|
NODE_LOADING_FATAL("debug");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void launcher_config_init(struct launcher_config *config)
|
||||||
|
{
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
memset(config->bootstrap.selector, 0, sizeof(config->bootstrap.selector));
|
||||||
|
config->bootstrap.property = NULL;
|
||||||
|
|
||||||
|
config->avs.property = NULL;
|
||||||
|
|
||||||
|
config->ea3_ident.property = NULL;
|
||||||
|
|
||||||
|
config->eamuse.property = NULL;
|
||||||
|
|
||||||
|
memset(config->hook.hook_dlls, 0, sizeof(config->hook.hook_dlls));
|
||||||
|
memset(
|
||||||
|
config->hook.before_hook_dlls,
|
||||||
|
0,
|
||||||
|
sizeof(config->hook.before_hook_dlls));
|
||||||
|
memset(config->hook.iat_hook_dlls, 0, sizeof(config->hook.iat_hook_dlls));
|
||||||
|
|
||||||
|
config->debug.remote_debugger = false;
|
||||||
|
config->debug.log_property_configs = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void launcher_config_load(
|
||||||
|
struct property *property, struct launcher_config *config)
|
||||||
|
{
|
||||||
|
struct property_node *root_node;
|
||||||
|
struct property_node *node;
|
||||||
|
avs_error error;
|
||||||
|
|
||||||
|
log_assert(property);
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
root_node = property_search(property, NULL, ROOT_NODE);
|
||||||
|
|
||||||
|
if (root_node == NULL) {
|
||||||
|
NODE_MISSING_FATAL("");
|
||||||
|
}
|
||||||
|
|
||||||
|
error = property_node_refer(
|
||||||
|
NULL,
|
||||||
|
root_node,
|
||||||
|
"version@",
|
||||||
|
PROPERTY_TYPE_ATTR,
|
||||||
|
&config->version,
|
||||||
|
sizeof(uint32_t));
|
||||||
|
|
||||||
|
if (AVS_IS_ERROR(error)) {
|
||||||
|
log_fatal("Missing version attribute on root node");
|
||||||
|
}
|
||||||
|
|
||||||
|
// if (config->version != 1) {
|
||||||
|
// log_fatal("Unsupported version of launcher configuration: %d",
|
||||||
|
// config->version);
|
||||||
|
// }
|
||||||
|
|
||||||
|
node = property_search(NULL, root_node, "bootstrap");
|
||||||
|
|
||||||
|
if (node == NULL) {
|
||||||
|
NODE_MISSING_FATAL("bootstrap");
|
||||||
|
}
|
||||||
|
|
||||||
|
_launcher_config_bootstrap_load(node, &config->bootstrap);
|
||||||
|
|
||||||
|
node = property_search(NULL, root_node, "avs");
|
||||||
|
|
||||||
|
if (node) {
|
||||||
|
config->avs.property = _launcher_config_layered_config_nodes_load(node);
|
||||||
|
}
|
||||||
|
|
||||||
|
node = property_search(NULL, root_node, "ea3_ident");
|
||||||
|
|
||||||
|
if (node) {
|
||||||
|
config->ea3_ident.property =
|
||||||
|
_launcher_config_layered_config_nodes_load(node);
|
||||||
|
}
|
||||||
|
|
||||||
|
node = property_search(NULL, root_node, "eamuse");
|
||||||
|
|
||||||
|
if (node) {
|
||||||
|
config->eamuse.property =
|
||||||
|
_launcher_config_layered_config_nodes_load(node);
|
||||||
|
}
|
||||||
|
|
||||||
|
node = property_search(NULL, root_node, "hook");
|
||||||
|
|
||||||
|
if (node) {
|
||||||
|
_launcher_config_hook_load(node, &config->hook);
|
||||||
|
}
|
||||||
|
|
||||||
|
_launcher_config_debug_load(root_node, &config->debug);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool launcher_config_add_hook_dll(
|
||||||
|
struct launcher_config *config, const char *path)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
log_assert(config);
|
||||||
|
log_assert(path);
|
||||||
|
|
||||||
|
i = 0;
|
||||||
|
|
||||||
|
while (i < LAUNCHER_CONFIG_MAX_HOOK_DLL) {
|
||||||
|
if (strlen(config->hook.hook_dlls[i]) == 0) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
i++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i >= LAUNCHER_CONFIG_MAX_HOOK_DLL) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
str_cpy(config->hook.hook_dlls[i], sizeof(config->hook.hook_dlls[i]), path);
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool launcher_config_add_before_hook_dll(
|
||||||
|
struct launcher_config *config, const char *path)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
log_assert(config);
|
||||||
|
log_assert(path);
|
||||||
|
|
||||||
|
i = 0;
|
||||||
|
|
||||||
|
while (i < LAUNCHER_CONFIG_MAX_HOOK_DLL) {
|
||||||
|
if (strlen(config->hook.before_hook_dlls[i]) == 0) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
i++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i >= LAUNCHER_CONFIG_MAX_HOOK_DLL) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
str_cpy(
|
||||||
|
config->hook.before_hook_dlls[i],
|
||||||
|
sizeof(config->hook.before_hook_dlls[i]),
|
||||||
|
path);
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool launcher_config_add_iat_hook_dll(
|
||||||
|
struct launcher_config *config, const char *path)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
log_assert(config);
|
||||||
|
log_assert(path);
|
||||||
|
|
||||||
|
i = 0;
|
||||||
|
|
||||||
|
while (i < LAUNCHER_CONFIG_MAX_HOOK_DLL) {
|
||||||
|
if (strlen(config->hook.iat_hook_dlls[i]) == 0) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
i++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i >= LAUNCHER_CONFIG_MAX_HOOK_DLL) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
str_cpy(
|
||||||
|
config->hook.iat_hook_dlls[i],
|
||||||
|
sizeof(config->hook.iat_hook_dlls[i]),
|
||||||
|
path);
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void launcher_config_fini(struct launcher_config *config)
|
||||||
|
{
|
||||||
|
log_assert(config);
|
||||||
|
|
||||||
|
property_util_free(config->bootstrap.property);
|
||||||
|
|
||||||
|
if (config->avs.property) {
|
||||||
|
property_util_free(config->avs.property);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (config->ea3_ident.property) {
|
||||||
|
property_util_free(config->ea3_ident.property);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (config->eamuse.property) {
|
||||||
|
property_util_free(config->eamuse.property);
|
||||||
|
}
|
||||||
|
}
|
||||||
56
src/main/launcher/launcher-config.h
Normal file
56
src/main/launcher/launcher-config.h
Normal file
@@ -0,0 +1,56 @@
|
|||||||
|
#ifndef LAUNCHER_CONFIG_H
|
||||||
|
#define LAUNCHER_CONFIG_H
|
||||||
|
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
|
#include "util/array.h"
|
||||||
|
|
||||||
|
#define LAUNCHER_CONFIG_MAX_HOOK_DLL 16
|
||||||
|
|
||||||
|
struct launcher_config {
|
||||||
|
uint32_t version;
|
||||||
|
|
||||||
|
struct launcher_bootstrap_config {
|
||||||
|
char selector[128];
|
||||||
|
struct property *property;
|
||||||
|
} bootstrap;
|
||||||
|
|
||||||
|
struct launcher_avs_config {
|
||||||
|
struct property *property;
|
||||||
|
} avs;
|
||||||
|
|
||||||
|
struct launcher_ea3_ident_config {
|
||||||
|
struct property *property;
|
||||||
|
} ea3_ident;
|
||||||
|
|
||||||
|
struct launcher_eamuse_config {
|
||||||
|
struct property *property;
|
||||||
|
} eamuse;
|
||||||
|
|
||||||
|
struct launcher_hook_config {
|
||||||
|
char hook_dlls[LAUNCHER_CONFIG_MAX_HOOK_DLL][MAX_PATH];
|
||||||
|
char before_hook_dlls[LAUNCHER_CONFIG_MAX_HOOK_DLL][MAX_PATH];
|
||||||
|
char iat_hook_dlls[LAUNCHER_CONFIG_MAX_HOOK_DLL][MAX_PATH];
|
||||||
|
} hook;
|
||||||
|
|
||||||
|
struct launcher_debug_config {
|
||||||
|
bool remote_debugger;
|
||||||
|
bool log_property_configs;
|
||||||
|
} debug;
|
||||||
|
};
|
||||||
|
|
||||||
|
void launcher_config_init(struct launcher_config *config);
|
||||||
|
|
||||||
|
void launcher_config_load(
|
||||||
|
struct property *property, struct launcher_config *config);
|
||||||
|
|
||||||
|
bool launcher_config_add_hook_dll(
|
||||||
|
struct launcher_config *config, const char *path);
|
||||||
|
bool launcher_config_add_before_hook_dll(
|
||||||
|
struct launcher_config *config, const char *path);
|
||||||
|
bool launcher_config_add_iat_hook_dll(
|
||||||
|
struct launcher_config *config, const char *path);
|
||||||
|
|
||||||
|
void launcher_config_fini(struct launcher_config *config);
|
||||||
|
|
||||||
|
#endif
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user