OSDN Git Service

63b497232ff102ed2b66d24655fd85a4f9cb709b
[csp-qt/common_source_project-fm7.git] / source / readme_by_artane.txt
1 ** Qt porting for Common Source Code Project **
2                                          July 13, 2018
3               K.Ohta <whatisthis.sowhat _at_ gmail.com>
4
5 * If you can't read Japanese, read readme.qt.txt .
6
7 0. 概要
8    このパッケージは、Common Source Code Project (以下、CSP)
9    をQt5に移植したものです。
10    バイナリはGNU/Linux(64bit)用とMinGW (32bit Windows)用を
11    用意しています。
12    
13    ソースコード:
14    
15      https://github.com/Artanejp/common_source_project-fm7/releases/tag/SNAPSHOT_20180713
16
17    追加情報:
18    
19      各機種バイナリーは、osdn.net もしくはミラーサイトより入手可能です。
20     
21     https://osdn.net/projects/csp-qt/  
22    
23      https://osdn.net/projects/csp-qt/releases/ をチェックしてください。
24
25     Win32: 
26
27     GNU/Linux(amd64) : 
28
29 【おねがい】
30       doc/以下の文書で日本語しかなかったものを英語に翻訳していますが、機械翻訳を使ってるのであやしいです。
31      
32        英語の上手い方、校正などお願いします m(_ _)m
33
34 1. 背景
35
36    CSPは、非常に優れた構造のエミュレータです(しかし、些か重くてコンパイラ
37    がいい最適化をしないと重めですが)。
38    しかし、このコードはM$ Visual C++依存の部分が非常に多いです。
39    そこで、GNU/Linuxでこれを動かすためにQtに色々と移植していきましょう。
40    と言う感じで作業をはじめました。
41
42 2. 最低限必要なもの(Qt版)
43
44    a. Qt5 ツールキット。Qt 5.5以降を推奨します。
45    
46    b. OpenGL, 多分、最低OpenGL 2.1は必要です。(注:ひょっとしたら、OpenGLES2以降ならば動くように変えるかも知れない)
47    
48    c. gcc / g++ (5.0以降?)もしくは llvm clang / clang++ (3.5以降?)
49       コンパイラツールチェーン。
50       
51    d. SDL2 (SDL 1.xではないので注意)
52    
53    e. CMake 2.8以降。
54    
55    f. ffmpegから、libavとlibswが必要です。 http://ffmpeg.org/ より。
56    
57    g. ffmpegは、Windowsに関してはバンドルしてありますので、動かない時はインストールしてみてください。
58       
59    h. Qt5.5(Ubuntu 16.04LTS向け)もしくはQt5.10(Win32とDebian GNU/Linux sid向け)でビルドしてあります。
60    
61    i. 表示基盤のデフォルトが、OpenGL ES2.0になりました。コマンドラインオプション --opengl で変更が可能です(--helpで参照)
62    
63    * Windows もしくは GNU/Linux のcross tool chain (要Wine)で、MinGW (gcc6) と Qt 5.10 でのビルドができることを確認しました。     
64    * TIPS:
65    
66      * Windows等で動かした時に、画面の書き替えが表示されない場合は、環境変数 QT_OPENGL を software にしてみてください。(例えば、
67        WindowsをVirtualBoxのゲストで使ってる場合など)
68        
69      * Windows版バイナリには、ソフトウェアレンダリングのopengl32.dllが添付されてますが、最近のパソコンの専用GPUドライバなら、
70        もっと程度のいいOpenGLが入ってるはずです。
71        添付版opengl32.dllを適当な名前に変更して動くかどうか試してみて下さい。
72      
73 3. ビルドの方法
74
75    ソースコードを解凍するか、git clone / pull した後で:
76    
77    $ cd {srctop}/source/build-cmake/{Machine name}/
78    $ mkdir build
79    $ cd build
80    
81    To configure:
82    
83    $ cmake ..
84    
85    or
86    
87    $ ccmake ..
88
89    To build:
90    
91    $ make
92
93    To install:
94    
95    $ sudo make install
96
97 4. Qt固有の話
98
99    * 設定ファイル(scancode.cfg と foo.ini)は、"~/.config/CommonSourceCodeProject/emufoo/" (Windowsの場合は".\CommonSourceCodeProject\emudfoo\" ) におかれます(移動しました)。
100
101    * BIOSや効果音WAVやセーブステートは、、"~/CommonSourceCodeProject/emufoo/" (Windowsの場合は".\CommonSourceCodeProject\emudfoo\" ) におかれます(移動しました)。
102    
103    * 全ての記録物(スクリーンショットや動画や録音WAV)は、*当面の間* "~/CommonSourceCodeProject/emufoo/" (Windowsの場合は".\CommonSourceCodeProject\emudfoo\" ) におかれます。
104
105    * ToolTipsを付けました。(2017-01-24)
106       
107    * 日本語に翻訳しました。(2017-01-24)
108    
109    
110    * キーコード変換テーブルファイルが、$HOME/.config/CommonSourceCodeProject/emu{Machine Name}/scancode.cfg に書き込まれます。
111    
112      書式は、カンマで区切られた16進データです(10進ではないので注意) .
113      
114      1カラム目はM$ ヴァーチャルキーコード。
115      
116      2カラム目はQtネィティブのスキャンキーコードです。
117      
118    * UI部分の共通コンポーネント (src/qt/gui) を共有ライブラリlibCSPgui.soにまとめました。
119    
120    * インストール用のBASHスクリプトを用意しました。src/tool/installer_unix.shです。
121    
122    * ROMと同じところに、特定のWAVファイル(VMによって異なる)を入れると、FDDのシーク音やテープのボタン音・リレー音を鳴らすことが出来ます。
123    
124    * ローマ字カタカナ変換支援機構が一部の機種に実装されてます。romaji_kana.ja.txt をお読みください。
125     
126 5. 移植状況
127    
128    a.現在、Debian GNU/Linux "sid"と、Ubuntu Linux 16.04LTS "Xenial"
129      の AMD64版でしかテストしていません。
130     が、多分他のGNU/Linux OSやBSD系のOS (Mac含む) でもビルドすれば
131     動くでしょう。
132      Windows もしくは GNU/Linux(要Wineとbinfmt-support)上でのMinGWと
133      Qt community edition でのビルドが通るようになりました。
134       
135    b. 今は、Qtの開発側が「Qt4おわりね」とアナウンスしたので、Qt4ではなく
136       Qt5を使っています。
137       添付してあるバイナリは、Qt 5.5でビルドしました(が、Qt 5.1以降なら動くはずです)。
138
139    c. Linux用ビルドでは、GCCをリンク時最適化(LTO)モードで使っています。
140    d. MZ-2500のソケット機能を実装してみていますが、マトモにテストできてません(;´Д`)
141    
142 6. Upstream repositry:
143       https://github.com/Artanejp/common_source_project-fm7
144       
145       https://osdn.net/projects/csp-qt/scm/git/common_source_project-fm7
146
147 7. Project Page:
148       https://osdn.jp/projects/csp-qt/
149
150 8. Upstream (Takeda Toshiyaさんのオリジナル) 
151       http://takeda-toshiya.my.coocan.jp/
152
153
154 Special thanks to:
155   Ryu Takegamiさん : eFM-8/7/77/AV/40/EX のデバッグに協力していただいています。
156   はせりんさん     : eFM-8/7/77/AV/40/EX のデバッグに協力していただいています。
157 Changes:
158
159 * 前の変更点をお読みになる場合には、ChangeLogと000_gitlog.txtをお読み下さい。
160
161 * SNAPSHOT July 13, 2018
162   * Upstream 2018-05-24 .
163   * [STATE] Apply new state save/load framework.See doc/a_new_state_save_load_framework.ja.txt (still only written in Japanese).
164   * [STATE] Use CRC32 protection to data.
165   * [STATE] Add header per devices.
166   * [EMU/STATE] Enable to Gzip'ed state saving / loading.
167   * [CONFIG/Bug] I forgot change top default of renderer. X-)
168   * [VM/X1] Copy VRAMs to shadow data at starting a frame.Reduce flickering a lot.
169   * [VM/PC9801] DISPLAY: Keep memory switch settings (saved to MEMSW.BIN).
170   * [VM/I386] Remove compiler warning conversion float64 (a.k.a UINT64) <-> double.
171               This still not regard when sizeof(double) != sizeof(UINT64).
172   * [VM/FM7][SOUND/BEEP] Set samplerate to 6000Hz.Simplize logic.
173   * [VM/DATAREC] Fix crash at removing CMT when not stopping to play.
174   * [VM/DATAREC] Fix crash with MZT data.
175   * [VM/NOISE] Adjust endian of WAV data.
176   * [VM/NOISE] Fix infinity loop with corruptWAV data.
177   * [VM/MC6809] Collect CPU statistics always, printing is controlled by menu immediately.
178   * [VM/Z80] Add collecting cpu status feature for Z80.
179   * [OSD/SOUND] Qt: Fix hang-up with resetting at some situations.
180                 Try to fix issue of http://matsuri.5ch.net/test/read.cgi/i4004/1526806551/38 .
181   * [COMMON] Fix buffer overflow around strncpy().
182   * [COMMON] Add pair16_t and pair64_t.
183   * [COMMON] Add immediate value functions for pair_t.
184   * [COMMON][VM/Qt] Add common wav-loading / saving helper functions to common.cpp .
185   * [COMMON] Update min() and max().
186   * [FILEIO] Add FILEIO::Fflush().
187   * [FMGEN/PSG] Fix weird noise generation for SSG/PSG.
188   * [FMGEN/OPNBASE] Force to calculate frequency factors around prescaler when OPNBase::LoadState().
189                     Fix wrong sound after loding state.
190   * [FMGEN/OPNA] Fix infinity loop at loading rhythm WAVs.
191   * [FMGEN/OPNA] Adjust endian of WAV data (maybe).
192   * [Qt/OpenGL] Fix buffer overflow when changing VM's screen size.
193   * [Qt/Bug] Remove using_flags->get_config_ptr()->foo.
194   * [Qt/MAIN] LOGGER: Fix crash on exit.
195   * [Qt/LOGGER] CSP_Logger makes daughter of QObject.Add messaging slot entry.
196   * [Qt/LOGGER] Use QVector insterad of QQueue to reduce CPU usage.
197   * [Qt/LOGGER] Bug: Logging all devices.
198   * [Qt/OpenGLES] TRY: Reduce power consumption.
199   * [Qt/OpenGL] Prepare to use OpenGL 4.x (CORE).
200   * [Qt/OpenGLES] Prepare to use OpenGL ES 3.1.
201   * [Qt/OpenGLES] Delete condition branch in shader, use #ifdef and const values.
202   * [Qt/OpenGL] Re-Add screen rotate.
203   * [BUILD/CMAKE] Add "USE_SANITIZER" and "USE_STACK_PROTECTOR" entries to buildvars_foo.dat[.tmpl]
204                   to detect wrong usage of variables / protect from stack overflow.
205   * [BUILD/CMAKE] FM7: Not build IO::, this is not used.
206   * [Qt/WIN32] Move config and logger to inner pointer, now, libCSPavio is separated to single DLL.
207   * [Qt/WIN32] Move CSP_Logger to libCSPemu_utils.[foo.so|dll] from libCSPgui.[foo.so|dll] .
208   * [WIN32] Update cross build script.
209   * Built with 9275209c6bed03ccd06716a486e29451c446751d or later.
210
211 -- July 13, 2018 13:09:15 +0900 K.Ohta <whatisthis.sowhat@gmail.com>
212
213 本家の変更:
214 * 前の変更点をお読みになる場合には、history.txtをお読み下さい。
215
216 5/24/2018
217
218 [COMMON] import Mr.Artane.'s fixes (Commits on May 10, 2018)
219 [COMMON/FIFO] import Mr.Artane.'s fixes (Commits on May 10, 2018)
220 [EMU] support set_vm_screen_lines() (thanks Mr.Artane.)
221 [EMU] fix interfaces for bubble cassette
222 [EMU] add interfaces for hard disk
223 [WINMAIN] add interfaces for hard disk
224
225 [VM/DEVICE] support read_debug_reg()
226 [VM/DISK] import Mr.Artane.'s fixes (Commits on May 10, 2018)
227 [VM/HARDDISK] support hard disk handler
228 [VM/I286] improve i286 core based on MAME 0.197
229 [VM/I286] support read_debug_reg()
230 [VM/I386] support read_debug_reg()
231 [VM/I8237] fix verify command
232 [VM/I8237] support to read bank register by read_signal()
233 [VM/MC6809] import Mr.Artane.'s fixes (Commits on May 10, 2018)
234 [VM/SCSI_DEV] support SASI specify command
235 [VM/SCSI_HDD] improve to use hard disk handler
236 [VM/SCSI_HOST] support to read ack signal
237
238 [BUBCOM80] support Systems Formulate BUBCOM80
239 [FM77AV] import Mr.Artane.'s fixes (Commits on May 10, 2018)
240 [FMR30] support to change hard disk image
241 [FMR50] support to change hard disk image
242 [FMR50/BIOS] improve to use hard disk handler
243 [MZ2500] support to select floppy drive type 2DD/2D
244 [MZ2500] support to change hard disk image
245 [MZ2500/MZ1E30] reimplent SASI I/F with general SCSI host/hard disk device
246 [PC9801/CPUREG] support NMI enable/disable
247 [PC9801/MEMBUS] improve for 24bit/32bit address
248 [PC9801/SASI] support SASI I/F and hard disk drives
249 [X1TURBO/SASI] support SASI I/F and hard disk drives
250
251 -----
252
253 お楽しみあれ!
254 -- Ohta.