Thread: [Fuse-for-macosx-commits] SF.net SVN: fuse-for-macosx:[534] trunk
Brought to you by:
fredm
From: <fr...@us...> - 2008-10-21 12:05:59
|
Revision: 534 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=534&view=rev Author: fredm Date: 2008-10-21 12:05:43 +0000 (Tue, 21 Oct 2008) Log Message: ----------- Merge up to vendor revision 3775. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=3775&view=rev Modified Paths: -------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj trunk/FuseGenerator/LibspectrumSCRExtractor.m trunk/FuseGenerator/generate.pl trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj trunk/FuseImporter/LibspectrumMetadataImporter.m trunk/FuseImporter/generate.pl trunk/FuseImporter/libspectrum.h trunk/fuse/Makefile.am trunk/fuse/README trunk/fuse/compat/amiga/Makefile.am trunk/fuse/compat/morphos/Makefile.am trunk/fuse/compat/unix/Makefile.am trunk/fuse/compat/unix/osname.c trunk/fuse/compat/win32/Makefile.am trunk/fuse/compat.h trunk/fuse/configure.in trunk/fuse/dck.c trunk/fuse/debugger/Makefile.am trunk/fuse/debugger/breakpoint.c trunk/fuse/debugger/breakpoint.h trunk/fuse/debugger/command.c trunk/fuse/debugger/commandl.l trunk/fuse/debugger/commandy.y trunk/fuse/debugger/debugger.c trunk/fuse/debugger/debugger.h trunk/fuse/debugger/debugger_internals.h trunk/fuse/debugger/expression.c trunk/fuse/disk/beta.c trunk/fuse/disk/beta.h trunk/fuse/disk/disk.c trunk/fuse/disk/fdd.c trunk/fuse/disk/fdd.h trunk/fuse/disk/plusd.c trunk/fuse/disk/plusd.h trunk/fuse/disk/upd_fdc.c trunk/fuse/disk/upd_fdc.h trunk/fuse/disk/wd_fdc.c trunk/fuse/disk/wd_fdc.h trunk/fuse/divide.c trunk/fuse/event.c trunk/fuse/event.h trunk/fuse/fuse.c trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/controllers/DebuggerController.m trunk/fuse/fusepb/models/Emulator.m trunk/fuse/hacking/ChangeLog trunk/fuse/if1.c trunk/fuse/input.c trunk/fuse/input.h trunk/fuse/keysyms.pl trunk/fuse/loader.c trunk/fuse/machine.c trunk/fuse/machines/specplus3.h trunk/fuse/memory.c trunk/fuse/menu.c trunk/fuse/menu.h trunk/fuse/menu_data.dat trunk/fuse/menu_data.pl trunk/fuse/periph.c trunk/fuse/periph.h trunk/fuse/profile.c trunk/fuse/rzx.c trunk/fuse/rzx.h trunk/fuse/screenshot.c trunk/fuse/settings.dat trunk/fuse/simpleide.c trunk/fuse/snapshot.c trunk/fuse/sound/alsasound.c trunk/fuse/sound/dxsound.c trunk/fuse/sound/win32sound.c trunk/fuse/spectrum.c trunk/fuse/spectrum.h trunk/fuse/tape.c trunk/fuse/tape.h trunk/fuse/timer/timer.c trunk/fuse/timer/timer.h trunk/fuse/ui/cocoa/cocoajoystick.c trunk/fuse/ui/fb/fbdisplay.c trunk/fuse/ui/gtk/debugger.c trunk/fuse/ui/gtk/gtkjoystick.c trunk/fuse/ui/gtk/gtkkeyboard.c trunk/fuse/ui/gtk/gtkui.c trunk/fuse/ui/options.dat trunk/fuse/ui/scaler/scalers.c trunk/fuse/ui/sdl/sdldisplay.c trunk/fuse/ui/sdl/sdljoystick.c trunk/fuse/ui/svga/svgadisplay.c trunk/fuse/ui/svga/svgajoystick.c trunk/fuse/ui/uidisplay.h trunk/fuse/ui/uijoystick.c trunk/fuse/ui/widget/Makefile.am trunk/fuse/ui/widget/browse.c trunk/fuse/ui/widget/debugger.c trunk/fuse/ui/widget/error.c trunk/fuse/ui/widget/filesel.c trunk/fuse/ui/widget/memory.c trunk/fuse/ui/widget/menu.c trunk/fuse/ui/widget/options.pl trunk/fuse/ui/widget/picture.c trunk/fuse/ui/widget/pokefinder.c trunk/fuse/ui/widget/query.c trunk/fuse/ui/widget/roms.c trunk/fuse/ui/widget/select.c trunk/fuse/ui/widget/text.c trunk/fuse/ui/widget/widget.c trunk/fuse/ui/widget/widget.h trunk/fuse/ui/widget/widget_internals.h trunk/fuse/ui/win32/Makefile.am trunk/fuse/ui/win32/binary.c trunk/fuse/ui/win32/binary.rc trunk/fuse/ui/win32/browse.c trunk/fuse/ui/win32/browse.h trunk/fuse/ui/win32/browse.rc trunk/fuse/ui/win32/debugger.c trunk/fuse/ui/win32/debugger.h trunk/fuse/ui/win32/debugger.rc trunk/fuse/ui/win32/memorybrowser.c trunk/fuse/ui/win32/memorybrowser.h trunk/fuse/ui/win32/memorybrowser.rc trunk/fuse/ui/win32/options-header.pl trunk/fuse/ui/win32/options-resource.pl trunk/fuse/ui/win32/options.pl trunk/fuse/ui/win32/picture.c trunk/fuse/ui/win32/picture.h trunk/fuse/ui/win32/picture.rc trunk/fuse/ui/win32/pokefinder.c trunk/fuse/ui/win32/pokefinder.h trunk/fuse/ui/win32/pokefinder.rc trunk/fuse/ui/win32/rollback.c trunk/fuse/ui/win32/rollback.rc trunk/fuse/ui/win32/roms.c trunk/fuse/ui/win32/roms.rc trunk/fuse/ui/win32/select_template.rc trunk/fuse/ui/win32/statusbar.c trunk/fuse/ui/win32/win32display.c trunk/fuse/ui/win32/win32internals.h trunk/fuse/ui/win32/win32joystick.c trunk/fuse/ui/win32/win32joystick.rc trunk/fuse/ui/win32/win32keyboard.c trunk/fuse/ui/win32/win32ui.c trunk/fuse/ui/xlib/xdisplay.c trunk/fuse/ui/xlib/xui.c trunk/fuse/unittests/unittests.c trunk/fuse/utils.c trunk/fuse/z80/coretest.c trunk/fuse/z80/tests/tests.expected trunk/fuse/z80/tests/tests.in trunk/fuse/z80/z80.c trunk/fuse/z80/z80.h trunk/fuse/z80/z80.pl trunk/fuse/z80/z80_ops.c trunk/fuse/zxatasp.c trunk/fuse/zxcf.c trunk/libspectrum/generate.pl trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/accessor.pl trunk/libspectrum/libspectrum/bzip2.c trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/creator.c trunk/libspectrum/libspectrum/crypto.c trunk/libspectrum/libspectrum/csw.c trunk/libspectrum/libspectrum/dck.c trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/ide.c trunk/libspectrum/libspectrum/internals.h trunk/libspectrum/libspectrum/libspectrum.c trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/make-perl.c trunk/libspectrum/libspectrum/microdrive.c trunk/libspectrum/libspectrum/myglib/Makefile.am trunk/libspectrum/libspectrum/myglib/ghash.c trunk/libspectrum/libspectrum/myglib/gslist.c trunk/libspectrum/libspectrum/plusd.c trunk/libspectrum/libspectrum/rzx.c trunk/libspectrum/libspectrum/sna.c trunk/libspectrum/libspectrum/snapshot.c trunk/libspectrum/libspectrum/sp.c trunk/libspectrum/libspectrum/szx.c trunk/libspectrum/libspectrum/tap.c trunk/libspectrum/libspectrum/tape.c trunk/libspectrum/libspectrum/tape_block.c trunk/libspectrum/libspectrum/tape_block.h trunk/libspectrum/libspectrum/test/Makefile.am trunk/libspectrum/libspectrum/test/edges.c trunk/libspectrum/libspectrum/test/test.c trunk/libspectrum/libspectrum/test/test.h trunk/libspectrum/libspectrum/test/test15.c trunk/libspectrum/libspectrum/tzx_read.c trunk/libspectrum/libspectrum/tzx_write.c trunk/libspectrum/libspectrum/warajevo_read.c trunk/libspectrum/libspectrum/wav.c trunk/libspectrum/libspectrum/z80.c trunk/libspectrum/libspectrum/z80em.c trunk/libspectrum/libspectrum/zlib.c trunk/libspectrum/libspectrum/zxs.c trunk/libspectrum/libspectrum.h trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj Added Paths: ----------- trunk/fuse/PORTING trunk/fuse/compat/unix/file.c trunk/fuse/compat/wii/ trunk/fuse/compat/wii/Makefile.am trunk/fuse/compat/wii/file.c trunk/fuse/debugger/event.c trunk/fuse/debugger/variable.c trunk/fuse/mempool.c trunk/fuse/mempool.h trunk/fuse/ui/win32/confirm.c trunk/fuse/ui/win32/fileselector.c trunk/libspectrum/libspectrum/memory.c trunk/libspectrum/libspectrum/myglib/garray.c trunk/libspectrum/libspectrum/test/writeprotected.mdr Removed Paths: ------------- trunk/fuse/compat/wii/Makefile.am trunk/fuse/compat/wii/file.c trunk/fuse/ui/win32/error.c trunk/fuse/ui/win32/win32display.h trunk/fuse/ui/win32/win32keyboard.h Property Changed: ---------------- trunk/fuse/ trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2008-10-21 12:05:43 UTC (rev 534) @@ -16,6 +16,8 @@ B63944FB0D18C7C30059DAA5 /* tape_accessors.txt in Sources */ = {isa = PBXBuildFile; fileRef = B6D30B2E0D162B910036CC54 /* tape_accessors.txt */; }; B63944FC0D18C7C30059DAA5 /* snap_accessors.txt in Sources */ = {isa = PBXBuildFile; fileRef = B6D30B2C0D162B810036CC54 /* snap_accessors.txt */; }; B63945090D18CA120059DAA5 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B63945080D18CA120059DAA5 /* Cocoa.framework */; }; + B67F1E790E93A39800246616 /* garray.c in Sources */ = {isa = PBXBuildFile; fileRef = B67F1E780E93A39800246616 /* garray.c */; }; + B67F1E7B0E93A3AF00246616 /* memory.c in Sources */ = {isa = PBXBuildFile; fileRef = B67F1E7A0E93A3AF00246616 /* memory.c */; }; B6D30AE60D1627ED0036CC54 /* bzip2.c in Sources */ = {isa = PBXBuildFile; fileRef = B6D30AE50D1627ED0036CC54 /* bzip2.c */; }; B6D30AEC0D16280E0036CC54 /* creator.c in Sources */ = {isa = PBXBuildFile; fileRef = B6D30AE70D16280E0036CC54 /* creator.c */; }; B6D30AED0D16280E0036CC54 /* crypto.c in Sources */ = {isa = PBXBuildFile; fileRef = B6D30AE80D16280E0036CC54 /* crypto.c */; }; @@ -107,6 +109,8 @@ B63944A90D18B0430059DAA5 /* LibspectrumSCRExtractor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LibspectrumSCRExtractor.m; sourceTree = "<group>"; }; B63944CB0D18C1CD0059DAA5 /* config.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = config.h; sourceTree = SOURCE_ROOT; }; B63945080D18CA120059DAA5 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = "<absolute>"; }; + B67F1E780E93A39800246616 /* garray.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = garray.c; path = ../../../libspectrum/libspectrum/myglib/garray.c; sourceTree = "<group>"; }; + B67F1E7A0E93A3AF00246616 /* memory.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = memory.c; path = ../../libspectrum/libspectrum/memory.c; sourceTree = "<group>"; }; B6D30AE30D1627C90036CC54 /* libspectrum.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = libspectrum.h; path = ../libspectrum.h; sourceTree = "<group>"; }; B6D30AE50D1627ED0036CC54 /* bzip2.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bzip2.c; sourceTree = "<group>"; }; B6D30AE70D16280E0036CC54 /* creator.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = creator.c; sourceTree = "<group>"; }; @@ -251,6 +255,7 @@ B6D30AF20D1628470036CC54 /* internals.h */, B6D30AF30D1628470036CC54 /* libspectrum.c */, B6D30AE30D1627C90036CC54 /* libspectrum.h */, + B67F1E7A0E93A3AF00246616 /* memory.c */, B6D30AF70D16288A0036CC54 /* microdrive.c */, B6D30AF90D1628A10036CC54 /* plusd.c */, B6D30AFB0D1628DB0036CC54 /* rzx.c */, @@ -280,6 +285,7 @@ B6D30B230D1629DC0036CC54 /* myglib */ = { isa = PBXGroup; children = ( + B67F1E780E93A39800246616 /* garray.c */, B6D30B250D162A130036CC54 /* ghash.c */, B6D30B260D162A130036CC54 /* gslist.c */, ); @@ -431,6 +437,8 @@ B6D30B4C0D1653510036CC54 /* ColourMacros.c in Sources */, B6D30B510D1653730036CC54 /* JWSpectrumScreen.m in Sources */, B63944AB0D18B0430059DAA5 /* LibspectrumSCRExtractor.m in Sources */, + B67F1E790E93A39800246616 /* garray.c in Sources */, + B67F1E7B0E93A3AF00246616 /* memory.c in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; Modified: trunk/FuseGenerator/LibspectrumSCRExtractor.m =================================================================== --- trunk/FuseGenerator/LibspectrumSCRExtractor.m 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseGenerator/LibspectrumSCRExtractor.m 2008-10-21 12:05:43 UTC (rev 534) @@ -194,8 +194,7 @@ int seen_scr_header = 0; - error = libspectrum_tape_alloc( &tape ); - if( error != LIBSPECTRUM_ERROR_NONE ) { return; } + tape = libspectrum_tape_alloc(); error = libspectrum_tape_read( tape, buffer, length, LIBSPECTRUM_ID_UNKNOWN, [filename UTF8String] ); @@ -326,7 +325,7 @@ libspectrum_rzx *rzx; libspectrum_snap *snap; - error = libspectrum_rzx_alloc( &rzx ); if( error ) return; + rzx = libspectrum_rzx_alloc(); error = libspectrum_rzx_read( rzx, buffer, length ); if( error != LIBSPECTRUM_ERROR_NONE ) { return; } @@ -348,8 +347,7 @@ int error = 0; libspectrum_snap *snap; - error = libspectrum_snap_alloc( &snap ); - if( error != LIBSPECTRUM_ERROR_NONE ) { return; } + snap = libspectrum_snap_alloc(); error = libspectrum_snap_read( snap, buffer, length, type, [filename UTF8String] ); Modified: trunk/FuseGenerator/generate.pl =================================================================== --- trunk/FuseGenerator/generate.pl 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseGenerator/generate.pl 2008-10-21 12:05:43 UTC (rev 534) @@ -25,7 +25,9 @@ #define TRUE (!FALSE) #endif +typedef char gchar; typedef int gint; +typedef long glong; typedef gint gboolean; typedef unsigned int guint; typedef const void * gconstpointer; @@ -94,6 +96,9 @@ gint WIN32_DLL g_int_equal (gconstpointer v, gconstpointer v2); guint WIN32_DLL g_int_hash (gconstpointer v); +gint WIN32_DLL g_str_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_str_hash (gconstpointer v); GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); @@ -113,6 +118,25 @@ guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +typedef struct _GArray GArray; + +struct _GArray { + /* Public */ + gchar *data; + size_t len; + + /* Private */ + guint element_size; + size_t allocated; +}; + +GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); +#define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); +GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +#define g_array_index(a,t,i) (*(((t*)a->data)+i)) +GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); + #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) CODE Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseGenerator/libspectrum.h 2008-10-21 12:05:43 UTC (rev 534) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3595 2008-04-01 10:51:58Z pak21 $ + $Id: libspectrum.h.in 3771 2008-09-11 11:23:17Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -84,7 +84,9 @@ #define TRUE (!FALSE) #endif +typedef char gchar; typedef int gint; +typedef long glong; typedef gint gboolean; typedef unsigned int guint; typedef const void * gconstpointer; @@ -153,6 +155,9 @@ gint WIN32_DLL g_int_equal (gconstpointer v, gconstpointer v2); guint WIN32_DLL g_int_hash (gconstpointer v); +gint WIN32_DLL g_str_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_str_hash (gconstpointer v); GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); @@ -172,6 +177,25 @@ guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +typedef struct _GArray GArray; + +struct _GArray { + /* Public */ + gchar *data; + size_t len; + + /* Private */ + guint element_size; + size_t allocated; +}; + +GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); +#define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); +GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +#define g_array_index(a,t,i) (*(((t*)a->data)+i)) +GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); + #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) @@ -225,6 +249,27 @@ libspectrum_default_error_function( libspectrum_error error, const char *format, va_list ap ); +/* Memory allocators */ + +typedef void* (*libspectrum_malloc_fn_t)( size_t size ); +typedef void* (*libspectrum_calloc_fn_t)( size_t nmemb, size_t size ); +typedef void* (*libspectrum_realloc_fn_t)( void *ptr, size_t size ); +typedef void (*libspectrum_free_fn_t)( void *ptr ); + +typedef struct libspectrum_mem_vtable_t { + libspectrum_malloc_fn_t malloc; + libspectrum_calloc_fn_t calloc; + libspectrum_realloc_fn_t realloc; + libspectrum_free_fn_t free; +} libspectrum_mem_vtable_t; + +void* WIN32_DLL libspectrum_malloc( size_t size ); +void* WIN32_DLL libspectrum_calloc( size_t nmemb, size_t size ); +void* WIN32_DLL libspectrum_realloc( void *ptr, size_t size ); +void WIN32_DLL libspectrum_free( void *ptr ); + +void WIN32_DLL libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ); + /* Attempt to identify a given file */ /* Various types of file we might manage to identify */ @@ -445,9 +490,9 @@ typedef struct libspectrum_creator libspectrum_creator; +libspectrum_creator* WIN32_DLL +libspectrum_creator_alloc( void ); libspectrum_error WIN32_DLL -libspectrum_creator_alloc( libspectrum_creator **creator ); -libspectrum_error WIN32_DLL libspectrum_creator_free( libspectrum_creator *creator ); libspectrum_error WIN32_DLL @@ -490,7 +535,7 @@ typedef struct libspectrum_snap libspectrum_snap; -libspectrum_error WIN32_DLL libspectrum_snap_alloc( libspectrum_snap **snap ); +libspectrum_snap* WIN32_DLL libspectrum_snap_alloc( void ); libspectrum_error WIN32_DLL libspectrum_snap_free( libspectrum_snap *snap ); /* Read in a snapshot, optionally guessing what type it is */ @@ -605,7 +650,7 @@ void WIN32_DLL libspectrum_snap_set_interface1_drive_count( libspectrum_snap *snap, int interface1_drive_count ); int WIN32_DLL libspectrum_snap_interface1_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_interface1_custom_rom( libspectrum_snap *snap, int interface1_custom_rom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_interface1_rom( libspectrum_snap * snap, int idx ); +libspectrum_byte WIN32_DLL * libspectrum_snap_interface1_rom( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_interface1_rom( libspectrum_snap *snap, int idx, libspectrum_byte* interface1_rom ); size_t WIN32_DLL libspectrum_snap_interface1_rom_length( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_interface1_rom_length( libspectrum_snap *snap, int idx, size_t interface1_rom_length ); @@ -727,7 +772,7 @@ void WIN32_DLL libspectrum_snap_set_simpleide_active( libspectrum_snap *snap, int simpleide_active ); int WIN32_DLL libspectrum_snap_divide_active( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_divide_active( libspectrum_snap *snap, int divide_active ); -int WIN32_DLL libspectrum_snap_divide_eprom_writeprotect( libspectrum_snap *snap); +int WIN32_DLL libspectrum_snap_divide_eprom_writeprotect( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_divide_eprom_writeprotect( libspectrum_snap *snap, int divide_eprom_writeprotect ); int WIN32_DLL libspectrum_snap_divide_paged( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_divide_paged( libspectrum_snap *snap, int divide_paged ); @@ -737,10 +782,9 @@ void WIN32_DLL libspectrum_snap_set_divide_pages( libspectrum_snap *snap, size_t divide_pages ); libspectrum_byte WIN32_DLL * libspectrum_snap_divide_eprom( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_eprom( libspectrum_snap *snap, int idx, libspectrum_byte* divide_eprom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap , int idx ); +libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_ram( libspectrum_snap *snap, int idx, libspectrum_byte* divide_ram ); - /* DEPRECATED: use libspectrum_snap_read() instead */ DEPRECATED libspectrum_error WIN32_DLL @@ -835,10 +879,9 @@ } libspectrum_tape_state_type; /* Routines to manipulate tape blocks */ +libspectrum_tape_block* WIN32_DLL +libspectrum_tape_block_alloc( libspectrum_tape_type type ); libspectrum_error WIN32_DLL -libspectrum_tape_block_alloc( libspectrum_tape_block **block, - libspectrum_tape_type type ); -libspectrum_error WIN32_DLL libspectrum_tape_block_free( libspectrum_tape_block *block ); libspectrum_tape_type WIN32_DLL libspectrum_tape_block_type( libspectrum_tape_block *block ); @@ -857,6 +900,9 @@ int WIN32_DLL libspectrum_tape_block_metadata( libspectrum_tape_block *block ); +libspectrum_dword +libspectrum_tape_block_length( libspectrum_tape_block *block ); + /* Accessor functions */ libspectrum_dword WIN32_DLL libspectrum_tape_block_bit_length( libspectrum_tape_block *block ); libspectrum_error WIN32_DLL libspectrum_tape_block_set_bit_length( libspectrum_tape_block *block, libspectrum_dword bit_length ); @@ -916,7 +962,7 @@ /* A linked list of tape blocks */ typedef struct libspectrum_tape libspectrum_tape; -libspectrum_error WIN32_DLL libspectrum_tape_alloc( libspectrum_tape **tape ); +libspectrum_tape* WIN32_DLL libspectrum_tape_alloc( void ); libspectrum_error WIN32_DLL libspectrum_tape_clear( libspectrum_tape *tape ); libspectrum_error WIN32_DLL libspectrum_tape_free( libspectrum_tape *tape ); @@ -969,15 +1015,15 @@ libspectrum_tape_nth_block( libspectrum_tape *tape, int n ); /* Append a block to the current tape */ -libspectrum_error WIN32_DLL +void WIN32_DLL libspectrum_tape_append_block( libspectrum_tape *tape, libspectrum_tape_block *block ); -libspectrum_error +void WIN32_DLL libspectrum_tape_remove_block( libspectrum_tape *tape, libspectrum_tape_iterator it ); -libspectrum_error +libspectrum_error WIN32_DLL libspectrum_tape_insert_block( libspectrum_tape *tape, libspectrum_tape_block *block, size_t position ); @@ -1059,10 +1105,10 @@ typedef struct libspectrum_rzx libspectrum_rzx; -libspectrum_error WIN32_DLL libspectrum_rzx_alloc( libspectrum_rzx **rzx ); +libspectrum_rzx* WIN32_DLL libspectrum_rzx_alloc( void ); libspectrum_error WIN32_DLL libspectrum_rzx_free( libspectrum_rzx *rzx ); -libspectrum_error WIN32_DLL +void WIN32_DLL libspectrum_rzx_start_input( libspectrum_rzx *rzx, libspectrum_dword tstates ); libspectrum_error WIN32_DLL libspectrum_rzx_stop_input( libspectrum_rzx *rzx ); @@ -1125,8 +1171,6 @@ libspectrum_creator *creator, int compress, libspectrum_rzx_dsa_key *key ); -libspectrum_error WIN32_DLL libspectrum_rzx_alloc( libspectrum_rzx **rzx ); - /* Something to step through all the blocks in an input recording */ typedef struct _GSList *libspectrum_rzx_iterator; @@ -1181,9 +1225,9 @@ /* Constructor/destructor */ +libspectrum_microdrive* WIN32_DLL +libspectrum_microdrive_alloc( void ); libspectrum_error WIN32_DLL -libspectrum_microdrive_alloc( libspectrum_microdrive **microdrive ); -libspectrum_error WIN32_DLL libspectrum_microdrive_free( libspectrum_microdrive *microdrive ); /* Accessors */ @@ -1215,7 +1259,7 @@ libspectrum_error WIN32_DLL libspectrum_microdrive_mdr_read( libspectrum_microdrive *microdrive, libspectrum_byte *buffer, size_t length ); -libspectrum_error WIN32_DLL +void WIN32_DLL libspectrum_microdrive_mdr_write( const libspectrum_microdrive *microdrive, libspectrum_byte **buffer, size_t *length ); @@ -1251,7 +1295,7 @@ libspectrum_dck_block *dck[256]; /* dck block data */ } libspectrum_dck; -libspectrum_error WIN32_DLL libspectrum_dck_alloc( libspectrum_dck **dck ); +libspectrum_dck* WIN32_DLL libspectrum_dck_alloc( void ); libspectrum_error WIN32_DLL libspectrum_dck_free( libspectrum_dck *dck, int keep_pages ); @@ -1311,10 +1355,9 @@ typedef struct libspectrum_ide_channel libspectrum_ide_channel; +libspectrum_ide_channel* WIN32_DLL +libspectrum_ide_alloc( libspectrum_ide_databus databus ); libspectrum_error WIN32_DLL -libspectrum_ide_alloc( libspectrum_ide_channel **chn, - libspectrum_ide_databus databus ); -libspectrum_error WIN32_DLL libspectrum_ide_free( libspectrum_ide_channel *chn ); libspectrum_error WIN32_DLL Modified: trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2008-10-21 12:05:43 UTC (rev 534) @@ -13,6 +13,8 @@ B60E533C082720EC00F2C004 /* GetMetadataForFile.m in Sources */ = {isa = PBXBuildFile; fileRef = B60E533B082720EC00F2C004 /* GetMetadataForFile.m */; }; B61617260C1CE2980009ADF9 /* csw.c in Sources */ = {isa = PBXBuildFile; fileRef = B61617250C1CE2980009ADF9 /* csw.c */; }; B616172A0C1CE2A50009ADF9 /* wav.c in Sources */ = {isa = PBXBuildFile; fileRef = B61617290C1CE2A50009ADF9 /* wav.c */; }; + B61E31AF0E925C66008097AC /* memory.c in Sources */ = {isa = PBXBuildFile; fileRef = B61E31AE0E925C66008097AC /* memory.c */; }; + B61E31B30E925C73008097AC /* garray.c in Sources */ = {isa = PBXBuildFile; fileRef = B61E31B20E925C73008097AC /* garray.c */; }; B62C1CD00B761515000BA4E0 /* symbol_table.c in Sources */ = {isa = PBXBuildFile; fileRef = B62C1CCF0B761515000BA4E0 /* symbol_table.c */; }; B639B7930A6BB2C100927E24 /* z80em.c in Sources */ = {isa = PBXBuildFile; fileRef = B639B7920A6BB2C100927E24 /* z80em.c */; }; B69709730827C03F00904D8F /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B69709720827C03F00904D8F /* Foundation.framework */; }; @@ -114,6 +116,8 @@ B60E533B082720EC00F2C004 /* GetMetadataForFile.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GetMetadataForFile.m; sourceTree = "<group>"; }; B61617250C1CE2980009ADF9 /* csw.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = csw.c; path = ../../libspectrum/libspectrum/csw.c; sourceTree = "<group>"; }; B61617290C1CE2A50009ADF9 /* wav.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = wav.c; path = ../../libspectrum/libspectrum/wav.c; sourceTree = "<group>"; }; + B61E31AE0E925C66008097AC /* memory.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = memory.c; path = ../../libspectrum/libspectrum/memory.c; sourceTree = "<group>"; }; + B61E31B20E925C73008097AC /* garray.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = garray.c; path = ../../../libspectrum/libspectrum/myglib/garray.c; sourceTree = "<group>"; }; B62C1CCF0B761515000BA4E0 /* symbol_table.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = symbol_table.c; path = ../../libspectrum/libspectrum/symbol_table.c; sourceTree = "<group>"; }; B639B7920A6BB2C100927E24 /* z80em.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = z80em.c; path = ../../libspectrum/libspectrum/z80em.c; sourceTree = "<group>"; }; B6687E130A607F1D005D0FDE /* libspectrum.h.in */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = libspectrum.h.in; path = ../../libspectrum/libspectrum/libspectrum.h.in; sourceTree = "<group>"; }; @@ -242,6 +246,7 @@ B6BF2A040A5FFD0100D16624 /* internals.h */, B6BF2A050A5FFD0100D16624 /* libspectrum.c */, B6BF2A060A5FFD0100D16624 /* libspectrum.h */, + B61E31AE0E925C66008097AC /* memory.c */, B6BF2A070A5FFD0100D16624 /* microdrive.c */, B6BF2A080A5FFD0100D16624 /* plusd.c */, B6BF2A090A5FFD0100D16624 /* rzx.c */, @@ -271,6 +276,7 @@ B6BF29F10A5FFC9700D16624 /* myglib */ = { isa = PBXGroup; children = ( + B61E31B20E925C73008097AC /* garray.c */, B6BF29FC0A5FFCD700D16624 /* gslist.c */, B6BF29F80A5FFCC200D16624 /* ghash.c */, ); @@ -400,6 +406,8 @@ B62C1CD00B761515000BA4E0 /* symbol_table.c in Sources */, B61617260C1CE2980009ADF9 /* csw.c in Sources */, B616172A0C1CE2A50009ADF9 /* wav.c in Sources */, + B61E31AF0E925C66008097AC /* memory.c in Sources */, + B61E31B30E925C73008097AC /* garray.c in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; Modified: trunk/FuseImporter/LibspectrumMetadataImporter.m =================================================================== --- trunk/FuseImporter/LibspectrumMetadataImporter.m 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseImporter/LibspectrumMetadataImporter.m 2008-10-21 12:05:43 UTC (rev 534) @@ -177,35 +177,17 @@ libspectrum_tape *tape; libspectrum_tape_iterator iterator; libspectrum_tape_block *block; + libspectrum_dword tstates_total = 0; size_t i; - error = libspectrum_tape_alloc( &tape ); - if( error != LIBSPECTRUM_ERROR_NONE ) { - return NO; - } + tape = libspectrum_tape_alloc(); error = libspectrum_tape_read( tape, buffer, length, type, fsrep ); if( error != LIBSPECTRUM_ERROR_NONE ) { return NO; } - int flags = 0; - libspectrum_dword tstates_total = 0; - libspectrum_dword edge_tstates = 0; - - while( !(flags & LIBSPECTRUM_TAPE_FLAGS_STOP) ) { - error = libspectrum_tape_get_next_edge( &edge_tstates, &flags, tape ); - if( error != LIBSPECTRUM_ERROR_NONE ) return NO; - - tstates_total += edge_tstates; - } - - float duration = tstates_total/3500000.0; - - [attributes setObject:[NSNumber numberWithFloat:duration] - forKey:(NSString *)kMDItemDurationSeconds]; - [attributes setObject:[NSNumber numberWithInt:1] forKey:(NSString *)kMDItemAudioChannelCount]; @@ -385,10 +367,17 @@ break; } + tstates_total += libspectrum_tape_block_length( block ); + block = libspectrum_tape_iterator_next( &iterator ); } + float duration = tstates_total/3500000.0; + + [attributes setObject:[NSNumber numberWithFloat:duration] + forKey:(NSString *)kMDItemDurationSeconds]; + error = libspectrum_tape_free( tape ); if( error != LIBSPECTRUM_ERROR_NONE ) { munmap( buffer, length ); @@ -470,10 +459,7 @@ libspectrum_snap *snap; - error = libspectrum_snap_alloc( &snap ); - if( error != LIBSPECTRUM_ERROR_NONE ) { - return NO; - } + snap = libspectrum_snap_alloc(); error = libspectrum_snap_read( snap, buffer, length, type, fsrep ); if( error ) { @@ -501,10 +487,7 @@ libspectrum_rzx *rzx; libspectrum_snap *snap = NULL; - error = libspectrum_rzx_alloc( &rzx ); - if( error != LIBSPECTRUM_ERROR_NONE ) { - return NO; - } + rzx = libspectrum_rzx_alloc(); error = libspectrum_rzx_read( rzx, buffer, length ); if( error ) { Modified: trunk/FuseImporter/generate.pl =================================================================== --- trunk/FuseImporter/generate.pl 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseImporter/generate.pl 2008-10-21 12:05:43 UTC (rev 534) @@ -25,7 +25,9 @@ #define TRUE (!FALSE) #endif +typedef char gchar; typedef int gint; +typedef long glong; typedef gint gboolean; typedef unsigned int guint; typedef const void * gconstpointer; @@ -94,6 +96,9 @@ gint WIN32_DLL g_int_equal (gconstpointer v, gconstpointer v2); guint WIN32_DLL g_int_hash (gconstpointer v); +gint WIN32_DLL g_str_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_str_hash (gconstpointer v); GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); @@ -113,6 +118,25 @@ guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +typedef struct _GArray GArray; + +struct _GArray { + /* Public */ + gchar *data; + size_t len; + + /* Private */ + guint element_size; + size_t allocated; +}; + +GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); +#define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); +GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +#define g_array_index(a,t,i) (*(((t*)a->data)+i)) +GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); + #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) CODE Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/FuseImporter/libspectrum.h 2008-10-21 12:05:43 UTC (rev 534) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3595 2008-04-01 10:51:58Z pak21 $ + $Id: libspectrum.h.in 3771 2008-09-11 11:23:17Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -84,7 +84,9 @@ #define TRUE (!FALSE) #endif +typedef char gchar; typedef int gint; +typedef long glong; typedef gint gboolean; typedef unsigned int guint; typedef const void * gconstpointer; @@ -153,6 +155,9 @@ gint WIN32_DLL g_int_equal (gconstpointer v, gconstpointer v2); guint WIN32_DLL g_int_hash (gconstpointer v); +gint WIN32_DLL g_str_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_str_hash (gconstpointer v); GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); @@ -172,6 +177,25 @@ guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +typedef struct _GArray GArray; + +struct _GArray { + /* Public */ + gchar *data; + size_t len; + + /* Private */ + guint element_size; + size_t allocated; +}; + +GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); +#define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); +GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +#define g_array_index(a,t,i) (*(((t*)a->data)+i)) +GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); + #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) @@ -225,6 +249,27 @@ libspectrum_default_error_function( libspectrum_error error, const char *format, va_list ap ); +/* Memory allocators */ + +typedef void* (*libspectrum_malloc_fn_t)( size_t size ); +typedef void* (*libspectrum_calloc_fn_t)( size_t nmemb, size_t size ); +typedef void* (*libspectrum_realloc_fn_t)( void *ptr, size_t size ); +typedef void (*libspectrum_free_fn_t)( void *ptr ); + +typedef struct libspectrum_mem_vtable_t { + libspectrum_malloc_fn_t malloc; + libspectrum_calloc_fn_t calloc; + libspectrum_realloc_fn_t realloc; + libspectrum_free_fn_t free; +} libspectrum_mem_vtable_t; + +void* WIN32_DLL libspectrum_malloc( size_t size ); +void* WIN32_DLL libspectrum_calloc( size_t nmemb, size_t size ); +void* WIN32_DLL libspectrum_realloc( void *ptr, size_t size ); +void WIN32_DLL libspectrum_free( void *ptr ); + +void WIN32_DLL libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ); + /* Attempt to identify a given file */ /* Various types of file we might manage to identify */ @@ -445,9 +490,9 @@ typedef struct libspectrum_creator libspectrum_creator; +libspectrum_creator* WIN32_DLL +libspectrum_creator_alloc( void ); libspectrum_error WIN32_DLL -libspectrum_creator_alloc( libspectrum_creator **creator ); -libspectrum_error WIN32_DLL libspectrum_creator_free( libspectrum_creator *creator ); libspectrum_error WIN32_DLL @@ -490,7 +535,7 @@ typedef struct libspectrum_snap libspectrum_snap; -libspectrum_error WIN32_DLL libspectrum_snap_alloc( libspectrum_snap **snap ); +libspectrum_snap* WIN32_DLL libspectrum_snap_alloc( void ); libspectrum_error WIN32_DLL libspectrum_snap_free( libspectrum_snap *snap ); /* Read in a snapshot, optionally guessing what type it is */ @@ -605,7 +650,7 @@ void WIN32_DLL libspectrum_snap_set_interface1_drive_count( libspectrum_snap *snap, int interface1_drive_count ); int WIN32_DLL libspectrum_snap_interface1_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_interface1_custom_rom( libspectrum_snap *snap, int interface1_custom_rom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_interface1_rom( libspectrum_snap * snap, int idx ); +libspectrum_byte WIN32_DLL * libspectrum_snap_interface1_rom( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_interface1_rom( libspectrum_snap *snap, int idx, libspectrum_byte* interface1_rom ); size_t WIN32_DLL libspectrum_snap_interface1_rom_length( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_interface1_rom_length( libspectrum_snap *snap, int idx, size_t interface1_rom_length ); @@ -727,7 +772,7 @@ void WIN32_DLL libspectrum_snap_set_simpleide_active( libspectrum_snap *snap, int simpleide_active ); int WIN32_DLL libspectrum_snap_divide_active( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_divide_active( libspectrum_snap *snap, int divide_active ); -int WIN32_DLL libspectrum_snap_divide_eprom_writeprotect( libspectrum_snap *snap); +int WIN32_DLL libspectrum_snap_divide_eprom_writeprotect( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_divide_eprom_writeprotect( libspectrum_snap *snap, int divide_eprom_writeprotect ); int WIN32_DLL libspectrum_snap_divide_paged( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_divide_paged( libspectrum_snap *snap, int divide_paged ); @@ -737,10 +782,9 @@ void WIN32_DLL libspectrum_snap_set_divide_pages( libspectrum_snap *snap, size_t divide_pages ); libspectrum_byte WIN32_DLL * libspectrum_snap_divide_eprom( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_eprom( libspectrum_snap *snap, int idx, libspectrum_byte* divide_eprom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap , int idx ); +libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_ram( libspectrum_snap *snap, int idx, libspectrum_byte* divide_ram ); - /* DEPRECATED: use libspectrum_snap_read() instead */ DEPRECATED libspectrum_error WIN32_DLL @@ -835,10 +879,9 @@ } libspectrum_tape_state_type; /* Routines to manipulate tape blocks */ +libspectrum_tape_block* WIN32_DLL +libspectrum_tape_block_alloc( libspectrum_tape_type type ); libspectrum_error WIN32_DLL -libspectrum_tape_block_alloc( libspectrum_tape_block **block, - libspectrum_tape_type type ); -libspectrum_error WIN32_DLL libspectrum_tape_block_free( libspectrum_tape_block *block ); libspectrum_tape_type WIN32_DLL libspectrum_tape_block_type( libspectrum_tape_block *block ); @@ -857,6 +900,9 @@ int WIN32_DLL libspectrum_tape_block_metadata( libspectrum_tape_block *block ); +libspectrum_dword +libspectrum_tape_block_length( libspectrum_tape_block *block ); + /* Accessor functions */ libspectrum_dword WIN32_DLL libspectrum_tape_block_bit_length( libspectrum_tape_block *block ); libspectrum_error WIN32_DLL libspectrum_tape_block_set_bit_length( libspectrum_tape_block *block, libspectrum_dword bit_length ); @@ -916,7 +962,7 @@ /* A linked list of tape blocks */ typedef struct libspectrum_tape libspectrum_tape; -libspectrum_error WIN32_DLL libspectrum_tape_alloc( libspectrum_tape **tape ); +libspectrum_tape* WIN32_DLL libspectrum_tape_alloc( void ); libspectrum_error WIN32_DLL libspectrum_tape_clear( libspectrum_tape *tape ); libspectrum_error WIN32_DLL libspectrum_tape_free( libspectrum_tape *tape ); @@ -969,15 +1015,15 @@ libspectrum_tape_nth_block( libspectrum_tape *tape, int n ); /* Append a block to the current tape */ -libspectrum_error WIN32_DLL +void WIN32_DLL libspectrum_tape_append_block( libspectrum_tape *tape, libspectrum_tape_block *block ); -libspectrum_error +void WIN32_DLL libspectrum_tape_remove_block( libspectrum_tape *tape, libspectrum_tape_iterator it ); -libspectrum_error +libspectrum_error WIN32_DLL libspectrum_tape_insert_block( libspectrum_tape *tape, libspectrum_tape_block *block, size_t position ); @@ -1059,10 +1105,10 @@ typedef struct libspectrum_rzx libspectrum_rzx; -libspectrum_error WIN32_DLL libspectrum_rzx_alloc( libspectrum_rzx **rzx ); +libspectrum_rzx* WIN32_DLL libspectrum_rzx_alloc( void ); libspectrum_error WIN32_DLL libspectrum_rzx_free( libspectrum_rzx *rzx ); -libspectrum_error WIN32_DLL +void WIN32_DLL libspectrum_rzx_start_input( libspectrum_rzx *rzx, libspectrum_dword tstates ); libspectrum_error WIN32_DLL libspectrum_rzx_stop_input( libspectrum_rzx *rzx ); @@ -1125,8 +1171,6 @@ libspectrum_creator *creator, int compress, libspectrum_rzx_dsa_key *key ); -libspectrum_error WIN32_DLL libspectrum_rzx_alloc( libspectrum_rzx **rzx ); - /* Something to step through all the blocks in an input recording */ typedef struct _GSList *libspectrum_rzx_iterator; @@ -1181,9 +1225,9 @@ /* Constructor/destructor */ +libspectrum_microdrive* WIN32_DLL +libspectrum_microdrive_alloc( void ); libspectrum_error WIN32_DLL -libspectrum_microdrive_alloc( libspectrum_microdrive **microdrive ); -libspectrum_error WIN32_DLL libspectrum_microdrive_free( libspectrum_microdrive *microdrive ); /* Accessors */ @@ -1215,7 +1259,7 @@ libspectrum_error WIN32_DLL libspectrum_microdrive_mdr_read( libspectrum_microdrive *microdrive, libspectrum_byte *buffer, size_t length ); -libspectrum_error WIN32_DLL +void WIN32_DLL libspectrum_microdrive_mdr_write( const libspectrum_microdrive *microdrive, libspectrum_byte **buffer, size_t *length ); @@ -1251,7 +1295,7 @@ libspectrum_dck_block *dck[256]; /* dck block data */ } libspectrum_dck; -libspectrum_error WIN32_DLL libspectrum_dck_alloc( libspectrum_dck **dck ); +libspectrum_dck* WIN32_DLL libspectrum_dck_alloc( void ); libspectrum_error WIN32_DLL libspectrum_dck_free( libspectrum_dck *dck, int keep_pages ); @@ -1311,10 +1355,9 @@ typedef struct libspectrum_ide_channel libspectrum_ide_channel; +libspectrum_ide_channel* WIN32_DLL +libspectrum_ide_alloc( libspectrum_ide_databus databus ); libspectrum_error WIN32_DLL -libspectrum_ide_alloc( libspectrum_ide_channel **chn, - libspectrum_ide_databus databus ); -libspectrum_error WIN32_DLL libspectrum_ide_free( libspectrum_ide_channel *chn ); libspectrum_error WIN32_DLL Property changes on: trunk/fuse ___________________________________________________________________ Added: svn:mergeinfo + /vendor/fuse-emulator/current/fuse:530-533 Modified: trunk/fuse/Makefile.am =================================================================== --- trunk/fuse/Makefile.am 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/Makefile.am 2008-10-21 12:05:43 UTC (rev 534) @@ -1,7 +1,7 @@ # Process this file with automake to produce Makefile.in ## Copyright (c) 1999-2008 Philip Kendall -## $Id: Makefile.am 3609 2008-05-01 13:17:56Z fredm $ +## $Id: Makefile.am 3617 2008-05-17 08:09:47Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -72,6 +72,7 @@ loader.c \ machine.c \ memory.c \ + mempool.c \ menu.c \ module.c \ periph.c \ Copied: trunk/fuse/PORTING (from rev 533, vendor/fuse-emulator/current/fuse/PORTING) =================================================================== --- trunk/fuse/PORTING (rev 0) +++ trunk/fuse/PORTING 2008-10-21 12:05:43 UTC (rev 534) @@ -0,0 +1,22 @@ +Porting Fuse +============ + +Sorry, at the moment this isn't a helpful guide as to what you need to do +to port Fuse to a new platform. + +Unfortunately, various people have failed to read and understand the GNU +General Public License (see 'COPYING') before porting Fuse, so this is a +very brief guide to what you can and can't do with Fuse's code: + +* If you release a binary of Fuse, you *must* release *all* the source + code you used to create it at the same time. "Soon" or "when I've + tidied up the code" is NOT acceptable. + +* If you use any code which you haven't written yourself, it must be + available under a licence compatible with the GPL. As an example, this + means you may *not* use any code which "may not be used for commercial + purposes". Any code which is licenced under the GPL (v2), the modified + BSD license or which is truly in the public domain is OK. + +Note that above is not an exhaustive list of what you can and cannot +do with Fuse's code. For the full details, see the GPL. Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/README 2008-10-21 12:05:43 UTC (rev 534) @@ -26,6 +26,14 @@ * Emulation of the DivIDE, Interface I, Kempston mouse, Spectrum +3e, ZXATASP, ZXCF, Beta 128 and +D interfaces. +Help! <xyz> doesn't work +------------------------ + +If you're having a problem using/running/building Fuse, the two places +you're most likely to get help are the development mailing list +<fus...@li...> or the official forums at +<http://sourceforge.net/forum/?group_id=91293>. + What you'll need to run Fuse ---------------------------- @@ -143,4 +151,4 @@ Philip Kendall <phi...@sh...> 5 January 2008 -$Id: README 3584 2008-03-25 10:27:30Z fredm $ +$Id: README 3718 2008-07-19 12:29:41Z pak21 $ Modified: trunk/fuse/compat/amiga/Makefile.am =================================================================== --- trunk/fuse/compat/amiga/Makefile.am 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/compat/amiga/Makefile.am 2008-10-21 12:05:43 UTC (rev 534) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in -## Copyright (c) 2007 Philip Kendall +## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3578 2008-03-22 20:51:36Z zubzero $ +## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,7 +27,8 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = osname.c \ +libcompatos_a_SOURCES = ../unix/file.c \ + osname.c \ paths.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Modified: trunk/fuse/compat/morphos/Makefile.am =================================================================== --- trunk/fuse/compat/morphos/Makefile.am 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/compat/morphos/Makefile.am 2008-10-21 12:05:43 UTC (rev 534) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in -## Copyright (c) 2007 Philip Kendall +## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3115 2007-08-19 02:49:14Z fredm $ +## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,7 +27,8 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = osname.c \ +libcompatos_a_SOURCES = ../unix/file.c \ + osname.c \ ../amiga/paths.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Modified: trunk/fuse/compat/unix/Makefile.am =================================================================== --- trunk/fuse/compat/unix/Makefile.am 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/compat/unix/Makefile.am 2008-10-21 12:05:43 UTC (rev 534) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in -## Copyright (c) 2007 Philip Kendall +## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3115 2007-08-19 02:49:14Z fredm $ +## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,7 +27,8 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = osname.c \ +libcompatos_a_SOURCES = file.c \ + osname.c \ paths.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Copied: trunk/fuse/compat/unix/file.c (from rev 533, vendor/fuse-emulator/current/fuse/compat/unix/file.c) =================================================================== --- trunk/fuse/compat/unix/file.c (rev 0) +++ trunk/fuse/compat/unix/file.c 2008-10-21 12:05:43 UTC (rev 534) @@ -0,0 +1,107 @@ +/* file.c: File-related compatibility routines + Copyright (c) 2008 Philip Kendall + + $Id: file.c 3722 2008-07-22 03:12:28Z specu $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include <errno.h> +#include <fcntl.h> +#include <string.h> +#include <sys/types.h> +#include <sys/stat.h> +#include <unistd.h> + +#include "compat.h" +#include "ui/ui.h" + +/* Certain brain damaged operating systems (DOS/Windows) treat text + and binary files different in open(2) and need to be given the + O_BINARY flag to tell them it's a binary file */ +#ifndef O_BINARY +#define O_BINARY 0 +#endif /* #ifndef O_BINARY */ + +const compat_fd COMPAT_FILE_OPEN_FAILED = -1; + +compat_fd +compat_file_open( const char *path, int write ) +{ + int flags = write ? O_WRONLY | O_CREAT | O_BINARY : O_RDONLY | O_BINARY; + return open( path, flags ); +} + +off_t +compat_file_get_length( compat_fd fd ) +{ + struct stat file_info; + + if( fstat( fd, &file_info ) ) { + ui_error( UI_ERROR_ERROR, "couldn't stat file: %s", strerror( errno ) ); + return -1; + } + + return file_info.st_size; +} + +int +compat_file_read( compat_fd fd, utils_file *file ) +{ + ssize_t bytes = read( fd, file->buffer, file->length ); + if( bytes != file->length ) { + if( bytes == -1 ) { + ui_error( UI_ERROR_ERROR, "error reading file: %s", strerror( errno ) ); + } else { + ui_error( UI_ERROR_ERROR, + "error reading file: expected %ld bytes, but read only %ld", + (unsigned long)file->length, (unsigned long)bytes ); + } + return 1; + } + + return 0; +} + +int +compat_file_write( compat_fd fd, const unsigned char *buffer, size_t length ) +{ + ssize_t bytes = write( fd, buffer, length ); + if( bytes != length ) { + if( bytes == -1 ) { + ui_error( UI_ERROR_ERROR, "error writing file: %s", strerror( errno ) ); + } else { + ui_error( UI_ERROR_ERROR, + "error writing file: expected %ld bytes, but wrote only %ld", + (unsigned long)length, (unsigned long)bytes ); + } + return 1; + } + + return 0; +} + +int +compat_file_close( compat_fd fd ) +{ + return close( fd ); +} Modified: trunk/fuse/compat/unix/osname.c =================================================================== --- trunk/fuse/compat/unix/osname.c 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/compat/unix/osname.c 2008-10-21 12:05:43 UTC (rev 534) @@ -1,7 +1,7 @@ /* osname.c: Get a representation of the OS we're running on Copyright (c) 1999-2007 Philip Kendall - $Id: osname.c 3115 2007-08-19 02:49:14Z fredm $ + $Id: osname.c 3626 2008-05-23 10:30:30Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -38,7 +38,7 @@ int error; error = uname( &osname ); - if( error ) { + if( error < 0 ) { ui_error( UI_ERROR_ERROR, "error getting system information: %s", strerror( errno ) ); return 1; Deleted: trunk/fuse/compat/wii/Makefile.am =================================================================== --- vendor/fuse-emulator/current/fuse/compat/wii/Makefile.am 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/compat/wii/Makefile.am 2008-10-21 12:05:43 UTC (rev 534) @@ -1,34 +0,0 @@ -## Process this file with automake to produce Makefile.in -## Copyright (c) 2007-2008 Philip Kendall - -## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ - -## This program is free software; you can redistribute it and/or modify -## it under the terms of the GNU General Public License as published by -## the Free Software Foundation; either version 2 of the License, or -## (at your option) any later version. -## -## This program is distributed in the hope that it will be useful, -## but WITHOUT ANY WARRANTY; without even the implied warranty of -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -## GNU General Public License for more details. -## -## You should have received a copy of the GNU General Public License along -## with this program; if not, write to the Free Software Foundation, Inc., -## 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -## -## Author contact information: -## -## E-mail: phi...@sh... - -AUTOMAKE_OPTIONS = foreign - -AM_CPPFLAGS = -I$(srcdir)/../.. - -noinst_LIBRARIES = libcompatos.a - -libcompatos_a_SOURCES = file.c \ - osname.c \ - paths.c - -INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Copied: trunk/fuse/compat/wii/Makefile.am (from rev 533, vendor/fuse-emulator/current/fuse/compat/wii/Makefile.am) =================================================================== --- trunk/fuse/compat/wii/Makefile.am (rev 0) +++ trunk/fuse/compat/wii/Makefile.am 2008-10-21 12:05:43 UTC (rev 534) @@ -0,0 +1,34 @@ +## Process this file with automake to produce Makefile.in +## Copyright (c) 2007-2008 Philip Kendall + +## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ + +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License along +## with this program; if not, write to the Free Software Foundation, Inc., +## 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +## +## Author contact information: +## +## E-mail: phi...@sh... + +AUTOMAKE_OPTIONS = foreign + +AM_CPPFLAGS = -I$(srcdir)/../.. + +noinst_LIBRARIES = libcompatos.a + +libcompatos_a_SOURCES = file.c \ + osname.c \ + paths.c + +INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Deleted: trunk/fuse/compat/wii/file.c =================================================================== --- vendor/fuse-emulator/current/fuse/compat/wii/file.c 2008-09-28 12:29:27 UTC (rev 533) +++ trunk/fuse/compat/wii/file.c 2008-10-21 12:05:43 UTC (rev 534) @@ -1,90 +0,0 @@ -/* file.c: File-related compatibility routines - Copyright (c) 2008 Philip Kendall - - $Id: file.c 3688 2008-06-23 18:17:56Z pak21 $ - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - Author contact information: - - E-mail: phi...@sh... - -*/ - -#include <config.h> - -#include <errno.h> -#include <fcntl.h> -#include <sys/types.h> -#include <sys/stat.h> -#include <unistd.h> - -#include "compat.h" -#include "ui/ui.h" - -const compat_fd COMPAT_FILE_OPEN_FAILED = NULL; - -compat_fd -compat_file_open( const char *path, int write ) -{ - return fopen( path, write ? "w" : "r" ); -} - -off_t -compat_file_get_length( compat_fd fd ) -{ - struct stat file_info; - - if( fstat( fileno( fd ), &file_info ) ) { - ui_error( UI_ERROR_ERROR, "couldn't stat file: %s", strerror( errno ) ); - return -1; - } - - return file_info.st_size; -} - -int -compat_file_read( compat_fd fd, utils_file *file ) -{ - size_t bytes = fread( file->buffer, 1, file->length, fd ); - if( bytes != file->length ) { - ui_error( UI_ERROR_ERROR, - "error reading file: expected %d bytes, but read only %d", - file->length, bytes ); - return 1; - } - - return 0; -} - -int -compat_file_write( compat_fd fd, const unsigned char *buffer, size_t length ) -{ - size_t bytes = fwrite( buffer, 1, length, fd ); - if( bytes != length ) { - ui_error( UI_ERROR_ERROR, - "error writing file: expected %d bytes, but wrote only %d", - length, bytes ); - return 1; - } - - return 0; -} - -int -compat_file_close( compat_fd fd ) -{ - return fclose( fd ); -} Copied: trunk/fuse/compat/wii/file.c (from rev 533, vendor/fuse-emulator/current/fuse/compat/wii/file.c) =================================================================== --- trunk/fuse/compat/wii/file.c (rev 0) +++ trunk/fuse/compat/wii/file.c 2008-10-21 12:05:43 UTC (rev 534) @@ -0,0 +1,90 @@ +/* file.c: File-related compatibility routines + Copyright (c) 2008 Philip Kendall + + $Id: file.c 3688 2008-06-23 18:17:56Z pak21 $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTI... [truncated message content] |
From: <fr...@us...> - 2008-11-03 12:27:42
|
Revision: 539 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=539&view=rev Author: fredm Date: 2008-11-03 12:27:34 +0000 (Mon, 03 Nov 2008) Log Message: ----------- Merge up to vendor revision 3804. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=3804&view=rev Modified Paths: -------------- trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/libspectrum.h trunk/fuse/ChangeLog trunk/fuse/README trunk/fuse/compat/unix/file.c trunk/fuse/configure.in trunk/fuse/disk/fdd.c trunk/fuse/disk/upd_fdc.c trunk/fuse/fuse.c trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/models/Emulator.m trunk/fuse/hacking/ChangeLog trunk/fuse/man/fuse.1 trunk/fuse/menu.c trunk/fuse/rzx.c trunk/fuse/settings.dat trunk/fuse/ui/options.dat trunk/fuse/ui/win32/win32internals.h trunk/fuse/ui/win32/win32joystick.c trunk/fuse/ui/win32/win32joystick.h trunk/fuse/ui/win32/win32ui.c trunk/fuse/z80/tests/README trunk/libspectrum/libspectrum/ChangeLog trunk/libspectrum/libspectrum/README trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/rzx.c trunk/libspectrum/libspectrum/sna.c trunk/libspectrum/libspectrum/tap.c trunk/libspectrum/libspectrum/tape_block.c trunk/libspectrum/libspectrum/test/test.c trunk/libspectrum/libspectrum/tzx_read.c trunk/libspectrum/libspectrum/tzx_write.c trunk/libspectrum/libspectrum/warajevo_read.c trunk/libspectrum/libspectrum/z80.c trunk/libspectrum/libspectrum.h Added Paths: ----------- trunk/libspectrum/libspectrum/test/empty.z80 Property Changed: ---------------- trunk/fuse/ trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/FuseGenerator/libspectrum.h 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3771 2008-09-11 11:23:17Z pak21 $ + $Id: libspectrum.h.in 3792 2008-10-27 20:49:34Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -785,24 +785,6 @@ libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_ram( libspectrum_snap *snap, int idx, libspectrum_byte* divide_ram ); -/* DEPRECATED: use libspectrum_snap_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_sna_read( libspectrum_snap *snap, - const libspectrum_byte *buffer, size_t buffer_length ); - -/* DEPRECATED: use libspectrum_snap_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_z80_read( libspectrum_snap *snap, - const libspectrum_byte *buffer, size_t buffer_length ); - -/* DEPRECATED: use libspectrum_snap_write() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_z80_write( libspectrum_byte **buffer, size_t *length, - libspectrum_snap *snap ); - /* * Tape handling routines */ @@ -900,7 +882,7 @@ int WIN32_DLL libspectrum_tape_block_metadata( libspectrum_tape_block *block ); -libspectrum_dword +libspectrum_dword WIN32_DLL libspectrum_tape_block_length( libspectrum_tape_block *block ); /* Accessor functions */ @@ -1028,42 +1010,6 @@ libspectrum_tape_block *block, size_t position ); -/*** Routines for .tap format files ***/ - -/* DEPRECATED: use libspectrum_tape_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tap_read( libspectrum_tape *tape, const libspectrum_byte *buffer, - const size_t length ); - -/* DEPRECATED: use libspectrum_tape_write() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tap_write( libspectrum_byte **buffer, size_t *length, - libspectrum_tape *tape ); - -/*** Routines for .tzx format files ***/ - -/* DEPRECATED: use libspectrum_tape_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tzx_read( libspectrum_tape *tape, const libspectrum_byte *buffer, - const size_t length ); - -/* DEPRECATED: use libspectrum_tape_write() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tzx_write( libspectrum_byte **buffer, size_t *length, - libspectrum_tape *tape ); - -/*** Routines for Warajevo .tap format files ***/ - -/* DEPRECATED: use libspectrum_tape_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_warajevo_read( libspectrum_tape *tape, - const libspectrum_byte *buffer, size_t length ); - /*** Routines for iterating through a tape ***/ libspectrum_tape_block WIN32_DLL * @@ -1113,7 +1059,7 @@ libspectrum_error WIN32_DLL libspectrum_rzx_stop_input( libspectrum_rzx *rzx ); libspectrum_error WIN32_DLL -libspectrum_rzx_add_snap( libspectrum_rzx *rzx, libspectrum_snap *snap ); +libspectrum_rzx_add_snap( libspectrum_rzx *rzx, libspectrum_snap *snap, int automatic ); libspectrum_error WIN32_DLL libspectrum_rzx_rollback( libspectrum_rzx *rzx, libspectrum_snap **snap ); libspectrum_error WIN32_DLL @@ -1207,6 +1153,8 @@ libspectrum_rzx_iterator it ); libspectrum_snap* WIN32_DLL libspectrum_rzx_iterator_get_snap( libspectrum_rzx_iterator it ); +int WIN32_DLL +libspectrum_rzx_iterator_snap_is_automatic( libspectrum_rzx_iterator it ); /* * Microdrive image handling routines Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/FuseImporter/libspectrum.h 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3771 2008-09-11 11:23:17Z pak21 $ + $Id: libspectrum.h.in 3792 2008-10-27 20:49:34Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -785,24 +785,6 @@ libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_ram( libspectrum_snap *snap, int idx, libspectrum_byte* divide_ram ); -/* DEPRECATED: use libspectrum_snap_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_sna_read( libspectrum_snap *snap, - const libspectrum_byte *buffer, size_t buffer_length ); - -/* DEPRECATED: use libspectrum_snap_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_z80_read( libspectrum_snap *snap, - const libspectrum_byte *buffer, size_t buffer_length ); - -/* DEPRECATED: use libspectrum_snap_write() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_z80_write( libspectrum_byte **buffer, size_t *length, - libspectrum_snap *snap ); - /* * Tape handling routines */ @@ -900,7 +882,7 @@ int WIN32_DLL libspectrum_tape_block_metadata( libspectrum_tape_block *block ); -libspectrum_dword +libspectrum_dword WIN32_DLL libspectrum_tape_block_length( libspectrum_tape_block *block ); /* Accessor functions */ @@ -1028,42 +1010,6 @@ libspectrum_tape_block *block, size_t position ); -/*** Routines for .tap format files ***/ - -/* DEPRECATED: use libspectrum_tape_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tap_read( libspectrum_tape *tape, const libspectrum_byte *buffer, - const size_t length ); - -/* DEPRECATED: use libspectrum_tape_write() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tap_write( libspectrum_byte **buffer, size_t *length, - libspectrum_tape *tape ); - -/*** Routines for .tzx format files ***/ - -/* DEPRECATED: use libspectrum_tape_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tzx_read( libspectrum_tape *tape, const libspectrum_byte *buffer, - const size_t length ); - -/* DEPRECATED: use libspectrum_tape_write() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_tzx_write( libspectrum_byte **buffer, size_t *length, - libspectrum_tape *tape ); - -/*** Routines for Warajevo .tap format files ***/ - -/* DEPRECATED: use libspectrum_tape_read() instead */ -DEPRECATED -libspectrum_error WIN32_DLL -libspectrum_warajevo_read( libspectrum_tape *tape, - const libspectrum_byte *buffer, size_t length ); - /*** Routines for iterating through a tape ***/ libspectrum_tape_block WIN32_DLL * @@ -1113,7 +1059,7 @@ libspectrum_error WIN32_DLL libspectrum_rzx_stop_input( libspectrum_rzx *rzx ); libspectrum_error WIN32_DLL -libspectrum_rzx_add_snap( libspectrum_rzx *rzx, libspectrum_snap *snap ); +libspectrum_rzx_add_snap( libspectrum_rzx *rzx, libspectrum_snap *snap, int automatic ); libspectrum_error WIN32_DLL libspectrum_rzx_rollback( libspectrum_rzx *rzx, libspectrum_snap **snap ); libspectrum_error WIN32_DLL @@ -1207,6 +1153,8 @@ libspectrum_rzx_iterator it ); libspectrum_snap* WIN32_DLL libspectrum_rzx_iterator_get_snap( libspectrum_rzx_iterator it ); +int WIN32_DLL +libspectrum_rzx_iterator_snap_is_automatic( libspectrum_rzx_iterator it ); /* * Microdrive image handling routines Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/current/fuse:530-533 + /vendor/fuse-emulator/current/fuse:530-538 Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/ChangeLog 2008-11-03 12:27:34 UTC (rev 539) @@ -1,3 +1,54 @@ +2008-11-?? Philip Kendall <phi...@sh...> + + * Fuse 0.10.0 released + + * New upd765 FDC emulation; all known +3 DSK images now work (Gergely + Szasz; thanks to Simon Owen for expert technical advice). + * Loading acceleration (Philip Kendall). + * Automatic saves while using RZX recording (Philip Kendall). + * Many improvements to Win32 UI (mostly Marek Januszewski). + * Improved widget UI, with look and feel borrowed from that in FuseX + (Fredrick Meunier; thanks, crabfists). + + * Emulation core improvements: + * New --late-timings option to emulate machines with 1 tstate + later timings (Philip Kendall) + * Reading from the 128K's memory control port causes that byte to + be written back to the port (Philip Kendall; thanks, Marat + Fayzullin). + * NMI causes Z80 to unHALT (Philip Kendall; thanks, Simon Owen). + * Emulate C, H and P/V flags on repeated IO instructions (Philip + Kendall). + * Fix crash when using Interface 1 on unoptimised Fuse builds + (Philip Kendall). + + * Debugger improvements: + * Debugger events to allow the debugger to stop when various + Spectrum-level events happen (Philip Kendall). + * Allow debugger commands to be run when a breakpoint is hit. + No UI for this at present, but can be set from the command line. + (Philip Kendall). + * Command to exit emulator (Philip Kendall). + * Make time breakpoints work properly when more than one is present + (Philip Kendall). + + * Miscellaneous improvements: + * Loader detection now works with the Digital Integration loader + (Philip Kendall). + * New HQ2X and HQ3x scalers (Gergely Szasz). + * Revert Pentagon 128 to being the "base" machine without extra + ROMs (Fredrick Meunier). + * Updated +3e ROMs (Fredrick Meunier; thanks, Garry Lancaster). + * Allow DivIDE, custom ROMs, Kempston mouse status and Simple 8-bit + IDE interface to be saved in snapshots (Fredrick Meunier). + * Better (but probably not perfect) TS2068 contention (Philip + Kendall). + * OpenSolaris compilation fixes (Fredrick Meunier; thanks, Andrew + Owen). + * C89 compatibility fixes (Fredrick Meunier; thanks, sweetlilmr). + * Remove GTK+'s build explicit dependency on Xlib (Philip Kendall). + * Minor AmigaOS improvements (Chris Young). + 2008-01-05 Philip Kendall <phi...@sh...> * Fuse 0.9.0 released @@ -878,4 +929,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 3482 2008-01-07 12:32:26Z pak21 $ +$Id: ChangeLog 3787 2008-10-22 19:10:25Z pak21 $ Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/README 2008-11-03 12:27:34 UTC (rev 539) @@ -5,8 +5,9 @@ unsurprisingly, an emulator of the ZX Spectrum (a popular 1980s home computer, especially in the UK) for Unix. However, it has now also been ported to Mac OS X, which may or may not count as a Unix variant -depending on your advocacy position and emulates some of the -better-known ZX Spectrum clones as well. +depending on your advocacy position and Windows which definitely isn't +a Unix variant. Fuse also emulates some of the better-known ZX Spectrum +clones as well. What Fuse does have: @@ -15,7 +16,7 @@ Pentagon 128, "512" (Pentagon 128 with extra memory) and 1024 and Scorpion ZS 256 emulation. * Runs at true Speccy speed on any computer you're likely to try it on. -* Support for loading from .tzx files. +* Support for loading from .tzx files, including accelerated loading. * Sound (on systems supporting the Open Sound System, SDL, or OpenBSD/ Solaris's /dev/audio). * Emulation of most of the common joysticks used on the Spectrum @@ -151,4 +152,4 @@ Philip Kendall <phi...@sh...> 5 January 2008 -$Id: README 3718 2008-07-19 12:29:41Z pak21 $ +$Id: README 3801 2008-10-31 16:22:13Z pak21 $ Modified: trunk/fuse/compat/unix/file.c =================================================================== --- trunk/fuse/compat/unix/file.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/compat/unix/file.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* file.c: File-related compatibility routines Copyright (c) 2008 Philip Kendall - $Id: file.c 3722 2008-07-22 03:12:28Z specu $ + $Id: file.c 3776 2008-10-06 00:49:45Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -48,7 +48,7 @@ compat_file_open( const char *path, int write ) { int flags = write ? O_WRONLY | O_CREAT | O_BINARY : O_RDONLY | O_BINARY; - return open( path, flags ); + return open( path, flags, 0666 ); } off_t Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/configure.in 2008-11-03 12:27:34 UTC (rev 539) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 3756 2008-08-24 13:41:23Z specu $ +dnl $Id: configure.in 3796 2008-10-28 20:44:45Z specu $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -381,7 +381,7 @@ dnl Check if libsamplerate is available AC_MSG_CHECKING(whether libsamplerate support requested) AC_ARG_WITH(libsamplerate, - [ --without-libsamplerate use libsamplerate], + [ --without-libsamplerate don't use libsamplerate], if test "$withval" = no; then libsamplerate=no; else libsamplerate=yes; fi, libsamplerate=yes) AC_MSG_RESULT($libsamplerate) Modified: trunk/fuse/disk/fdd.c =================================================================== --- trunk/fuse/disk/fdd.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/disk/fdd.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* fdd.c: Routines for emulating floppy disk drives Copyright (c) 2007 Gergely Szasz - $Id: fdd.c 3681 2008-06-16 09:40:29Z pak21 $ + $Id: fdd.c 3802 2008-11-02 17:06:41Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -165,7 +165,7 @@ machine_current->timings.processor_speed / 10, motor_event, d ); } else { - event_add_with_data( tstates + 2 * /* 1 revolution */ + event_add_with_data( tstates + 3 * /* 1.5 revolution */ machine_current->timings.processor_speed / 10, motor_event, d ); } Modified: trunk/fuse/disk/upd_fdc.c =================================================================== --- trunk/fuse/disk/upd_fdc.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/disk/upd_fdc.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* upd_fdc.c: NEC floppy disk controller emulation Copyright (c) 2007 Gergely Szasz - $Id: upd_fdc.c 3723 2008-07-22 07:49:06Z pak21 $ + $Id: upd_fdc.c 3802 2008-11-02 17:06:41Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -187,7 +187,7 @@ UPD_FDC_ST1_NO_DATA ); f->id_mark = UPD_FDC_AM_NONE; i = f->rev; - while( i == f->rev ) { + while( i == f->rev && d->fdd.ready ) { fdd_read_write_data( &d->fdd, FDD_READ ); if( d->fdd.index ) f->rev--; crc_preset( f ); if( f->mf ) { /* double density (MFM) */ @@ -242,6 +242,7 @@ return 0; /* found and OK */ } } + if(!d->fdd.ready) f->rev = 0; f->status_register[1] |= UPD_FDC_ST1_MISSING_AM | UPD_FDC_ST1_NO_DATA; /*FIXME _NO_DATA? */ return 2; /* not found */ } Modified: trunk/fuse/fuse.c =================================================================== --- trunk/fuse/fuse.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/fuse.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* fuse.c: The Free Unix Spectrum Emulator Copyright (c) 1999-2008 Philip Kendall - $Id: fuse.c 3718 2008-07-19 12:29:41Z pak21 $ + $Id: fuse.c 3797 2008-10-29 12:04:34Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/fusepb/English.lproj/InfoPlist.strings =================================================================== (Binary files differ) Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/fusepb/Info-Fuse.plist 2008-11-03 12:27:34 UTC (rev 539) @@ -480,7 +480,7 @@ <key>CFBundleSignature</key> <string>FUSE</string> <key>CFBundleVersion</key> - <string>3775</string> + <string>3804</string> <key>NSMainNibFile</key> <string>MainMenu</string> <key>NSPrincipalClass</key> Modified: trunk/fuse/fusepb/models/Emulator.m =================================================================== --- trunk/fuse/fusepb/models/Emulator.m 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/fusepb/models/Emulator.m 2008-11-03 12:27:34 UTC (rev 539) @@ -433,7 +433,7 @@ error = snapshot_copy_to( snap ); if( error ) { libspectrum_snap_free( snap ); return; } - libspectrum_rzx_add_snap( rzx, snap ); + libspectrum_rzx_add_snap( rzx, snap, 0 ); libspectrum_rzx_start_input( rzx, tstates ); } Modified: trunk/fuse/hacking/ChangeLog =================================================================== --- trunk/fuse/hacking/ChangeLog 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/hacking/ChangeLog 2008-11-03 12:27:34 UTC (rev 539) @@ -2895,3 +2895,29 @@ rollback.rc,select_template.rc}: Win32: Changed style for all dialogs to make those dialogs show on the taskbar, converted select_template.rc from DOS to UNIX (Marek). +20081006 compat/unix/file.c: make sure mode is specified when opening a file + for writing (fixes bug #2146742) (thanks, Cygnus) (Fred). +20081021 z80/tests/README: small documentation update (patch #2183257) + (Matthew Westcott). +20081021 ChangeLog: update for 0.10.0 release. +20081022 menu.c,rzx.c,settings.dat,ui/options.dat: support for autosaves + when using RZX recording. +20081024 man/fuse.1: update. Still TODO: debugger updates. +20081024 man/fuse.1: debugger updates. +20081024 man/fuse.1: minor update for disk formats and compressed disk images + (Fred). +20081028 configure.in: Fixed a typo in the configure script + (was '--without-libsamplerate use libsamplerate') (Marek). +20081029 fuse.c: move up settings_end to happen just after printer_end for + similar reasons - on OS X settings_end refers to machine and other + entries, so must be complete before deallocating the machine arrays + (Fred). +20081031 README: small update for 0.10.0. +20081102 disk/{fdd.c,upd_fdc.c}: stop hang if asked for index hole when disk + motor is off, and change spindown time so that The Running Man disk + works (bug #2212424) (Gergely Szasz; thanks, Mark Woodmass). +20081102 ui/win32/win32ui.c: Win32: Made ui_error_specific function work + similarly to the gtk ui equivalent (Marek). +20081102 ui/win32/{win32ui.c,win32internals.h,win32joystick.[ch}: Win32: + Implemented joystick handling using mmsystem API (and tested using PPJoy + joystick emulator, hope it works with real hardware) (Marek). Modified: trunk/fuse/man/fuse.1 =================================================================== --- trunk/fuse/man/fuse.1 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/man/fuse.1 2008-11-03 12:27:34 UTC (rev 539) @@ -80,6 +80,17 @@ .\" the options list is in alphabetical order by long option name (or .\" short option name if none). .\" +.I \-\-accelerate\-loader +.RS +Specify whether Fuse should attempt to accelerate tape loaders by "short +circuiting" the loading loop. This will in general speed up loading, but +may cause some loaders to fail. (Enabled by default, but you can use +.RI ` \-\-no\-accelerate\-loader ' +to disable). The same as the General Options dialog's +.I "Accelerate loaders" +option. +.RE +.PP .I \-\-aspect\-hint .RS Specify whether the GTK+ and Xlib user interfaces should `hint' to the @@ -115,6 +126,14 @@ option. .RE .PP +.I \-\-beeper\-stereo +.RS +Specify whether fake stereo should be added to the emulation of the +Spectrum beeper. Same as the Sound Options dialog's +.I "Beeper pseudo-stereo" +option. +.RE +.PP .I \-\-beta128 .RS Emulate a Beta 128 interface. Same as the Peripherals Options dialog's @@ -122,12 +141,9 @@ option. .RE .PP -.I \-\-beeper\-stereo .RS -Specify whether fake stereo should be added to the emulation of the -Spectrum beeper. Same as the Sound Options dialog's -.I "Beeper pseudo-stereo" -option. +.I \-\-betadisk +Specify a Betadisk image to load. .RE .PP .I \-\-bw\-tv @@ -178,6 +194,15 @@ option. .RE .PP +.I "\-\-debugger\-command string" +.RS +Specify a debugger command to be run before emulator startup. This can +be used to set breakpoints or the like. Currently, this is the only +method to input multi-line debugger commands. (See the +.B "MONITOR/DEBUGGER" +section for more information). +.RE +.PP .I "\-\-detect\-loader" .RS Specify whether Fuse should attempt to detect when the tape is being @@ -189,12 +214,42 @@ option. .RE .PP +.I \-\-divide +.RS +Emulate the DivIDE interface. The same as the Peripherals Options +dialog's +.I "DivIDE interface" +option. +.RE +.PP +.I "\-\-divide\-masterfile file" +.br +.I "\-\-divide\-slavefile file" +.RS +Specify an IDE image to be loaded into the DivIDE's emulated master +and slave drives respectively. +.RE +.PP +.I \-\-divide\-write\-protect +.RS +Specify that the emulated DivIDE's write protect jumper should be +considered set. The same as the Peripherals Options dialog's +.I "DivIDE write protect" +option. +.RE +.PP .I "\-\-dock file" .RS Insert the specified file into the emulated Timex 2068 variant dock; also select the TC2068 on startup if available. .RE .PP +.I "\-\-doublescan\-mode" +.RS +Specify the the framebuffer UI should attempt to use a double scan mode +(where each line is displayed twice). +.RE +.PP .I "\-\-embed\-snapshot" .RS Specify whether a snapshot should be embedded in an RZX file when @@ -291,7 +346,9 @@ .PP .I \-\-interface2 .RS -Emulate a Sinclair Interface II. Same as the Peripherals Options dialog's +Emulate a Sinclair Interface II. (Enabled by default, but you can use +.RI ` \-\-no\-interface2 ' +to disable). Same as the Peripherals Options dialog's .I "Interface II" option. .RE @@ -326,6 +383,16 @@ .RI ` /dev/js1 "'." .RE .PP +.I \-\-joystick-prompt +.RS +If this option is specified, Fuse Fuse will prompt you which form of +joystick emulation you wish to use when loading a snapshot. No prompt +will be issued if the configuration in the snapshot matches what you +are currently using. The same as the General Options dialog's +.I "Snap joystick prompt" +option. +.RE +.PP .I \-\-kempston .RS Emulate a Kempston joystick. Same as the Peripherals Options dialog's @@ -340,6 +407,16 @@ option. .RE .PP +.I \-\-late\-timings +.RS +It has been observed that some real Spectrums run such that the screen +is rendered one tstate later than on other real hardware. This option +specifies that Fuse should emulate such a machine. Same as the General +Options dialog's +.I "Late timings" +option. +.RE +.PP .I \-\-loading\-sound .RS Specify whether the sound made while tapes are loading should be @@ -576,6 +653,16 @@ options. .RE .PP +.I \-\-rzx-autosaves +.RS +Specify that, while recording an RZX file, Fuse should automatically add +a snapshot to the recording stream every 5 seconds. (Default to on, but +you can use +.RI ` \-\-no-rzx-autosaves ' +to disable). Same as the RZX Options dialog's "Create autosaves" option; +see there for more details. +.RE +.PP .I \-\-separation .RS Give stereo separation of the 128's AY sound channels. Same as the @@ -1453,7 +1540,15 @@ to connect to the joystick interface enabled in the snapshot unless it already matches your current configuration. .RE +.PP +.I "Late timings" +.RS +If selected, Fuse will cause all screen-related timings (for example, +when the screen is rendered and when memory contention occurs) to be +one tstate later than "normal", an effect which is present on some real +hardware. .RE +.RE .PP .I "Options, Sound..." .RS @@ -1677,6 +1772,20 @@ aborts). Note that any changed settings only apply to the currently-running Fuse. .PP +.I "Create autosaves" +.RS +If this option is selected, Fuse will add a snapshot into the recording +stream every 5 seconds while creating an RZX file, thus enabling the +rollback facilities to be used without having to explicitly add +snapshots into the stream. Older snapshots will be pruned from the +stream to keep the file size and number of snapshots down: each snapshot +up to 15 seconds will be kept, then one snapshot every 15 seconds until +one minute, then one snapshot every minute until 5 minutes, and then one +snapshot every 5 minutes. Note that this "pruning" applies only to +automatically inserted snapshots: snapshots manually inserted into the +stream will never be pruned. +.RE +.PP .I "Compress RZX data" .RS If this option is selected, and @@ -1960,11 +2069,11 @@ .RS Another Russian clone of the Spectrum. Some details can be found at -.IR "http://www.worldofspectrum.org/rusfaq/index.html" , like all the -Russian clones they they have built in 3.5" disk drives, accessed via -the Beta 128 disk interface and TR-DOS (the Technology Research Disk -Operating System). The most important distinction from the Pentagon -128k and similar machines is the display timing details. +.IR "http://www.worldofspectrum.org/rusfaq/index.html" , +like all the Russian clones they they have built in 3.5" disk drives, +accessed via the Beta 128 disk interface and TR-DOS (the Technology +Research Disk Operating System). The most important distinction from +the Pentagon 128k and similar machines is the display timing details. .RE .PP .I "Spectrum SE" @@ -2899,11 +3008,65 @@ .RS Set a breakpoint to occur .I time -tstates after the start of the current frame, assuming +tstates after the start of the every frame, assuming .I condition evaluates true (if one is given). .RE .PP +br{eakpoint} ev{ent} +.IR area : detail " [" condition ] +.RS +Set a breakpoint to occur when the event specified by +.IR area : detail +occurs and +.I condition +evaluates to true. The events which can be caught are: +.PP +divide:page +.br +divide:unpage +.RS +The DivIDE interface is paged into or out of memory respectively +.RE +.br +if1:page +.br +if1:unpage +.RS +The Interface 1 shadow ROM is paged into or out of memory +.RE +.br +rzx:end +.RS +An RZX recording finishes playing +.RE +.br +tape:play +.br +tape:stop +.RS +The emulated tape starts or stops playing +.RE +.br +zxcf:page +.br +zxcf:unpage +.RS +The ZXCF interface is paged into or out of memory +.RE +.br +zxatasp:page +.br +zxatasp:unpage +.RS +The ZXATASP interface is paged into or out of memory +.RE +.PP +In all cases, the event can be specified as +.IR area :* +to catch all events from that area. +.RE +.PP cl{ear} .RI [ address ] .RS @@ -2914,6 +3077,25 @@ is omitted. Port read/write breakpoints are unaffected. .RE .PP +com{mmands} +.I id <newline> +.br +.I <debugger command> <newline> +.br +.I <debugger command> <newline> +.br +.I ... +.br +end +.RS +Set things such that the specified debugger commands will be +automatically executed when breakpoint +.I id +is triggered. There is currently no user interface for entering +multi-line debugger commands, so the only way to specify this command is +on the command-line via the \-\-debugger\-command option. +.RE +.PP cond{ition} .IR "id " [ condition ] .RS @@ -2950,6 +3132,11 @@ .IR address . .RE .PP +ex{it} +.RS +Exit the emulator immediately. +.RE +.PP fi{nish} .RS Exit from the current CALL or equivalent. This isn't infallible: it @@ -3217,8 +3404,9 @@ .RE .PP .I .SAD +.I .SDF .RS -For compatibility with SAM Coup\('e disk images using this format. +For compatibility with SAM Coup\('e disk images using these formats. Note that SAM Coup\('e `.DSK' images share the same format as `.MGT'. .RE .PP @@ -3251,11 +3439,6 @@ .I http://www.cpc-emu.org/linux/cpcemu_e.txt .RE .PP -.I .SDF -.RS -TODO -.RE -.PP Fuse supports most of them for writing: .I .UDI .FDI .MGT .IMG .SAD .TRD .SCL .DSK (only the old CPC format). @@ -3285,9 +3468,7 @@ or .IR gzip (3) just as if they were uncompressed. -.I libdsk -provides an equivalent functionality for +3 images if available, -but there is currently no support for reading compressed +D or Beta +There is currently no support for reading compressed +3, +D or Beta disk images. .\" .\"------------------------------------------------------------------ @@ -3319,7 +3500,8 @@ .PP The libao file output devices not work properly with the GTK+ UI. No error reporting, but the created file does not contain any sound data. -If you use a `weak' machine alsa09 make a lot of click and pop with +If you use a `weak' machine alsa09 makes a lot of clicks and pops and +will output .RI ` "ALSA: underrun, at least 0ms." ' error messages. .\" Modified: trunk/fuse/menu.c =================================================================== --- trunk/fuse/menu.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/menu.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* menu.c: general menu callbacks Copyright (c) 2004-2005 Philip Kendall - $Id: menu.c 3714 2008-07-06 18:10:29Z fredm $ + $Id: menu.c 3787 2008-10-22 19:10:25Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -93,7 +93,7 @@ error = snapshot_copy_to( snap ); if( error ) { libspectrum_snap_free( snap ); return; } - libspectrum_rzx_add_snap( rzx, snap ); + libspectrum_rzx_add_snap( rzx, snap, 0 ); libspectrum_rzx_start_input( rzx, tstates ); } Modified: trunk/fuse/rzx.c =================================================================== --- trunk/fuse/rzx.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/rzx.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* rzx.c: .rzx files Copyright (c) 2002-2003 Philip Kendall - $Id: rzx.c 3703 2008-06-30 20:36:11Z pak21 $ + $Id: rzx.c 3787 2008-10-22 19:10:25Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -58,6 +58,9 @@ /* The number of bytes read via IN during the current frame */ size_t rzx_in_count; +/* The number of frames we've recorded in this RZX file */ +static size_t autosave_frame_count; + /* And the values of those bytes */ libspectrum_byte *rzx_in_bytes; @@ -95,6 +98,9 @@ a competition mode RZX file */ static const float SPEED_TOLERANCE = 5; +/* How often will we create an autosave file */ +static const size_t AUTOSAVE_INTERVAL = 5 * 50; + /* Debugger events */ static const char *event_type_string = "rzx"; static const char *end_event_detail_string = "end"; @@ -152,7 +158,7 @@ return 1; } - error = libspectrum_rzx_add_snap( rzx, snap ); + error = libspectrum_rzx_add_snap( rzx, snap, 0 ); if( error ) { libspectrum_snap_free( snap ); return error; @@ -160,13 +166,12 @@ } - /* Put an input recording block into the RZX file */ libspectrum_rzx_start_input( rzx, tstates ); - /* Start the count of instruction fetches here */ - counter_reset(); rzx_in_count = 0; + counter_reset(); + rzx_in_count = 0; + autosave_frame_count = 0; - /* Note that we're recording */ rzx_recording = 1; ui_menu_activate( UI_MENU_ITEM_RECORDING, 1 ); @@ -366,6 +371,80 @@ return 0; } +typedef struct prune_info_t { + libspectrum_rzx_iterator it; + size_t frames; +} prune_info_t; + +static void +autosave_prune( void ) +{ + GArray *autosaves = g_array_new( FALSE, FALSE, sizeof( prune_info_t ) ); + libspectrum_rzx_iterator it; + size_t i, frames = 0; + + for( it = libspectrum_rzx_iterator_begin( rzx ); + it; + it = libspectrum_rzx_iterator_next( it ) ) { + + libspectrum_rzx_block_id id = libspectrum_rzx_iterator_get_type( it ); + + switch( id ) { + + case LIBSPECTRUM_RZX_INPUT_BLOCK: + frames += libspectrum_rzx_iterator_get_frames( it ); break; + + case LIBSPECTRUM_RZX_SNAPSHOT_BLOCK: + if( libspectrum_rzx_iterator_snap_is_automatic( it ) ) { + prune_info_t info = { it, frames }; + g_array_append_val( autosaves, info ); + } + break; + + default: + break; + } + } + + /* Convert 'time from start' into 'time before now' */ + for( i = 0; i < autosaves->len; i++ ) { + prune_info_t *info = &( g_array_index( autosaves, prune_info_t, i ) ); + info->frames = frames - info->frames; + } + + for( i = autosaves->len - 1; i > 0; i-- ) { + prune_info_t save1 = g_array_index( autosaves, prune_info_t, i ), + save2 = g_array_index( autosaves, prune_info_t, i - 1 ); + + if( ( save1.frames == 15 * 50 || + save1.frames == 60 * 50 || + save1.frames == 300 * 50 ) && + save2.frames < 2 * save1.frames + ) + /* FIXME: could possibly merge adjacent IRBs here */ + libspectrum_rzx_iterator_delete( rzx, save1.it ); + } + + g_array_set_size( autosaves, 0 ); +} + +static void +autosave_frame( void ) +{ + libspectrum_snap *snap; + + if( ++autosave_frame_count % AUTOSAVE_INTERVAL ) return; + + snap = libspectrum_snap_alloc(); + snapshot_copy_to( snap ); + + libspectrum_rzx_stop_input( rzx ); + libspectrum_rzx_add_snap( rzx, snap, 1 ); + libspectrum_rzx_start_input( rzx, tstates ); + + autosave_prune(); +} + static int recording_frame( void ) { libspectrum_error error; @@ -395,6 +474,8 @@ } + if( settings_current.rzx_autosaves ) autosave_frame(); + return 0; } Modified: trunk/fuse/settings.dat =================================================================== --- trunk/fuse/settings.dat 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/settings.dat 2008-11-03 12:27:34 UTC (rev 539) @@ -2,7 +2,7 @@ # Copyright (c) 2002-2008 Philip Kendall # Copyright (c) 2003-2005 Fredrick Meunier -# $Id: settings.dat 3751 2008-08-19 15:46:09Z specu $ +# $Id: settings.dat 3787 2008-10-22 19:10:25Z pak21 $ # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -122,6 +122,7 @@ competition_mode, boolean, 0 competition_code, numeric, 0 embed_snapshot, boolean, 1 +rzx_autosaves, boolean, 1 snapshot, string, NULL, 's' tape_file, string, NULL, 't', tape, tapefile Modified: trunk/fuse/ui/options.dat =================================================================== --- trunk/fuse/ui/options.dat 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/ui/options.dat 2008-11-03 12:27:34 UTC (rev 539) @@ -48,6 +48,7 @@ rzx RZX Options +Checkbox, Create (a)utosaves, rzx_autosaves, INPUT_KEY_a Checkbox, (C)ompress RZX data, rzx_compression, INPUT_KEY_c Checkbox, C(o)mpetition mode, competition_mode, INPUT_KEY_o Entry, Co(m)petition code, competition_code, INPUT_KEY_m, 8, Modified: trunk/fuse/ui/win32/win32internals.h =================================================================== --- trunk/fuse/ui/win32/win32internals.h 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/ui/win32/win32internals.h 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* win32internals.h: stuff internal to the Win32 UI Copyright (c) 2004 Marek Januszewski - $Id: win32internals.h 3768 2008-09-07 01:33:19Z specu $ + $Id: win32internals.h 3804 2008-11-03 04:21:02Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -31,6 +31,10 @@ #include <commdlg.h> #include <shellapi.h> +/* FIXME: this should be included as part of windows.h, but is not + because WIN32_LEAN_AND_MEAN is defined along the way somewhere */ +#include <mmsystem.h> + #include <libspectrum.h> #define ID_STATUSBAR 900 Modified: trunk/fuse/ui/win32/win32joystick.c =================================================================== --- trunk/fuse/ui/win32/win32joystick.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/ui/win32/win32joystick.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* gtkjoystick.c: Joystick emulation Copyright (c) 2003-2008 Darren Salt, Philip Kendall, Marek Januszewski - $Id: win32joystick.c 3751 2008-08-19 15:46:09Z specu $ + $Id: win32joystick.c 3804 2008-11-03 04:21:02Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -27,17 +27,12 @@ #include <config.h> -#if !defined USE_JOYSTICK || defined HAVE_JSW_H -#include "../uijoystick.c" -#else - /* FIXME: implement win32 joystick using mmsystem, not jsw */ -#endif - #include <tchar.h> #include <windows.h> #include "fuse.h" #include "joystick.h" +#include "input.h" #include "keyboard.h" #include "menu.h" #include "settings.h" @@ -45,6 +40,126 @@ #include "win32joystick.h" +#if !defined USE_JOYSTICK || defined HAVE_JSW_H + +#include "../uijoystick.c" + +#else /* #if !defined USE_JOYSTICK || defined HAVE_JSW_H */ + +/* Functions to handle Joystick events */ +#include "ui/ui.h" +#include "ui/uijoystick.h" + +static void do_axis( int which, WORD value, + input_key negative, input_key positive ); + +int +ui_joystick_init( void ) +{ + int retval; + JOYINFO joyinfo; + + retval = joyGetNumDevs(); + + if( retval >= 2 ) { + + retval = 2; + + if( joyGetPos( JOYSTICKID2, &joyinfo ) == JOYERR_UNPLUGGED ) { + ui_error( UI_ERROR_ERROR, "failed to initialise joystick 2" ); + return 0; + } + } + + if( retval > 0 ) { + + if( joyGetPos( JOYSTICKID1, &joyinfo ) == JOYERR_UNPLUGGED ) { + ui_error( UI_ERROR_ERROR, "failed to initialise joystick 1" ); + return 0; + } + } + + return retval; +} + +void +ui_joystick_poll( void ) +{ + /* No action needed; joysticks already handled by the Window messages + sent by mmsystem */ +} + +void +win32joystick_buttonevent( int which_joystick, int button_down, + unsigned int wParam ) +{ + input_event_t event; + int button = 0; + + if( wParam & JOY_BUTTON1 ) button = INPUT_JOYSTICK_FIRE_1; + else if( wParam & JOY_BUTTON2 ) button = INPUT_JOYSTICK_FIRE_2; + else if( wParam & JOY_BUTTON3 ) button = INPUT_JOYSTICK_FIRE_3; + else if( wParam & JOY_BUTTON4 ) button = INPUT_JOYSTICK_FIRE_4; + else if( wParam & JOY_BUTTON5 ) button = INPUT_JOYSTICK_FIRE_5; + else if( wParam & JOY_BUTTON6 ) button = INPUT_JOYSTICK_FIRE_6; + else if( wParam & JOY_BUTTON7 ) button = INPUT_JOYSTICK_FIRE_7; + else if( wParam & JOY_BUTTON8 ) button = INPUT_JOYSTICK_FIRE_8; + else if( wParam & JOY_BUTTON9 ) button = INPUT_JOYSTICK_FIRE_9; + else if( wParam & JOY_BUTTON10 ) button = INPUT_JOYSTICK_FIRE_10; + else return; /* Fuse supports up to 10 joystick buttons */ + + event.types.joystick.which = which_joystick; + event.type = button_down + ? INPUT_EVENT_JOYSTICK_PRESS : INPUT_EVENT_JOYSTICK_RELEASE; + event.types.joystick.button = button; + input_event( &event ); +} + +void +win32joystick_move( int which_joystick, unsigned short pos_x, + unsigned short pos_y ) +{ + do_axis( which_joystick, pos_x, + INPUT_JOYSTICK_LEFT, INPUT_JOYSTICK_RIGHT ); + do_axis( which_joystick, pos_y, + INPUT_JOYSTICK_UP, INPUT_JOYSTICK_DOWN ); +} + +static void +do_axis( int which, WORD value, input_key negative, input_key positive ) +{ + input_event_t event1, event2; + + event1.types.joystick.which = event2.types.joystick.which = which; + + event1.types.joystick.button = negative; + event2.types.joystick.button = positive; + + /* MS Windows sends a value between 0 and 65535, hopefully those will work */ + if( value > 49152 ) { + event1.type = INPUT_EVENT_JOYSTICK_RELEASE; + event2.type = INPUT_EVENT_JOYSTICK_PRESS; + } else if( value < 16384 ) { + event1.type = INPUT_EVENT_JOYSTICK_PRESS; + event2.type = INPUT_EVENT_JOYSTICK_RELEASE; + } else { + event1.type = INPUT_EVENT_JOYSTICK_RELEASE; + event2.type = INPUT_EVENT_JOYSTICK_RELEASE; + } + + input_event( &event1 ); + input_event( &event2 ); +} + +void +ui_joystick_end( void ) +{ + /* Initialization and unitialization is handled by MS Windows */ +} + +#endif /* #if !defined USE_JOYSTICK || defined HAVE_JSW_H */ + +/* Win32 UI functions to handle Joystick options menus */ struct button_info { int *setting; TCHAR name[80]; Modified: trunk/fuse/ui/win32/win32joystick.h =================================================================== --- trunk/fuse/ui/win32/win32joystick.h 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/ui/win32/win32joystick.h 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* win32joystick.h: Joystick emulation Copyright (c) 2008 Marek Januszewski - $Id: win32joystick.h 3588 2008-03-27 17:48:10Z zubzero $ + $Id: win32joystick.h 3804 2008-11-03 04:21:02Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -62,3 +62,15 @@ #define IDC_JOYSTICKS_BUTTON_BUTTON10 ( IDC_JOYSTICKS_BUTTON_BUTTON9 + 1 ) #define IDR_JOYSTICKS_POPUP ( IDC_JOYSTICKS_BUTTON_BUTTON10 + 1 ) + +/* + win32joystick_buttonevent parameters: + which_joystick = 0 => JOYSTICK1 + which_joystick = 1 => JOYSTICK2 + button_down = 1 => button pressed + button_down = 0 => button released +*/ +void win32joystick_buttonevent( int which_joystick, int button_down, + unsigned int wParam ); +void win32joystick_move( int which_joystick, + unsigned short pos_x, unsigned short pos_y ); Modified: trunk/fuse/ui/win32/win32ui.c =================================================================== --- trunk/fuse/ui/win32/win32ui.c 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/ui/win32/win32ui.c 2008-11-03 12:27:34 UTC (rev 539) @@ -1,7 +1,7 @@ /* win32ui.c: Win32 routines for dealing with the user interface Copyright (c) 2003-2007 Marek Januszewski, Philip Kendall, Stuart Brady - $Id: win32ui.c 3768 2008-09-07 01:33:19Z specu $ + $Id: win32ui.c 3804 2008-11-03 04:21:02Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -28,6 +28,7 @@ #include "debugger/debugger.h" #include "display.h" #include "fuse.h" +#include "joystick.h" #include "keyboard.h" #include "menu.h" #include "menu_data.h" @@ -40,9 +41,9 @@ #include "timer/timer.h" #include "timer/timer.h" #include "ui/ui.h" -#include "ui/uijoystick.h" #include "utils.h" #include "win32internals.h" +#include "win32joystick.h" /* fuse_hPrevInstance is needed only to register window class */ static HINSTANCE fuse_hPrevInstance; @@ -120,6 +121,20 @@ fuse_window_proc( HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam ) { switch( msg ) { + +#if defined USE_JOYSTICK && !defined HAVE_JSW_H + + case WM_CREATE: + if( joysticks_supported > 0 ) + if( joySetCapture( hWnd, JOYSTICKID1, 0, FALSE ) ) + ui_error( UI_ERROR_ERROR, "Couldn't start capture for joystick 1" ); + if( joysticks_supported > 1 ) + if( joySetCapture( hWnd, JOYSTICKID2, 0, FALSE ) ) + ui_error( UI_ERROR_ERROR, "Couldn't start capture for joystick 2" ); + break; + +#endif /* if defined USE_JOYSTICK && !defined HAVE_JSW_H */ + case WM_COMMAND: if( ! handle_menu( LOWORD( wParam ), hWnd ) ) return 0; @@ -228,8 +243,36 @@ else if( LOWORD( wParam ) == WA_INACTIVE ) return win32ui_lose_focus( hWnd, wParam, lParam ); break; + +#if defined USE_JOYSTICK && !defined HAVE_JSW_H + + case MM_JOY1BUTTONDOWN: + win32joystick_buttonevent( 0, 1, wParam ); + break; + + case MM_JOY1BUTTONUP: + win32joystick_buttonevent( 0, 0, wParam ); + break; + + case MM_JOY2BUTTONDOWN: + win32joystick_buttonevent( 1, 1, wParam ); + break; + + case MM_JOY2BUTTONUP: + win32joystick_buttonevent( 1, 0, wParam ); + break; + + case MM_JOY1MOVE: + win32joystick_move( 0, LOWORD( lParam ), HIWORD( lParam ) ); + break; + + case MM_JOY2MOVE: + win32joystick_move( 1, LOWORD( lParam ), HIWORD( lParam ) ); + break; + +#endif /* if defined USE_JOYSTICK && !defined HAVE_JSW_H */ + } - return( DefWindowProc( hWnd, msg, wParam, lParam ) ); } @@ -362,33 +405,27 @@ int ui_error_specific( ui_error_level severity, const char *message ) { - /* finish - can ui be not initialized? */ - HWND hWnd; + /* If we don't have a UI yet, we can't output widgets */ + if( !display_ui_initialised ) return 0; - fuse_emulation_pause(); - - hWnd = GetActiveWindow(); - switch( severity ) { case UI_ERROR_INFO: - MessageBox( hWnd, message, "Fuse - Info", MB_ICONINFORMATION | MB_OK ); + MessageBox( fuse_hWnd, message, "Fuse - Info", MB_ICONINFORMATION | MB_OK ); break; case UI_ERROR_WARNING: - MessageBox( hWnd, message, "Fuse - Warning", MB_ICONWARNING | MB_OK ); + MessageBox( fuse_hWnd, message, "Fuse - Warning", MB_ICONWARNING | MB_OK ); break; case UI_ERROR_ERROR: - MessageBox( hWnd, message, "Fuse - Error", MB_ICONERROR | MB_OK ); + MessageBox( fuse_hWnd, message, "Fuse - Error", MB_ICONERROR | MB_OK ); break; default: - MessageBox( hWnd, message, "Fuse - (Unknown Error Level)", + MessageBox( fuse_hWnd, message, "Fuse - (Unknown Error Level)", MB_ICONINFORMATION | MB_OK ); break; } - fuse_emulation_unpause(); - return 0; } @@ -644,25 +681,6 @@ return UI_CONFIRM_JOYSTICK_NONE; } -int -ui_joystick_init( void ) -{ - STUB; - return 0; -} - -void -ui_joystick_end( void ) -{ - STUB; -} - -void -ui_joystick_poll( void ) -{ - /* STUB; */ -} - /* * Font code */ Modified: trunk/fuse/z80/tests/README =================================================================== --- trunk/fuse/z80/tests/README 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/fuse/z80/tests/README 2008-11-03 12:27:34 UTC (rev 539) @@ -8,10 +8,12 @@ <arbitrary test description> AF BC DE HL AF' BC' DE' HL' IX IY SP PC -I R IFF1 IFF2 <halted> <tstates> +I R IFF1 IFF2 IM <halted> <tstates> <halted> specifies whether the Z80 is halted. -<tstates> specifies the number of tstates to run the test for. +<tstates> specifies the number of tstates to run the test for, in + decimal; the number actually executed may be higher, as the final + instruction is allowed to complete. Then followed by lines specifying the initial memory setup. Each has the format: Property changes on: trunk/libspectrum/libspectrum ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/current/libspectrum:530-533 + /vendor/fuse-emulator/current/libspectrum:530-538 Modified: trunk/libspectrum/libspectrum/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/ChangeLog 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/libspectrum/libspectrum/ChangeLog 2008-11-03 12:27:34 UTC (rev 539) @@ -1,3 +1,47 @@ +2008-11-?? Philip Kendall <phi...@sh...> + + * libspectrum 0.5.0 released. + + * Memory management change: memory allocation functions now abort + on failure. Leads to simpler code both internally and for + users of the library (Philip Kendall). + + * Support for tape acceleration (Philip Kendall) + + * IDE improvements to allow DivIDE to support FATware (Philip + Kendall; thanks, http://www.dusky.sk/zxs/) + + * New API to deal with flagging automatic snapshots in RZX files + (Philip Kendall). + + * New function to get length (time) of a tape block (Philip Kendall, + Fredrick Meunier). + + * 128K SNA files are now treated as being for the Pentagon 128 + rather than the Spectrum 128 (Fredrick Meunier) + + * SNA files now written out correctly (Philip Kendall). + + * Handle MDR write protection flag correctly (Philip Kendall) + + * Allow MDR images with bad checksums to load (the error will + be handled by the If1 ROM) (Gergely Szasz) + + * Support saving custom ROMs in SZX snapshots (Fredrick Meunier, + Stuart Brady) + + * Support for DivIDE, Kempston mouse and the simple IDE interface + in SZX snapshots (Fredrick Meunier) + + * Allow building without libgcrypt (Stuart Brady) + + * Amiga and MorphOS compilation fixes (Chris Young, Q-Master) + + * Don't produce empty libraries to fix build process on + OpenSolaris (Fredrick Meunier) + + * Remove deprecated functions (Fredrick Meunier). + 2008-01-05 Philip Kendall <phi...@sh...> * libspectrum 0.4.0 released. @@ -225,5 +269,5 @@ * libspectrum separated from Fuse just before the 0.5.0 release of Fuse; see Fuse's ChangeLog for changes up to this point -$Id: ChangeLog 3480 2008-01-07 12:19:50Z pak21 $ +$Id: ChangeLog 3791 2008-10-27 20:20:40Z pak21 $ Modified: trunk/libspectrum/libspectrum/README =================================================================== --- trunk/libspectrum/libspectrum/README 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/libspectrum/libspectrum/README 2008-11-03 12:27:34 UTC (rev 539) @@ -42,14 +42,14 @@ http://fuse-emulator.sourceforge.net/libspectrum.php -Compiling from CVS ------------------- +Compiling from Subversion +------------------------- -If you're using version of libspectrum from CVS rather than one of the -released tarballs, you'll need to run `autogen.sh' before running -'configure' for the first time. +If you're using version of libspectrum from Subversion rather than one +of the released tarballs, you'll need to run `autogen.sh' before +running 'configure' for the first time. Philip Kendall <phi...@sh...> 5 January 2008 -$Id: README 3480 2008-01-07 12:19:50Z pak21 $ +$Id: README 3795 2008-10-27 21:02:43Z pak21 $ Modified: trunk/libspectrum/libspectrum/doc/libspectrum.txt =================================================================== --- trunk/libspectrum/libspectrum/doc/libspectrum.txt 2008-11-03 11:45:06 UTC (rev 538) +++ trunk/libspectrum/libspectrum/doc/libspectrum.txt 2008-11-03 12:27:34 UTC (rev 539) @@ -61,9 +61,9 @@ libspectrum_error libspectrum_init( void ) This routine must be called before any other libspectrum routines, -other than `libspectrum_version' and `libspectrum_check_version' to -initialise the library. If it isn't called, undefined behaviour may -result. +other than `libspectrum_version', `libspectrum_check_version' and +`libspectrum_mem_set_vtable' to initialise the library. If it isn't +called, undefined behaviour may result. const char *libspectrum_version( void ) @@ -83,6 +83,34 @@ returns non-zero if the libspectrum version in use is at least `version' or zero if it is not. +Memory handling +=============== + +By default, libspectrum will use the standard library's malloc(), +calloc(), realloc() and free() for memory handling, but wrapped so that +they are "strong" (they will either succeed or abort the program). It is +possible to replace these with custom allocation routines if you wish. + +typedef void* (*libspectrum_malloc_fn_t)( size_t size ); +typedef void* (*libspectrum_calloc_fn_t)( size_t nmemb, size_t size ); +typedef void* (*libspectrum_realloc_fn_t)( void *ptr, size_t size ); +typedef void (*libspectrum_free_fn_t)( void *ptr ); + +typedef struct libspectrum_mem_vtable_t { + libspectrum_malloc_fn_t malloc; + libspectrum_calloc_fn_t calloc; + libspectrum_realloc_fn_t realloc; + libspectrum_free_fn_t free; +} libspectrum_mem_vtable_t; + +void libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ) + +Set the memory handling routines to be those specified by `table'. This +function may *not* be called after libspectrum_init() has been called. +Note that libspectrum will ensure that the memory allocators are still +strong, and will abort the program if any of the allocators returns +NULL. + Error handling ============== @@ -391,7 +419,7 @@ libspectrum provides a `libspectrum_creator' structure to store this information. -libspectrum_error libspectrum_creator_alloc( libspectrum_creator **creator ) +libspectrum_creator* libspectrum_creator_alloc( void ) Allocate a new `libspectrum_creator' structure. @@ -451,7 +479,7 @@ `libspectrum_snap' structure, which can be accessed via the following routines: -libspectrum_error libspectrum_snap_alloc( libspectrum_snap **snap ) +libspectrum_snap* libspectrum_snap_alloc( void ) Allocate a new libspectrum_snap structure. @@ -695,34 +723,6 @@ The only formats for which serialisation is supported are .sna, .szx and .z80. -Deprecated snapshot routines ----------------------------- - -There are also three format-specific functions. However, *these -functions are deprecated and should not be used in new code*: - -libspectrum_error libspectrum_sna_read( libspectrum_snap *snap, - const libspectrum_byte *buffer, - size_t buffer_length ) - -Take the .sna snapshot of length `buffer_length' bytes at `buffer' and -convert it to a `libspectrum_snap' structure. - -libspectrum_error libspectrum_z80_read( libspectrum_snap *snap, - const libspectrum_byte *buffer, - size_t buffer_length ) - -Similarly for a .z80 snapshot. - -libspectrum_error libspectrum_z80_write( libspectrum_byte **buffer, - size_t *length, - libspectrum_snap *snap ) - -Take the snapshot in `snap' and serialise it into a .z80 file at -'*buffer'. On entry, '*buffer' is assumed to be allocated '*length' -bytes, and will grow if necessary; if '*length' is zero, '*buffer' can -be uninitialised on entry. - Tape functions ============== @@ -732,7 +732,7 @@ The routines for dealing with tapes are: -libspectrum_error libspectrum_tape_alloc( libspectrum_tape **tape ) +libspectrum_tape* libspectrum_tape_alloc( void ) Allocate a new libspectrum_tape object. @@ -793,6 +793,10 @@ forced high at this edge LIBSPECTRUM_TAPE_FLAGS_NO_EDGE This "edge" isn't really an edge and doesn't change the input signal from the tape. +LIBSPECTRUM_TAPE_FLAGS_LENGTH_SHORT This edge is a "short" edge; used + for loader acceleration +LIBSPECTRUM_TAPE_FLAGS_LENGTH_LONG This edge is a "long" edge; again + used for loader acceleration int libspectrum_tape_present( libspectrum_tape *tape ) @@ -809,12 +813,27 @@ Set the current block on the tape to be the `n'th block and initialise it. Again, the first block on the tape is block 0. -libspectrum_error +void libspectrum_tape_append_block( libspectrum_tape *tape, libspectrum_tape_block *block ) Append `block' to `tape'. +void +libspectrum_tape_remove_block( libspectrum_tape *tape, + libspectrum_tape_iterator it ) + +Remove the block pointed to by `it' (see the "Tape iterators" section) +from the tape. + +libspectrum_error +libspectrum_tape_insert_block( libspectrum_tape *tape, + libspectrum_tape_block *block, + size_t position ) + +Insert `block' into `tape` in position `position', where position 0 +would make the new block the first block on the tape. + libspectrum_tape_block* libspectrum_tape_current_block( libspectrum_tape *tape ) @@ -832,50 +851,6 @@ Move the tape along so it points to the next block, initialise that block and return it. -Deprecated tape routines ------------------------- - -*These functions are deprecated and should not be used in new code*: - -libspectrum_error -libspectrum_tap_read( libspectrum_tape *tape, const libspectrum_byte *buffer, - const size_t length ) - -Form a tape object in `tape' from the .tap file of `length' bytes -starting at `buffer'. This routine deals with the `normal' (Z80-style) -.tap files, not with Warajevo .tap files. - -libspectrum_error -libspectrum_tap_write( libspectrum_byte **buffer, size_t *length, - libspectrum_tape *tape ) - -Attempt to convert the tape in `tape' to a .tap file in `*buffer', which -has previously been allocated `*length' bytes by user code. The .tap -format can handle only standard speed loading blocks; a best guess -attempt will be made to convert other blocks, but the resultant .tap -file probably won't work. - -libspectrum_error -libspectrum_tzx_read( libspectrum_tape *tape, const libspectrum_byte *buffer, - const size_t length ) - -Just as `libspectrum_tap_read', but for .tzx format files. - -libspectrum_error -libspectrum_tzx_write( libspectrum_byte **buffer, size_t *length, - libspectrum_tape *tape ) - -Just as `libspectrum_tap_write', but for .tzx files. The conversion to -.tzx format is not lossy as it is with converting to .tap. - -libspectrum_error -libspectrum_warajevo_read( libspectrum_tape *tape, - const libspectrum_byte *buffer, - const size_t length ) - -Just as `libspectrum_tap_read', but for Warajevo-style .tap files. -There is no currently no function to write a Warajevo-style .tap file. - Tape iterators -------------- @@ -946,9 +921,8 @@ The basic routines for dealing with tape blocks are: -libspectrum_error -libspectrum_tape_block_alloc( libspectrum_tape_block **block, - libspectrum_tape_type type ) +libspectrum_tape_block* +libspectrum_tape_block_alloc( libspectrum_tape_type type ) Allocate a new tape block of `type'. @@ -994,6 +968,11 @@ Returns 1 if the block consists solely of metadata (comments, etc.) or 0 if ... [truncated message content] |
From: <fr...@us...> - 2008-11-07 12:14:33
|
Revision: 544 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=544&view=rev Author: fredm Date: 2008-11-07 12:14:27 +0000 (Fri, 07 Nov 2008) Log Message: ----------- Correct reporting of unknown classes, log name of tape being scanned for metadata. Modified Paths: -------------- trunk/FuseGenerator/LibspectrumSCRExtractor.m trunk/FuseImporter/LibspectrumMetadataImporter.m Modified: trunk/FuseGenerator/LibspectrumSCRExtractor.m =================================================================== --- trunk/FuseGenerator/LibspectrumSCRExtractor.m 2008-11-05 11:41:07 UTC (rev 543) +++ trunk/FuseGenerator/LibspectrumSCRExtractor.m 2008-11-07 12:14:27 UTC (rev 544) @@ -169,7 +169,7 @@ break; default: - NSLog(@"LibspectrumSCRExtractor: loadFile: unknown class %d!\n", type ); + NSLog(@"LibspectrumSCRExtractor: loadFile: unknown class %d!\n", lsclass ); } if( munmap( buffer, length ) == -1 ) { Modified: trunk/FuseImporter/LibspectrumMetadataImporter.m =================================================================== --- trunk/FuseImporter/LibspectrumMetadataImporter.m 2008-11-05 11:41:07 UTC (rev 543) +++ trunk/FuseImporter/LibspectrumMetadataImporter.m 2008-11-07 12:14:27 UTC (rev 544) @@ -183,6 +183,8 @@ tape = libspectrum_tape_alloc(); + NSLog(@"LibspectrumMetadataImporter: reading tape `%s'\n", fsrep ); + error = libspectrum_tape_read( tape, buffer, length, type, fsrep ); if( error != LIBSPECTRUM_ERROR_NONE ) { return NO; @@ -697,7 +699,7 @@ break; default: - NSLog(@"LibspectrumMetadataImporter: loadFile: unknown class %d!\n", type ); + NSLog(@"LibspectrumMetadataImporter: loadFile: unknown class %d!\n", lsclass ); retval = NO; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2008-11-18 12:05:29
|
Revision: 547 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=547&view=rev Author: fredm Date: 2008-11-18 12:05:21 +0000 (Tue, 18 Nov 2008) Log Message: ----------- Merge up to vendor 0.10.0-pre1 release. Modified Paths: -------------- trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/libspectrum.h trunk/fuse/ChangeLog trunk/fuse/Makefile.am trunk/fuse/configure.in trunk/fuse/disk/disk.c trunk/fuse/fuse.c trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html trunk/fuse/fusepb/resources/Fuse Help/html/monitor.html trunk/fuse/hacking/ChangeLog trunk/fuse/hacking/Makefile.am trunk/fuse/hacking/cvs-tags trunk/fuse/machines/specplus2a.c trunk/fuse/machines/specplus3.c trunk/fuse/man/fuse.1 trunk/fuse/ui/win32/Makefile.am trunk/fuse/utils.c trunk/libspectrum/Info.plist trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/doc/cvs-tags trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/libspectrum.c trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum.h trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj Property Changed: ---------------- trunk/fuse/ trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/FuseGenerator/libspectrum.h 2008-11-18 12:05:21 UTC (rev 547) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3792 2008-10-27 20:49:34Z specu $ + $Id: libspectrum.h.in 3806 2008-11-08 10:42:38Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -286,7 +286,10 @@ /* Below here, present only in 0.1.1 and later */ + /* The next entry is deprecated in favour of the more specific + LIBSPECTRUM_ID_DISK_CPC and LIBSPECTRUM_ID_DISK_ECPC */ LIBSPECTRUM_ID_DISK_DSK, /* .dsk +3 disk image */ + LIBSPECTRUM_ID_DISK_SCL, /* .scl TR-DOS disk image */ LIBSPECTRUM_ID_DISK_TRD, /* .trd TR-DOS disk image */ LIBSPECTRUM_ID_CARTRIDGE_DCK, /* .dck Timex cartridge image */ @@ -318,6 +321,7 @@ LIBSPECTRUM_ID_TAPE_Z80EM, /* Z80Em tape image */ /* Below here, present only in 0.4.0 and later */ + LIBSPECTRUM_ID_TAPE_WAV, /* .wav tape image */ LIBSPECTRUM_ID_TAPE_SPC, /* SP-style .spc tape image */ LIBSPECTRUM_ID_TAPE_STA, /* Speculator-style .sta tape image */ @@ -326,6 +330,15 @@ LIBSPECTRUM_ID_DISK_IMG, /* .img DISCiPLE/+D disk image */ LIBSPECTRUM_ID_DISK_MGT, /* .mgt DISCiPLE/+D disk image */ + /* Below here, present only in 0.5.0 and later */ + + LIBSPECTRUM_ID_DISK_UDI, /* .udi generic disk image */ + LIBSPECTRUM_ID_DISK_FDI, /* .fdi generic disk image */ + LIBSPECTRUM_ID_DISK_CPC, /* .dsk plain CPC +3 disk image */ + LIBSPECTRUM_ID_DISK_ECPC, /* .dsk extended CPC +3 disk image */ + LIBSPECTRUM_ID_DISK_SAD, /* .sad generic disk image */ + LIBSPECTRUM_ID_DISK_TD0, /* .td0 generic disk image */ + LIBSPECTRUM_ID_SCREEN_SCR, /* .scr screen file */ } libspectrum_id_t; @@ -359,6 +372,10 @@ LIBSPECTRUM_CLASS_DISK_PLUSD, /* DISCiPLE/+D disk image */ + /* Below here, present only in 0.5.0 and later */ + + LIBSPECTRUM_CLASS_DISK_GENERIC, /* generic disk image */ + LIBSPECTRUM_CLASS_SCREENSHOT, /* Screenshot */ } libspectrum_class_t; Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/FuseImporter/libspectrum.h 2008-11-18 12:05:21 UTC (rev 547) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3792 2008-10-27 20:49:34Z specu $ + $Id: libspectrum.h.in 3806 2008-11-08 10:42:38Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -286,7 +286,10 @@ /* Below here, present only in 0.1.1 and later */ + /* The next entry is deprecated in favour of the more specific + LIBSPECTRUM_ID_DISK_CPC and LIBSPECTRUM_ID_DISK_ECPC */ LIBSPECTRUM_ID_DISK_DSK, /* .dsk +3 disk image */ + LIBSPECTRUM_ID_DISK_SCL, /* .scl TR-DOS disk image */ LIBSPECTRUM_ID_DISK_TRD, /* .trd TR-DOS disk image */ LIBSPECTRUM_ID_CARTRIDGE_DCK, /* .dck Timex cartridge image */ @@ -318,6 +321,7 @@ LIBSPECTRUM_ID_TAPE_Z80EM, /* Z80Em tape image */ /* Below here, present only in 0.4.0 and later */ + LIBSPECTRUM_ID_TAPE_WAV, /* .wav tape image */ LIBSPECTRUM_ID_TAPE_SPC, /* SP-style .spc tape image */ LIBSPECTRUM_ID_TAPE_STA, /* Speculator-style .sta tape image */ @@ -326,6 +330,15 @@ LIBSPECTRUM_ID_DISK_IMG, /* .img DISCiPLE/+D disk image */ LIBSPECTRUM_ID_DISK_MGT, /* .mgt DISCiPLE/+D disk image */ + /* Below here, present only in 0.5.0 and later */ + + LIBSPECTRUM_ID_DISK_UDI, /* .udi generic disk image */ + LIBSPECTRUM_ID_DISK_FDI, /* .fdi generic disk image */ + LIBSPECTRUM_ID_DISK_CPC, /* .dsk plain CPC +3 disk image */ + LIBSPECTRUM_ID_DISK_ECPC, /* .dsk extended CPC +3 disk image */ + LIBSPECTRUM_ID_DISK_SAD, /* .sad generic disk image */ + LIBSPECTRUM_ID_DISK_TD0, /* .td0 generic disk image */ + LIBSPECTRUM_ID_SCREEN_SCR, /* .scr screen file */ } libspectrum_id_t; @@ -359,6 +372,10 @@ LIBSPECTRUM_CLASS_DISK_PLUSD, /* DISCiPLE/+D disk image */ + /* Below here, present only in 0.5.0 and later */ + + LIBSPECTRUM_CLASS_DISK_GENERIC, /* generic disk image */ + LIBSPECTRUM_CLASS_SCREENSHOT, /* Screenshot */ } libspectrum_class_t; Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/current/fuse:530-538 + /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-538 Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/ChangeLog 2008-11-18 12:05:21 UTC (rev 547) @@ -16,6 +16,8 @@ * Reading from the 128K's memory control port causes that byte to be written back to the port (Philip Kendall; thanks, Marat Fayzullin). + * Reading the AY data port on the +2A/+3 is the same as reading + the register port (Philip Kendall; thanks, Mark Woodmass). * NMI causes Z80 to unHALT (Philip Kendall; thanks, Simon Owen). * Emulate C, H and P/V flags on repeated IO instructions (Philip Kendall). @@ -929,4 +931,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 3787 2008-10-22 19:10:25Z pak21 $ +$Id: ChangeLog 3823 2008-11-16 17:32:18Z pak21 $ Modified: trunk/fuse/Makefile.am =================================================================== --- trunk/fuse/Makefile.am 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/Makefile.am 2008-11-18 12:05:21 UTC (rev 547) @@ -1,7 +1,7 @@ # Process this file with automake to produce Makefile.in ## Copyright (c) 1999-2008 Philip Kendall -## $Id: Makefile.am 3617 2008-05-17 08:09:47Z pak21 $ +## $Id: Makefile.am 3818 2008-11-15 13:28:08Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -173,6 +173,7 @@ loader.h \ machine.h \ memory.h \ + mempool.h \ menu.h \ module.h \ periph.h \ Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/configure.in 2008-11-18 12:05:21 UTC (rev 547) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 3796 2008-10-28 20:44:45Z specu $ +dnl $Id: configure.in 3827 2008-11-17 21:19:48Z pak21 $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -24,7 +24,7 @@ AC_CANONICAL_SYSTEM dnl Use automake to produce `Makefile.in' -AM_INIT_AUTOMAKE(fuse, 0.9.0) +AM_INIT_AUTOMAKE(fuse, 0.10.0-pre1) dnl Checks for programs. AC_PROG_CC Modified: trunk/fuse/disk/disk.c =================================================================== --- trunk/fuse/disk/disk.c 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/disk/disk.c 2008-11-18 12:05:21 UTC (rev 547) @@ -1,7 +1,7 @@ /* disk.c: Routines for handling disk images Copyright (c) 2007 Gergely Szasz - $Id: disk.c 3748 2008-08-15 09:04:33Z pak21 $ + $Id: disk.c 3815 2008-11-09 19:19:59Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -35,6 +35,7 @@ #include "bitmap.h" #include "crc.h" #include "disk.h" +#include "utils.h" /* The ordering of these strings must match the order of the * disk_error_t enumeration in disk.h */ @@ -90,6 +91,15 @@ #define GAP_MINIMAL_FM 4 #define GAP_MINIMAL_MFM 5 +#define buffavail(buffer) ( buffer->file.length - buffer->index ) +/* data buffer */ +#define buff ( buffer->file.buffer + buffer->index ) + +typedef struct buffer_t { /* to store buffer data */ + utils_file file; /* buffer, length */ + size_t index; +} buffer_t; + const char * disk_strerror( int error ) { @@ -99,6 +109,27 @@ } static int +buffread( void *data, size_t len, buffer_t *buffer ) +{ + if( len > buffer->file.length - buffer->index ) + return 0; + memcpy( data, buffer->file.buffer + buffer->index, len ); + buffer->index += len; + return 1; +} + +static int +buffseek( buffer_t *buffer, long offset, int whence ) +{ + if( whence == SEEK_CUR ) + offset += buffer->index; + if( offset >= buffer->file.length ) + return -1; + buffer->index = offset; + return 0; +} + +static int id_read( disk_t *d, int *head, int *track, int *sector, int *length ) { int a1mark = 0; @@ -462,9 +493,11 @@ #define NO_DDAM 0 #define DDAM 1 #define NO_AUTOFILL -1 -/* if 'file' == NULL, then copy data bytes from 'data' */ +/* copy data from *buffer and update *buffer->index */ +/* if 'buffer' == NULL, then copy data bytes from 'data' */ static int -data_add( disk_t *d, FILE *file, unsigned char *data, int len, int ddam, int gaptype, int crc_error, int autofill ) +data_add( disk_t *d, buffer_t *buffer, unsigned char *data, int len, int ddam, + int gaptype, int crc_error, int autofill ) { int length; libspectrum_word crc = 0xffff; @@ -484,13 +517,15 @@ if( d->i + len + 2 >= d->bpt ) /* too many data bytes */ return 1; /*------------------------------ data ------------------------------*/ - if( file == NULL ) { + if( buffer == NULL ) { memcpy( d->track + d->i, data, len ); length = len; } else { - length = fread( d->track + d->i, 1, len, file ); + length = buffavail( buffer ); + if( length > len ) length = len; + buffread( d->track + d->i, length, buffer ); } - if( length != len ) { /* autofill with 'autofill' */ + if( length < len ) { /* autofill with 'autofill' */ if( autofill < 0 ) return 1; while( length < len ) { @@ -536,7 +571,7 @@ #define PREINDEX 1 static int -trackgen( disk_t *d, FILE *file, int head, int track, +trackgen( disk_t *d, buffer_t *buffer, int head, int track, int sector_base, int sectors, int sector_length, int preindex, int gap, int interleave, int autofill ) { @@ -544,7 +579,7 @@ int slen = calc_sectorlen( ( d->density != DISK_SD && d->density != DISK_8_SD ), sector_length, gap ); int idx; - + d->i = 0; d->track = d->data + ( ( d->sides * track + head ) * d->tlen ); d->clocks = d->track + d->bpt; @@ -559,7 +594,7 @@ d->i = idx + ( pos + i ) * slen; if( id_add( d, head, track, s, sector_length >> 8, gap, CRC_OK ) ) return 1; - if( data_add( d, file, NULL, sector_length, NO_DDAM, gap, CRC_OK, autofill ) ) + if( data_add( d, buffer, NULL, sector_length, NO_DDAM, gap, CRC_OK, autofill ) ) return 1; pos += interleave; if( pos >= sectors ) { @@ -592,7 +627,7 @@ disk_alloc( disk_t *d ) { size_t dlen; - + if( d->density != DISK_DENS_AUTO ) { d->bpt = disk_bpt[ d->density ]; } else if( d->bpt > 12500 ) { @@ -642,7 +677,7 @@ d->density = density == DISK_DENS_AUTO ? DISK_DD : density; d->sides = sides; d->cylinders = cylinders; - + if( disk_alloc( d ) != DISK_OK ) return d->status; @@ -655,13 +690,12 @@ alloc_uncompress_buffer( unsigned char **buffer, int length ) { unsigned char *b; - + if( *buffer != NULL ) /* return if allocated */ return 0; b = calloc( length, 1 ); if( b == NULL ) return 1; - memset( b, 0, length ); *buffer = b; return 0; } @@ -672,27 +706,27 @@ d->cylinders < 1 || d->cylinders > 85 ) return d->status = DISK_GEOM static int -open_udi( FILE *file, disk_t *d ) +open_udi( buffer_t *buffer, disk_t *d ) { int i, j, bpt; - d->sides = head[10] + 1; - d->cylinders = head[9] + 1; + d->sides = buff[10] + 1; + d->cylinders = buff[9] + 1; GEOM_CHECK; d->density = DISK_DENS_AUTO; - fseek( file, 16, SEEK_SET ); + buffer->index = 16; d->bpt = 0; /* scan file for the longest track */ for( i = 0; i < d->sides * d->cylinders; i++ ) { - if( fread( head, 3, 1, file ) != 1 ) + if( buffavail( buffer ) < 3 ) return d->status = DISK_OPEN; - bpt = head[1] + 256 * head[2]; /* current track len... */ - if( head[0] != 0x00 ) + if( buff[0] != 0x00 ) return d->status = DISK_UNSUP; + bpt = buff[1] + 256 * buff[2]; /* current track len... */ if( bpt > d->bpt ) d->bpt = bpt; - if( fseek( file, bpt + bpt / 8 + ( bpt % 8 ? 1 : 0 ), SEEK_CUR ) == -1 ) + if( buffseek( buffer, 3 + bpt + bpt / 8 + ( bpt % 8 ? 1 : 0 ), SEEK_CUR ) == -1 ) return d->status = DISK_OPEN; } @@ -705,27 +739,21 @@ if( disk_alloc( d ) != DISK_OK ) return d->status; d->bpt = bpt; /* restore the maximal byte per track */ - fseek( file, 16, SEEK_SET ); + buffer->index = 16; d->track = d->data; for( i = 0; i < d->sides * d->cylinders; i++ ) { - if( fread( head, 3, 1, file ) != 1 ) - return d->status = DISK_OPEN; - bpt = head[1] + 256 * head[2]; /* current track len... */ - if( head[0] != 0x00 ) - return d->status = DISK_UNSUP; - /* read track + clocks */ + bpt = buff[1] + 256 * buff[2]; /* current track len... */ + buffer->index += 3; + /* read track + clocks */ if( d->bpt == bpt ) { /* if udi track length equal with the maximal track length */ - if( fread( d->track, bpt + bpt / 8 + ( bpt % 8 ? 1 : 0 ), 1, file ) != 1 ) - return d->status = DISK_OPEN; + buffread( d->track, bpt + bpt / 8 + ( bpt % 8 ? 1 : 0 ), buffer ); } else { - if( fread( d->track, bpt , 1, file ) != 1 ) /* first the data */ - return d->status = DISK_OPEN; + buffread( d->track, bpt, buffer ); /* first the data */ d->track += bpt; for( j = d->bpt - bpt; j > 0; j--, d->track++ ) *d->track = 0x4e; /* fill track data with 0x4e */ - if( fread( d->track, bpt / 8 + ( bpt % 8 ? 1 : 0 ), 1, file ) != 1 ) - return d->status = DISK_OPEN; /* next the clock marks */ + buffread( d->track, bpt / 8 + ( bpt % 8 ? 1 : 0 ), buffer ); d->track += bpt / 8 + ( bpt % 8 ? 1 : 0 ); for( j = ( d->bpt / 8 + ( d->bpt % 8 ? 1 : 0 ) ) - ( bpt / 8 + ( bpt % 8 ? 1 : 0 ) ); j > 0; j--, d->track++ ) @@ -738,21 +766,21 @@ } static int -open_mgt_img( FILE *file, disk_t *d, size_t file_length, disk_type_t type ) +open_mgt_img( buffer_t *buffer, disk_t *d ) { int i, j, sectors, seclen; - fseek( file, 0, SEEK_SET ); + buffer->index = 0; /* guess geometry of disk: * 2*80*10*512, 1*80*10*512 or 1*40*10*512 */ - if( file_length == 2*80*10*512 ) { + if( buffer->file.length == 2*80*10*512 ) { d->sides = 2; d->cylinders = 80; sectors = 10; seclen = 512; - } else if( file_length == 1*80*10*512 ) { + } else if( buffer->file.length == 1*80*10*512 ) { /* we cannot distinguish between a single sided 80 track image * and a double sided 40 track image (2*40*10*512) */ d->sides = 1; d->cylinders = 80; sectors = 10; seclen = 512; - } else if( file_length == 1*40*10*512 ) { + } else if( buffer->file.length == 1*40*10*512 ) { d->sides = 1; d->cylinders = 40; sectors = 10; seclen = 512; } else { return d->status = DISK_GEOM; @@ -763,17 +791,17 @@ if( disk_alloc( d ) != DISK_OK ) return d->status; - if( type == DISK_IMG ) { /* IMG out-out */ + if( d->type == DISK_IMG ) { /* IMG out-out */ for( j = 0; j < d->sides; j++ ) { for( i = 0; i < d->cylinders; i++ ) { - if( trackgen( d, file, j, i, 1, sectors, seclen, + if( trackgen( d, buffer, j, i, 1, sectors, seclen, NO_PREINDEX, GAP_MGT_PLUSD, NO_INTERLEAVE, NO_AUTOFILL ) ) return d->status = DISK_GEOM; } } } else { /* MGT alt */ for( i = 0; i < d->sides * d->cylinders; i++ ) { - if( trackgen( d, file, i % 2, i / 2, 1, sectors, seclen, + if( trackgen( d, buffer, i % 2, i / 2, 1, sectors, seclen, NO_PREINDEX, GAP_MGT_PLUSD, NO_INTERLEAVE, NO_AUTOFILL ) ) return d->status = DISK_GEOM; } @@ -783,16 +811,16 @@ } static int -open_sad( FILE *file, disk_t *d, int preindex ) +open_sad( buffer_t *buffer, disk_t *d, int preindex ) { int i, j, sectors, seclen; - fseek( file, 22, SEEK_SET ); - d->sides = head[18]; - d->cylinders = head[19]; + d->sides = buff[18]; + d->cylinders = buff[19]; GEOM_CHECK; - sectors = head[20]; - seclen = head[21] * 64; + sectors = buff[20]; + seclen = buff[21] * 64; + buffer->index = 22; /* create a DD disk */ d->density = DISK_DD; @@ -801,7 +829,7 @@ for( j = 0; j < d->sides; j++ ) { for( i = 0; i < d->cylinders; i++ ) { - if( trackgen( d, file, j, i, 1, sectors, seclen, preindex, + if( trackgen( d, buffer, j, i, 1, sectors, seclen, preindex, GAP_MGT_PLUSD, NO_INTERLEAVE, NO_AUTOFILL ) ) return d->status = DISK_GEOM; } @@ -811,20 +839,21 @@ } static int -open_trd( FILE *file, disk_t *d ) +open_trd( buffer_t *buffer, disk_t *d ) { int i, j, sectors, seclen; - fseek( file, 8*256, SEEK_SET ); - if( fread( head, 256, 1, file ) != 1 ) + if( buffseek( buffer, 8*256, SEEK_CUR ) == -1 ) + return d->status = DISK_OPEN; + if( buffavail( buffer ) < 256 ) return d->status = DISK_OPEN; - if( head[231] != 0x10 || head[227] < 0x16 || head[227] > 0x19 ) + if( buff[231] != 0x10 || buff[227] < 0x16 || buff[227] > 0x19 ) return d->status = DISK_OPEN; /*?*/ /* guess geometry of disk */ - d->sides = head[227] & 0x08 ? 1 : 2; - d->cylinders = head[227] & 0x01 ? 40 : 80; + d->sides = buff[227] & 0x08 ? 1 : 2; + d->cylinders = buff[227] & 0x01 ? 40 : 80; sectors = 16; seclen = 256; /* create a DD disk */ @@ -832,10 +861,10 @@ if( disk_alloc( d ) != DISK_OK ) return d->status; - fseek( file, 0, SEEK_SET ); + buffer->index = 0; for( i = 0; i < d->cylinders; i++ ) { for( j = 0; j < d->sides; j++ ) { - if( trackgen( d, file, j, i, 1, sectors, seclen, + if( trackgen( d, buffer, j, i, 1, sectors, seclen, NO_PREINDEX, GAP_TRDOS, INTERLEAVE_2, 0x00 ) ) return d->status = DISK_GEOM; } @@ -844,25 +873,25 @@ } static int -open_fdi( FILE *file, disk_t *d, int preindex ) +open_fdi( buffer_t *buffer, disk_t *d, int preindex ) { int i, j, h, gap; int bpt, bpt_fm, max_bpt = 0, max_bpt_fm = 0; int data_offset, track_offset, head_offset, sector_offset; - d->wrprot = head[0x03] == 1 ? 1 : 0; - d->sides = head[0x06] + 256 * head[0x07]; - d->cylinders = head[0x04] + 256 * head[0x05]; + d->wrprot = buff[0x03] == 1 ? 1 : 0; + d->sides = buff[0x06] + 256 * buff[0x07]; + d->cylinders = buff[0x04] + 256 * buff[0x05]; GEOM_CHECK; - data_offset = head[0x0a] + 256 * head[0x0b]; - h = 0x0e + head[0x0c] + 256 * head[0x0d]; /* save head start */ + data_offset = buff[0x0a] + 256 * buff[0x0b]; + h = 0x0e + buff[0x0c] + 256 * buff[0x0d]; /* save head start */ head_offset = h; /* first determine the longest track */ d->bpt = 0; for( i = 0; i < d->cylinders * d->sides; i++ ) { /* ALT */ - fseek( file, head_offset, SEEK_SET ); - if( fread( head, 7, 1, file ) != 1 ) /* 7 := track head */ + buffer->index = head_offset; + if( buffread( head, 7, buffer ) != 1 ) /* 7 := track head */ return d->status = DISK_OPEN; bpt = postindex_len( d, GAP_MINIMAL_MFM ) + ( preindex ? preindex_len( d, GAP_MINIMAL_MFM ) : 0 ) + 6; /* +gap4 */ @@ -870,7 +899,7 @@ ( preindex ? preindex_len( d, GAP_MINIMAL_FM ) : 0 ) + 3; /* +gap4 */ for( j = 0; j < head[0x06]; j++ ) { /* calculate track len */ if( j % 35 == 0 ) { /* 35-sector header */ - if( fread( head + 7, 245, 1, file ) != 1 ) /* 7*35 := max 35 sector head */ + if( buffread( head + 7, 245, buffer ) != 1 ) /* 7*35 := max 35 sector head */ return d->status = DISK_OPEN; } if( ( head[ 0x0b + 7 * ( j % 35 ) ] & 0x3f ) != 0 ) { @@ -885,7 +914,7 @@ head_offset += 7 + 7 * head[ 0x06 ]; } - + if( max_bpt == 0 || max_bpt_fm == 0 ) return d->status = DISK_GEOM; @@ -903,9 +932,8 @@ head_offset = h; /* restore head start */ for( i = 0; i < d->cylinders * d->sides; i++ ) { /* ALT */ - fseek( file, head_offset, SEEK_SET ); - if( fread( head, 7, 1, file ) != 1 ) /* 7 = track head */ - return d->status = DISK_OPEN; + buffer->index = head_offset; + buffread( head, 7, buffer ); /* 7 = track head */ track_offset = head[0x00] + 256 * head[0x01] + 65536 * head[0x02] + 16777216 * head[0x03]; d->track = d->data + i * d->tlen; d->clocks = d->track + d->bpt; @@ -918,17 +946,16 @@ if( j % 35 == 0 ) { /* if we have more than 35 sector in a track, we have to seek back to the next sector headers and read it ( max 35 sector header */ - fseek( file, head_offset + 7 *( j + 1 ), SEEK_SET ); - if( fread( head + 7, 245, 1, file ) != 1 ) /* 7*35 := max 35 sector head */ - return d->status = DISK_OPEN; + buffer->index = head_offset + 7 *( j + 1 ); + buffread( head + 7, 245, buffer ); /* 7*35 := max 35 sector head */ } id_add( d, head[ 0x08 + 7 * ( j % 35 ) ], head[ 0x07 + 7*( j % 35 ) ], head[ 0x09 + 7*( j % 35 ) ], head[ 0x0a + 7*( j % 35 ) ], gap, ( head[ 0x0b + 7*( j % 35 ) ] & 0x3f ) ? CRC_OK : CRC_ERROR ); sector_offset = head[ 0x0c + 7 * ( j % 35 ) ] + 256 * head[ 0x0d + 7 * ( j % 35 ) ]; - fseek( file, data_offset + track_offset + sector_offset, SEEK_SET ); - data_add( d, file, NULL, ( head[ 0x0b + 7 * ( j % 35 ) ] & 0x3f ) == 0 ? + buffer->index = data_offset + track_offset + sector_offset; + data_add( d, buffer, NULL, ( head[ 0x0b + 7 * ( j % 35 ) ] & 0x3f ) == 0 ? -1 : 0x80 << head[ 0x0a + 7 * ( j % 35 ) ], head[ 0x0b + 7 * ( j % 35 ) ] & 0x80 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ); @@ -940,70 +967,79 @@ } static int -open_cpc( FILE *file, disk_t *d, disk_type_t type, int preindex ) +open_cpc( buffer_t *buffer, disk_t *d, int preindex ) { - int i, j, seclen, idlen, gap; + int i, j, seclen, idlen, gap, sector_pad; int bpt, max_bpt = 0, trlen; - int fix[42], plus3_fix; + int fix[84], plus3_fix; + unsigned char *hdrb; - d->sides = head[0x31]; - d->cylinders = head[0x30]; /* maximum number of tracks */ + d->sides = buff[0x31]; + d->cylinders = buff[0x30]; /* maximum number of tracks */ GEOM_CHECK; + buffer->index = 256; +/* first scan for the longest track */ for( i = 0; i < d->sides*d->cylinders; i++ ) { /* sometimes in the header there are more track than in the file */ - if( fread( head, 1, 1, file ) != 1 && feof( file ) ) { + if( buffavail( buffer ) == 0 ) { /* no more data */ d->cylinders = i / d->sides + i % d->sides; /* the real cylinder number */ break; } - if( fread( head + 1, 255, 1, file ) != 1 || - memcmp( head, "Track-Info\r\n", 12 ) ) /* read track header */ + if( buffavail( buffer ) < 256 || + memcmp( buff, "Track-Info\r\n", 12 ) ) /* check track header */ return d->status = DISK_OPEN; - gap = (unsigned char)head[0x16] == 0xff ? GAP_MINIMAL_FM : + gap = (unsigned char)buff[0x16] == 0xff ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM; plus3_fix = trlen = 0; - while( i < head[0x10] * d->sides + head[0x11] ) { - if( i < 42 ) fix[i] = 0; + while( i < buff[0x10] * d->sides + buff[0x11] ) { + if( i < 84 ) fix[i] = 0; i++; } + if( i >= d->sides*d->cylinders || + i != buff[0x10] * d->sides + buff[0x11] ) /* problem with track idx. */ + return d->status = DISK_OPEN; + bpt = postindex_len( d, gap ) + ( preindex ? preindex_len( d, gap ) : 0 ) + ( gap == GAP_MINIMAL_MFM ? 6 : 3 ); /* gap4 */ - for( j = 0; j < head[0x15]; j++ ) { /* each sector */ - seclen = type == DISK_ECPC ? head[ 0x1e + 8 * j ] + - 256 * head[ 0x1f + 8 * j ] - : 0x80 << head[ 0x1b + 8 * j ]; - bpt += calc_sectorlen( gap == GAP_MINIMAL_MFM ? 1 : 0, seclen, gap ); + sector_pad = 0; + for( j = 0; j < buff[0x15]; j++ ) { /* each sector */ + seclen = d->type == DISK_ECPC ? buff[ 0x1e + 8 * j ] + + 256 * buff[ 0x1f + 8 * j ] + : 0x80 << buff[ 0x1b + 8 * j ]; + idlen = 0x80 << buff[ 0x1b + 8 * j ]; /* sector length from ID */ + bpt += calc_sectorlen( gap == GAP_MINIMAL_MFM ? 1 : 0, idlen, gap ); trlen += seclen; - if( i < 42 && d->flag & DISK_FLAG_PLUS3_CPC ) { - if( j == 0 && head[ 0x1b + 8 * j ] == 6 && seclen > 6144 ) + if( i < 84 && d->flag & DISK_FLAG_PLUS3_CPC ) { + if( j == 0 && buff[ 0x1b + 8 * j ] == 6 && seclen > 6144 ) plus3_fix = 4; - else if( j == 0 && head[ 0x1b + 8 * j ] == 6 ) + else if( j == 0 && buff[ 0x1b + 8 * j ] == 6 ) plus3_fix = 1; else if( j == 0 && - head[ 0x18 + 8 * j ] == j && head[ 0x19 + 8 * j ] == j && - head[ 0x1a + 8 * j ] == j && head[ 0x1b + 8 * j ] == j ) + buff[ 0x18 + 8 * j ] == j && buff[ 0x19 + 8 * j ] == j && + buff[ 0x1a + 8 * j ] == j && buff[ 0x1b + 8 * j ] == j ) plus3_fix = 3; - else if( j == 1 && plus3_fix == 1 && head[ 0x1b + 8 * j ] == 2 ) + else if( j == 1 && plus3_fix == 1 && buff[ 0x1b + 8 * j ] == 2 ) plus3_fix = 2; - else if( j > 1 && plus3_fix == 2 && head[ 0x1b + 8 * j ] != 2 ) + else if( j > 1 && plus3_fix == 2 && buff[ 0x1b + 8 * j ] != 2 ) plus3_fix = 0; else if( j > 0 && plus3_fix == 3 && - ( head[ 0x18 + 8 * j ] != j || head[ 0x19 + 8 * j ] != j || - head[ 0x1a + 8 * j ] != j || head[ 0x1b + 8 * j ] != j ) ) + ( buff[ 0x18 + 8 * j ] != j || buff[ 0x19 + 8 * j ] != j || + buff[ 0x1a + 8 * j ] != j || buff[ 0x1b + 8 * j ] != j ) ) plus3_fix = 0; else if( j > 10 && plus3_fix == 2 ) plus3_fix = 0; } if( seclen == 0x80 ) /* every 128byte length sector padded */ - fseek( file, 0x80, SEEK_CUR ); + sector_pad++; } - if( i < 42 ) { + if( i < 84 ) { fix[i] = plus3_fix; if( fix[i] == 4 ) bpt = 6500;/* Type 1 variant DD+ (e.g. Coin Op Hits) */ else if( fix[i] != 0 ) bpt = 6250;/* we assume a standard DD track */ } - fseek( file, trlen, SEEK_CUR ); + buffer->index += trlen + sector_pad * 128 + 256; if( bpt > max_bpt ) max_bpt = bpt; } @@ -1016,28 +1052,25 @@ return d->status; d->track = d->data; d->clocks = d->track + d->bpt; - fseek( file, 256, SEEK_SET ); /* rewind to first track */ + buffer->index = 256; /* rewind to first track */ for( i = 0; i < d->sides*d->cylinders; i++ ) { - if( fread( head, 256, 1, file ) != 1 || - memcmp( head, "Track-Info\r\n", 12 ) ) /* read track header */ - return d->status = DISK_OPEN; + hdrb = buff; + buffer->index += 256; /* skip to data */ + gap = (unsigned char)hdrb[0x16] == 0xff ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM; - gap = (unsigned char)head[0x16] == 0xff ? GAP_MINIMAL_FM : - GAP_MINIMAL_MFM; - - i = head[0x10] * d->sides + head[0x11]; /* adjust track No. */ + i = hdrb[0x10] * d->sides + hdrb[0x11]; /* adjust track No. */ d->track = d->data + i * d->tlen; d->clocks = d->track + d->bpt; d->i = 0; if( preindex) preindex_add( d, gap ); postindex_add( d, gap ); trlen = 0; - for( j = 0; j < head[0x15]; j++ ) { /* each sector */ - seclen = type == DISK_ECPC ? head[ 0x1e + 8 * j ] + /* data length in sector */ - 256 * head[ 0x1f + 8 * j ] - : 0x80 << head[ 0x1b + 8 * j ]; - idlen = 0x80 << head[ 0x1b + 8 * j ]; /* sector length from ID */ - + for( j = 0; j < hdrb[0x15]; j++ ) { /* each sector */ + seclen = d->type == DISK_ECPC ? hdrb[ 0x1e + 8 * j ] + /* data length in sector */ + 256 * hdrb[ 0x1f + 8 * j ] + : 0x80 << hdrb[ 0x1b + 8 * j ]; + idlen = 0x80 << hdrb[ 0x1b + 8 * j ]; /* sector length from ID */ + trlen += seclen; if( idlen == 0 || idlen > ( 0x80 << 0x08 ) ) /* error in sector length code -> ignore */ idlen = seclen; @@ -1045,48 +1078,48 @@ if( seclen > idlen && seclen % idlen ) /* seclen != N * len */ return d->status = DISK_OPEN; - if( fix[i] == 2 && j == 0 ) { /* repositionate the dummy track */ + if( i < 84 && fix[i] == 2 && j == 0 ) { /* repositionate the dummy track */ d->i = 8; } - id_add( d, head[ 0x19 + 8 * j ], head[ 0x18 + 8 * j ], - head[ 0x1a + 8 * j ], head[ 0x1b + 8 * j ], gap, - head[ 0x1c + 8 * j ] & 0x20 && !( head[ 0x1d + 8 * j ] & 0x20 ) ? - CRC_ERROR : CRC_OK ); + id_add( d, hdrb[ 0x19 + 8 * j ], hdrb[ 0x18 + 8 * j ], + hdrb[ 0x1a + 8 * j ], hdrb[ 0x1b + 8 * j ], gap, + hdrb[ 0x1c + 8 * j ] & 0x20 && !( hdrb[ 0x1d + 8 * j ] & 0x20 ) ? + CRC_ERROR : CRC_OK ); - if( fix[i] == 1 && j == 0 ) { /* 6144 */ - data_add( d, file, NULL, seclen, - head[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, - head[ 0x1c + 8 * j ] & 0x20 && head[ 0x1d + 8 * j ] & 0x20 ? + if( i < 84 && fix[i] == 1 && j == 0 ) { /* 6144 */ + data_add( d, buffer, NULL, seclen, + hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, + hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); - } else if( fix[i] == 2 && j == 0 ) { /* 6144, 10x512 */ - datamark_add( d, head[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap ); + } else if( i < 84 && fix[i] == 2 && j == 0 ) { /* 6144, 10x512 */ + datamark_add( d, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap ); gap_add( d, 2, gap ); - fseek( file, seclen, SEEK_CUR ); - } else if( fix[i] == 3 ) { /* 128, 256, 512, ... 4096k */ - data_add( d, file, NULL, 128, - head[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, - head[ 0x1c + 8 * j ] & 0x20 && head[ 0x1d + 8 * j ] & 0x20 ? + buffer->index += seclen; + } else if( i < 84 && fix[i] == 3 ) { /* 128, 256, 512, ... 4096k */ + data_add( d, buffer, NULL, 128, + hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, + hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); - fseek( file, seclen - 128, SEEK_CUR ); - } else if( fix[i] == 4 ) { /* Nx8192 (max 6384 byte ) */ - data_add( d, file, NULL, 6384, - head[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, - head[ 0x1c + 8 * j ] & 0x20 && head[ 0x1d + 8 * j ] & 0x20 ? + buffer->index += seclen - 128; + } else if( i < 84 && fix[i] == 4 ) { /* Nx8192 (max 6384 byte ) */ + data_add( d, buffer, NULL, 6384, + hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, + hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); - fseek( file, seclen - 6384, SEEK_CUR ); + buffer->index += seclen - 6384; } else { - data_add( d, file, NULL, seclen > idlen ? idlen : seclen, - head[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, - head[ 0x1c + 8 * j ] & 0x20 && head[ 0x1d + 8 * j ] & 0x20 ? + data_add( d, buffer, NULL, seclen > idlen ? idlen : seclen, + hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, + hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); if( seclen > idlen ) { /* weak sector with multiple copy */ - fseek( file, ( seclen / ( 0x80 << head[ 0x1b + 8 * j ] ) - 1 ) * - ( 0x80 << head[ 0x1b + 8 * j ] ), SEEK_CUR ); + buffer->index +=( seclen / ( 0x80 << hdrb[ 0x1b + 8 * j ] ) - 1 ) * + ( 0x80 << hdrb[ 0x1b + 8 * j ] ); /* ( ( N * len ) / len - 1 ) * len */ } } if( seclen == 0x80 ) /* every 128byte length sector padded */ - fseek( file, 0x80, SEEK_CUR ); + buffer->index += 0x80; } gap4_add( d, gap ); } @@ -1094,7 +1127,7 @@ } static int -open_scl( FILE *file, disk_t *d ) +open_scl( buffer_t *buffer, disk_t *d ) { int i, j, s, sectors, seclen; int scl_deleted, scl_files, scl_i; @@ -1116,25 +1149,25 @@ */ - if( ( scl_files = head[8] ) > 128 || scl_files < 1 ) /* number of files */ + if( ( scl_files = buff[8] ) > 128 || scl_files < 1 ) /* number of files */ return d->status = DISK_GEOM; /* too many file */ - fseek( file, 9, SEEK_SET ); /* read SCL entries */ + buffer->index = 9; /* read SCL entries */ d->track = d->data; /* track 0 */ d->clocks = d->track + d->bpt; d->i = 0; postindex_add( d, GAP_TRDOS ); scl_i = d->i; /* the position of first sector */ - s = 1; /* start sector number */ - scl_deleted = 0; /* deleted files */ + s = 1; /* start sector number */ + scl_deleted = 0; /* deleted files */ sectors = 0; /* allocated sectors */ - /* we use 'head[]' to build - TR-DOS directory */ - j = 0; /* index for head[] */ + /* we use 'head[]' to build + TR-DOS directory */ + j = 0; /* index for head[] */ memset( head, 0, 256 ); seclen = calc_sectorlen( 1, 256, GAP_TRDOS ); /* one sector raw length */ for( i = 0; i < scl_files; i++ ) { /* read all entry and build TR-DOS dir */ - if( fread( head + j, 14, 1, file ) != 1 ) + if( buffread( head + j, 14, buffer ) != 1 ) return d->status = DISK_OPEN; head[ j + 14 ] = sectors % 16; /* ( sectors + 16 ) % 16 := sectors % 16 starting sector */ @@ -1185,10 +1218,10 @@ memset( head, 0, 256 ); /* clear sector data... */ } gap4_add( d, GAP_TRDOS ); - + /* now we continue with the data */ for( i = 1; i < d->sides * d->cylinders; i++ ) { - if( trackgen( d, file, i % 2, i / 2, 1, 16, 256, + if( trackgen( d, buffer, i % 2, i / 2, 1, 16, 256, NO_PREINDEX, GAP_TRDOS, INTERLEAVE_2, 0x00 ) ) return d->status = DISK_OPEN; } @@ -1196,61 +1229,61 @@ } static int -open_td0( FILE *file, disk_t *d, int preindex ) +open_td0( buffer_t *buffer, disk_t *d, int preindex ) { int i, j, s, sectors, seclen, bpt, gap, mfm, mfm_old; int data_offset, track_offset, sector_offset; - unsigned char *buff; + unsigned char *uncomp_buff, *hdrb; - if( head[0] == 't' ) /* signature "td" -> advanced compression */ + if( buff[0] == 't' ) /* signature "td" -> advanced compression */ return d->status = DISK_IMPL; /* not implemented */ - buff = NULL; /* we may use this buffer */ - mfm_old = head[5] & 0x80 ? 0 : 1; /* td0notes say: may older teledisk + uncomp_buff = NULL; /* we may use this buffer */ + mfm_old = buff[5] & 0x80 ? 0 : 1; /* td0notes say: may older teledisk indicate the SD on high bit of data rate */ - d->sides = head[9]; /* 1 or 2 */ + d->sides = buff[9]; /* 1 or 2 */ if( d->sides < 1 || d->sides > 2 ) return d->status = DISK_GEOM; /* skip comment block if any */ - data_offset = track_offset = 12 + ( head[7] & 0x80 ? - 10 + head[14] + 256 * head[15] : 0 ); + data_offset = track_offset = 12 + ( buff[7] & 0x80 ? + 10 + buff[14] + 256 * buff[15] : 0 ); /* determine the greatest track length */ d->bpt = 0; d->cylinders = 0; seclen = 0; while( 1 ) { - fseek( file, track_offset, SEEK_SET ); - if( fread( head, 1, 1, file ) != 1 ) + buffer->index = track_offset; + if( buffavail( buffer ) < 1 ) return d->status = DISK_OPEN; - if( ( sectors = head[0] ) == 255 ) /* sector number 255 => end of tracks */ + if( ( sectors = buff[0] ) == 255 ) /* sector number 255 => end of tracks */ break; - if( fread( head + 1, 3, 1, file ) != 1 ) /* finish to read track header */ + if( buffavail( buffer ) < 4 ) /* check track header is avail. */ return d->status = DISK_OPEN; - if( head[1] + 1 > d->cylinders ) /* find the biggest cylinder number */ - d->cylinders = head[1] + 1; + if( buff[1] + 1 > d->cylinders ) /* find the biggest cylinder number */ + d->cylinders = buff[1] + 1; bpt = 0; sector_offset = track_offset + 4; - mfm = head[2] & 0x80 ? 0 : 1; /* 0x80 == 1 => SD track */ + mfm = buff[2] & 0x80 ? 0 : 1; /* 0x80 == 1 => SD track */ bpt = postindex_len( d, mfm_old || mfm ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM ) + ( preindex ? preindex_len( d, mfm_old || mfm ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM ) : 0 ) + mfm_old || mfm ? 6 : 3; for( s = 0; s < sectors; s++ ) { - fseek( file, sector_offset, SEEK_SET ); - if( fread( head, 6, 1, file ) != 1 ) + buffer->index = sector_offset; + if( buffavail( buffer ) < 6 ) /* check sector header is avail. */ return d->status = DISK_OPEN; - if( !( head[4] & 0x30 ) ) { /* only if we have data */ - if( fread( head + 6, 3, 1, file ) != 1 ) /* read data header */ + if( !( buff[4] & 0x30 ) ) { /* only if we have data */ + if( buffavail( buffer ) < 9 ) /* check data header is avail. */ return d->status = DISK_OPEN; - bpt += calc_sectorlen( mfm_old || mfm, 0x80 << head[3], + bpt += calc_sectorlen( mfm_old || mfm, 0x80 << buff[3], mfm_old || mfm ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM ); - if( head[3] > seclen ) - seclen = head[3]; /* biggest sector */ - sector_offset += head[6] + 256 * head[7] - 1; + if( buff[3] > seclen ) + seclen = buff[3]; /* biggest sector */ + sector_offset += buff[6] + 256 * buff[7] - 1; } sector_offset += 9; } @@ -1268,138 +1301,122 @@ d->track = d->data; d->clocks = d->track + d->bpt; - fseek( file, data_offset, SEEK_SET ); /* first track header */ + buffer->index = data_offset; /* first track header */ while( 1 ) { - if( fread( head, 1, 1, file ) != 1 ) - return d->status = DISK_OPEN; - if( ( sectors = head[0] ) == 255 ) /* sector number 255 => end of tracks */ + if( ( sectors = buff[0] ) == 255 ) /* sector number 255 => end of tracks */ break; - if( fread( head + 1, 3, 1, file ) != 1 ) { /* finish to read track header */ - if( buff ) - free( buff ); - fclose( file ); - return d->status = DISK_OPEN; - } - d->track = d->data + ( d->sides * head[1] + ( head[2] & 0x01 ) ) * d->tlen; + d->track = d->data + ( d->sides * buff[1] + ( buff[2] & 0x01 ) ) * d->tlen; d->clocks = d->track + d->bpt; d->i = 0; - /* later teledisk -> if head[2] & 0x80 -> FM track */ - gap = mfm_old || head[2] & 0x80 ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM; + /* later teledisk -> if buff[2] & 0x80 -> FM track */ + gap = mfm_old || buff[2] & 0x80 ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM; postindex_add( d, gap ); + buffer->index += 4; /* sector header*/ for( s = 0; s < sectors; s++ ) { - if( fread( head, 6, 1, file ) != 1 ) { /* sector head */ - if( buff ) - free( buff ); - fclose( file ); - return d->status = DISK_OPEN; - } - if( !( head[4] & 0x40 ) ) /* if we have id we add */ - id_add( d, head[1], head[0], head[2], head[3], gap, - head[4] & 0x02 ? CRC_ERROR : CRC_OK ); - if( !( head[4] & 0x30 ) ) { /* only if we have data */ - if( fread( head + 6, 3, 1, file ) != 1 ) { /* read data header */ - if( buff ) - free( buff ); - return d->status = DISK_OPEN; - } - } - if( head[4] & 0x40 ) { /* if we have _no_ id we drop data... */ - fseek( file, head[6] + 256 * head[7] - 1, SEEK_CUR ); + hdrb = buff; + buffer->index += 9; /* skip to data */ + if( !( hdrb[4] & 0x40 ) ) /* if we have id we add */ + id_add( d, hdrb[1], hdrb[0], hdrb[2], hdrb[3], gap, + hdrb[4] & 0x02 ? CRC_ERROR : CRC_OK ); + if( hdrb[4] & 0x40 ) { /* if we have _no_ id we drop data... */ + buffer->index += hdrb[6] + 256 * hdrb[7] - 1; continue; /* next sector */ } - seclen = 0x80 << head[3]; + if( !( hdrb[4] & 0x30 ) ) { /* only if we have data */ + seclen = 0x80 << hdrb[3]; - switch( head[8] ) { - case 0: /* raw sector data */ - if( head[6] + 256 * head[7] - 1 != seclen ) { - if( buff ) - free( buff ); - return d->status = DISK_OPEN; - } - if( data_add( d, file, NULL, head[6] + 256 * head[7] - 1, - head[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { - if( buff ) - free( buff ); - return d->status = DISK_OPEN; - } - break; - case 1: /* Repeated 2-byte pattern */ - if( buff == NULL && alloc_uncompress_buffer( &buff, 8192 ) ) - return d->status = DISK_MEM; - for( i = 0; i < seclen; ) { /* fill buffer */ - if( fread( head + 9, 4, 1, file ) != 1 ) { /* read block header */ - free( buff ); + switch( hdrb[8] ) { + case 0: /* raw sector data */ + if( hdrb[6] + 256 * hdrb[7] - 1 != seclen ) { + if( uncomp_buff ) + free( uncomp_buff ); return d->status = DISK_OPEN; } - if( i + 2 * ( head[9] + 256*head[10] ) > seclen ) { - /* too many data bytes */ - free( buff ); + if( data_add( d, buffer, NULL, hdrb[6] + 256 * hdrb[7] - 1, + hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { + if( uncomp_buff ) + free( uncomp_buff ); return d->status = DISK_OPEN; } - /* ab ab ab ab ab ab ab ab ab ab ab ... */ - for( j = 1; j < head[9] + 256 * head[10]; j++ ) - memcpy( buff + i + j * 2, &head[11], 2 ); - i += 2 * ( head[9] + 256 * head[10] ); - } - if( data_add( d, NULL, buff, head[6] + 256 * head[7] - 1, - head[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { - free( buff ); - return d->status = DISK_OPEN; - } - break; - case 2: /* Run Length Encoded data */ - if( buff == NULL && alloc_uncompress_buffer( &buff, 8192 ) ) - return d->status = DISK_MEM; - for( i = 0; i < seclen; ) { /* fill buffer */ - if( fread( head + 9, 2, 1, file ) != 1 ) {/* read block header */ - free( buff ); - return d->status = DISK_OPEN; - } - if( head[9] == 0 ) { /* raw bytes */ - if( i + head[10] > seclen || /* too many data bytes */ - fread( buff + i, head[10], 1, file ) != 1 ) { - free( buff ); + break; + case 1: /* Repeated 2-byte pattern */ + if( uncomp_buff == NULL && alloc_uncompress_buffer( &uncomp_buff, 8192 ) ) + return d->status = DISK_MEM; + for( i = 0; i < seclen; ) { /* fill buffer */ + if( buffavail( buffer ) < 13 ) { /* check block header is avail. */ + free( uncomp_buff ); return d->status = DISK_OPEN; } - i += head[10]; - } else { /* repeated samples */ - if( i + 2 * head[9] * head[10] > seclen || /* too many data bytes */ - fread( buff + i, 2 * head[9], 1, file ) != 1 ) { - free( buff ); + if( i + 2 * ( hdrb[9] + 256*hdrb[10] ) > seclen ) { + /* too many data bytes */ + free( uncomp_buff ); return d->status = DISK_OPEN; } + /* ab ab ab ab ab ab ab ab ab ab ab ... */ + for( j = 1; j < hdrb[9] + 256 * hdrb[10]; j++ ) + memcpy( uncomp_buff + i + j * 2, &hdrb[11], 2 ); + i += 2 * ( hdrb[9] + 256 * hdrb[10] ); + } + if( data_add( d, NULL, uncomp_buff, hdrb[6] + 256 * hdrb[7] - 1, + hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { + free( uncomp_buff ); + return d->status = DISK_OPEN; + } + break; + case 2: /* Run Length Encoded data */ + if( uncomp_buff == NULL && alloc_uncompress_buffer( &uncomp_buff, 8192 ) ) + return d->status = DISK_MEM; + for( i = 0; i < seclen; ) { /* fill buffer */ + if( buffavail( buffer ) < 11 ) { /* check block header is avail */ + free( uncomp_buff ); + return d->status = DISK_OPEN; + } + if( hdrb[9] == 0 ) { /* raw bytes */ + if( i + hdrb[10] > seclen || /* too many data bytes */ + buffread( uncomp_buff + i, hdrb[10], buffer ) != 1 ) { + free( uncomp_buff ); + return d->status = DISK_OPEN; + } + i += hdrb[10]; + } else { /* repeated samples */ + if( i + 2 * hdrb[9] * hdrb[10] > seclen || /* too many data bytes */ + buffread( uncomp_buff + i, 2 * hdrb[9], buffer ) != 1 ) { + free( uncomp_buff ); + return d->status = DISK_OPEN; + } /* abcdefgh abcdefg abcdefg abcdefg ... \--v---/ - 2*head[9] + 2*hdrb[9] | | | | | - +- 0 +- 1 +- 2 +- 3 ... +- head[10]-1 + +- 0 +- 1 +- 2 +- 3 ... +- hdrb[10]-1 */ - for( j = 1; j < head[10]; j++ ) /* repeat 'n' times */ - memcpy( buff + i + j * 2 * head[9], buff + i, 2 * head[9] ); - i += 2 * head[9] * head[10]; + for( j = 1; j < hdrb[10]; j++ ) /* repeat 'n' times */ + memcpy( uncomp_buff + i + j * 2 * hdrb[9], uncomp_buff + i, 2 * hdrb[9] ); + i += 2 * hdrb[9] * hdrb[10]; + } } - } - if( data_add( d, NULL, buff, head[6] + 256 * head[7] - 1, - head[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { - free( buff ); + if( data_add( d, NULL, uncomp_buff, hdrb[6] + 256 * hdrb[7] - 1, + hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { + free( uncomp_buff ); + return d->status = DISK_OPEN; + } + break; + default: + if( uncomp_buff ) + free( uncomp_buff ); return d->status = DISK_OPEN; + break; } - break; - default: - if( buff ) - free( buff ); - return d->status = DISK_OPEN; - break; } } gap4_add( d, gap ); } - if( buff ) - free( buff ); + if( uncomp_buff ) + free( uncomp_buff ); return d->status = DISK_OK; } @@ -1409,107 +1426,72 @@ int disk_open( disk_t *d, const char *filename, int preindex ) { - FILE *file; - disk_type_t type; - struct stat file_info; - const char *ext; - size_t namelen; + buffer_t buffer; + libspectrum_id_t type; + int error; - if( filename == NULL || *filename == '\0' ) - return d->status = DISK_OPEN; - - if( ( file = fopen( filename, "rb" ) ) == NULL ) - return d->status = DISK_OPEN; - - if( stat( filename, &file_info) ) { - fclose( file ); - return d->status = DISK_OPEN; - } - - if( fread( head, 256, 1, file ) != 1 ) { - fclose( file ); - return d->status = DISK_OPEN; - } - - namelen = strlen( filename ); - if( namelen < 4 ) - ext = NULL; - else - ext = filename + namelen - 4; - - type = DISK_TYPE_NONE; - - if( memcmp( head, "UDI!", 4 ) == 0 ) - type = DISK_UDI; - else if( memcmp( head, "EXTENDED", 8 ) == 0 ) - type = DISK_ECPC; - else if( memcmp( head, "MV - CPC", 8 ) == 0 ) - type = DISK_CPC; - else if( memcmp( head, "FDI", 3 ) == 0 ) - type = DISK_FDI; - else if( memcmp( head, "Aley's disk backup", 18 ) == 0 ) - type = DISK_SAD; - else if( memcmp( head, "SINCLAIR", 8 ) == 0 ) - type = DISK_SCL; - else if( memcmp( head, "TD", 2 ) == 0 || memcmp( head, "td", 2 ) == 0 ) - type = DISK_TD0; - else { - if( ext == NULL ) { - fclose( file ); - return d->status = DISK_OPEN; - } - if( !strcasecmp( ext, ".mgt" ) || !strcasecmp( ext, ".dsk" ) ) - type = DISK_MGT; /* ALT side */ - else if( !strcasecmp( ext, ".img" ) ) /* out-out */ - type = DISK_IMG; - else if( !strcasecmp( ext, ".trd" ) ) /* out-out */ - type = DISK_TRD; - } - if( access( filename, W_OK ) == -1 ) /* file read only */ d->wrprot = 1; else d->wrprot = 0; - + + if( utils_read_file( filename, &buffer.file ) ) + return d->status = DISK_OPEN; + + buffer.index = 0; + + error = libspectrum_identify_file_raw( &type, filename, + buffer.file.buffer, buffer.file.length ); + if( error ) return d->status = DISK_OPEN; + d->type = DISK_TYPE_NONE; switch ( type ) { - case DISK_UDI: - open_udi( file, d ); + case LIBSPECTRUM_ID_DISK_UDI: + d->type = DISK_UDI; + open_udi( &buffer, d ); break; - case DISK_MGT: - case DISK_IMG: - open_mgt_img( file, d, file_info.st_size, type ); + case LIBSPECTRUM_ID_DISK_MGT: + d->type = DISK_MGT; + case LIBSPECTRUM_ID_DISK_IMG: + if( d->type == DISK_TYPE_NONE) d->type = DISK_IMG; + open_mgt_img( &buffer, d ); break; - case DISK_SAD: - open_sad( file, d, preindex ); + case LIBSPECTRUM_ID_DISK_SAD: + d->type = DISK_SAD; + open_sad( &buffer, d, preindex ); break; - case DISK_TRD: - open_trd( file, d ); + case LIBSPECTRUM_ID_DISK_TRD: + d->type = DISK_TRD; + open_trd( &buffer, d ); break; - case DISK_FDI: - open_fdi( file, d, preindex ); + case LIBSPECTRUM_ID_DISK_FDI: + d->type = DISK_FDI; + open_fdi( &buffer, d, preindex ); break; - case DISK_CPC: - case DISK_ECPC: - open_cpc( file, d, type, preindex ); + case LIBSPECTRUM_ID_DISK_CPC: + d->type = DISK_CPC; + case LIBSPECTRUM_ID_DISK_ECPC: + if( d->type == DISK_TYPE_NONE) d->type = DISK_ECPC; + open_cpc( &buffer, d, preindex ); break; - case DISK_SCL: - open_scl( file, d ); + case LIBSPECTRUM_ID_DISK_SCL: + d->type = DISK_SCL; + open_scl( &buffer, d ); break; - case DISK_TD0: - open_td0( file, d, preindex ); + case LIBSPECTRUM_ID_DISK_TD0: + d->type = DISK_TD0; + open_td0( &buffer, d, preindex ); break; default: - fclose( file ); + utils_close_file( &buffer.file ); return d->status = DISK_OPEN; } if( d->status != DISK_OK ) { if( d->data != NULL ) free( d->data ); - fclose( file ); + utils_close_file( &buffer.file ); return d->status; } - fclose( file ); - d->type = type; + utils_close_file( &buffer.file ); d->dirty = 0; return d->status = DISK_OK; } @@ -1517,7 +1499,7 @@ /*--------------------- start of write section ----------------*/ static int -write_udi( FILE * file, disk_t * d ) +write_udi( FILE *file, disk_t *d ) { int i, j; size_t len; @@ -1568,7 +1550,7 @@ } static int -write_img_mgt( FILE * file, disk_t * d, disk_type_t type ) +write_img_mgt( FILE *file, disk_t *d ) { int i, j, sbase, sectors, seclen, mfm; @@ -1576,7 +1558,7 @@ sbase != 1 || seclen != 2 || sectors != 10 ) return d->status = DISK_GEOM; - if( type == DISK_IMG ) { /* out-out */ + if( d->type == DISK_IMG ) { /* out-out */ for( j = 0; j < d->sides; j++ ) { for( i = 0; i < d->cylinders; i++ ) { if( savetrack( d, file, j, i, 1, sectors, seclen ) ) @@ -1595,7 +1577,7 @@ } static int -write_trd( FILE * file, disk_t * d ) +write_trd( FILE *file, disk_t *d ) { int i, j, sbase, sectors, seclen, mfm; @@ -1612,7 +1594,7 @@ } static int -write_sad( FILE * file, disk_t * d ) +write_sad( FILE *file, disk_t *d ) { int i, j, sbase, sectors, seclen, mfm; @@ -1637,7 +1619,7 @@ } static int -write_fdi( FILE * file, disk_t * d ) +write_fdi( FILE *file, disk_t *d ) { int i, j, k, sbase, sectors, seclen, mfm, del; int h, t, s, b; @@ -1680,7 +1662,7 @@ head[0x05] = 0; guess_track_geom( d, j, i, &sbase, §ors, &seclen, &mfm ); head[0x06] = sectors; - if( fwrite( head, 7, 1, file ) != 1 ) + if( fwrite( head, 7, 1, file ) != 1 ) /* track header */ return d->status = DISK_WRPART; d->track = d->data + ( ( d->sides * i + j ) * d->tlen ); @@ -1703,7 +1685,7 @@ soff += 0x80 << b; } k++; - } /* Track header */ + } /* Sector header */ if( fwrite( head, 7 * k, 1, file ) != 1 ) return d->status = DISK_WRPART; @@ -1727,7 +1709,7 @@ } static int -write_cpc( FILE * file, disk_t * d ) +write_cpc( FILE *file, disk_t *d ) { int i, j, k, sbase, sectors, seclen, mfm; int h, t, s, b; @@ -1785,7 +1767,7 @@ } static int -write_scl( FILE * file, disk_t * d ) +write_scl( FILE *file, disk_t *d ) { int i, j, k, l, t, s, sbase, sectors, seclen, mfm, del; int entries; @@ -1902,7 +1884,7 @@ } static int -write_log( FILE * file, disk_t * d ) +write_log( FILE *file, disk_t *d ) { int i, j, k, del, rev; int h, t, s, b; @@ -1943,7 +1925,7 @@ k = 0; while( k < b ) { if( !( k % 16 ) ) - fprintf( file, "0x%08x:", d->i ); + fprintf( file, "0x%08x:", k ); fprintf( file, " 0x%02x", d->track[ d->i ] ); k++; if( !( k % 16 ) ) @@ -2027,25 +2009,25 @@ break; case DISK_IMG: case DISK_MGT: - write_img_mgt( file, d, d->type ); + write_img_mgt( file, d ); break; case DISK_TRD: - write_trd( file, d ); + write_trd( file, d ); break; case DISK_SAD: - write_sad( file, d ); + write_sad( file, d ); break; case DISK_FDI: - write_fdi( file, d ); + write_fdi( file, d ); break; case DISK_SCL: - write_scl( file, d ); + write_scl( file, d ); break; case DISK_CPC: - write_cpc( file, d ); + write_cpc( file, d ); break; case DISK_LOG: - write_log( file, d ); + write_log( file, d ); break; default: return d->status = DISK_WRFILE; Modified: trunk/fuse/fuse.c =================================================================== --- trunk/fuse/fuse.c 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/fuse.c 2008-11-18 12:05:21 UTC (rev 547) @@ -1,7 +1,7 @@ /* fuse.c: The Free Unix Spectrum Emulator Copyright (c) 1999-2008 Philip Kendall - $Id: fuse.c 3797 2008-10-29 12:04:34Z fredm $ + $Id: fuse.c 3807 2008-11-08 15:17:00Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -544,6 +544,23 @@ case LIBSPECTRUM_CLASS_DISK_TRDOS: start_files->disk_beta = filename; break; + case LIBSPECTRUM_CLASS_DISK_GENERIC: + if( machine_current->machine == LIBSPECTRUM_MACHINE_PLUS3 || + machine_current->machine == LIBSPECTRUM_MACHINE_PLUS2A ) + start_files->disk_plus3 = filename; + else if( machine_current->machine == LIBSPECTRUM_MACHINE_PENT || + machine_current->machine == LIBSPECTRUM_MACHINE_PENT512 || + machine_current->machine == LIBSPECTRUM_MACHINE_PENT1024 || + machine_current->machine == LIBSPECTRUM_MACHINE_SCORP ) + start_files->disk_beta = filename; + else { + if( periph_beta128_active ) + start_files->disk_beta = filename; + else if( periph_plusd_active ) + start_files->disk_plusd = filename; + } + break; + case LIBSPECTRUM_CLASS_RECORDING: start_files->playback = filename; break; Modified: trunk/fuse/fusepb/English.lproj/InfoPlist.strings =================================================================== (Binary files differ) Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/fusepb/Info-Fuse.plist 2008-11-18 12:05:21 UTC (rev 547) @@ -480,7 +480,7 @@ <key>CFBundleSignature</key> <string>FUSE</string> <key>CFBundleVersion</key> - <string>3804</string> + <string>0.10.0-pre1</string> <key>NSMainNibFile</key> <string>MainMenu</string> <key>NSPrincipalClass</key> Modified: trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2008-11-18 12:05:21 UTC (rev 547) @@ -40,8 +40,10 @@ option to emulate machines with 1 tstate later timings (Philip Kendall).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Reading from the 128K's memory control port causes that byte to be written back to the -port (Philip Kendall; thanks, Marat Fayzullin).<br> - </font></li> +port (Philip Kendall; thanks, Marat Fayzullin).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Reading the AY +data port on the +2A/+3 is the same as reading the register port +(Philip Kendall; thanks, Mark Woodmass).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">NMI causes Z80 to unHALT (Philip Kendall; thanks, Simon Owen).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Emulate C, H and Modified: trunk/fuse/fusepb/resources/Fuse Help/html/monitor.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/monitor.html 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/fusepb/resources/Fuse Help/html/monitor.html 2008-11-18 12:05:21 UTC (rev 547) @@ -240,8 +240,12 @@ value of the Z80 register <span class="emphasis"><em>register</em></span> to <span class="emphasis"><em>value</em></span>.</font></p> -<p> -<font face="Lucida Grande,Helvetica,Arial">s{tep} Equivalent to the <span +<p><font face="Lucida Grande,Helvetica,Arial">se{t} <span + class="emphasis"><em>$variable +value</em></span> Set the value of the debugger variable +<span class="emphasis"><em>variable</em></span> to <span + class="emphasis"><em>value</em></span>.</font></p> +<p><font face="Lucida Grande,Helvetica,Arial">s{tep} Equivalent to the <span class="emphasis"><em>Single Step</em></span> button.</font></p> @@ -279,9 +283,10 @@ which uses a restricted version of C's syntax; exactly the same syntax is used for conditional breakpoints, with `0' being false and any other value being true. In numeric expressions, you can use -integer constants (all calculations is done in integers), register +integer constants (all calculations are done in integers), register names (which simply evaluate to the value of the register), -parentheses, the standard four numeric operations (`+', `-', `*' +debugger variables, parentheses, the standard four numeric operations +(`+', `-', `*' and `/'), the (non-)equality operators `==' and `!=', the comparision operators `>', `<', `>=' and `<=', bitwise and (`&'), or (`|') and exclusive or (`^') and logical and Modified: trunk/fuse/hacking/ChangeLog =================================================================== --- trunk/fuse/hacking/ChangeLog 2008-11-18 11:02:52 UTC (rev 546) +++ trunk/fuse/hacking/ChangeLog 2008-11-18 12:05:21 UTC (rev 547) @@ -2921,3 +2921,18 @@ 20081102 ui/win32/{win32ui.c,win32internals.h,win32joystick.[ch}: Win32: Implemented joystick handling using mmsystem API (and tested using PPJoy joystick emulator, hope it works with real hardware) (Marek). +20081108 disk/disk.c: prevent array overrun (bug #2240211) (Gergely Szasz). +20081108 disk/disk.c,fuse.c,utils.c: use libspectrum's ability to + identify more disk image formats (patch #2233744) (Gergely Szasz). +20081109 hacking/cvs-tags: document 0.10.0 branch. +20081109 disk/disk.c: stop buffer overrun from malformed .dsk (fixes bug + #2248067) (Gergely Szasz). +20081115 man/fuse.1: add debugger variables and print command + (Release-0_10_0-branch). +20081115 Makefile.am,hacking/Makefile.am,ui/win32/Makefile.am: make sure + all files are distributed (Release-0_10_0-bran... [truncated message content] |
From: <fr...@us...> - 2008-12-04 11:42:06
|
Revision: 558 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=558&view=rev Author: fredm Date: 2008-12-04 11:37:00 +0000 (Thu, 04 Dec 2008) Log Message: ----------- Merge in changes from vendor 0.10.0 release. Modified Paths: -------------- trunk/FuseGenerator/config.h trunk/FuseImporter/config.h trunk/fuse/README trunk/fuse/compat/amiga/paths.c trunk/fuse/configure.in trunk/fuse/disk/disk.c trunk/fuse/disk/upd_fdc.c trunk/fuse/fuse.c trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/config.h trunk/fuse/hacking/ChangeLog trunk/fuse/man/fuse.1 trunk/fuse/rzx.c trunk/fuse/scld.c trunk/fuse/utils.c trunk/libspectrum/Info.plist trunk/libspectrum/config.h trunk/libspectrum/libspectrum/ChangeLog trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/README trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/doc/libspectrum.3 trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/test/Makefile.am trunk/libspectrum/libspectrum/timings.c trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj Property Changed: ---------------- trunk/fuse/ trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/config.h =================================================================== --- trunk/FuseGenerator/config.h 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/FuseGenerator/config.h 2008-12-04 11:37:00 UTC (rev 558) @@ -83,7 +83,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.2.2" +#define VERSION "0.5.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Modified: trunk/FuseImporter/config.h =================================================================== --- trunk/FuseImporter/config.h 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/FuseImporter/config.h 2008-12-04 11:37:00 UTC (rev 558) @@ -83,7 +83,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.2.2" +#define VERSION "0.5.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-538 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-538 Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/README 2008-12-04 11:37:00 UTC (rev 558) @@ -1,5 +1,5 @@ -The Free Unix Spectrum Emulator (Fuse) 0.9.0 -============================================ +The Free Unix Spectrum Emulator (Fuse) 0.10.0 +============================================= Fuse (the Free Unix Spectrum Emulator) was originally, and somewhat unsurprisingly, an emulator of the ZX Spectrum (a popular 1980s home @@ -150,6 +150,6 @@ ( http://www.worldofspectrum.org/faq/index.html ) first! Philip Kendall <phi...@sh...> -5 January 2008 +3 December 2008 -$Id: README 3801 2008-10-31 16:22:13Z pak21 $ +$Id: README 3866 2008-11-29 17:05:40Z pak21 $ Modified: trunk/fuse/compat/amiga/paths.c =================================================================== --- trunk/fuse/compat/amiga/paths.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/compat/amiga/paths.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* paths.c: Path-related compatibility routines Copyright (c) 1999-2007 Philip Kendall - $Id: paths.c 3578 2008-03-22 20:51:36Z zubzero $ + $Id: paths.c 3844 2008-11-19 21:31:07Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -42,6 +42,5 @@ int compat_is_absolute_path( const char *path ) { - /* Is this correct? */ - return path[0] == '/'; + return strchr(path,':'); } Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/configure.in 2008-12-04 11:37:00 UTC (rev 558) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 3827 2008-11-17 21:19:48Z pak21 $ +dnl $Id: configure.in 3866 2008-11-29 17:05:40Z pak21 $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -24,7 +24,7 @@ AC_CANONICAL_SYSTEM dnl Use automake to produce `Makefile.in' -AM_INIT_AUTOMAKE(fuse, 0.10.0-pre1) +AM_INIT_AUTOMAKE(fuse, 0.10.0) dnl Checks for programs. AC_PROG_CC Modified: trunk/fuse/disk/disk.c =================================================================== --- trunk/fuse/disk/disk.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/disk/disk.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* disk.c: Routines for handling disk images Copyright (c) 2007 Gergely Szasz - $Id: disk.c 3815 2008-11-09 19:19:59Z pak21 $ + $Id: disk.c 3858 2008-11-29 11:15:22Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -966,6 +966,13 @@ return d->status = DISK_OK; } +#define CPC_ISSUE_NONE 0 +#define CPC_ISSUE_1 1 +#define CPC_ISSUE_2 2 +#define CPC_ISSUE_3 3 +#define CPC_ISSUE_4 4 +#define CPC_ISSUE_5 5 + static int open_cpc( buffer_t *buffer, disk_t *d, int preindex ) { @@ -1009,35 +1016,45 @@ 256 * buff[ 0x1f + 8 * j ] : 0x80 << buff[ 0x1b + 8 * j ]; idlen = 0x80 << buff[ 0x1b + 8 * j ]; /* sector length from ID */ - bpt += calc_sectorlen( gap == GAP_MINIMAL_MFM ? 1 : 0, idlen, gap ); - trlen += seclen; + if( idlen != 0 && idlen <= ( 0x80 << 0x08 ) && /* idlen is o.k. */ + seclen > idlen && seclen % idlen ) /* seclen != N * len */ + return d->status = DISK_OPEN; + + bpt += calc_sectorlen( gap == GAP_MINIMAL_MFM ? 1 : 0, seclen > idlen ? idlen : seclen, gap ); if( i < 84 && d->flag & DISK_FLAG_PLUS3_CPC ) { if( j == 0 && buff[ 0x1b + 8 * j ] == 6 && seclen > 6144 ) - plus3_fix = 4; - else if( j == 0 && buff[ 0x1b + 8 * j ] == 6 ) - plus3_fix = 1; + plus3_fix = CPC_ISSUE_4; + else if( j == 0 && buff[ 0x1b + 8 * j ] == 6 ) + plus3_fix = CPC_ISSUE_1; else if( j == 0 && buff[ 0x18 + 8 * j ] == j && buff[ 0x19 + 8 * j ] == j && buff[ 0x1a + 8 * j ] == j && buff[ 0x1b + 8 * j ] == j ) - plus3_fix = 3; - else if( j == 1 && plus3_fix == 1 && buff[ 0x1b + 8 * j ] == 2 ) - plus3_fix = 2; - else if( j > 1 && plus3_fix == 2 && buff[ 0x1b + 8 * j ] != 2 ) - plus3_fix = 0; - else if( j > 0 && plus3_fix == 3 && + plus3_fix = CPC_ISSUE_3; + else if( j == 1 && plus3_fix == CPC_ISSUE_1 && + buff[ 0x1b + 8 * j ] == 2 ) + plus3_fix = CPC_ISSUE_2; + else if( i == 38 && j == 0 && buff[ 0x1b + 8 * j ] == 2 ) + plus3_fix = CPC_ISSUE_5; + else if( j > 1 && plus3_fix == CPC_ISSUE_2 && buff[ 0x1b + 8 * j ] != 2 ) + plus3_fix = CPC_ISSUE_NONE; + else if( j > 0 && plus3_fix == CPC_ISSUE_3 && ( buff[ 0x18 + 8 * j ] != j || buff[ 0x19 + 8 * j ] != j || buff[ 0x1a + 8 * j ] != j || buff[ 0x1b + 8 * j ] != j ) ) - plus3_fix = 0; - else if( j > 10 && plus3_fix == 2 ) - plus3_fix = 0; + plus3_fix = CPC_ISSUE_NONE; + else if( j > 10 && plus3_fix == CPC_ISSUE_2 ) + plus3_fix = CPC_ISSUE_NONE; + else if( i == 38 && j > 0 && plus3_fix == CPC_ISSUE_5 && + buff[ 0x1b + 8 * j ] != 2 - ( j & 1 ) ) + plus3_fix = CPC_ISSUE_NONE; } + trlen += seclen; if( seclen == 0x80 ) /* every 128byte length sector padded */ sector_pad++; } if( i < 84 ) { fix[i] = plus3_fix; - if( fix[i] == 4 ) bpt = 6500;/* Type 1 variant DD+ (e.g. Coin Op Hits) */ - else if( fix[i] != 0 ) bpt = 6250;/* we assume a standard DD track */ + if( fix[i] == CPC_ISSUE_4 ) bpt = 6500;/* Type 1 variant DD+ (e.g. Coin Op Hits) */ + else if( fix[i] != CPC_ISSUE_NONE ) bpt = 6250;/* we assume a standard DD track */ } buffer->index += trlen + sector_pad * 128 + 256; if( bpt > max_bpt ) @@ -1064,20 +1081,16 @@ if( preindex) preindex_add( d, gap ); postindex_add( d, gap ); - trlen = 0; + for( j = 0; j < hdrb[0x15]; j++ ) { /* each sector */ seclen = d->type == DISK_ECPC ? hdrb[ 0x1e + 8 * j ] + /* data length in sector */ 256 * hdrb[ 0x1f + 8 * j ] : 0x80 << hdrb[ 0x1b + 8 * j ]; idlen = 0x80 << hdrb[ 0x1b + 8 * j ]; /* sector length from ID */ - trlen += seclen; if( idlen == 0 || idlen > ( 0x80 << 0x08 ) ) /* error in sector length code -> ignore */ idlen = seclen; - if( seclen > idlen && seclen % idlen ) /* seclen != N * len */ - return d->status = DISK_OPEN; - if( i < 84 && fix[i] == 2 && j == 0 ) { /* repositionate the dummy track */ d->i = 8; } @@ -1086,35 +1099,49 @@ hdrb[ 0x1c + 8 * j ] & 0x20 && !( hdrb[ 0x1d + 8 * j ] & 0x20 ) ? CRC_ERROR : CRC_OK ); - if( i < 84 && fix[i] == 1 && j == 0 ) { /* 6144 */ + if( i < 84 && fix[i] == CPC_ISSUE_1 && j == 0 ) { /* 6144 */ data_add( d, buffer, NULL, seclen, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); - } else if( i < 84 && fix[i] == 2 && j == 0 ) { /* 6144, 10x512 */ + } else if( i < 84 && fix[i] == CPC_ISSUE_2 && j == 0 ) { /* 6144, 10x512 */ datamark_add( d, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap ); gap_add( d, 2, gap ); buffer->index += seclen; - } else if( i < 84 && fix[i] == 3 ) { /* 128, 256, 512, ... 4096k */ + } else if( i < 84 && fix[i] == CPC_ISSUE_3 ) { /* 128, 256, 512, ... 4096k */ data_add( d, buffer, NULL, 128, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); buffer->index += seclen - 128; - } else if( i < 84 && fix[i] == 4 ) { /* Nx8192 (max 6384 byte ) */ + } else if( i < 84 && fix[i] == CPC_ISSUE_4 ) { /* Nx8192 (max 6384 byte ) */ data_add( d, buffer, NULL, 6384, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); buffer->index += seclen - 6384; + } else if( i < 84 && fix[i] == CPC_ISSUE_5 ) { /* 9x512 */ + /* 512 256 512 256 512 256 512 256 512 */ + if( idlen == 256 ) { + data_add( d, NULL, buff, 512, + hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, + hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? + CRC_ERROR : CRC_OK, 0x00 ); + buffer->index += idlen; + } else { + data_add( d, buffer, NULL, idlen, + hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, + hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? + CRC_ERROR : CRC_OK, 0x00 ); + } } else { - data_add( d, buffer, NULL, seclen > idlen ? idlen : seclen, - hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, + data_add( d, buffer, NULL, seclen > idlen ? idlen : seclen, + hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? CRC_ERROR : CRC_OK, 0x00 ); if( seclen > idlen ) { /* weak sector with multiple copy */ - buffer->index +=( seclen / ( 0x80 << hdrb[ 0x1b + 8 * j ] ) - 1 ) * - ( 0x80 << hdrb[ 0x1b + 8 * j ] ); + buffer->index +=( seclen / ( 0x80 << hdrb[ 0x1b + 8 * j ] ) - 1 ) * + ( 0x80 << hdrb[ 0x1b + 8 * j ] ); /* ( ( N * len ) / len - 1 ) * len */ } } Modified: trunk/fuse/disk/upd_fdc.c =================================================================== --- trunk/fuse/disk/upd_fdc.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/disk/upd_fdc.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* upd_fdc.c: NEC floppy disk controller emulation Copyright (c) 2007 Gergely Szasz - $Id: upd_fdc.c 3802 2008-11-02 17:06:41Z pak21 $ + $Id: upd_fdc.c 3858 2008-11-29 11:15:22Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -905,15 +905,18 @@ f->data_offset++; } } - if( f->data_offset == f->sector_length ) { /* read the CRC */ + if( ( f->cmd->id == UPD_CMD_READ_DIAG && f->data_offset == f->rlen ) || + ( f->cmd->id == UPD_CMD_READ_DATA && f->data_offset == f->sector_length ) ) { /* read the CRC */ fdd_read_write_data( &d->fdd, FDD_READ ); crc_add( f, d ); fdd_read_write_data( &d->fdd, FDD_READ ); crc_add( f, d ); if( f->crc != 0x000 ) { f->status_register[2] |= UPD_FDC_ST2_DATA_ERROR; f->status_register[1] |= UPD_FDC_ST1_CRC_ERROR; - f->status_register[0] |= UPD_FDC_ST0_INT_ABNORM; - cmd_result( f ); /* set up result phase */ - return r; + if( f->cmd->id == UPD_CMD_READ_DATA ) { /* READ DIAG not aborted! */ + f->status_register[0] |= UPD_FDC_ST0_INT_ABNORM; + cmd_result( f ); /* set up result phase */ + return r; + } } if( f->cmd->id == UPD_CMD_READ_DATA ) { Modified: trunk/fuse/fuse.c =================================================================== --- trunk/fuse/fuse.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/fuse.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* fuse.c: The Free Unix Spectrum Emulator Copyright (c) 1999-2008 Philip Kendall - $Id: fuse.c 3807 2008-11-08 15:17:00Z pak21 $ + $Id: fuse.c 3868 2008-12-01 21:00:58Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -103,7 +103,7 @@ libspectrum_creator *fuse_creator; /* The earliest version of libspectrum we need */ -static const char *LIBSPECTRUM_MIN_VERSION = "0.2.0.1"; +static const char *LIBSPECTRUM_MIN_VERSION = "0.5.0"; /* The various types of file we may want to run on startup */ typedef struct start_files_t { Modified: trunk/fuse/fusepb/English.lproj/InfoPlist.strings =================================================================== (Binary files differ) Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/fusepb/Info-Fuse.plist 2008-12-04 11:37:00 UTC (rev 558) @@ -476,11 +476,11 @@ <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleShortVersionString</key> - <string>0.9.0</string> + <string>0.10.0</string> <key>CFBundleSignature</key> <string>FUSE</string> <key>CFBundleVersion</key> - <string>0.10.0-pre1</string> + <string>0.10.0</string> <key>NSMainNibFile</key> <string>MainMenu</string> <key>NSPrincipalClass</key> Modified: trunk/fuse/fusepb/config.h =================================================================== --- trunk/fuse/fusepb/config.h 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/fusepb/config.h 2008-12-04 11:37:00 UTC (rev 558) @@ -152,7 +152,7 @@ /* #undef USE_WIDGET */ /* Version number of package */ -#define VERSION "0.10.0-pre1" +#define VERSION "0.10.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Modified: trunk/fuse/hacking/ChangeLog =================================================================== --- trunk/fuse/hacking/ChangeLog 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/hacking/ChangeLog 2008-12-04 11:37:00 UTC (rev 558) @@ -2936,3 +2936,21 @@ register port (thanks, Mark Woodmass). 20081117 ocnfigure.in: bump version number for 0.10.0-pre1 release (Release_0_10_0-branch). +20081118 rzx.c: don't autosave rzx snapshots when we are recording in compo + mode (Fred). +20081119 disk/{disk.c,upd_fdc.c}: fix READ_DIAG emlation bugs to support + LERM Plus-3-Mate (fixes bug #2312217) (Gergely Szasz). +20081120 compat/amiga/paths.c: implement compat_is_absolute_path for Amiga + (final part of patch #1712260) (Chris Young). +20081120 utils.c: don't switch machine on autoloading a Timex dock cart if we + can already support them (Fred). +20081122 disk/disk.c: fix a track length calculation bug (more of bug #2312217) + (Gergely Szasz). +20081125 scld.c: fix loading of dock/exrom information from snapshots (Fred). +20081129 disk/disk.c: limit weak sector handling to fix Coin-Op Hits (more of + bug #2312217) (Gergely Szasz). +20081129 disk/disk.c: one instance of plus3_fix wasn't updated (thanks, Stuart + Brady) (Fred). +20081129 configure.in,man/fuse.1,README: final tweaks for 0.10.0 release + (Release_0_10_0-branch). +20081201 fuse.c: update libspectrum version needed (Release_0_10_0-branch). Modified: trunk/fuse/man/fuse.1 =================================================================== --- trunk/fuse/man/fuse.1 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/man/fuse.1 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ .\" -*- nroff -*- .\" .\" fuse.1: Fuse man page -.\" Copyright (c) 2001-2007 Russell Marks, Philip Kendall, Darren Salt, +.\" Copyright (c) 2001-2008 Russell Marks, Philip Kendall, Darren Salt, .\" Fredrick Meunier, Stuart Brady .\" .\" This program is free software; you can redistribute it and/or modify @@ -23,7 +23,7 @@ .\" E-mail: phi...@sh... .\" .\" -.TH fuse 1 "5th January, 2008" "Version 0.9.0" "Emulators" +.TH fuse 1 "3rd December, 2008" "Version 0.10.0" "Emulators" .\" .\"------------------------------------------------------------------ .\" Modified: trunk/fuse/rzx.c =================================================================== --- trunk/fuse/rzx.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/rzx.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* rzx.c: .rzx files Copyright (c) 2002-2003 Philip Kendall - $Id: rzx.c 3787 2008-10-22 19:10:25Z pak21 $ + $Id: rzx.c 3836 2008-11-18 04:24:34Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -474,7 +474,8 @@ } - if( settings_current.rzx_autosaves ) autosave_frame(); + if( !rzx_competition_mode && settings_current.rzx_autosaves ) + autosave_frame(); return 0; } Modified: trunk/fuse/scld.c =================================================================== --- trunk/fuse/scld.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/scld.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* scld.c: Routines for handling the Timex SCLD Copyright (c) 2002-2006 Fredrick Meunier, Philip Kendall, Witold Filipczyk - $Id: scld.c 3389 2007-12-03 12:54:17Z fredm $ + $Id: scld.c 3849 2008-11-25 02:10:31Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -181,6 +181,27 @@ } } +static int +scld_dock_exrom_from_snapshot( memory_page *dest, int page_num, int writable, + void *source ) +{ + dest->offset = 0; + dest->page_num = page_num; + dest->writable = writable; + dest->source = MEMORY_SOURCE_CARTRIDGE; + dest->page = + memory_pool_allocate( MEMORY_PAGE_SIZE * sizeof( libspectrum_byte ) ); + if( !dest->page ) { + ui_error( UI_ERROR_ERROR, "Out of memory at %s:%d", __FILE__, + __LINE__ ); + return 1; + } + + memcpy( dest->page, source, MEMORY_PAGE_SIZE ); + + return 0; +} + static void scld_from_snapshot( libspectrum_snap *snap ) { @@ -201,43 +222,17 @@ for( i = 0; i < 8; i++ ) { if( libspectrum_snap_dock_cart( snap, i ) ) { - if( !memory_map_dock[i]->page ) { - memory_map_dock[i]->offset = 0; - memory_map_dock[i]->page_num = 0; - memory_map_dock[i]->writable = libspectrum_snap_dock_ram( snap, i ); - memory_map_dock[i]->source = MEMORY_SOURCE_CARTRIDGE; - memory_map_dock[i]->page = memory_pool_allocate( - MEMORY_PAGE_SIZE * - sizeof( libspectrum_byte ) ); - if( !memory_map_dock[i]->page ) { - ui_error( UI_ERROR_ERROR, "Out of memory at %s:%d", __FILE__, - __LINE__ ); - return; - } - } - - memcpy( memory_map_dock[i]->page, libspectrum_snap_dock_cart( snap, i ), - MEMORY_PAGE_SIZE ); + if( scld_dock_exrom_from_snapshot( memory_map_dock[i], i, + libspectrum_snap_dock_ram( snap, i ), + libspectrum_snap_dock_cart( snap, i ) ) ) + return; } if( libspectrum_snap_exrom_cart( snap, i ) ) { - if( !memory_map_dock[i]->page ) { - memory_map_exrom[i]->offset = 0; - memory_map_exrom[i]->page_num = 0; - memory_map_exrom[i]->writable = libspectrum_snap_exrom_ram( snap, i ); - memory_map_exrom[i]->source = MEMORY_SOURCE_CARTRIDGE; - memory_map_exrom[i]->page = memory_pool_allocate( - MEMORY_PAGE_SIZE * - sizeof( libspectrum_byte ) ); - if( !memory_map_exrom[i]->page ) { - ui_error( UI_ERROR_ERROR, "Out of memory at %s:%d", __FILE__, - __LINE__ ); - return; - } - } - - memcpy( memory_map_exrom[i]->page, - libspectrum_snap_exrom_cart( snap, i ), MEMORY_PAGE_SIZE ); + if( scld_dock_exrom_from_snapshot( memory_map_exrom[i], i, + libspectrum_snap_exrom_ram( snap, i ), + libspectrum_snap_exrom_cart( snap, i ) ) ) + return; } } @@ -247,6 +242,7 @@ machine_current->memory_map(); } + } static void Modified: trunk/fuse/utils.c =================================================================== --- trunk/fuse/utils.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/fuse/utils.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* utils.c: some useful helper functions Copyright (c) 1999-2008 Philip Kendall, Fredrick Meunier - $Id: utils.c 3807 2008-11-08 15:17:00Z pak21 $ + $Id: utils.c 3846 2008-11-20 07:17:21Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -156,7 +156,10 @@ break; case LIBSPECTRUM_CLASS_CARTRIDGE_TIMEX: - error = machine_select( LIBSPECTRUM_MACHINE_TC2068 ); if( error ) break; + if( !( machine_current->capabilities & + LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_DOCK ) ) { + error = machine_select( LIBSPECTRUM_MACHINE_TC2068 ); if( error ) break; + } error = dck_insert( filename ); break; Modified: trunk/libspectrum/Info.plist =================================================================== --- trunk/libspectrum/Info.plist 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/Info.plist 2008-12-04 11:37:00 UTC (rev 558) @@ -23,6 +23,6 @@ <key>CFBundleSignature</key> <string>????</string> <key>CFBundleVersion</key> - <string>0.5.0-pre1</string> + <string>0.5.0</string> </dict> </plist> Modified: trunk/libspectrum/config.h =================================================================== --- trunk/libspectrum/config.h 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/config.h 2008-12-04 11:37:00 UTC (rev 558) @@ -86,7 +86,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.4.0" +#define VERSION "0.5.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Property changes on: trunk/libspectrum/libspectrum ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-538 + /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-538 Modified: trunk/libspectrum/libspectrum/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/ChangeLog 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/ChangeLog 2008-12-04 11:37:00 UTC (rev 558) @@ -42,6 +42,8 @@ * Remove deprecated functions (Fredrick Meunier). + * Tweak timings for TS2068 (Fredrick Meunier; thanks Philip Kendall). + 2008-01-05 Philip Kendall <phi...@sh...> * libspectrum 0.4.0 released. @@ -269,5 +271,5 @@ * libspectrum separated from Fuse just before the 0.5.0 release of Fuse; see Fuse's ChangeLog for changes up to this point -$Id: ChangeLog 3791 2008-10-27 20:20:40Z pak21 $ +$Id: ChangeLog 3867 2008-11-29 23:43:28Z fredm $ Modified: trunk/libspectrum/libspectrum/Makefile.am =================================================================== --- trunk/libspectrum/libspectrum/Makefile.am 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/Makefile.am 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2001-2004 Philip Kendall -## $Id: Makefile.am 3698 2008-06-30 15:12:02Z pak21 $ +## $Id: Makefile.am 3864 2008-11-29 16:45:36Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -58,7 +58,7 @@ zlib.c \ zxs.c -libspectrum_la_LDFLAGS = -version-info 6:0:1 -no-undefined +libspectrum_la_LDFLAGS = -version-info 7:0:0 -no-undefined libspectrum_la_LIBADD = @AUDIOFILE_LIBS@ -lm Modified: trunk/libspectrum/libspectrum/README =================================================================== --- trunk/libspectrum/libspectrum/README 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/README 2008-12-04 11:37:00 UTC (rev 558) @@ -1,4 +1,4 @@ -libspectrum 0.4.0 +libspectrum 0.5.0 ================= libspectrum is a library which is designed to make the input and @@ -13,6 +13,8 @@ * Tape images: .tzx, .tap, .spc, .sta and .ltp (read/write) and Warajevo .tap, Z80Em and CSW version 1 (read only). * Input recordings: .rzx (read/write). +* Disk images: .dsk (both plain and extended), .fdi, .sad, .scl, .td0, + .trd and .udi (identification only). * Timex cartridges: .dck (read only). * IDE hard disk images: .hdf (read/write). * Microdrive cartridge images: .mdr (read/write). @@ -50,6 +52,6 @@ running 'configure' for the first time. Philip Kendall <phi...@sh...> -5 January 2008 +3 December 2008 -$Id: README 3795 2008-10-27 21:02:43Z pak21 $ +$Id: README 3864 2008-11-29 16:45:36Z pak21 $ Modified: trunk/libspectrum/libspectrum/configure.in =================================================================== --- trunk/libspectrum/libspectrum/configure.in 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/configure.in 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ dnl Process this file with autoconf to produce a configure script. -dnl Copyright (c) 1999-2004 Philip Kendall +dnl Copyright (c) 1999-2008 Philip Kendall -dnl $Id: configure.in 3825 2008-11-17 21:10:27Z pak21 $ +dnl $Id: configure.in 3864 2008-11-29 16:45:36Z pak21 $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -25,7 +25,7 @@ AM_CONFIG_HEADER(config.h) dnl Use automake to produce `Makefile.in' -AM_INIT_AUTOMAKE(libspectrum, 0.5.0-pre1) +AM_INIT_AUTOMAKE(libspectrum, 0.5.0) dnl Checks for programs. AC_PROG_CC @@ -108,6 +108,7 @@ 1.2.0, AC_DEFINE([HAVE_LIB_GLIB], 1, [Defined if we've got glib]) LIBS="$LIBS `glib-config --libs`", + glib=no AC_MSG_WARN(glib not found - using internal replacement) ) fi Modified: trunk/libspectrum/libspectrum/doc/libspectrum.3 =================================================================== --- trunk/libspectrum/libspectrum/doc/libspectrum.3 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/doc/libspectrum.3 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ .\" -*- nroff -*- .\" .\" libspectrum.3: libspectrum summary -.\" Copyright (c) 2004-2007 Philip Kendall +.\" Copyright (c) 2004-2008 Philip Kendall .\" .\" This program is free software; you can redistribute it and/or modify .\" it under the terms of the GNU General Public License as published by @@ -22,7 +22,7 @@ .\" E-mail: phi...@sh... .\" .\" -.TH libspectrum 3 "5th January, 2008" "Version 0.4.0" "Emulators" +.TH libspectrum 3 "3rd December, 2008" "Version 0.5.0" "Emulators" .\" .\"------------------------------------------------------------------ .\" @@ -50,6 +50,9 @@ .IP \(bu 2 Input recordings: .rzx (read/write). .IP \(bu 2 +Disk images: .dsk (both plain and extended), .fdi, .sad, .scl, .td0, .trd +and .udi (identification only). +.IP \(bu 2 Timex cartridges: .dck (read only). .IP \(bu 2 IDE hard disk images: .hdf (read/write). Modified: trunk/libspectrum/libspectrum/doc/libspectrum.txt =================================================================== --- trunk/libspectrum/libspectrum/doc/libspectrum.txt 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/doc/libspectrum.txt 2008-12-04 11:37:00 UTC (rev 558) @@ -1,4 +1,4 @@ -libspectrum 0.4.0 +libspectrum 0.5.0 ================= libspectrum is a fairly simple library designed to make the handling @@ -1687,4 +1687,4 @@ Write `data' to register `reg' of the IDE channel `chn'. -$Id: libspectrum.txt 3816 2008-11-10 11:13:18Z pak21 $ +$Id: libspectrum.txt 3864 2008-11-29 16:45:36Z pak21 $ Modified: trunk/libspectrum/libspectrum/hacking/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/hacking/ChangeLog 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/hacking/ChangeLog 2008-12-04 11:37:00 UTC (rev 558) @@ -700,3 +700,13 @@ (libspectrum_0_5_0-branch). 20081117 configure.in: bump version number for 0.5.0-pre1 release (libspectrum_0_5_0-branch). +20081118 test/Makefile.am: distribute empty.z80 and writeprotected.mdr test + data files (Fred). +20081118 configure.in: set glib status off if we can't find it (thanks, Chris + Young) (Fred). +20081129 timings.c: correct first contended tstate for TS2068 based on updated + fusetest from Phil (Fred). +20081129 configure.in,doc/libspectrum.{3,txt},hacking/ChangeLog,Makefile.am, + README: final tweaks for 0.5.0 release (libspectrum_0_5_0-branch). +20081130 ChangeLog: add reference to TS2068 timing update + (libspectrum_0_5_0-branch) (Fred). Modified: trunk/libspectrum/libspectrum/test/Makefile.am =================================================================== --- trunk/libspectrum/libspectrum/test/Makefile.am 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/test/Makefile.am 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007 Philip Kendall -## $Id: Makefile.am 3691 2008-06-25 15:26:10Z pak21 $ +## $Id: Makefile.am 3834 2008-11-18 04:17:15Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -42,23 +42,25 @@ EXTRA_DIST += \ test/Makefile.am \ test/complete-tzx.pl \ + test/empty-drb.tzx \ test/empty.csw \ - test/empty-drb.tzx \ - test/invalid.gz \ - test/invalid.szx \ - test/invalid.tzx \ + test/empty.z80 \ test/invalid-archiveinfo.tzx \ test/invalid-custominfo.tzx \ test/invalid-gdb.tzx \ test/invalid-hardwareinfo.tzx \ test/invalid-warajevo-blockoffset.tap \ + test/invalid.gz \ + test/invalid.szx \ + test/invalid.tzx \ test/jump.tzx \ test/loop.tzx \ test/loop2.tzx \ test/loopend.tzx \ test/sp-2000.sna.gz \ test/sp-ffff.sna.gz \ - test/turbo-zeropilot.tzx + test/turbo-zeropilot.tzx \ + test/writeprotected.mdr CLEANFILES += \ test/.libs/test \ Modified: trunk/libspectrum/libspectrum/timings.c =================================================================== --- trunk/libspectrum/libspectrum/timings.c 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum/timings.c 2008-12-04 11:37:00 UTC (rev 558) @@ -1,7 +1,7 @@ /* timings.c: Timing routines Copyright (c) 2003 Philip Kendall - $Id: timings.c 3296 2007-11-12 11:45:22Z fredm $ + $Id: timings.c 3859 2008-11-29 11:24:42Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -86,7 +86,7 @@ /* SE */ { 3500000, 1750000, 24, 128, 24, 48, 47, 192, 48, 25, 32, 14336 }, /* TS2068 */ - { 3528000, 1764000, 24, 128, 24, 48, 24, 192, 25, 21, 32, 9184 }, + { 3528000, 1764000, 24, 128, 24, 48, 24, 192, 25, 21, 32, 9169 }, /* Pentagon 512K */ { 3584000, 1792000, 36, 128, 28, 32, 64, 192, 48, 16, 36, 17988 }, /* Pentagon 1024K */ Modified: trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj =================================================================== --- trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj 2008-12-04 10:57:47 UTC (rev 557) +++ trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj 2008-12-04 11:37:00 UTC (rev 558) @@ -391,8 +391,8 @@ isa = XCBuildConfiguration; buildSettings = { COPY_PHASE_STRIP = NO; - DYLIB_COMPATIBILITY_VERSION = 6; - DYLIB_CURRENT_VERSION = 6.0.1; + DYLIB_COMPATIBILITY_VERSION = 7; + DYLIB_CURRENT_VERSION = 7.0.0; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", @@ -402,7 +402,7 @@ FRAMEWORK_SEARCH_PATHS_QUOTED_1 = "\"$(SRCROOT)/../bzip2/build/Deployment\""; FRAMEWORK_SEARCH_PATHS_QUOTED_2 = "\"$(SRCROOT)/../libgcrypt/build/Deployment\""; FRAMEWORK_SEARCH_PATHS_QUOTED_3 = "\"$(SRCROOT)/../audiofile/build/Deployment\""; - FRAMEWORK_VERSION = "0.5.0-pre1"; + FRAMEWORK_VERSION = 0.5.0; GCC_DYNAMIC_NO_PIC = NO; GCC_ENABLE_FIX_AND_CONTINUE = YES; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2008-12-09 12:08:38
|
Revision: 565 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=565&view=rev Author: fredm Date: 2008-12-09 12:08:31 +0000 (Tue, 09 Dec 2008) Log Message: ----------- Migrate to XCode 3.1 and set base targets to 10.4. Add x86_64 build of QuickLook viewer. Remove some warnings and fix sorting of ROMs array in preferences controller. Modified Paths: -------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj trunk/FuseGenerator/LibspectrumSCRExtractor.m trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj trunk/audiofile/audiofile.xcodeproj/project.pbxproj trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/controllers/DebuggerController.m trunk/fuse/fusepb/controllers/FuseController.m trunk/fuse/settings.pl trunk/fuse/utils.c trunk/libgcrypt/libgcrypt.xcodeproj/project.pbxproj trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj Modified: trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2008-12-09 12:08:31 UTC (rev 565) @@ -472,7 +472,7 @@ "-lz", ); PRODUCT_NAME = FuseGenerator; - VALID_ARCHS = "i386 ppc"; + VALID_ARCHS = "ppc x86_64 i386"; WRAPPER_EXTENSION = qlgenerator; ZERO_LINK = YES; }; @@ -496,7 +496,7 @@ "-lz", ); PRODUCT_NAME = FuseGenerator; - VALID_ARCHS = "i386 ppc"; + VALID_ARCHS = "ppc x86_64 i386"; WARNING_CFLAGS = ( "-Wmost", "-Wno-four-char-constants", @@ -509,8 +509,11 @@ 2CA326230896AD4900168862 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "ppc i386 ppc64 x86_64"; DEAD_CODE_STRIPPING = YES; GCC_C_LANGUAGE_STANDARD = c99; + GCC_VERSION = 4.2; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; PREBINDING = NO; @@ -521,12 +524,11 @@ 2CA326240896AD4900168862 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - ppc, - i386, - ); + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "ppc i386 ppc64 x86_64"; DEAD_CODE_STRIPPING = YES; GCC_C_LANGUAGE_STANDARD = c99; + GCC_VERSION = 4.2; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; PREBINDING = NO; Modified: trunk/FuseGenerator/LibspectrumSCRExtractor.m =================================================================== --- trunk/FuseGenerator/LibspectrumSCRExtractor.m 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/FuseGenerator/LibspectrumSCRExtractor.m 2008-12-09 12:08:31 UTC (rev 565) @@ -442,7 +442,7 @@ scr_length ); } - scrData = [NSData dataWithBytesNoCopy:(const void *)scr_data length:scr_length]; + scrData = [NSData dataWithBytesNoCopy:(void *)scr_data length:scr_length]; image_type = TYPE_SCR; } Modified: trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2008-12-09 12:08:31 UTC (rev 565) @@ -436,10 +436,6 @@ B6B0E2FD08CC65D5001D8411 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); COPY_PHASE_STRIP = NO; DEBUGGING_SYMBOLS = YES; FRAMEWORK_SEARCH_PATHS = ""; @@ -461,8 +457,6 @@ INFOPLIST_FILE = Info.plist; INSTALL_PATH = /Library/Spotlight; LIBRARY_STYLE = Bundle; - MACOSX_DEPLOYMENT_TARGET = 10.4; - OPTIMIZATION_CFLAGS = "-O0"; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ( "-lbz2", @@ -485,10 +479,6 @@ B6B0E2FE08CC65D5001D8411 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); COPY_PHASE_STRIP = YES; FRAMEWORK_SEARCH_PATHS = ""; GCC_ENABLE_FIX_AND_CONTINUE = NO; @@ -501,7 +491,6 @@ INFOPLIST_FILE = Info.plist; INSTALL_PATH = /Library/Spotlight; LIBRARY_STYLE = Bundle; - MACOSX_DEPLOYMENT_TARGET = 10.4; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ( "-lbz2", @@ -524,10 +513,6 @@ B6B0E2FF08CC65D5001D8411 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); FRAMEWORK_SEARCH_PATHS = ""; GCC_GENERATE_DEBUGGING_SYMBOLS = NO; GCC_PRECOMPILE_PREFIX_HEADER = NO; @@ -538,7 +523,6 @@ INFOPLIST_FILE = Info.plist; INSTALL_PATH = /Library/Spotlight; LIBRARY_STYLE = Bundle; - MACOSX_DEPLOYMENT_TARGET = 10.4; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ( "-lbz2", @@ -561,7 +545,10 @@ B6B0E30108CC65D5001D8411 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_VERSION = 4.0; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Development; @@ -569,8 +556,11 @@ B6B0E30208CC65D5001D8411 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; + GCC_VERSION = 4.0; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Deployment; @@ -578,7 +568,10 @@ B6B0E30308CC65D5001D8411 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_VERSION = 4.0; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Default; Modified: trunk/audiofile/audiofile.xcodeproj/project.pbxproj =================================================================== --- trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2008-12-09 12:08:31 UTC (rev 565) @@ -134,7 +134,7 @@ 000000000000000016620A20 /* units.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = units.h; sourceTree = "<group>"; }; 000000000000000016620B50 /* util.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = util.h; sourceTree = "<group>"; }; 000000000000000016620BD0 /* wave.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = wave.h; sourceTree = "<group>"; }; - B62395C00C1CF586003B8E87 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = Info.plist; sourceTree = "<group>"; }; + B62395C00C1CF586003B8E87 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; B62395C10C1CF586003B8E87 /* audiofile.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = audiofile.framework; sourceTree = BUILT_PRODUCTS_DIR; }; B62395C80C1CF5AC003B8E87 /* config.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = config.h; sourceTree = SOURCE_ROOT; }; /* End PBXFileReference section */ @@ -303,9 +303,11 @@ 000000000000000016601A90 /* Project object */ = { isa = PBXProject; buildConfigurationList = B62395470C1CF4F8003B8E87 /* Build configuration list for PBXProject "audiofile" */; + compatibilityVersion = "Xcode 2.4"; hasScannedForEncodings = 1; mainGroup = 0000000000000000166142F0; projectDirPath = ""; + projectRoot = ""; targets = ( B623958A0C1CF586003B8E87 /* audiofile Framework */, ); @@ -390,13 +392,12 @@ B62395480C1CF4F8003B8E87 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = NO; FRAMEWORK_VERSION = 0.2.6; + GCC_VERSION = 4.0; MACOSX_DEPLOYMENT_TARGET = 10.4; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; @@ -405,13 +406,12 @@ B62395490C1CF4F8003B8E87 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; FRAMEWORK_VERSION = 0.2.6; + GCC_VERSION = 4.0; MACOSX_DEPLOYMENT_TARGET = 10.4; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; @@ -420,13 +420,12 @@ B623954A0C1CF4F8003B8E87 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = NO; FRAMEWORK_VERSION = 0.2.6; + GCC_VERSION = 4.0; MACOSX_DEPLOYMENT_TARGET = 10.4; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; @@ -435,6 +434,8 @@ B62395BD0C1CF586003B8E87 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; COPY_PHASE_STRIP = NO; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; @@ -460,11 +461,10 @@ OTHER_LDFLAGS = ( "-lm", "-lc", - "-seg1addr", - 0x27000000, ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = audiofile; SECTORDER_FLAGS = ""; @@ -477,6 +477,8 @@ B62395BE0C1CF586003B8E87 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; COPY_PHASE_STRIP = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; @@ -501,11 +503,10 @@ OTHER_LDFLAGS = ( "-lm", "-lc", - "-seg1addr", - 0x27000000, ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = audiofile; SECTORDER_FLAGS = ""; @@ -518,6 +519,8 @@ B62395BF0C1CF586003B8E87 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; FRAMEWORK_VERSION = 0.2.6; @@ -540,11 +543,10 @@ OTHER_LDFLAGS = ( "-lm", "-lc", - "-seg1addr", - 0x27000000, ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = audiofile; SECTORDER_FLAGS = ""; Modified: trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj =================================================================== --- trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2008-12-09 12:08:31 UTC (rev 565) @@ -314,7 +314,7 @@ B615BFE60B4261E50082D535 /* HIDJoysticks.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; name = HIDJoysticks.m; path = content_arrays/HIDJoysticks.m; sourceTree = "<group>"; }; B619FC2E090D9BC200344F94 /* SavePanelAccessoryView.nib */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = SavePanelAccessoryView.nib; path = nibs/SavePanelAccessoryView.nib; sourceTree = "<group>"; }; B61EEB950D1A917D006FEA80 /* FuseGenerator.qlgenerator */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.bundle"; name = FuseGenerator.qlgenerator; path = ../../FuseGenerator/build/Release/FuseGenerator.qlgenerator; sourceTree = SOURCE_ROOT; }; - B61F46A909121DF100C8096C /* Info-Fuse.plist */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = "Info-Fuse.plist"; sourceTree = "<group>"; }; + B61F46A909121DF100C8096C /* Info-Fuse.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "Info-Fuse.plist"; sourceTree = "<group>"; }; B61F46AA09121DF200C8096C /* Fuse.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Fuse.app; sourceTree = BUILT_PRODUCTS_DIR; }; B621A11E062E92FB00F63DBC /* if2.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = if2.c; path = ../if2.c; sourceTree = SOURCE_ROOT; }; B621A11F062E92FB00F63DBC /* if2.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = if2.h; path = ../if2.h; sourceTree = SOURCE_ROOT; }; @@ -1268,9 +1268,11 @@ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; buildConfigurationList = B63319B3086803BA00732AA3 /* Build configuration list for PBXProject "Fuse" */; + compatibilityVersion = "Xcode 2.4"; hasScannedForEncodings = 1; mainGroup = 29B97314FDCFA39411CA2CEA /* Fuse */; projectDirPath = ""; + projectRoot = ""; targets = ( B61F459009121DF100C8096C /* Fuse */, ); @@ -1515,10 +1517,6 @@ B61F46A609121DF100C8096C /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); COPY_PHASE_STRIP = NO; FRAMEWORK_SEARCH_PATHS = ( "$(HOME)/Library/Frameworks", @@ -1558,10 +1556,6 @@ B61F46A709121DF100C8096C /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - ppc, - i386, - ); COPY_PHASE_STRIP = YES; FRAMEWORK_SEARCH_PATHS = ( "$(HOME)/Library/Frameworks", @@ -1600,10 +1594,6 @@ B61F46A809121DF100C8096C /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - ppc, - i386, - ); FRAMEWORK_SEARCH_PATHS = ( "$(HOME)/Library/Frameworks", ../../libspectrum/build/Deployment, @@ -1641,13 +1631,13 @@ B63319B4086803BA00732AA3 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; + GCC_VERSION = 4.0; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; YACCFLAGS = "-d"; @@ -1659,14 +1649,14 @@ B63319B5086803BA00732AA3 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; + GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; + GCC_VERSION = 4.0; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; YACCFLAGS = "-d"; @@ -1678,13 +1668,13 @@ B63319B6086803BA00732AA3 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; + GCC_VERSION = 4.0; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; YACCFLAGS = "-d"; Modified: trunk/fuse/fusepb/controllers/DebuggerController.m =================================================================== --- trunk/fuse/fusepb/controllers/DebuggerController.m 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/fuse/fusepb/controllers/DebuggerController.m 2008-12-09 12:08:31 UTC (rev 565) @@ -482,7 +482,7 @@ - (IBAction)debugger_cmd_evaluate:(id)sender { - debugger_command_evaluate( [[entry stringValue] lossyCString] ); + debugger_command_evaluate( [[entry stringValue] UTF8String] ); } - (IBAction)debugger_done_step:(id)sender Modified: trunk/fuse/fusepb/controllers/FuseController.m =================================================================== --- trunk/fuse/fusepb/controllers/FuseController.m 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/fuse/fusepb/controllers/FuseController.m 2008-12-09 12:08:31 UTC (rev 565) @@ -963,13 +963,13 @@ NSPoint point; event1 = [NSEvent keyEventWithType:NSKeyUp location:point modifierFlags:0 - timestamp:nil windowNumber:0 context:nil characters:character + timestamp:0 windowNumber:0 context:nil characters:character charactersIgnoringModifiers:character isARepeat:NO keyCode:keyCode]; [NSApp postEvent:event1 atStart:NO]; event2 = [NSEvent keyEventWithType:NSFlagsChanged location:point - modifierFlags:0 timestamp:nil windowNumber:0 context:nil + modifierFlags:0 timestamp:0 windowNumber:0 context:nil characters:nil charactersIgnoringModifiers:nil isARepeat:NO keyCode:0]; [NSApp postEvent:event2 atStart:NO]; @@ -991,7 +991,7 @@ NSPoint point; event1 = [NSEvent keyEventWithType:NSKeyUp location:point modifierFlags:0 - timestamp:nil windowNumber:0 context:nil characters:@" " + timestamp:0 windowNumber:0 context:nil characters:@" " charactersIgnoringModifiers:@" " isARepeat:NO keyCode:keyCode]; [NSApp postEvent:event1 atStart:NO]; } @@ -1276,7 +1276,7 @@ @"Stop Recording"]; } -- (BOOL)validateMenuItem:(id <NSMenuItem>)menuItem +- (BOOL)validateMenuItem:(NSMenuItem*)menuItem { switch( [menuItem tag] ) { case 1: Modified: trunk/fuse/settings.pl =================================================================== --- trunk/fuse/settings.pl 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/fuse/settings.pl 2008-12-09 12:08:31 UTC (rev 565) @@ -607,6 +607,24 @@ print hashline( __LINE__ ), << 'CODE'; +/* Comparison function to sort the machineroms array */ +int +machineroms_compare( id dict1, id dict2, void *context ) +{ + NSMutableDictionary *roms1 = (NSMutableDictionary*)dict1; + NSMutableDictionary *roms2 = (NSMutableDictionary*)dict2; + int index1 = machine_get_index( [[roms1 valueForKey:@"machine"] machineType] ); + int index2 = machine_get_index( [[roms2 valueForKey:@"machine"] machineType] ); + int retval = NSOrderedSame; + if( index1 > index2 ) { + retval = NSOrderedDescending; + } else if( index1 < index2 ) { + retval = NSOrderedAscending; + } + + return retval; +} + /* Fill a NSMutableArray with rom information suitable for use with Cocoa bindings */ NSMutableArray* @@ -642,14 +660,8 @@ print hashline( __LINE__ ), << 'CODE'; /* We assume that we got all machines in the array, this should always be true*/ - NSEnumerator *enumerator = [machineroms objectEnumerator]; - while ( ( roms = [enumerator nextObject] ) ) { - int index = machine_get_index( [[roms valueForKey:@"machine"] machineType] ); - int i = [machineroms indexOfObject:roms]; - if( i != index ) { - [machineroms exchangeObjectAtIndex:i withObjectAtIndex:index]; - } - } + [machineroms sortUsingFunction:machineroms_compare context:nil]; + return machineroms; } CODE Modified: trunk/fuse/utils.c =================================================================== --- trunk/fuse/utils.c 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/fuse/utils.c 2008-12-09 12:08:31 UTC (rev 565) @@ -253,7 +253,7 @@ resource_url, file, false); if (file_url == NULL) goto deallocate; - if (!CFURLGetFileSystemRepresentation (file_url, TRUE, path, + if (!CFURLGetFileSystemRepresentation (file_url, TRUE, (unsigned char*)path, PATH_MAX)) goto deallocate; deallocate: Modified: trunk/libgcrypt/libgcrypt.xcodeproj/project.pbxproj =================================================================== --- trunk/libgcrypt/libgcrypt.xcodeproj/project.pbxproj 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/libgcrypt/libgcrypt.xcodeproj/project.pbxproj 2008-12-09 12:08:31 UTC (rev 565) @@ -138,7 +138,7 @@ 000000000000000016430580 /* mpi-inv.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; path = "mpi-inv.c"; sourceTree = "<group>"; }; 000000000000000016430A90 /* dsa.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; path = dsa.c; sourceTree = "<group>"; }; 000000000000000016430DB0 /* module.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; path = module.c; sourceTree = "<group>"; }; - B61D2B3C0A59ED5F0008B6CC /* Info-gcrypt.plist */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = "Info-gcrypt.plist"; sourceTree = "<group>"; }; + B61D2B3C0A59ED5F0008B6CC /* Info-gcrypt.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "Info-gcrypt.plist"; sourceTree = "<group>"; }; B61D2B3D0A59ED5F0008B6CC /* gcrypt.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = gcrypt.framework; sourceTree = BUILT_PRODUCTS_DIR; }; B69AFF390A5BFD0F00EEA5ED /* config.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = config.h; sourceTree = SOURCE_ROOT; }; /* End PBXFileReference section */ @@ -357,9 +357,11 @@ 00000000000000001640F4D0 /* Project object */ = { isa = PBXProject; buildConfigurationList = B61D2B3F0A59ED600008B6CC /* Build configuration list for PBXProject "libgcrypt" */; + compatibilityVersion = "Xcode 2.4"; hasScannedForEncodings = 1; mainGroup = 00000000000000001640F560; projectDirPath = ""; + projectRoot = ""; targets = ( B61D2B040A59ED5F0008B6CC /* gcrypt Framework */, ); @@ -467,9 +469,9 @@ ); INFOPLIST_FILE = "Info-gcrypt.plist"; INSTALL_PATH = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 10.3; OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = gcrypt; SECTORDER_FLAGS = ""; @@ -502,9 +504,9 @@ ); INFOPLIST_FILE = "Info-gcrypt.plist"; INSTALL_PATH = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 10.3; OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = gcrypt; SECTORDER_FLAGS = ""; @@ -535,9 +537,9 @@ ); INFOPLIST_FILE = "Info-gcrypt.plist"; INSTALL_PATH = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 10.3; OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = gcrypt; SECTORDER_FLAGS = ""; @@ -549,11 +551,11 @@ B61D2B400A59ED600008B6CC /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_VERSION = 4.0; + PREBINDING = NO; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Development; @@ -561,12 +563,12 @@ B61D2B410A59ED600008B6CC /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; + GCC_VERSION = 4.0; + PREBINDING = NO; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Deployment; @@ -574,11 +576,11 @@ B61D2B420A59ED600008B6CC /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_VERSION = 4.0; + PREBINDING = NO; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Default; Modified: trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj =================================================================== --- trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj 2008-12-09 12:04:14 UTC (rev 564) +++ trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj 2008-12-09 12:08:31 UTC (rev 565) @@ -123,7 +123,7 @@ B67099A00A6B4EA700CA951F /* z80em.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; path = z80em.c; sourceTree = "<group>"; }; B6BF2A9A0A60023100D16624 /* libspectrum.h.in */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = libspectrum.h.in; sourceTree = "<group>"; }; B6BF2AA40A6005E800D16624 /* libspectrum.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = libspectrum.h; sourceTree = SOURCE_ROOT; }; - B6CBAD780A5F3C2900F826D6 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = Info.plist; sourceTree = "<group>"; }; + B6CBAD780A5F3C2900F826D6 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; B6CBAD790A5F3C2900F826D6 /* spectrum.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = spectrum.framework; sourceTree = BUILT_PRODUCTS_DIR; }; B6CBADB70A5F3F3400F826D6 /* gcrypt.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = gcrypt.framework; path = ../libgcrypt/build/Deployment/gcrypt.framework; sourceTree = SOURCE_ROOT; }; B6CBAE200A5FDDC700F826D6 /* snap_accessors.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = snap_accessors.txt; sourceTree = "<group>"; }; @@ -275,9 +275,11 @@ 000000000000000016410950 /* Project object */ = { isa = PBXProject; buildConfigurationList = B69A010D0A5F3BF500EEA5ED /* Build configuration list for PBXProject "libspectrum" */; + compatibilityVersion = "Xcode 2.4"; hasScannedForEncodings = 1; mainGroup = 0000000000000000164109E0; projectDirPath = ""; + projectRoot = ""; targets = ( B6CBAD510A5F3C2900F826D6 /* spectrum Framework */, ); @@ -353,11 +355,10 @@ B69A010E0A5F3BF500EEA5ED /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_VERSION = 4.0; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Development; @@ -365,12 +366,11 @@ B69A010F0A5F3BF500EEA5ED /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; + GCC_VERSION = 4.0; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Deployment; @@ -378,11 +378,10 @@ B69A01100A5F3BF500EEA5ED /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = ( - i386, - ppc, - ); + ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DEBUG_INFORMATION_FORMAT = dwarf; + GCC_VERSION = 4.0; SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; }; name = Default; @@ -425,11 +424,10 @@ OTHER_LDFLAGS = ( "-lbz2", "-lz", - "-seg1addr", - 0x10000000, ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = spectrum; SECTORDER_FLAGS = ""; @@ -476,11 +474,10 @@ OTHER_LDFLAGS = ( "-lbz2", "-lz", - "-seg1addr", - 0x10000000, ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = spectrum; SECTORDER_FLAGS = ""; @@ -525,11 +522,10 @@ OTHER_LDFLAGS = ( "-lbz2", "-lz", - "-seg1addr", - 0x10000000, ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; + PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = spectrum; SECTORDER_FLAGS = ""; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2009-06-29 22:25:17
|
Revision: 601 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=601&view=rev Author: fredm Date: 2009-06-29 22:23:59 +0000 (Mon, 29 Jun 2009) Log Message: ----------- Merge up to vendor revision 4041. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=4041&view=rev Modified Paths: -------------- trunk/FuseGenerator/generate.pl trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/generate.pl trunk/FuseImporter/libspectrum.h trunk/fuse/AUTHORS trunk/fuse/ChangeLog trunk/fuse/Makefile.am trunk/fuse/README trunk/fuse/TODO trunk/fuse/ay.c trunk/fuse/ay.h trunk/fuse/compat/Makefile.am trunk/fuse/compat/amiga/Makefile.am trunk/fuse/compat/amiga/paths.c trunk/fuse/compat/morphos/Makefile.am trunk/fuse/compat/morphos/osname.c trunk/fuse/compat/unix/Makefile.am trunk/fuse/compat/unix/file.c trunk/fuse/compat/unix/osname.c trunk/fuse/compat/unix/paths.c trunk/fuse/compat/wii/Makefile.am trunk/fuse/compat/win32/Makefile.am trunk/fuse/compat/win32/osname.c trunk/fuse/compat/win32/paths.c trunk/fuse/compat.h trunk/fuse/configure.in trunk/fuse/debugger/event.c trunk/fuse/debugger/variable.c trunk/fuse/disk/beta.c trunk/fuse/disk/beta.h trunk/fuse/disk/disk.c trunk/fuse/disk/disk.h trunk/fuse/disk/fdd.c trunk/fuse/disk/fdd.h trunk/fuse/disk/plusd.c trunk/fuse/disk/plusd.h trunk/fuse/disk/upd_fdc.c trunk/fuse/display.c trunk/fuse/display.h trunk/fuse/event.c trunk/fuse/event.h trunk/fuse/fuse.c trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/Makefile trunk/fuse/fusepb/controllers/FuseController.h trunk/fuse/fusepb/controllers/FuseController.m trunk/fuse/fusepb/controllers/PreferencesController.h trunk/fuse/fusepb/controllers/PreferencesController.m trunk/fuse/fusepb/models/Emulator.h trunk/fuse/fusepb/models/Emulator.m trunk/fuse/fusepb/nibs/MainMenu.nib/classes.nib trunk/fuse/fusepb/nibs/MainMenu.nib/info.nib trunk/fuse/fusepb/nibs/MainMenu.nib/keyedobjects.nib trunk/fuse/fusepb/nibs/Preferences.nib/designable.nib trunk/fuse/fusepb/nibs/Preferences.nib/keyedobjects.nib trunk/fuse/fusepb/timer/timer.c trunk/fuse/fusepb/views/DisplayOpenGLView.h trunk/fuse/fusepb/views/DisplayOpenGLView.m trunk/fuse/hacking/ChangeLog trunk/fuse/hacking/Makefile.am trunk/fuse/hacking/cvs-tags trunk/fuse/hacking/timer.txt trunk/fuse/input.c trunk/fuse/joystick.c trunk/fuse/joystick.h trunk/fuse/kempmouse.c trunk/fuse/keysyms.pl trunk/fuse/loader.c trunk/fuse/machine.c trunk/fuse/machines/pentagon.c trunk/fuse/machines/pentagon1024.c trunk/fuse/machines/pentagon512.c trunk/fuse/machines/scorpion.c trunk/fuse/machines/spec128.c trunk/fuse/machines/spec16.c trunk/fuse/machines/spec48.c trunk/fuse/machines/spec48.h trunk/fuse/machines/spec_se.c trunk/fuse/machines/specplus2.c trunk/fuse/machines/specplus2a.c trunk/fuse/machines/specplus3.c trunk/fuse/machines/specplus3.h trunk/fuse/machines/specplus3e.c trunk/fuse/machines/tc2048.c trunk/fuse/machines/tc2068.c trunk/fuse/machines/tc2068.h trunk/fuse/man/fuse.1 trunk/fuse/memory.c trunk/fuse/memory.h trunk/fuse/mempool.c trunk/fuse/mempool.h trunk/fuse/menu.c trunk/fuse/menu.h trunk/fuse/menu_data.dat trunk/fuse/menu_data.pl trunk/fuse/periph.c trunk/fuse/periph.h trunk/fuse/perl/cpp-perl.pl trunk/fuse/rzx.c trunk/fuse/scld.c trunk/fuse/settings.dat trunk/fuse/settings.pl trunk/fuse/snapshot.c trunk/fuse/sound/Makefile.am trunk/fuse/sound/alsasound.c trunk/fuse/sound/coreaudiosound.c trunk/fuse/sound/sdlsound.c trunk/fuse/sound.h trunk/fuse/spectrum.c trunk/fuse/tape.c trunk/fuse/timer/Makefile.am trunk/fuse/timer/sdl.c trunk/fuse/timer/timer.c trunk/fuse/timer/timer.h trunk/fuse/ui/Makefile.am trunk/fuse/ui/cocoa/cocoaui.m trunk/fuse/ui/fb/Makefile.am trunk/fuse/ui/fb/fbdisplay.c trunk/fuse/ui/gtk/Makefile.am trunk/fuse/ui/gtk/confirm.c trunk/fuse/ui/gtk/debugger.c trunk/fuse/ui/gtk/gtkdisplay.c trunk/fuse/ui/gtk/gtkinternals.h trunk/fuse/ui/gtk/gtkui.c trunk/fuse/ui/gtk/options-header.pl trunk/fuse/ui/gtk/options.pl trunk/fuse/ui/gtk/pokefinder.c trunk/fuse/ui/options.dat trunk/fuse/ui/scaler/scaler_hq2x.c trunk/fuse/ui/scaler/scaler_hq3x.c trunk/fuse/ui/svga/svgadisplay.c trunk/fuse/ui/svga/svgajoystick.c trunk/fuse/ui/svga/svgaui.c trunk/fuse/ui/ui.h trunk/fuse/ui/uijoystick.c trunk/fuse/ui/widget/Makefile.am trunk/fuse/ui/widget/debugger.c trunk/fuse/ui/widget/filesel.c trunk/fuse/ui/widget/menu.c trunk/fuse/ui/widget/options-header.pl trunk/fuse/ui/widget/options.pl trunk/fuse/ui/widget/query.c trunk/fuse/ui/widget/select.c trunk/fuse/ui/widget/text.c trunk/fuse/ui/widget/widget.c trunk/fuse/ui/widget/widget.h trunk/fuse/ui/widget/widget_internals.h trunk/fuse/ui/win32/Makefile.am trunk/fuse/ui/win32/confirm.c trunk/fuse/ui/win32/debugger.c trunk/fuse/ui/win32/fileselector.c trunk/fuse/ui/win32/icons/Makefile.am trunk/fuse/ui/win32/memorybrowser.c trunk/fuse/ui/win32/memorybrowser.h trunk/fuse/ui/win32/memorybrowser.rc trunk/fuse/ui/win32/options-header.pl trunk/fuse/ui/win32/options-resource.pl trunk/fuse/ui/win32/pokefinder.c trunk/fuse/ui/win32/rollback.c trunk/fuse/ui/win32/rollback.h trunk/fuse/ui/win32/rollback.rc trunk/fuse/ui/win32/roms.c trunk/fuse/ui/win32/roms.h trunk/fuse/ui/win32/roms.rc trunk/fuse/ui/win32/win32joystick.c trunk/fuse/ui/win32/win32ui.c trunk/fuse/ui.c trunk/fuse/ula.c trunk/fuse/utils.c trunk/fuse/utils.h trunk/fuse/z80/coretest.c trunk/fuse/z80/z80.c trunk/fuse/z80/z80_ops.c trunk/libspectrum/generate.pl trunk/libspectrum/libspectrum/AUTHORS trunk/libspectrum/libspectrum/ChangeLog trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/README trunk/libspectrum/libspectrum/accessor.pl trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/doc/cvs-tags trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/libspectrum.c trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/make-perl.c trunk/libspectrum/libspectrum/myglib/gslist.c trunk/libspectrum/libspectrum/sna.c trunk/libspectrum/libspectrum/snap_accessors.txt trunk/libspectrum/libspectrum/snapshot.c trunk/libspectrum/libspectrum/szx.c trunk/libspectrum/libspectrum/tape.c trunk/libspectrum/libspectrum/tape_block.c trunk/libspectrum/libspectrum/test/Makefile.am trunk/libspectrum/libspectrum/timings.c trunk/libspectrum/libspectrum/tzx_write.c trunk/libspectrum/libspectrum/warajevo_read.c trunk/libspectrum/libspectrum/z80.c trunk/libspectrum/libspectrum.h Added Paths: ----------- trunk/fuse/compat/unix/dir.c trunk/fuse/compat/unix/timer.c trunk/fuse/compat/wii/dir.c trunk/fuse/compat/wii/osname.c trunk/fuse/compat/wii/paths.c trunk/fuse/compat/wii/timer.c trunk/fuse/compat/win32/timer.c trunk/fuse/fuller.c trunk/fuse/fuller.h trunk/fuse/fusepb/main.mm trunk/fuse/ide/ trunk/fuse/ide/Makefile.am trunk/fuse/ide/divide.c trunk/fuse/ide/divide.h trunk/fuse/ide/ide.c trunk/fuse/ide/ide.h trunk/fuse/ide/simpleide.c trunk/fuse/ide/simpleide.h trunk/fuse/ide/zxatasp.c trunk/fuse/ide/zxatasp.h trunk/fuse/ide/zxcf.c trunk/fuse/ide/zxcf.h trunk/fuse/melodik.c trunk/fuse/melodik.h trunk/fuse/sound/Blip_Buffer.cpp trunk/fuse/sound/Blip_Buffer.h trunk/fuse/sound/wiisound.c trunk/fuse/sound.cpp trunk/fuse/timer/native.c trunk/fuse/ui/cocoa/options-cocoa-header.pl trunk/fuse/ui/cocoa/options-header.pl trunk/fuse/ui/cocoa/options.pl trunk/fuse/ui/wii/ trunk/fuse/ui/wii/Makefile.am trunk/fuse/ui/wii/wiidisplay.c trunk/fuse/ui/wii/wiidisplay.h trunk/fuse/ui/wii/wiijoystick.c trunk/fuse/ui/wii/wiikeyboard.c trunk/fuse/ui/wii/wiikeyboard.h trunk/fuse/ui/wii/wiikeysyms.h trunk/fuse/ui/wii/wiimouse.c trunk/fuse/ui/wii/wiimouse.h trunk/fuse/ui/wii/wiiui.c trunk/fuse/ui/win32/installer/ trunk/fuse/ui/win32/installer/Makefile.am trunk/fuse/ui/win32/installer/fuse.nsi Removed Paths: ------------- trunk/fuse/compat/wii/file.c trunk/fuse/divide.c trunk/fuse/divide.h trunk/fuse/fuse.cpp trunk/fuse/fusepb/main.m trunk/fuse/ide/Makefile.am trunk/fuse/ide/divide.c trunk/fuse/ide/divide.h trunk/fuse/ide/ide.c trunk/fuse/ide/ide.h trunk/fuse/ide/simpleide.c trunk/fuse/ide/simpleide.h trunk/fuse/ide/zxatasp.c trunk/fuse/ide/zxatasp.h trunk/fuse/ide/zxcf.c trunk/fuse/ide/zxcf.h trunk/fuse/ide.c trunk/fuse/ide.h trunk/fuse/simpleide.c trunk/fuse/simpleide.h trunk/fuse/sound.c trunk/fuse/timer/unix.c trunk/fuse/timer/win32.c trunk/fuse/ui/wii/Makefile.am trunk/fuse/ui/wii/wiidisplay.c trunk/fuse/ui/wii/wiidisplay.h trunk/fuse/ui/wii/wiijoystick.c trunk/fuse/ui/wii/wiikeyboard.c trunk/fuse/ui/wii/wiikeyboard.h trunk/fuse/ui/wii/wiikeysyms.h trunk/fuse/ui/wii/wiimouse.c trunk/fuse/ui/wii/wiimouse.h trunk/fuse/ui/wii/wiiui.c trunk/fuse/ui/win32/installer/Makefile.am trunk/fuse/ui/win32/installer/fuse.nsi trunk/fuse/zxatasp.c trunk/fuse/zxatasp.h trunk/fuse/zxcf.c trunk/fuse/zxcf.h Property Changed: ---------------- trunk/fuse/ trunk/fuse/fusepb/ trunk/libspectrum/libspectrum/ trunk/libspectrum/libspectrum.h Modified: trunk/FuseGenerator/generate.pl =================================================================== --- trunk/FuseGenerator/generate.pl 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/FuseGenerator/generate.pl 2009-06-29 22:23:59 UTC (rev 601) @@ -75,6 +75,10 @@ void WIN32_DLL g_slist_free (GSList *list); +GSList WIN32_DLL *g_slist_last (GSList *list); + +GSList WIN32_DLL *g_slist_reverse (GSList *list); + GSList WIN32_DLL *g_slist_nth (GSList *list, guint n); Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/FuseGenerator/libspectrum.h 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3806 2008-11-08 10:42:38Z pak21 $ + $Id: libspectrum.h.in 4039 2009-06-27 06:04:44Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -134,6 +134,10 @@ void WIN32_DLL g_slist_free (GSList *list); +GSList WIN32_DLL *g_slist_last (GSList *list); + +GSList WIN32_DLL *g_slist_reverse (GSList *list); + GSList WIN32_DLL *g_slist_nth (GSList *list, guint n); @@ -801,6 +805,11 @@ void WIN32_DLL libspectrum_snap_set_divide_eprom( libspectrum_snap *snap, int idx, libspectrum_byte* divide_eprom ); libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_ram( libspectrum_snap *snap, int idx, libspectrum_byte* divide_ram ); +int WIN32_DLL libspectrum_snap_fuller_box_active( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_fuller_box_active( libspectrum_snap *snap, int fuller_box_active ); +int WIN32_DLL libspectrum_snap_melodik_active( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int + melodik_active ); /* * Tape handling routines @@ -862,6 +871,7 @@ extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LEVEL_HIGH; /* Set level high */ extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_SHORT; extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_LONG; +extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_TAPE; /* Tape has finished */ /* The states which a block can be in */ typedef enum libspectrum_tape_state_type { @@ -1000,6 +1010,10 @@ libspectrum_tape_block WIN32_DLL * libspectrum_tape_peek_next_block( libspectrum_tape *tape ); +/* Peek at the last block on the tape */ +libspectrum_tape_block WIN32_DLL * +libspectrum_tape_peek_last_block( libspectrum_tape *tape ); + /* Cause the next block on the tape to be active, initialise it and return it */ libspectrum_tape_block WIN32_DLL * Modified: trunk/FuseImporter/generate.pl =================================================================== --- trunk/FuseImporter/generate.pl 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/FuseImporter/generate.pl 2009-06-29 22:23:59 UTC (rev 601) @@ -75,6 +75,10 @@ void WIN32_DLL g_slist_free (GSList *list); +GSList WIN32_DLL *g_slist_last (GSList *list); + +GSList WIN32_DLL *g_slist_reverse (GSList *list); + GSList WIN32_DLL *g_slist_nth (GSList *list, guint n); Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/FuseImporter/libspectrum.h 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 3806 2008-11-08 10:42:38Z pak21 $ + $Id: libspectrum.h.in 4039 2009-06-27 06:04:44Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -134,6 +134,10 @@ void WIN32_DLL g_slist_free (GSList *list); +GSList WIN32_DLL *g_slist_last (GSList *list); + +GSList WIN32_DLL *g_slist_reverse (GSList *list); + GSList WIN32_DLL *g_slist_nth (GSList *list, guint n); @@ -801,6 +805,11 @@ void WIN32_DLL libspectrum_snap_set_divide_eprom( libspectrum_snap *snap, int idx, libspectrum_byte* divide_eprom ); libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_divide_ram( libspectrum_snap *snap, int idx, libspectrum_byte* divide_ram ); +int WIN32_DLL libspectrum_snap_fuller_box_active( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_fuller_box_active( libspectrum_snap *snap, int fuller_box_active ); +int WIN32_DLL libspectrum_snap_melodik_active( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int + melodik_active ); /* * Tape handling routines @@ -862,6 +871,7 @@ extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LEVEL_HIGH; /* Set level high */ extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_SHORT; extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_LONG; +extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_TAPE; /* Tape has finished */ /* The states which a block can be in */ typedef enum libspectrum_tape_state_type { @@ -1000,6 +1010,10 @@ libspectrum_tape_block WIN32_DLL * libspectrum_tape_peek_next_block( libspectrum_tape *tape ); +/* Peek at the last block on the tape */ +libspectrum_tape_block WIN32_DLL * +libspectrum_tape_peek_last_block( libspectrum_tape *tape ); + /* Cause the next block on the tape to be active, initialise it and return it */ libspectrum_tape_block WIN32_DLL * Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-538 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-600 Modified: trunk/fuse/AUTHORS =================================================================== --- trunk/fuse/AUTHORS 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/AUTHORS 2009-06-29 22:23:59 UTC (rev 601) @@ -41,6 +41,8 @@ * Gergely Szasz: Interface I/microdrive emulation, the 'movie' code and the ao sound driver. +* Bjoern Giesler: the original Wii port. + * Philip Kendall: everything else. -$Id: AUTHORS 2433 2004-11-28 21:58:44Z pak21 $ +$Id: AUTHORS 3944 2009-01-10 18:17:04Z pak21 $ Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/ChangeLog 2009-06-29 22:23:59 UTC (rev 601) @@ -1,5 +1,15 @@ -2008-11-?? Philip Kendall <phi...@sh...> +2008-12-10 Philip Kendall <phi...@sh...> + * Fuse 0.10.0.1 released + + * Writing files would not truncate the file at the correct point, + leading to corrupt files when overwriting an existing file + (Philip Kendall; thanks, Matthew Westcott). + + * Distribute ui/fb/fbmouse.h (Fredrick Meunier; thanks, rkd77). + +2008-12-03 Philip Kendall <phi...@sh...> + * Fuse 0.10.0 released * New upd765 FDC emulation; all known +3 DSK images now work (Gergely @@ -931,4 +941,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 3823 2008-11-16 17:32:18Z pak21 $ +$Id: ChangeLog 3900 2008-12-10 19:31:31Z pak21 $ Modified: trunk/fuse/Makefile.am =================================================================== --- trunk/fuse/Makefile.am 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/Makefile.am 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ # Process this file with automake to produce Makefile.in -## Copyright (c) 1999-2008 Philip Kendall +## Copyright (c) 1999-2009 Philip Kendall -## $Id: Makefile.am 3818 2008-11-15 13:28:08Z pak21 $ +## $Id: Makefile.am 4032 2009-06-10 11:09:44Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -29,6 +29,7 @@ debugger \ disk \ hacking \ + ide \ lib \ machines \ man \ @@ -44,6 +45,7 @@ DIST_SUBDIRS = debugger \ disk \ hacking \ + ide \ lib \ machines \ man \ @@ -59,10 +61,9 @@ fuse_SOURCES = ay.c \ dck.c \ display.c \ - divide.c \ event.c \ - fuse.cpp \ - ide.c \ + fuller.c \ + fuse.c \ if1.c \ if2.c \ input.c \ @@ -71,6 +72,7 @@ keyboard.c \ loader.c \ machine.c \ + melodik.c \ memory.c \ mempool.c \ menu.c \ @@ -83,19 +85,16 @@ scld.c \ screenshot.c \ settings.c \ - simpleide.c \ slt.c \ snapshot.c \ - sound.c \ + sound.cpp \ spectrum.c \ tape.c \ ui.c \ uidisplay.c \ ula.c \ utils.c \ - windres.rc \ - zxatasp.c \ - zxcf.c + windres.rc if COMPAT_DIRNAME fuse_SOURCES += compat/dirname.c @@ -113,36 +112,42 @@ fuse_LDADD = debugger/libdebugger.a \ @UI_LIBS@ \ +debugger/libdebugger.a \ +disk/libdisk.a \ +ide/libide.a \ machines/libmachines.a \ -disk/libdisk.a \ pokefinder/libpokefinder.a \ sound/libsound.a \ +timer/libtimer.a \ ui/scaler/libscaler.a \ unittests/libunittests.a \ -debugger/libdebugger.a \ -timer/libtimer.a \ z80/libz80.a \ @LIBSPEC_LIBS@ \ @GLIB_LIBS@ \ @PNG_LIBS@ \ @SOUND_LIBS@ \ -@SAMPLERATE_LIBS@ \ @SDL_LIBS@ \ @X_LIBS@ \ @XML_LIBS@ \ compat/@COMPAT_OSNAME@/libcompatos.a \ @WINDRES_OBJ@ -fuse_DEPENDENCIES = @UI_LIBS@ \ - disk/libdisk.a \ - debugger/libdebugger.a \ - machines/libmachines.a \ - sound/libsound.a \ - unittests/libunittests.a\ - z80/libz80.a \ - @WINDRES_OBJ@ +fuse_DEPENDENCIES = debugger/libdebugger.a \ +@UI_LIBS@ \ +debugger/libdebugger.a \ +disk/libdisk.a \ +ide/libide.a \ +machines/libmachines.a \ +pokefinder/libpokefinder.a \ +sound/libsound.a \ +timer/libtimer.a \ +ui/scaler/libscaler.a \ +unittests/libunittests.a \ +z80/libz80.a \ +compat/@COMPAT_OSNAME@/libcompatos.a \ +@WINDRES_OBJ@ -BUILT_SOURCES = settings.c settings.h +BUILT_SOURCES = options.h settings.c settings.h windres.o: windres.rc winfuse.ico @WINDRES@ -I$(srcdir) -I. $(srcdir)/windres.rc windres.o @@ -153,18 +158,25 @@ settings.h: settings-header.pl settings.dat @PERL@ -I$(srcdir)/perl $(srcdir)/settings-header.pl $(srcdir)/settings.dat > $@.tmp && mv $@.tmp $@ +if WIDGET +options.h: $(srcdir)/perl/cpp-perl.pl config.h $(srcdir)/ui/@WIDGET@/options-header.pl $(srcdir)/ui/options.dat $(srcdir)/perl/Fuse.pm $(srcdir)/perl/Fuse/Dialog.pm + @PERL@ $(srcdir)/perl/cpp-perl.pl config.h $(srcdir)/ui/options.dat | @PERL@ -I$(srcdir)/perl $(srcdir)/ui/@WIDGET@/options-header.pl - public > $@.tmp && mv $@.tmp $@ +else +options.h: $(srcdir)/perl/cpp-perl.pl config.h $(srcdir)/ui/@UI@/options-header.pl $(srcdir)/ui/options.dat $(srcdir)/perl/Fuse.pm $(srcdir)/perl/Fuse/Dialog.pm + @PERL@ $(srcdir)/perl/cpp-perl.pl config.h $(srcdir)/ui/options.dat | @PERL@ -I$(srcdir)/perl $(srcdir)/ui/@UI@/options-header.pl - public > $@.tmp && mv $@.tmp $@ +endif + INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ \ -@XML_CFLAGS@ @SAMPLERATE_CFLAGS@ -DFUSEDATADIR="\"${pkgdatadir}\"" @SDL_CFLAGS@ +@XML_CFLAGS@ -DFUSEDATADIR="\"${pkgdatadir}\"" @SDL_CFLAGS@ noinst_HEADERS = ay.h \ bitmap.h \ compat.h \ dck.h \ display.h \ - divide.h \ event.h \ + fuller.h \ fuse.h \ - ide.h \ if1.h \ if2.h \ input.h \ @@ -172,6 +184,7 @@ kempmouse.h \ loader.h \ machine.h \ + melodik.h \ memory.h \ mempool.h \ menu.h \ @@ -181,7 +194,6 @@ rzx.h \ screenshot.h \ settings.h \ - simpleide.h \ slt.h \ snapshot.h \ sound.h \ @@ -189,12 +201,11 @@ tape.h \ utils.h \ joystick.h \ + options.h \ printer.h \ profile.h \ scld.h \ - ula.h \ - zxatasp.h \ - zxcf.h + ula.h EXTRA_DIST = AUTHORS \ README \ @@ -208,7 +219,8 @@ settings.dat \ winfuse.ico -CLEANFILES = settings.c \ +CLEANFILES = options.h \ + settings.c \ settings.h AM_CPPFLAGS = Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/README 2009-06-29 22:23:59 UTC (rev 601) @@ -1,5 +1,5 @@ -The Free Unix Spectrum Emulator (Fuse) 0.10.0 -============================================= +The Free Unix Spectrum Emulator (Fuse) 0.10.0.1 +=============================================== Fuse (the Free Unix Spectrum Emulator) was originally, and somewhat unsurprisingly, an emulator of the ZX Spectrum (a popular 1980s home @@ -55,8 +55,6 @@ * libpng: the ability to save screenshots * libxml2: the ability to load and save Fuse's current configuration * zlib: support for compressed RZX files - * samplerate: support for better beeper sound quality; get it from - http://www.mega-nerd.com/SRC/ If you've used Fuse prior to version 0.5.0, note that the external utilities (tzxlist, etc) are now available separately from Fuse @@ -123,6 +121,36 @@ The native Cocoa port by Fredrick Meunier <fr...@sp...> comes as a set of Xcode projects for libgcrypt, libspectrum and Fuse itself. +Building the Wii version of Fuse +-------------------------------- + +You'll need to have the standard Wii homebrew toolchain installed; see +eg <http://wiibrew.org/wiki/DevkitPro> for some information on setting +this up. + +After that, make sure the dev tools are in your path (export +PATH=$PATH:$DEVKITPPC/bin) and that a Wii version of libspectrum has been +built and installed. + +Then, use this configure line: + +./configure --target=powerpc-gekko --host=powerpc-gekko \ + --with-wii \ + --without-libxml2 --without-libiconv --without-gpm \ + --without-x --without-glib \ + CFLAGS="-g -I$DEVKITPPC/include -I$DEVKITPRO/libogc/include" \ + LDFLAGS="-g -mrvl -mcpu=750 -meabi -mhard-float \ + -Wl,-Map,fuse.elf.map -L$DEVKITPPC/lib \ + -L$DEVKITPRO/libogc/lib/wii" \ + LIBS="-lfat -lwiiuse -lbte -logc -lm" + +Finally, to build, use this line: + +EXEEXT=".elf" make -e + +This should build fuse.elf, which you can run on your Wii via the usual +methods. + Closing comments ---------------- @@ -150,6 +178,6 @@ ( http://www.worldofspectrum.org/faq/index.html ) first! Philip Kendall <phi...@sh...> -3 December 2008 +10 December 2008 -$Id: README 3866 2008-11-29 17:05:40Z pak21 $ +$Id: README 4021 2009-05-29 13:39:51Z fredm $ Modified: trunk/fuse/TODO =================================================================== --- trunk/fuse/TODO 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/TODO 2009-06-29 22:23:59 UTC (rev 601) @@ -1,16 +1,12 @@ TODO * Pentagon port #ff returning floating bus issues - it does it because the RusFAQ says so? -* Timex 2068 fusetests -* Console mode GUI -* Add "proper" preferences window +* Collapse Media hierarchy, just have Tape, Disk A, Disk B, Master, Slave, Microdrive 1..4 etc. * Add TITLE tags to help files? * SZX ZX Printer block? * PAL Compsite emulation * Separate out sound buffer interleaving code to allow for the use of hardware etc. sound mixing -* Add volume option to standard fuse + a sound API method to set volume (or a - parameter to sound_lowlevel_init) * Randomise FRAMES sys var after autoload snapshot loaded in order to try and get less deterministic program behaviour after load is complete * Use sheets rather than modal dialogs (for Save As) @@ -18,7 +14,6 @@ * Make border display optional * Make activity icons transparent * SZX +3 block - seems to be redundant? -* Add pause function * Add QuickLook HTML view showing Title, etc. like QuickLook on MP3s $Id: TODO 2026 2004-03-02 13:38:08Z pak21 $ Modified: trunk/fuse/ay.c =================================================================== --- trunk/fuse/ay.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/ay.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* ay.c: AY-8-3912 routines - Copyright (c) 1999-2004 Philip Kendall + Copyright (c) 1999-2009 Philip Kendall - $Id: ay.c 3494 2008-01-15 16:37:50Z pak21 $ + $Id: ay.c 4030 2009-06-07 14:38:38Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -131,22 +131,26 @@ if( current == 14 ) printer_serial_write( b ); } -static void -ay_from_snapshot( libspectrum_snap *snap ) +void +ay_state_from_snapshot( libspectrum_snap *snap ) { size_t i; - if( machine_current->capabilities & LIBSPECTRUM_MACHINE_CAPABILITY_AY ) { + ay_registerport_write( 0xfffd, + libspectrum_snap_out_ay_registerport( snap ) ); - ay_registerport_write( 0xfffd, - libspectrum_snap_out_ay_registerport( snap ) ); + for( i = 0; i < AY_REGISTERS; i++ ) { + machine_current->ay.registers[i] = + libspectrum_snap_ay_registers( snap, i ); + sound_ay_write( i, machine_current->ay.registers[i], 0 ); + } +} - for( i = 0; i < AY_REGISTERS; i++ ) { - machine_current->ay.registers[i] = - libspectrum_snap_ay_registers( snap, i ); - sound_ay_write( i, machine_current->ay.registers[i], 0 ); - } - +static void +ay_from_snapshot( libspectrum_snap *snap ) +{ + if( machine_current->capabilities & LIBSPECTRUM_MACHINE_CAPABILITY_AY ) { + ay_state_from_snapshot( snap ); } } Modified: trunk/fuse/ay.h =================================================================== --- trunk/fuse/ay.h 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/ay.h 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* ay.h: AY-8-3912 routines - Copyright (c) 1999-2004 Philip Kendall + Copyright (c) 1999-2009 Philip Kendall - $Id: ay.h 2993 2007-06-17 13:54:49Z pak21 $ + $Id: ay.h 4030 2009-06-07 14:38:38Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -42,4 +42,6 @@ void ay_dataport_write( libspectrum_word port, libspectrum_byte b ); +void ay_state_from_snapshot( libspectrum_snap *snap ); + #endif /* #ifndef FUSE_AY_H */ Modified: trunk/fuse/compat/Makefile.am =================================================================== --- trunk/fuse/compat/Makefile.am 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/Makefile.am 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2003-2007 Philip Kendall -## $Id: Makefile.am 3283 2007-11-09 12:21:06Z fredm $ +## $Id: Makefile.am 3944 2009-01-10 18:17:04Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -26,6 +26,7 @@ DIST_SUBDIRS += compat/amiga \ compat/morphos \ compat/unix \ + compat/wii \ compat/win32 EXTRA_fuse_SOURCES += compat/dirname.c \ Modified: trunk/fuse/compat/amiga/Makefile.am =================================================================== --- trunk/fuse/compat/amiga/Makefile.am 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/amiga/Makefile.am 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ +## $Id: Makefile.am 3935 2009-01-07 12:55:13Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,8 +27,10 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = ../unix/file.c \ +libcompatos_a_SOURCES = ../unix/dir.c \ + ../unix/file.c \ osname.c \ - paths.c + paths.c \ + ../unix/timer.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Modified: trunk/fuse/compat/amiga/paths.c =================================================================== --- trunk/fuse/compat/amiga/paths.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/amiga/paths.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* paths.c: Path-related compatibility routines Copyright (c) 1999-2007 Philip Kendall - $Id: paths.c 3844 2008-11-19 21:31:07Z fredm $ + $Id: paths.c 3843 2008-11-19 21:27:03Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/compat/morphos/Makefile.am =================================================================== --- trunk/fuse/compat/morphos/Makefile.am 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/morphos/Makefile.am 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ +## $Id: Makefile.am 3935 2009-01-07 12:55:13Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,8 +27,10 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = ../unix/file.c \ +libcompatos_a_SOURCES = ../unix/dir.c \ + ../unix/file.c \ osname.c \ - ../amiga/paths.c + ../amiga/paths.c \ + ../unix/timer.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Modified: trunk/fuse/compat/morphos/osname.c =================================================================== --- trunk/fuse/compat/morphos/osname.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/morphos/osname.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* osname.c: Get a representation of the OS we're running on Copyright (c) 1999-2007 Philip Kendall - $Id: osname.c 3139 2007-09-03 10:27:57Z fredm $ + $Id: osname.c 3922 2008-12-31 19:01:31Z zubzero $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/compat/unix/Makefile.am =================================================================== --- trunk/fuse/compat/unix/Makefile.am 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/unix/Makefile.am 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ +## $Id: Makefile.am 3935 2009-01-07 12:55:13Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,8 +27,10 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = file.c \ +libcompatos_a_SOURCES = dir.c \ + file.c \ osname.c \ - paths.c + paths.c \ + timer.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Copied: trunk/fuse/compat/unix/dir.c (from rev 600, vendor/fuse-emulator/current/fuse/compat/unix/dir.c) =================================================================== --- trunk/fuse/compat/unix/dir.c (rev 0) +++ trunk/fuse/compat/unix/dir.c 2009-06-29 22:23:59 UTC (rev 601) @@ -0,0 +1,63 @@ +/* dir.c: Directory-related compatibility routines + Copyright (c) 2009 Philip Kendall + + $Id: dir.c 3945 2009-01-10 18:44:42Z zubzero $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include <errno.h> +#include <string.h> + +#include "compat.h" + +compat_dir +compat_opendir( const char *path ) +{ + return opendir( path ); +} + +compat_dir_result_t +compat_readdir( compat_dir directory, char *name, size_t length ) +{ + compat_dir_result_t r; + struct dirent *dirent; + + errno = 0; + dirent = readdir( directory ); + + if( dirent ) { + r = COMPAT_DIR_RESULT_OK; + strncpy( name, dirent->d_name, length ); + name[ length - 1 ] = 0; + } else { + r = ( errno == 0 ? COMPAT_DIR_RESULT_END : COMPAT_DIR_RESULT_ERROR ); + } + + return r; +} + +int +compat_closedir( compat_dir directory ) +{ + return closedir( directory ); +} Modified: trunk/fuse/compat/unix/file.c =================================================================== --- trunk/fuse/compat/unix/file.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/unix/file.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* file.c: File-related compatibility routines Copyright (c) 2008 Philip Kendall - $Id: file.c 3776 2008-10-06 00:49:45Z fredm $ + $Id: file.c 4040 2009-06-27 09:32:42Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -33,22 +33,15 @@ #include <unistd.h> #include "compat.h" +#include "utils.h" #include "ui/ui.h" -/* Certain brain damaged operating systems (DOS/Windows) treat text - and binary files different in open(2) and need to be given the - O_BINARY flag to tell them it's a binary file */ -#ifndef O_BINARY -#define O_BINARY 0 -#endif /* #ifndef O_BINARY */ +const compat_fd COMPAT_FILE_OPEN_FAILED = NULL; -const compat_fd COMPAT_FILE_OPEN_FAILED = -1; - compat_fd compat_file_open( const char *path, int write ) { - int flags = write ? O_WRONLY | O_CREAT | O_BINARY : O_RDONLY | O_BINARY; - return open( path, flags, 0666 ); + return fopen( path, write ? "w" : "r" ); } off_t @@ -56,7 +49,7 @@ { struct stat file_info; - if( fstat( fd, &file_info ) ) { + if( fstat( fileno( fd ), &file_info ) ) { ui_error( UI_ERROR_ERROR, "couldn't stat file: %s", strerror( errno ) ); return -1; } @@ -67,15 +60,11 @@ int compat_file_read( compat_fd fd, utils_file *file ) { - ssize_t bytes = read( fd, file->buffer, file->length ); + size_t bytes = fread( file->buffer, 1, file->length, fd ); if( bytes != file->length ) { - if( bytes == -1 ) { - ui_error( UI_ERROR_ERROR, "error reading file: %s", strerror( errno ) ); - } else { - ui_error( UI_ERROR_ERROR, - "error reading file: expected %ld bytes, but read only %ld", - (unsigned long)file->length, (unsigned long)bytes ); - } + ui_error( UI_ERROR_ERROR, + "error reading file: expected %lu bytes, but read only %lu", + file->length, bytes ); return 1; } @@ -85,15 +74,11 @@ int compat_file_write( compat_fd fd, const unsigned char *buffer, size_t length ) { - ssize_t bytes = write( fd, buffer, length ); + size_t bytes = fwrite( buffer, 1, length, fd ); if( bytes != length ) { - if( bytes == -1 ) { - ui_error( UI_ERROR_ERROR, "error writing file: %s", strerror( errno ) ); - } else { - ui_error( UI_ERROR_ERROR, - "error writing file: expected %ld bytes, but wrote only %ld", - (unsigned long)length, (unsigned long)bytes ); - } + ui_error( UI_ERROR_ERROR, + "error writing file: expected %lu bytes, but wrote only %lu", + length, bytes ); return 1; } @@ -103,5 +88,5 @@ int compat_file_close( compat_fd fd ) { - return close( fd ); + return fclose( fd ); } Modified: trunk/fuse/compat/unix/osname.c =================================================================== --- trunk/fuse/compat/unix/osname.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/unix/osname.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* osname.c: Get a representation of the OS we're running on Copyright (c) 1999-2007 Philip Kendall - $Id: osname.c 3626 2008-05-23 10:30:30Z pak21 $ + $Id: osname.c 3922 2008-12-31 19:01:31Z zubzero $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/compat/unix/paths.c =================================================================== --- trunk/fuse/compat/unix/paths.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/unix/paths.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* paths.c: Path-related compatibility routines Copyright (c) 1999-2007 Philip Kendall - $Id: paths.c 3253 2007-10-26 02:02:17Z zubzero $ + $Id: paths.c 3922 2008-12-31 19:01:31Z zubzero $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Copied: trunk/fuse/compat/unix/timer.c (from rev 600, vendor/fuse-emulator/current/fuse/compat/unix/timer.c) =================================================================== --- trunk/fuse/compat/unix/timer.c (rev 0) +++ trunk/fuse/compat/unix/timer.c 2009-06-29 22:23:59 UTC (rev 601) @@ -0,0 +1,55 @@ +/* timer.c: UNIX speed routines for Fuse + Copyright (c) 1999-2008 Philip Kendall, Marek Januszewski, Fredrick Meunier + + $Id: timer.c 3982 2009-02-11 12:00:22Z fredm $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include <errno.h> +#include <string.h> +#include <sys/time.h> +#include <unistd.h> + +#include "compat.h" +#include "ui/ui.h" + +double +compat_timer_get_time( void ) +{ + struct timeval tv; + int error; + + error = gettimeofday( &tv, NULL ); + if( error ) { + ui_error( UI_ERROR_ERROR, "%s: error getting time: %s", __func__, strerror( errno ) ); + return -1; + } + + return tv.tv_sec + tv.tv_usec / 1000000.0; +} + +void +compat_timer_sleep( int ms ) +{ + usleep( ms * 1000 ); +} Modified: trunk/fuse/compat/wii/Makefile.am =================================================================== --- trunk/fuse/compat/wii/Makefile.am 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/wii/Makefile.am 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ +## $Id: Makefile.am 4040 2009-06-27 09:32:42Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,8 +27,10 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = file.c \ +libcompatos_a_SOURCES = dir.c \ + ../unix/file.c \ osname.c \ - paths.c + paths.c \ + timer.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Copied: trunk/fuse/compat/wii/dir.c (from rev 600, vendor/fuse-emulator/current/fuse/compat/wii/dir.c) =================================================================== --- trunk/fuse/compat/wii/dir.c (rev 0) +++ trunk/fuse/compat/wii/dir.c 2009-06-29 22:23:59 UTC (rev 601) @@ -0,0 +1,50 @@ +/* dir.c: Directory-related compatibility routines + Copyright (c) 2009 Philip Kendall + + $Id: dir.c 3945 2009-01-10 18:44:42Z zubzero $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include "compat.h" + +compat_dir +compat_opendir( const char *path ) +{ + return diropen( path ); +} + +compat_dir_result_t +compat_readdir( compat_dir directory, char *path, size_t length ) +{ + struct stat fstat; + + int done = dirnext( directory, path, &fstat ); + + return done ? COMPAT_DIR_RESULT_END : COMPAT_DIR_RESULT_OK; +} + +int +compat_closedir( compat_dir directory ) +{ + return dirclose( directory ); +} Deleted: trunk/fuse/compat/wii/file.c =================================================================== --- trunk/fuse/compat/wii/file.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/wii/file.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,90 +0,0 @@ -/* file.c: File-related compatibility routines - Copyright (c) 2008 Philip Kendall - - $Id: file.c 3688 2008-06-23 18:17:56Z pak21 $ - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - Author contact information: - - E-mail: phi...@sh... - -*/ - -#include <config.h> - -#include <errno.h> -#include <fcntl.h> -#include <sys/types.h> -#include <sys/stat.h> -#include <unistd.h> - -#include "compat.h" -#include "ui/ui.h" - -const compat_fd COMPAT_FILE_OPEN_FAILED = NULL; - -compat_fd -compat_file_open( const char *path, int write ) -{ - return fopen( path, write ? "w" : "r" ); -} - -off_t -compat_file_get_length( compat_fd fd ) -{ - struct stat file_info; - - if( fstat( fileno( fd ), &file_info ) ) { - ui_error( UI_ERROR_ERROR, "couldn't stat file: %s", strerror( errno ) ); - return -1; - } - - return file_info.st_size; -} - -int -compat_file_read( compat_fd fd, utils_file *file ) -{ - size_t bytes = fread( file->buffer, 1, file->length, fd ); - if( bytes != file->length ) { - ui_error( UI_ERROR_ERROR, - "error reading file: expected %d bytes, but read only %d", - file->length, bytes ); - return 1; - } - - return 0; -} - -int -compat_file_write( compat_fd fd, const unsigned char *buffer, size_t length ) -{ - size_t bytes = fwrite( buffer, 1, length, fd ); - if( bytes != length ) { - ui_error( UI_ERROR_ERROR, - "error writing file: expected %d bytes, but wrote only %d", - length, bytes ); - return 1; - } - - return 0; -} - -int -compat_file_close( compat_fd fd ) -{ - return fclose( fd ); -} Copied: trunk/fuse/compat/wii/osname.c (from rev 600, vendor/fuse-emulator/current/fuse/compat/wii/osname.c) =================================================================== --- trunk/fuse/compat/wii/osname.c (rev 0) +++ trunk/fuse/compat/wii/osname.c 2009-06-29 22:23:59 UTC (rev 601) @@ -0,0 +1,39 @@ +/* osname.c: Get a representation of the OS we're running on + Copyright (c) 1999-2009 Philip Kendall, Bjoern Giesler + + $Id: osname.c 3945 2009-01-10 18:44:42Z zubzero $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include <errno.h> +#include <stdlib.h> +#include <string.h> + +#include "ui/ui.h" + +int +compat_osname( char *buffer, size_t length ) +{ + snprintf(buffer, length, "Wii"); + return 0; +} Copied: trunk/fuse/compat/wii/paths.c (from rev 600, vendor/fuse-emulator/current/fuse/compat/wii/paths.c) =================================================================== --- trunk/fuse/compat/wii/paths.c (rev 0) +++ trunk/fuse/compat/wii/paths.c 2009-06-29 22:23:59 UTC (rev 601) @@ -0,0 +1,54 @@ +/* paths.c: Path-related compatibility routines + Copyright (c) 1999-2009 Philip Kendall, Bjoern Giesler + + $Id: paths.c 3970 2009-01-19 03:47:02Z specu $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include <stdlib.h> +#include <string.h> + +#include "compat.h" + +const char* +compat_get_temp_path( void ) +{ + return "/tmp"; +} + +const char* +compat_get_home_path( void ) +{ + return "sd:/apps/fuse"; +} + +int +compat_is_absolute_path( const char *path ) +{ + if(strlen(path) >= 1 && path[0] == '/') + return 1; + if(strlen(path) >= strlen("fat:/") && + strncmp(path, "fat:/", strlen("fat:/")) == 0) + return 1; + return 0; +} Copied: trunk/fuse/compat/wii/timer.c (from rev 600, vendor/fuse-emulator/current/fuse/compat/wii/timer.c) =================================================================== --- trunk/fuse/compat/wii/timer.c (rev 0) +++ trunk/fuse/compat/wii/timer.c 2009-06-29 22:23:59 UTC (rev 601) @@ -0,0 +1,57 @@ +/* unix.c: UNIX speed routines for Fuse + Copyright (c) 1999-2007 Philip Kendall, Marek Januszewski, Fredrick Meunier + + $Id: timer.c 3944 2009-01-10 18:17:04Z pak21 $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include <errno.h> +#include <string.h> +#include <unistd.h> + +#include "compat.h" +#include "ui/ui.h" + +/* FIXME: where should we get this prototype from? */ +extern int clock_gettime(struct timespec *tp); + +double +compat_timer_get_time( void ) +{ + int error; + struct timespec tp; + + error = clock_gettime(&tp); + if( error ) { + ui_error( UI_ERROR_ERROR, "%s: error getting time: %s", __func__, strerror( errno ) ); + return -1; + } + + return tp.tv_sec + tp.tv_nsec / 1000000000.0; +} + +void +compat_timer_sleep( int ms ) +{ + usleep( ms * 1000 ); +} Modified: trunk/fuse/compat/win32/Makefile.am =================================================================== --- trunk/fuse/compat/win32/Makefile.am 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/win32/Makefile.am 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007-2008 Philip Kendall -## $Id: Makefile.am 3687 2008-06-23 11:55:23Z pak21 $ +## $Id: Makefile.am 3935 2009-01-07 12:55:13Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -27,8 +27,10 @@ noinst_LIBRARIES = libcompatos.a -libcompatos_a_SOURCES = ../unix/file.c \ +libcompatos_a_SOURCES = ../unix/dir.c \ + ../unix/file.c \ osname.c \ - paths.c + paths.c \ + timer.c INCLUDES = @GLIB_CFLAGS@ @GTK_CFLAGS@ @LIBSPEC_CFLAGS@ Modified: trunk/fuse/compat/win32/osname.c =================================================================== --- trunk/fuse/compat/win32/osname.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/win32/osname.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* osname.c: Get a representation of the OS we're running on Copyright (c) 1999-2007 Philip Kendall - $Id: osname.c 3315 2007-11-20 03:01:59Z zubzero $ + $Id: osname.c 3922 2008-12-31 19:01:31Z zubzero $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/compat/win32/paths.c =================================================================== --- trunk/fuse/compat/win32/paths.c 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat/win32/paths.c 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* paths.c: Path-related compatibility routines Copyright (c) 1999-2007 Philip Kendall - $Id: paths.c 3253 2007-10-26 02:02:17Z zubzero $ + $Id: paths.c 3922 2008-12-31 19:01:31Z zubzero $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Copied: trunk/fuse/compat/win32/timer.c (from rev 600, vendor/fuse-emulator/current/fuse/compat/win32/timer.c) =================================================================== --- trunk/fuse/compat/win32/timer.c (rev 0) +++ trunk/fuse/compat/win32/timer.c 2009-06-29 22:23:59 UTC (rev 601) @@ -0,0 +1,42 @@ +/* timer.c: Win32 speed routines for Fuse + Copyright (c) 1999-2008 Philip Kendall, Marek Januszewski, Fredrick Meunier + + $Id: timer.c 3951 2009-01-12 18:09:42Z specu $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +#include <config.h> + +#include <windows.h> + +#include "compat.h" + +double +compat_timer_get_time( void ) +{ + return GetTickCount() / 1000.0; +} + +void +compat_timer_sleep( int ms ) +{ + Sleep( ms ); +} Modified: trunk/fuse/compat.h =================================================================== --- trunk/fuse/compat.h 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/compat.h 2009-06-29 22:23:59 UTC (rev 601) @@ -1,7 +1,7 @@ /* compat.h: various compatibility bits Copyright (c) 2003-2008 Philip Kendall - $Id: compat.h 3687 2008-06-23 11:55:23Z pak21 $ + $Id: compat.h 4040 2009-06-27 09:32:42Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -26,10 +26,11 @@ #ifndef FUSE_COMPAT_H #define FUSE_COMPAT_H +#include <stdio.h> +#include <dirent.h> #include <stdlib.h> +#include <sys/types.h> -#include <utils.h> - /* Remove the gcc-specific incantations if we're not using gcc */ #ifdef __GNUC__ @@ -49,12 +50,12 @@ char *dirname( char *path ); #endif /* #ifndef HAVE_DIRNAME */ -#if !defined HAVE_GETOPT_LONG && !defined AMIGA && !defined __MORPHOS__ +#if !defined HAVE_GETOPT_LONG && !defined AMIGA && !defined __MORPHOS__ && !defined __APPLE__ #include "compat/getopt.h" #endif /* #ifndef HAVE_GETOPT_LONG */ #ifndef HAVE_MKSTEMP -int mkstemp( char *tmpl ); +int mkstemp( char *templ ); #endif /* #ifndef HAVE_MKSTEMP */ /* That which separates components in a path name */ @@ -66,24 +67,52 @@ #define FUSE_DIR_SEP_STR "/" #endif +#ifndef PATH_MAX +#define PATH_MAX 1024 +#endif + int compat_osname( char *buffer, size_t length ); const char* compat_get_temp_path( void ); const char* compat_get_home_path( void ); int compat_is_absolute_path( const char *path ); +typedef FILE* compat_fd; + #ifndef UI_WII -typedef int compat_fd; +typedef DIR* compat_dir; #else /* #ifndef UI_WII */ -typedef FILE* compat_fd; +typedef DIR_ITER* compat_dir; #endif /* #ifndef UI_WII */ extern const compat_fd COMPAT_FILE_OPEN_FAILED; +/* File handling */ + +struct utils_file; + compat_fd compat_file_open( const char *path, int write ); off_t compat_file_get_length( compat_fd fd ); -int compat_file_read( compat_fd fd, utils_file *file ); +int compat_file_read( compat_fd fd, struct utils_file *file ); int compat_file_write( compat_fd fd, const unsigned char *buffer, size_t length ); int compat_file_close( compat_fd fd ); +/* Directory handling */ + +typedef enum compat_dir_result_t { + COMPAT_DIR_RESULT_OK, + COMPAT_DIR_RESULT_END, + COMPAT_DIR_RESULT_ERROR, +} compat_dir_result_t; + +compat_dir compat_opendir( const char *path ); +compat_dir_result_t compat_readdir( compat_dir directory, char *name, + size_t length ); +int compat_closedir( compat_dir directory ); + +/* Timing routines */ + +double compat_timer_get_time( void ); +void compat_timer_sleep( int ms ); + #endif /* #ifndef FUSE_COMPAT_H */ Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2009-06-27 12:48:09 UTC (rev 600) +++ trunk/fuse/configure.in 2009-06-29 22:23:59 UTC (rev 601) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 3866 2008-11-29 17:05:40Z pak21 $ +dnl $Id: configure.in 4028 2009-05-31 13:15:52Z fredm $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -24,7 +24,7 @@ AC_CANONICAL_SYSTEM dnl Use automake to produce `Makefile.in' -AM_INIT_AUTOMAKE(fuse, 0.10.0) +AM_INIT_AUTOMAKE(fuse, 0.10.0.1) dnl Checks for programs. AC_PROG_CC @@ -93,7 +93,7 @@ AC_MSG_RESULT($win32) if test "$win32" = yes; then AC_CHECK_HEADER(windows.h, - LIBS="$LIBS -mwindows -lcomctl32"; + LIBS="$LIBS -mwindows -lcomctl32 -lwinmm"; AC_DEFINE([UI_WIN32], 1, [Defined if Win32 UI in use]) AC_DEFINE([WINVER], 0x0400, [Minimal supported version of Windows is 95 or NT4]) AC_DEFINE([_WIN32_IE], 0x400, [Internet Explorer is 4.0 or higher is required]) @@ -149,6 +149,38 @@ fi fi +dnl Look for Wii interface (default = 0) +if test -z "$UI"; then + AC_MSG_CHECKING(whether Wii UI requested) + AC_ARG_WITH(wii, + [ --with-wii use Wii FB for user interface], + if test "$withval" = no; then wii=no; else wii=yes; fi, + wii=no) + AC_MSG_RESULT($wii) + if test "$wii" = yes; then + AC_DEFINE([UI_WII], 1, [Defined if Wii UI in use]) + AC_DEFINE([USE_WIDGET], 1, [Defined if we're using a widget-based UI]) + AC_DEFINE([USE_JOYSTICK], 1, [Defined if we're using hardware joysticks]) + UI=wii; WIDGET=widget; + UI_LIBS="ui/wii/libuiwii.a ui/widget/libwidget.a" + target_os=wii + dnl Look for libgpm (default=yes) + AC_MSG_CHECKING(whether gpm requested) + AC_ARG_WITH(gpm, + [ --without-gpm don't use libgp... [truncated message content] |
From: <fr...@us...> - 2009-08-02 10:35:46
|
Revision: 610 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=610&view=rev Author: fredm Date: 2009-08-02 10:35:36 +0000 (Sun, 02 Aug 2009) Log Message: ----------- Merge up to vendor revision 4041. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=4041&view=rev Modified Paths: -------------- trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/libspectrum.h trunk/fuse/AUTHORS trunk/fuse/ChangeLog trunk/fuse/README trunk/fuse/disk/Makefile.am trunk/fuse/disk/beta.c trunk/fuse/disk/disk.c trunk/fuse/disk/fdd.c trunk/fuse/disk/plusd.c trunk/fuse/disk/wd_fdc.c trunk/fuse/disk/wd_fdc.h trunk/fuse/fuse.c trunk/fuse/fusepb/Credits.html trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/controllers/FuseController.h trunk/fuse/fusepb/controllers/FuseController.m trunk/fuse/fusepb/controllers/PreferencesController.m trunk/fuse/fusepb/models/Emulator.h trunk/fuse/fusepb/models/Emulator.m trunk/fuse/fusepb/nibs/Preferences.nib/designable.nib trunk/fuse/fusepb/nibs/Preferences.nib/keyedobjects.nib trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html trunk/fuse/fusepb/resources/Fuse Help/html/formats.html trunk/fuse/fusepb/resources/Fuse Help/html/menus.html trunk/fuse/fusepb/resources/Fuse Help/html/preferences.html trunk/fuse/fusepb/resources/Fuse Help/html/tocstart.html trunk/fuse/fusepb/views/DisplayOpenGLView.h trunk/fuse/fusepb/views/DisplayOpenGLView.m trunk/fuse/hacking/ChangeLog trunk/fuse/ide/divide.c trunk/fuse/ide/divide.h trunk/fuse/ide/ide.c trunk/fuse/ide/ide.h trunk/fuse/ide/simpleide.c trunk/fuse/ide/simpleide.h trunk/fuse/ide/zxatasp.c trunk/fuse/ide/zxatasp.h trunk/fuse/ide/zxcf.c trunk/fuse/ide/zxcf.h trunk/fuse/machines/pentagon1024.c trunk/fuse/machines/spec128.c trunk/fuse/machines/spec16.c trunk/fuse/machines/spec48.c trunk/fuse/machines/spec_se.c trunk/fuse/machines/specplus2.c trunk/fuse/machines/tc2048.c trunk/fuse/man/fuse.1 trunk/fuse/memory.c trunk/fuse/menu.c trunk/fuse/menu.h trunk/fuse/menu_data.dat trunk/fuse/periph.c trunk/fuse/periph.h trunk/fuse/roms/Makefile.am trunk/fuse/settings.dat trunk/fuse/tape.c trunk/fuse/ui/cocoa/cocoaui.m trunk/fuse/ui/options.dat trunk/fuse/ui/ui.h trunk/fuse/ui.c trunk/fuse/utils.c trunk/fuse/z80/coretest.c trunk/fuse/z80/z80_checks.h trunk/fuse/z80/z80_ops.c trunk/libspectrum/libspectrum/accessor.pl trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/libspectrum.c trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/sna.c trunk/libspectrum/libspectrum/snap_accessors.txt trunk/libspectrum/libspectrum/snapshot.c trunk/libspectrum/libspectrum/szx.c trunk/libspectrum/libspectrum/z80.c trunk/libspectrum/libspectrum.h Added Paths: ----------- trunk/fuse/disk/opus.c trunk/fuse/disk/opus.h trunk/fuse/fusepb/resources/Fuse Help/html/opus.html trunk/fuse/roms/opus.rom Property Changed: ---------------- trunk/fuse/ trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/FuseGenerator/libspectrum.h 2009-08-02 10:35:36 UTC (rev 610) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4039 2009-06-27 06:04:44Z fredm $ + $Id: libspectrum.h.in 4060 2009-07-30 13:21:38Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -343,6 +343,8 @@ LIBSPECTRUM_ID_DISK_SAD, /* .sad generic disk image */ LIBSPECTRUM_ID_DISK_TD0, /* .td0 generic disk image */ + LIBSPECTRUM_ID_DISK_OPD, /* .opu/.opd Opus Discovery disk image */ + LIBSPECTRUM_ID_SCREEN_SCR, /* .scr screen file */ } libspectrum_id_t; @@ -355,6 +357,7 @@ LIBSPECTRUM_CLASS_CARTRIDGE_TIMEX, /* Timex cartridges */ LIBSPECTRUM_CLASS_DISK_PLUS3, /* +3 disk */ LIBSPECTRUM_CLASS_DISK_TRDOS, /* TR-DOS disk */ + LIBSPECTRUM_CLASS_DISK_OPUS, /* Opus Discovery disk*/ LIBSPECTRUM_CLASS_RECORDING, /* Input recording */ LIBSPECTRUM_CLASS_SNAPSHOT, /* Snapshot */ LIBSPECTRUM_CLASS_TAPE, /* Tape */ @@ -679,6 +682,8 @@ void WIN32_DLL libspectrum_snap_set_beta_active( libspectrum_snap *snap, int beta_active ); int WIN32_DLL libspectrum_snap_beta_paged( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_beta_paged( libspectrum_snap *snap, int beta_paged ); +int WIN32_DLL libspectrum_snap_beta_drive_count( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_beta_drive_count( libspectrum_snap *snap, int beta_drive_count ); int WIN32_DLL libspectrum_snap_beta_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_beta_custom_rom( libspectrum_snap *snap, int beta_custom_rom ); int WIN32_DLL libspectrum_snap_beta_direction( libspectrum_snap *snap ); @@ -699,6 +704,8 @@ void WIN32_DLL libspectrum_snap_set_plusd_active( libspectrum_snap *snap, int plusd_active ); int WIN32_DLL libspectrum_snap_plusd_paged( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_plusd_paged( libspectrum_snap *snap, int plusd_paged ); +int WIN32_DLL libspectrum_snap_plusd_drive_count( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_plusd_drive_count( libspectrum_snap *snap, int plusd_drive_count ); int WIN32_DLL libspectrum_snap_plusd_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_plusd_custom_rom( libspectrum_snap *snap, int plusd_custom_rom ); int WIN32_DLL libspectrum_snap_plusd_direction( libspectrum_snap *snap ); @@ -717,6 +724,40 @@ void WIN32_DLL libspectrum_snap_set_plusd_rom( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_rom ); libspectrum_byte WIN32_DLL * libspectrum_snap_plusd_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_plusd_ram( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_ram ); +int WIN32_DLL libspectrum_snap_opus_active( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_active( libspectrum_snap *snap, int opus_active ); +int WIN32_DLL libspectrum_snap_opus_paged( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_paged( libspectrum_snap *snap, int opus_paged ); +int WIN32_DLL libspectrum_snap_opus_drive_count( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_drive_count( libspectrum_snap *snap, int opus_drive_count ); +int WIN32_DLL libspectrum_snap_opus_custom_rom( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_custom_rom( libspectrum_snap *snap, int opus_custom_rom ); +int WIN32_DLL libspectrum_snap_opus_direction( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_direction( libspectrum_snap *snap, int opus_direction ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_track( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_track( libspectrum_snap *snap, libspectrum_byte opus_track ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_sector( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_sector( libspectrum_snap *snap, libspectrum_byte opus_sector ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data( libspectrum_snap *snap, libspectrum_byte opus_data ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_status( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_status( libspectrum_snap *snap, libspectrum_byte opus_status ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_reg_a( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_reg_a( libspectrum_snap *snap, libspectrum_byte opus_data_reg_a ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_dir_a( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_dir_a( libspectrum_snap *snap, libspectrum_byte opus_data_dir_a ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_control_a( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_control_a( libspectrum_snap *snap, libspectrum_byte opus_control_a ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_reg_b( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_reg_b( libspectrum_snap *snap, libspectrum_byte opus_data_reg_b ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_dir_b( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_dir_b( libspectrum_snap *snap, libspectrum_byte opus_data_dir_b ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_control_b( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_control_b( libspectrum_snap *snap, libspectrum_byte opus_control_b ); +libspectrum_byte WIN32_DLL * libspectrum_snap_opus_rom( libspectrum_snap *snap, int idx ); +void WIN32_DLL libspectrum_snap_set_opus_rom( libspectrum_snap *snap, int idx, libspectrum_byte* opus_rom ); +libspectrum_byte WIN32_DLL * libspectrum_snap_opus_ram( libspectrum_snap *snap, int idx ); +void WIN32_DLL libspectrum_snap_set_opus_ram( libspectrum_snap *snap, int idx, libspectrum_byte* opus_ram ); int WIN32_DLL libspectrum_snap_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_custom_rom( libspectrum_snap *snap, int custom_rom ); size_t WIN32_DLL libspectrum_snap_custom_rom_pages( libspectrum_snap *snap ); Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/FuseImporter/libspectrum.h 2009-08-02 10:35:36 UTC (rev 610) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4039 2009-06-27 06:04:44Z fredm $ + $Id: libspectrum.h.in 4060 2009-07-30 13:21:38Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -343,6 +343,8 @@ LIBSPECTRUM_ID_DISK_SAD, /* .sad generic disk image */ LIBSPECTRUM_ID_DISK_TD0, /* .td0 generic disk image */ + LIBSPECTRUM_ID_DISK_OPD, /* .opu/.opd Opus Discovery disk image */ + LIBSPECTRUM_ID_SCREEN_SCR, /* .scr screen file */ } libspectrum_id_t; @@ -355,6 +357,7 @@ LIBSPECTRUM_CLASS_CARTRIDGE_TIMEX, /* Timex cartridges */ LIBSPECTRUM_CLASS_DISK_PLUS3, /* +3 disk */ LIBSPECTRUM_CLASS_DISK_TRDOS, /* TR-DOS disk */ + LIBSPECTRUM_CLASS_DISK_OPUS, /* Opus Discovery disk*/ LIBSPECTRUM_CLASS_RECORDING, /* Input recording */ LIBSPECTRUM_CLASS_SNAPSHOT, /* Snapshot */ LIBSPECTRUM_CLASS_TAPE, /* Tape */ @@ -679,6 +682,8 @@ void WIN32_DLL libspectrum_snap_set_beta_active( libspectrum_snap *snap, int beta_active ); int WIN32_DLL libspectrum_snap_beta_paged( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_beta_paged( libspectrum_snap *snap, int beta_paged ); +int WIN32_DLL libspectrum_snap_beta_drive_count( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_beta_drive_count( libspectrum_snap *snap, int beta_drive_count ); int WIN32_DLL libspectrum_snap_beta_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_beta_custom_rom( libspectrum_snap *snap, int beta_custom_rom ); int WIN32_DLL libspectrum_snap_beta_direction( libspectrum_snap *snap ); @@ -699,6 +704,8 @@ void WIN32_DLL libspectrum_snap_set_plusd_active( libspectrum_snap *snap, int plusd_active ); int WIN32_DLL libspectrum_snap_plusd_paged( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_plusd_paged( libspectrum_snap *snap, int plusd_paged ); +int WIN32_DLL libspectrum_snap_plusd_drive_count( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_plusd_drive_count( libspectrum_snap *snap, int plusd_drive_count ); int WIN32_DLL libspectrum_snap_plusd_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_plusd_custom_rom( libspectrum_snap *snap, int plusd_custom_rom ); int WIN32_DLL libspectrum_snap_plusd_direction( libspectrum_snap *snap ); @@ -717,6 +724,40 @@ void WIN32_DLL libspectrum_snap_set_plusd_rom( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_rom ); libspectrum_byte WIN32_DLL * libspectrum_snap_plusd_ram( libspectrum_snap *snap, int idx ); void WIN32_DLL libspectrum_snap_set_plusd_ram( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_ram ); +int WIN32_DLL libspectrum_snap_opus_active( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_active( libspectrum_snap *snap, int opus_active ); +int WIN32_DLL libspectrum_snap_opus_paged( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_paged( libspectrum_snap *snap, int opus_paged ); +int WIN32_DLL libspectrum_snap_opus_drive_count( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_drive_count( libspectrum_snap *snap, int opus_drive_count ); +int WIN32_DLL libspectrum_snap_opus_custom_rom( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_custom_rom( libspectrum_snap *snap, int opus_custom_rom ); +int WIN32_DLL libspectrum_snap_opus_direction( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_direction( libspectrum_snap *snap, int opus_direction ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_track( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_track( libspectrum_snap *snap, libspectrum_byte opus_track ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_sector( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_sector( libspectrum_snap *snap, libspectrum_byte opus_sector ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data( libspectrum_snap *snap, libspectrum_byte opus_data ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_status( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_status( libspectrum_snap *snap, libspectrum_byte opus_status ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_reg_a( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_reg_a( libspectrum_snap *snap, libspectrum_byte opus_data_reg_a ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_dir_a( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_dir_a( libspectrum_snap *snap, libspectrum_byte opus_data_dir_a ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_control_a( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_control_a( libspectrum_snap *snap, libspectrum_byte opus_control_a ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_reg_b( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_reg_b( libspectrum_snap *snap, libspectrum_byte opus_data_reg_b ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_dir_b( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_data_dir_b( libspectrum_snap *snap, libspectrum_byte opus_data_dir_b ); +libspectrum_byte WIN32_DLL libspectrum_snap_opus_control_b( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_opus_control_b( libspectrum_snap *snap, libspectrum_byte opus_control_b ); +libspectrum_byte WIN32_DLL * libspectrum_snap_opus_rom( libspectrum_snap *snap, int idx ); +void WIN32_DLL libspectrum_snap_set_opus_rom( libspectrum_snap *snap, int idx, libspectrum_byte* opus_rom ); +libspectrum_byte WIN32_DLL * libspectrum_snap_opus_ram( libspectrum_snap *snap, int idx ); +void WIN32_DLL libspectrum_snap_set_opus_ram( libspectrum_snap *snap, int idx, libspectrum_byte* opus_ram ); int WIN32_DLL libspectrum_snap_custom_rom( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_custom_rom( libspectrum_snap *snap, int custom_rom ); size_t WIN32_DLL libspectrum_snap_custom_rom_pages( libspectrum_snap *snap ); Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-600 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-609 Modified: trunk/fuse/AUTHORS =================================================================== --- trunk/fuse/AUTHORS 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/AUTHORS 2009-08-02 10:35:36 UTC (rev 610) @@ -9,8 +9,8 @@ * Ian Collier: the original ZX Printer emulation (for xz80). -* John Elliott: for lib765, which provides Fuse's emulation of the +3's - FDC, and libdsk which provides support for more disk image formats: +* John Elliott: for lib765, which provided Fuse's original emulation of the + +3's FDC, and libdsk which provided support for more disk image formats: see http://www.seasip.demon.co.uk/Unix/LibDsk/ * Darren Salt: the original versions of the code for +3 emulation, @@ -34,15 +34,20 @@ * Marek Januszewski: Some patches making Fuse much closer to compiling under Win32, and fixing up the GTK+ 2.0 interface. -* Stuart Brady: for the Scorpion emulation and HP-UX sound support. +* Stuart Brady: for the Scorpion, +D interface emulation and HP-UX sound + support. * Garry Lancaster: the simple 8-bit IDE, ZXATASP and ZXCF support. -* Gergely Szasz: Interface I/microdrive emulation, the 'movie' code and the - ao sound driver. +* Gergely Szasz: +3, +D, Opus and Interface I/microdrive emulation, the 'movie' + code and the ao sound driver. * Bjoern Giesler: the original Wii port. +* Shay Green: the Blip_Buffer band pass filter for beeper and AY output. + +* Michael D Wynne: the Opus Discovery emulation (for EightyOne). + * Philip Kendall: everything else. -$Id: AUTHORS 3944 2009-01-10 18:17:04Z pak21 $ +$Id: AUTHORS 4060 2009-07-30 13:21:38Z fredm $ Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/ChangeLog 2009-08-02 10:35:36 UTC (rev 610) @@ -1,3 +1,43 @@ +2009-xx-xx Philip Kendall <phi...@sh...> + + * Fuse ?.??.? released + + FIXME: Just a start, mostly changes visible on Fuse for OS X at the + moment + * Add Opus Discovery disk interface support (Gergely Szasz and Fredrick + Meunier). + * Wii support. + * Many improvements to Win32 UI (Marek Januszewski). + * Add support for flipping disk images in single sided drives (Gergely + Szasz). + * Add support for automatically merging both both disk images where + they are in separate files named with the text [Ss]ide[ _][abAB12] + (Gergely Szasz). + * Switch to using Blip_Buffer (by Shay Green) for improved beeper and + AY output (Fredrick Meunier). + * Allow beeper and AY volumes to be set (Fredrick Meunier). + * Enable Beta 128 interface in 48K and TC2048 machines (thanks, + Omikron) (Fredrick Meunier). + * Add emulation of the Fuller Audio Box (Stuart Brady and Fredrick + Meunier). + * Allow sound to run from 2% speed up (Fredrick Meunier). + * Add emulation of the Melodik and similar 48K-compatible AY interfaces + that use the 128K sound ports (Fredrick Meunier). + * Add support for Pentagon 1024SL v2.2 16 colour mode (Fredrick + Meunier). + + * Miscellaneous improvements: + * Preformat new disks on +3 to allow the format command on +3 to work + (Gergely Szasz). + * Support non-standard TRD images with 41-83 tracks per side (Gergely + Szasz). + * Allow user to swap Kempston mouse buttons as some combinations of + physical hardware and Spectrum software make it hard to use the + standard mapping e.g. right clicking and moving the cursor on Mac + notebooks (thanks, Andrew Owen) (Fredrick Meunier). + * Fixes for speed estimation (Gergely Szasz). + * Fix border colour in Timex HiRes screenshots (Fredrick Meunier). + 2008-12-10 Philip Kendall <phi...@sh...> * Fuse 0.10.0.1 released @@ -941,4 +981,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 3900 2008-12-10 19:31:31Z pak21 $ +$Id: ChangeLog 4060 2009-07-30 13:21:38Z fredm $ Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/README 2009-08-02 10:35:36 UTC (rev 610) @@ -25,7 +25,7 @@ * Support for the RZX input recording file format, including rollback and 'competition mode'. * Emulation of the DivIDE, Interface I, Kempston mouse, Spectrum +3e, - ZXATASP, ZXCF, Beta 128 and +D interfaces. + ZXATASP, ZXCF, Beta 128, Opus Discovery and +D interfaces. Help! <xyz> doesn't work ------------------------ @@ -180,4 +180,4 @@ Philip Kendall <phi...@sh...> 10 December 2008 -$Id: README 4021 2009-05-29 13:39:51Z fredm $ +$Id: README 4060 2009-07-30 13:21:38Z fredm $ Modified: trunk/fuse/disk/Makefile.am =================================================================== --- trunk/fuse/disk/Makefile.am 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/disk/Makefile.am 2009-08-02 10:35:36 UTC (rev 610) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007 Stuart Brady -## $Id: Makefile.am 3584 2008-03-25 10:27:30Z fredm $ +## $Id: Makefile.am 4060 2009-07-30 13:21:38Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -33,6 +33,7 @@ crc.c \ disk.c \ fdd.c \ + opus.c \ plusd.c \ upd_fdc.c \ wd_fdc.c @@ -41,6 +42,7 @@ crc.h \ disk.h \ fdd.h \ + opus.h \ plusd.h \ upd_fdc.h \ wd_fdc.h Modified: trunk/fuse/disk/beta.c =================================================================== --- trunk/fuse/disk/beta.c 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/disk/beta.c 2009-08-02 10:35:36 UTC (rev 610) @@ -1,7 +1,7 @@ /* beta.c: Routines for handling the Beta disk interface Copyright (c) 2004-2008 Stuart Brady - $Id: beta.c 4029 2009-06-05 13:50:55Z fredm $ + $Id: beta.c 4060 2009-07-30 13:21:38Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -708,6 +708,11 @@ 1 ) ) return; + /* ignore drive count for now, there will be an issue with loading snaps where + drives have been disabled + libspectrum_snap_beta_drive_count( snap ) + */ + beta_fdc->direction = libspectrum_snap_beta_direction( snap ); beta_cr_write ( 0x001f, 0 ); @@ -723,6 +728,7 @@ int attached; wd_fdc *f = beta_fdc; libspectrum_byte *buffer; + int drive_count = 0; if( !periph_beta128_active ) return; @@ -745,6 +751,12 @@ libspectrum_snap_set_beta_custom_rom( snap, 1 ); } + drive_count++; /* Drive A is not removable */ + if( option_enumerate_diskoptions_drive_beta128b_type() > 0 ) drive_count++; + if( option_enumerate_diskoptions_drive_beta128c_type() > 0 ) drive_count++; + if( option_enumerate_diskoptions_drive_beta128d_type() > 0 ) drive_count++; + libspectrum_snap_set_beta_drive_count( snap, drive_count ); + libspectrum_snap_set_beta_paged ( snap, beta_active ); libspectrum_snap_set_beta_direction( snap, beta_fdc->direction ); libspectrum_snap_set_beta_status( snap, beta_sr_read( 0x001f, &attached ) ); Modified: trunk/fuse/disk/disk.c =================================================================== --- trunk/fuse/disk/disk.c 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/disk/disk.c 2009-08-02 10:35:36 UTC (rev 610) @@ -1,7 +1,7 @@ /* disk.c: Routines for handling disk images Copyright (c) 2007 Gergely Szasz - $Id: disk.c 4037 2009-06-13 13:28:42Z fredm $ + $Id: disk.c 4061 2009-07-30 23:37:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -252,6 +252,7 @@ #define DISK_MFM_VARI 16 #define DISK_DDAM 32 #define DISK_CORRUPT_SECTOR 64 +#define DISK_UNFORMATTED_TRACK 128 static int guess_track_geom( disk_t *d, int head, int track, int *sector_base, @@ -295,7 +296,7 @@ static int check_disk_geom( disk_t *d, int *sector_base, int *sectors, - int *seclen, int *mfm ) + int *seclen, int *mfm, int *unf ) { int h, t, s, slen, sbase, m; int r = 0; @@ -306,6 +307,7 @@ *sectors = -1; *seclen = -1; *mfm = -1; + *unf = -1; for( t = 0; t < d->cylinders; t++ ) { for( h = 0; h < d->sides; h++ ) { r |= guess_track_geom( d, h, t, &sbase, &s, &slen, &m ); @@ -317,6 +319,12 @@ *seclen = slen; if( *mfm == -1 ) *mfm = m; + if( sbase == -1 ) { /* unformatted */ + if( *unf == -1 && h > 0 ) *unf = -2; + if( *unf == -1 ) *unf = t; + continue; + } + if( *unf > -1 ) *unf = -2; if( sbase != *sector_base ) { r |= DISK_SBASE_VARI; if( sbase < *sector_base ) @@ -338,6 +346,11 @@ } } } + if( *unf == -2 ) { + r |= DISK_UNFORMATTED_TRACK; + *unf = -1; + } + return r; } @@ -569,6 +582,7 @@ #define NO_INTERLEAVE 1 #define INTERLEAVE_2 2 +#define INTERLEAVE_OPUS 13 #define NO_PREINDEX 0 #define PREINDEX 1 @@ -593,15 +607,18 @@ idx = d->i; pos = i = 0; for( s = sector_base; s < sector_base + sectors; s++ ) { - d->i = idx + ( pos + i ) * slen; + d->i = idx + pos * slen; if( id_add( d, head, track, s, sector_length >> 8, gap, CRC_OK ) ) return 1; if( data_add( d, buffer, NULL, sector_length, NO_DDAM, gap, CRC_OK, autofill ) ) return 1; pos += interleave; - if( pos >= sectors ) { - pos = 0; - i++; + if( pos >= sectors ) { /* wrap around */ + pos -= sectors; + if( pos <= i ) { /* we fill this pos already */ + pos++; /* skip one more pos */ + i++; + } } } d->i = idx + sectors * slen; @@ -783,14 +800,16 @@ } static int -open_mgt_img( buffer_t *buffer, disk_t *d ) +open_img_mgt_opd( buffer_t *buffer, disk_t *d ) { int i, j, sectors, seclen; buffer->index = 0; /* guess geometry of disk: - * 2*80*10*512, 1*80*10*512 or 1*40*10*512 */ + * 2*80*10*512, 1*80*10*512, 1*40*10*512, 1*40*18*256, 1*80*18*256, + * 2*80*18*256 + */ if( buffer->file.length == 2*80*10*512 ) { d->sides = 2; d->cylinders = 80; sectors = 10; seclen = 512; } else if( buffer->file.length == 1*80*10*512 ) { @@ -799,6 +818,14 @@ d->sides = 1; d->cylinders = 80; sectors = 10; seclen = 512; } else if( buffer->file.length == 1*40*10*512 ) { d->sides = 1; d->cylinders = 40; sectors = 10; seclen = 512; + } else if( buffer->file.length == 1*40*18*256 ) { + d->sides = 1; d->cylinders = 40; sectors = 18; seclen = 256; + } else if( buffer->file.length == 1*80*18*256 ) { + /* we cannot distinguish between a single sided 80 track image + * and a double sided 40 track image (2*40*18*256) */ + d->sides = 1; d->cylinders = 80; sectors = 18; seclen = 256; + } else if( buffer->file.length == 2*80*18*256 ) { + d->sides = 2; d->cylinders = 80; sectors = 18; seclen = 256; } else { return d->status = DISK_GEOM; } @@ -816,11 +843,14 @@ return d->status = DISK_GEOM; } } - } else { /* MGT alt */ - for( i = 0; i < d->sides * d->cylinders; i++ ) { - if( trackgen( d, buffer, i % 2, i / 2, 1, sectors, seclen, - NO_PREINDEX, GAP_MGT_PLUSD, NO_INTERLEAVE, NO_AUTOFILL ) ) - return d->status = DISK_GEOM; + } else { /* MGT / OPD alt */ + for( i = 0; i < d->cylinders; i++ ) { + for( j = 0; j < d->sides; j++ ) { + if( trackgen( d, buffer, j, i, d->type == DISK_MGT ? 1 : 0, sectors, seclen, + NO_PREINDEX, GAP_MGT_PLUSD, + d->type == DISK_MGT ? NO_INTERLEAVE : INTERLEAVE_OPUS, NO_AUTOFILL ) ) + return d->status = DISK_GEOM; + } } } @@ -1072,7 +1102,7 @@ plus3_fix = CPC_ISSUE_NONE; } trlen += seclen; - if( seclen == 0x80 ) /* every 128byte length sector padded */ + if( seclen % 0x100 ) /* every? 128/384/...byte length sector padded */ sector_pad++; } if( i < 84 ) { @@ -1106,6 +1136,7 @@ preindex_add( d, gap ); postindex_add( d, gap ); + sector_pad = 0; for( j = 0; j < hdrb[0x15]; j++ ) { /* each sector */ seclen = d->type == DISK_ECPC ? hdrb[ 0x1e + 8 * j ] + /* data length in sector */ 256 * hdrb[ 0x1f + 8 * j ] @@ -1169,10 +1200,11 @@ /* ( ( N * len ) / len - 1 ) * len */ } } - if( seclen == 0x80 ) /* every 128byte length sector padded */ - buffer->index += 0x80; + if( seclen % 0x100 ) /* every? 128/384/...byte length sector padded */ + sector_pad++; } gap4_add( d, gap ); + buffer->index += sector_pad * 0x80; } return d->status = DISK_OK; } @@ -1504,11 +1536,13 @@ d->type = DISK_UDI; open_udi( &buffer, d ); break; + case LIBSPECTRUM_ID_DISK_OPD: + d->type = DISK_OPD; case LIBSPECTRUM_ID_DISK_MGT: - d->type = DISK_MGT; + if( d->type == DISK_TYPE_NONE) d->type = DISK_MGT; case LIBSPECTRUM_ID_DISK_IMG: if( d->type == DISK_TYPE_NONE) d->type = DISK_IMG; - open_mgt_img( &buffer, d ); + open_img_mgt_opd( &buffer, d ); break; case LIBSPECTRUM_ID_DISK_SAD: d->type = DISK_SAD; @@ -1733,25 +1767,31 @@ } static int -write_img_mgt( FILE *file, disk_t *d ) +write_img_mgt_opd( FILE *file, disk_t *d ) { - int i, j, sbase, sectors, seclen, mfm; + int i, j, sbase, sectors, seclen, mfm, cyl; - if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm ) || - sbase != 1 || seclen != 2 || sectors != 10 ) + if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm, &cyl ) || + ( d->type != DISK_OPD && ( sbase != 1 || seclen != 2 || sectors != 10 ) ) || + ( d->type == DISK_OPD && ( sbase != 0 || seclen != 1 || sectors != 18 ) ) ) return d->status = DISK_GEOM; + if( cyl == -1 ) cyl = d->cylinders; + if( cyl != 40 && cyl != 80 ) + return d->status = DISK_GEOM; + if( d->type == DISK_IMG ) { /* out-out */ for( j = 0; j < d->sides; j++ ) { - for( i = 0; i < d->cylinders; i++ ) { + for( i = 0; i < cyl; i++ ) { if( savetrack( d, file, j, i, 1, sectors, seclen ) ) return d->status = DISK_GEOM; } } } else { /* alt */ - for( i = 0; i < d->cylinders; i++ ) { /* MGT */ + for( i = 0; i < cyl; i++ ) { /* MGT */ for( j = 0; j < d->sides; j++ ) { - if( savetrack( d, file, j, i, 1, sectors, seclen ) ) + if( savetrack( d, file, j, i, d->type == DISK_MGT ? 1 : 0, + sectors, seclen ) ) return d->status = DISK_GEOM; } } @@ -1762,12 +1802,14 @@ static int write_trd( FILE *file, disk_t *d ) { - int i, j, sbase, sectors, seclen, mfm; + int i, j, sbase, sectors, seclen, mfm, cyl; - if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm ) || + if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm, &cyl ) || sbase != 1 || seclen != 1 || sectors != 16 ) return d->status = DISK_GEOM; - for( i = 0; i < d->cylinders; i++ ) { + + if( cyl == -1 ) cyl = d->cylinders; + for( i = 0; i < cyl; i++ ) { for( j = 0; j < d->sides; j++ ) { if( savetrack( d, file, j, i, 1, sectors, seclen ) ) return d->status = DISK_GEOM; @@ -1779,21 +1821,22 @@ static int write_sad( FILE *file, disk_t *d ) { - int i, j, sbase, sectors, seclen, mfm; + int i, j, sbase, sectors, seclen, mfm, cyl; - if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm ) || sbase != 1 ) + if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm, &cyl ) || sbase != 1 ) return d->status = DISK_GEOM; + if( cyl == -1 ) cyl = d->cylinders; memcpy( head, "Aley's disk backup", 18 ); head[18] = d->sides; - head[19] = d->cylinders; + head[19] = cyl; head[20] = sectors; head[21] = seclen * 4; if( fwrite( head, 22, 1, file ) != 1 ) /* SAD head */ return d->status = DISK_WRPART; for( j = 0; j < d->sides; j++ ) { /* OUT-OUT */ - for( i = 0; i < d->cylinders; i++ ) { + for( i = 0; i < cyl; i++ ) { if( savetrack( d, file, j, i, 1, sectors, seclen ) ) return d->status = DISK_GEOM; } @@ -1894,19 +1937,21 @@ static int write_cpc( FILE *file, disk_t *d ) { - int i, j, k, sbase, sectors, seclen, mfm; + int i, j, k, sbase, sectors, seclen, mfm, cyl; int h, t, s, b; size_t len; - i = check_disk_geom( d, &sbase, §ors, &seclen, &mfm ); + i = check_disk_geom( d, &sbase, §ors, &seclen, &mfm, &cyl ); if( i & DISK_SECLEN_VARI || i & DISK_SPT_VARI ) return d->status = DISK_GEOM; if( i & DISK_MFM_VARI ) mfm = -1; + if( cyl == -1 ) cyl = d->cylinders; + memset( head, 0, 256 ); memcpy( head, "MV - CPCEMU Disk-File\r\nDisk-Info\r\n", 34 ); - head[0x30] = d->cylinders; + head[0x30] = cyl; head[0x31] = d->sides; len = sectors * ( 0x80 << seclen ) + 256; head[0x32] = len & 0xff; @@ -1916,7 +1961,7 @@ memset( head, 0, 256 ); memcpy( head, "Track-Info\r\n", 12 ); - for( i = 0; i < d->cylinders; i++ ) { + for( i = 0; i < cyl; i++ ) { for( j = 0; j < d->sides; j++ ) { d->track = d->data + ( ( d->sides * i + j ) * d->tlen ); d->clocks = d->track + d->bpt; @@ -1952,11 +1997,11 @@ static int write_scl( FILE *file, disk_t *d ) { - int i, j, k, l, t, s, sbase, sectors, seclen, mfm, del; + int i, j, k, l, t, s, sbase, sectors, seclen, mfm, del, cyl; int entries; libspectrum_dword sum = 597; /* sum of "SINCLAIR" */ - if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm ) || + if( check_disk_geom( d, &sbase, §ors, &seclen, &mfm, &cyl ) || sbase != 1 || seclen != 1 || sectors != 16 ) return d->status = DISK_GEOM; @@ -2071,7 +2116,9 @@ { int i, j, k, del, rev; int h, t, s, b; + char str[17]; + str[16] = '\0'; fprintf( file, "DISK tracks log!\n" ); fprintf( file, "Sides: %d, cylinders: %d\n", d->sides, d->cylinders ); for( j = 0; j < d->cylinders; j++ ) { /* ALT :) */ @@ -2110,9 +2157,11 @@ if( !( k % 16 ) ) fprintf( file, "0x%08x:", k ); fprintf( file, " 0x%02x", d->track[ d->i ] ); + str[ k & 0x0f ] = d->track[ d->i ] >= 32 && + d->track[ d->i ] < 127 ? d->track[ d->i ] : '.'; k++; if( !( k % 16 ) ) - fprintf( file, "\n" ); + fprintf( file, " | %s\n", str ); d->i++; if( d->i >= d->bpt ) { d->i = 0; @@ -2170,6 +2219,8 @@ d->type = DISK_CPC; /* ALT side */ else if( !strcasecmp( ext, ".mgt" ) ) d->type = DISK_MGT; /* ALT side */ + else if( !strcasecmp( ext, ".opd" ) || !strcasecmp( ext, ".opu" ) ) + d->type = DISK_OPD; /* ALT side */ else if( !strcasecmp( ext, ".img" ) ) /* out-out */ d->type = DISK_IMG; else if( !strcasecmp( ext, ".trd" ) ) /* ALT */ @@ -2192,7 +2243,8 @@ break; case DISK_IMG: case DISK_MGT: - write_img_mgt( file, d ); + case DISK_OPD: + write_img_mgt_opd( file, d ); break; case DISK_TRD: write_trd( file, d ); Modified: trunk/fuse/disk/fdd.c =================================================================== --- trunk/fuse/disk/fdd.c 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/disk/fdd.c 2009-08-02 10:35:36 UTC (rev 610) @@ -1,7 +1,7 @@ /* fdd.c: Routines for emulating floppy disk drives Copyright (c) 2007 Gergely Szasz - $Id: fdd.c 4012 2009-04-16 12:42:14Z fredm $ + $Id: fdd.c 4045 2009-07-10 13:11:12Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -131,6 +131,7 @@ fdd_init( fdd_t *d, fdd_type_t type, int heads, int cyls, int reinit ) { int upsidedown = d->upsidedown; + int selected = d->selected; disk_t *disk = d->disk; d->fdd_heads = d->fdd_cylinders = d->c_head = d->c_cylinder = 0; @@ -148,6 +149,7 @@ d->auto_geom = 1; d->fdd_heads = heads; d->fdd_cylinders = cyls; + if( reinit ) d->selected = selected; if( reinit && disk ) { fdd_unload( d ); fdd_load( d, disk, upsidedown ); Copied: trunk/fuse/disk/opus.c (from rev 609, vendor/fuse-emulator/current/fuse/disk/opus.c) =================================================================== --- trunk/fuse/disk/opus.c (rev 0) +++ trunk/fuse/disk/opus.c 2009-08-02 10:35:36 UTC (rev 610) @@ -0,0 +1,725 @@ +/* opus.c: Routines for handling the Opus Discovery interface + Copyright (c) 1999-2009 Stuart Brady, Fredrick Meunier, Philip Kendall, + Dmitry Sanarin, Darren Salt, Michael D Wynne, Gergely Szasz + + $Id: opus.c 4012 2009-04-16 12:42:14Z fredm $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + Philip: phi...@sh... + + Stuart: sd...@nt... + +*/ + +#include <config.h> + +#include <libspectrum.h> + +#include <string.h> + +#include "compat.h" +#include "machine.h" +#include "module.h" +#include "opus.h" +#include "printer.h" +#include "settings.h" +#include "ui/ui.h" +#include "wd_fdc.h" +#include "options.h" /* needed for get combo options */ +#include "z80/z80.h" + +#define DISK_TRY_MERGE(heads) ( option_enumerate_diskoptions_disk_try_merge() == 2 || \ + ( option_enumerate_diskoptions_disk_try_merge() == 1 && heads == 1 ) ) + +int opus_available = 0; +int opus_active = 0; + +static int opus_index_pulse; + +static int index_event; + +#define OPUS_NUM_DRIVES 2 + +static wd_fdc *opus_fdc; +static wd_fdc_drive opus_drives[ OPUS_NUM_DRIVES ]; + +static libspectrum_byte opus_ram[ 0x800 ]; + +/* 6821 PIA internal registers */ +static libspectrum_byte data_reg_a, data_dir_a, control_a; +static libspectrum_byte data_reg_b, data_dir_b, control_b; + +static void opus_reset( int hard_reset ); +static void opus_memory_map( void ); +static void opus_enabled_snapshot( libspectrum_snap *snap ); +static void opus_from_snapshot( libspectrum_snap *snap ); +static void opus_to_snapshot( libspectrum_snap *snap ); +static void opus_event_index( libspectrum_dword last_tstates, int type, + void *user_data ); + +static module_info_t opus_module_info = { + + opus_reset, + opus_memory_map, + opus_enabled_snapshot, + opus_from_snapshot, + opus_to_snapshot, + +}; + +void +opus_page( void ) +{ + opus_active = 1; + machine_current->ram.romcs = 1; + machine_current->memory_map(); +} + +void +opus_unpage( void ) +{ + opus_active = 0; + machine_current->ram.romcs = 0; + machine_current->memory_map(); +} + +static void +opus_memory_map( void ) +{ + if( !opus_active ) return; + + memory_map_read[ 0 ] = memory_map_write[ 0 ] = memory_map_romcs[ 0 ]; + memory_map_read[ 1 ] = memory_map_write[ 1 ] = memory_map_romcs[ 1 ]; +} + +static void +opus_set_datarq( struct wd_fdc *f ) +{ + event_add( 0, z80_nmi_event ); +} + +int +opus_init( void ) +{ + int i; + wd_fdc_drive *d; + + opus_fdc = wd_fdc_alloc_fdc( WD1770, 0, WD_FLAG_OPUS ); + + for( i = 0; i < OPUS_NUM_DRIVES; i++ ) { + d = &opus_drives[ i ]; + fdd_init( &d->fdd, FDD_SHUGART, 0, 0, 0 ); /* drive geometry 'autodetect' */ + d->disk.flag = DISK_FLAG_NONE; + } + + opus_fdc->current_drive = &opus_drives[ 0 ]; + fdd_select( &opus_drives[ 0 ].fdd, 1 ); + opus_fdc->dden = 1; + opus_fdc->set_intrq = NULL; + opus_fdc->reset_intrq = NULL; + opus_fdc->set_datarq = opus_set_datarq; + opus_fdc->reset_datarq = NULL; + opus_fdc->iface = NULL; + + index_event = event_register( opus_event_index, "Opus index" ); + + module_register( &opus_module_info ); + + return 0; +} + +static void +opus_reset( int hard_reset ) +{ + int i; + wd_fdc_drive *d; + const fdd_params_t *dt; + + opus_active = 0; + opus_available = 0; + + event_remove_type( index_event ); + + if( !periph_opus_active ) + return; + + machine_load_rom_bank( memory_map_romcs, 0, 0, + settings_current.rom_opus, + settings_default.rom_opus, 0x2000 ); + + memory_map_romcs[0].source = MEMORY_SOURCE_PERIPHERAL; + + memory_map_romcs[1].page = opus_ram; + memory_map_romcs[1].source = MEMORY_SOURCE_PERIPHERAL; + + machine_current->ram.romcs = 0; + + memory_map_romcs[ 0 ].writable = 0; + memory_map_romcs[ 1 ].writable = 1; + + data_reg_a = 0; + data_dir_a = 0; + control_a = 0; + data_reg_b = 0; + data_dir_b = 0; + control_b = 0; + + opus_available = 1; + opus_index_pulse = 0; + + if( hard_reset ) + memset( opus_ram, 0, 0x800 ); + + wd_fdc_master_reset( opus_fdc ); + + for( i = 0; i < OPUS_NUM_DRIVES; i++ ) { + d = &opus_drives[ i ]; + + d->index_pulse = 0; + d->index_interrupt = 0; + } + + /* We can eject disks only if they are currently present */ + dt = &fdd_params[ option_enumerate_diskoptions_drive_opus1_type() + 1 ]; /* +1 => there is no `Disabled' */ + fdd_init( &opus_drives[ OPUS_DRIVE_1 ].fdd, FDD_SHUGART, + dt->heads, dt->cylinders, 1 ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1, dt->enabled ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_EJECT, + opus_drives[ OPUS_DRIVE_1 ].fdd.loaded ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_FLIP_SET, + !opus_drives[ OPUS_DRIVE_1 ].fdd.upsidedown ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_WP_SET, + !opus_drives[ OPUS_DRIVE_1 ].fdd.wrprot ); + + + dt = &fdd_params[ option_enumerate_diskoptions_drive_opus2_type() ]; + fdd_init( &opus_drives[ OPUS_DRIVE_2 ].fdd, dt->enabled ? FDD_SHUGART : FDD_TYPE_NONE, + dt->heads, dt->cylinders, 1 ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2, dt->enabled ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_EJECT, + opus_drives[ OPUS_DRIVE_2 ].fdd.loaded ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_FLIP_SET, + !opus_drives[ OPUS_DRIVE_2 ].fdd.upsidedown ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_WP_SET, + !opus_drives[ OPUS_DRIVE_2 ].fdd.wrprot ); + + + opus_fdc->current_drive = &opus_drives[ 0 ]; + fdd_select( &opus_drives[ 0 ].fdd, 1 ); + machine_current->memory_map(); + opus_event_index( 0, index_event, NULL ); + + ui_statusbar_update( UI_STATUSBAR_ITEM_DISK, UI_STATUSBAR_STATE_INACTIVE ); +} + +void +opus_end( void ) +{ + opus_available = 0; +} + +/* + * opus_6821_access( reg, data, dir ) + * + * reg - register to access: + * + * data - if dir = 1 the value being written else ignored + * + * dir - direction of data. 0 = read, 1 = write + * + * returns: value of register if dir = 0 else 0 + * + * Mostly borrowed from EightyOne - A Windows ZX80/81/clone emulator + */ + +static libspectrum_byte +opus_6821_access( libspectrum_byte reg, libspectrum_byte data, + libspectrum_byte dir ) +{ + int drive, side; + int i; + + switch( reg & 0x03 ) { + case 0: + if( dir ) { + if( control_a & 0x04 ) { + data_reg_a = data; + + drive = ( data & 0x02 ) == 2 ? 1 : 0; + side = ( data & 0x10 )>>4 ? 1 : 0; + + for( i = 0; i < OPUS_NUM_DRIVES; i++ ) { + fdd_set_head( &opus_drives[ i ].fdd, side ); + } + + fdd_select( &opus_drives[ (!drive) ].fdd, 0 ); + fdd_select( &opus_drives[ drive ].fdd, 1 ); + + if( opus_fdc->current_drive != &opus_drives[ drive ] ) { + if( opus_fdc->current_drive->fdd.motoron ) { /* swap motoron */ + fdd_motoron( &opus_drives[ (!drive) ].fdd, 0 ); + fdd_motoron( &opus_drives[ drive ].fdd, 1 ); + } + opus_fdc->current_drive = &opus_drives[ drive ]; + } + } else { + data_dir_a = data; + } + } else { + if( control_a & 0x04 ) { + /* printer never busy (bit 6) */ + data_reg_a &= ~0x40; + return data_reg_a; + } else { + return data_dir_a; + } + } + break; + case 1: + if( dir ) { + control_a = data; + } else { + /* Always return bit 6 set to ACK parallel port actions */ + return control_a | 0x40; + } + break; + case 2: + if( dir ) { + if( control_b & 0x04 ) { + data_reg_b = data; + printer_parallel_write( 0x00, data ); + /* Don't worry about emulating the strobes from the ROM, they are + all bound up with checking current printer busy status which we + don't emulate, so just send the char now */ + printer_parallel_strobe_write( 0 ); + printer_parallel_strobe_write( 1 ); + printer_parallel_strobe_write( 0 ); + } else { + data_dir_b = data; + } + } else { + if( control_b & 0x04 ) { + return data_reg_b; + } else { + return data_dir_b; + } + } + break; + case 3: + if( dir ) { + control_b = data; + } else { + return control_b; + } + break; + } + + return 0; +} + +int +opus_disk_insert( opus_drive_number which, const char *filename, + int autoload ) +{ + int error; + wd_fdc_drive *d; + const fdd_params_t *dt; + + if( which >= OPUS_NUM_DRIVES ) { + ui_error( UI_ERROR_ERROR, "opus_disk_insert: unknown drive %d", + which ); + fuse_abort(); + } + + d = &opus_drives[ which ]; + + /* Eject any disk already in the drive */ + if( d->fdd.loaded ) { + /* Abort the insert if we want to keep the current disk */ + if( opus_disk_eject( which, 0 ) ) return 0; + } + + if( filename ) { + error = disk_open( &d->disk, filename, 0, DISK_TRY_MERGE( d->fdd.fdd_heads ) ); + if( error != DISK_OK ) { + ui_error( UI_ERROR_ERROR, "Failed to open disk image: %s", + disk_strerror( error ) ); + return 1; + } + } else { + switch( which ) { + case 0: + /* +1 => there is no `Disabled' */ + dt = &fdd_params[ option_enumerate_diskoptions_drive_opus1_type() + 1 ]; + break; + case 1: + default: + dt = &fdd_params[ option_enumerate_diskoptions_drive_opus2_type() ]; + break; + } + error = disk_new( &d->disk, dt->heads, dt->cylinders, DISK_DENS_AUTO, DISK_UDI ); + if( error != DISK_OK ) { + ui_error( UI_ERROR_ERROR, "Failed to create disk image: %s", + disk_strerror( error ) ); + return 1; + } + } + + fdd_load( &d->fdd, &d->disk, 0 ); + + /* Set the 'eject' item active */ + switch( which ) { + case OPUS_DRIVE_1: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_EJECT, 1 ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_FLIP_SET, + !opus_drives[ OPUS_DRIVE_1 ].fdd.upsidedown ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_WP_SET, + !opus_drives[ OPUS_DRIVE_1 ].fdd.wrprot ); + break; + case OPUS_DRIVE_2: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_EJECT, 1 ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_FLIP_SET, + !opus_drives[ OPUS_DRIVE_2 ].fdd.upsidedown ); + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_WP_SET, + !opus_drives[ OPUS_DRIVE_2 ].fdd.wrprot ); + break; + } + + if( filename && autoload ) { + /* XXX */ + } + + return 0; +} + +int +opus_disk_eject( opus_drive_number which, int write ) +{ + wd_fdc_drive *d; + + if( which >= OPUS_NUM_DRIVES ) + return 1; + + d = &opus_drives[ which ]; + + if( d->disk.type == DISK_TYPE_NONE ) + return 0; + + if( write ) { + + if( ui_opus_disk_write( which ) ) return 1; + + } else { + + if( d->disk.dirty ) { + + ui_confirm_save_t confirm = ui_confirm_save( + "Disk in Opus Discovery drive %c has been modified.\n" + "Do you want to save it?", + which == OPUS_DRIVE_1 ? '1' : '2' + ); + + switch( confirm ) { + + case UI_CONFIRM_SAVE_SAVE: + if( ui_opus_disk_write( which ) ) return 1; + break; + + case UI_CONFIRM_SAVE_DONTSAVE: break; + case UI_CONFIRM_SAVE_CANCEL: return 1; + + } + } + } + + fdd_unload( &d->fdd ); + disk_close( &d->disk ); + + /* Set the 'eject' item inactive */ + switch( which ) { + case OPUS_DRIVE_1: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_EJECT, 0 ); + break; + case OPUS_DRIVE_2: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_EJECT, 0 ); + break; + } + return 0; +} + +int +opus_disk_flip( opus_drive_number which, int flip ) +{ + wd_fdc_drive *d; + + if( which >= OPUS_NUM_DRIVES ) + return 1; + + d = &opus_drives[ which ]; + + if( !d->fdd.loaded ) + return 1; + + fdd_flip( &d->fdd, flip ); + + /* Update the 'write flip' menu item */ + switch( which ) { + case OPUS_DRIVE_1: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_FLIP_SET, + !opus_drives[ OPUS_DRIVE_1 ].fdd.upsidedown ); + break; + case OPUS_DRIVE_2: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_FLIP_SET, + !opus_drives[ OPUS_DRIVE_2 ].fdd.upsidedown ); + break; + } + return 0; +} + +int +opus_disk_writeprotect( opus_drive_number which, int wrprot ) +{ + wd_fdc_drive *d; + + if( which >= OPUS_NUM_DRIVES ) + return 1; + + d = &opus_drives[ which ]; + + if( !d->fdd.loaded ) + return 1; + + fdd_wrprot( &d->fdd, wrprot ); + + /* Update the 'write protect' menu item */ + switch( which ) { + case OPUS_DRIVE_1: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_1_WP_SET, + !opus_drives[ OPUS_DRIVE_1 ].fdd.wrprot ); + break; + case OPUS_DRIVE_2: + ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_OPUS_2_WP_SET, + !opus_drives[ OPUS_DRIVE_2 ].fdd.wrprot ); + break; + } + return 0; +} + +int +opus_disk_write( opus_drive_number which, const char *filename ) +{ + wd_fdc_drive *d = &opus_drives[ which ]; + int error; + + d->disk.type = DISK_TYPE_NONE; + error = disk_write( &d->disk, filename ); + + if( error != DISK_OK ) { + ui_error( UI_ERROR_ERROR, "couldn't write '%s' file: %s", filename, + disk_strerror( error ) ); + return 1; + } + + return 0; +} + +fdd_t * +opus_get_fdd( opus_drive_number which ) +{ + return &( opus_drives[ which ].fdd ); +} + +static void +opus_event_index( libspectrum_dword last_tstates, int type GCC_UNUSED, + void *user_data GCC_UNUSED ) +{ + int next_tstates; + int i; + + opus_index_pulse = !opus_index_pulse; + for( i = 0; i < OPUS_NUM_DRIVES; i++ ) { + wd_fdc_drive *d = &opus_drives[ i ]; + + d->index_pulse = opus_index_pulse; + if( !opus_index_pulse && d->index_interrupt ) { + wd_fdc_set_intrq( opus_fdc ); + d->index_interrupt = 0; + } + } + next_tstates = ( opus_index_pulse ? 10 : 190 ) * + machine_current->timings.processor_speed / 1000; + event_add( last_tstates + next_tstates, index_event ); +} + +libspectrum_byte +opus_read( libspectrum_word address ) +{ + libspectrum_byte data = 0xff; + + if( address >= 0x3800 ) data = 0xff; /* Undefined on Opus */ + else if( address >= 0x3000 ) /* 6821 PIA */ + data = opus_6821_access( address, 0, 0 ); + else if( address >= 0x2800 ) { /* WD1770 FDC */ + switch( address & 0x03 ) { + case 0: + data = wd_fdc_sr_read( opus_fdc ); + break; + case 1: + data = wd_fdc_tr_read( opus_fdc ); + break; + case 2: + data = wd_fdc_sec_read( opus_fdc ); + break; + case 3: + data = wd_fdc_dr_read( opus_fdc ); + break; + } + } + + return data; +} + +void +opus_write( libspectrum_word address, libspectrum_byte b ) +{ + if( address < 0x2000 ) return; + if( address >= 0x3800 ) return; + + if( address >= 0x3000 ) { + opus_6821_access( address, b, 1 ); + } else if( address >= 0x2800 ) { + switch( address & 0x03 ) { + case 0: + wd_fdc_cr_write( opus_fdc, b ); + break; + case 1: + wd_fdc_tr_write( opus_fdc, b ); + break; + case 2: + wd_fdc_sec_write( opus_fdc, b ); + break; + case 3: + wd_fdc_dr_write( opus_fdc, b ); + break; + } + } +} + +static libspectrum_byte * +alloc_and_copy_page( libspectrum_byte* source_page ) +{ + libspectrum_byte *buffer; + buffer = malloc( MEMORY_PAGE_SIZE ); + if( !buffer ) { + ui_error( UI_ERROR_ERROR, "Out of memory at %s:%d", __FILE__, + __LINE__ ); + return 0; + } + + memcpy( buffer, source_page, MEMORY_PAGE_SIZE ); + return buffer; +} + +static void +opus_enabled_snapshot( libspectrum_snap *snap ) +{ + if( libspectrum_snap_opus_active( snap ) ) + settings_current.opus = 1; +} + +static void +opus_from_snapshot( libspectrum_snap *snap ) +{ + if( !libspectrum_snap_opus_active( snap ) ) return; + + if( libspectrum_snap_opus_custom_rom( snap ) && + libspectrum_snap_opus_rom( snap, 0 ) && + machine_load_rom_bank_from_buffer( + memory_map_romcs, 0, 0, + libspectrum_snap_opus_rom( snap, 0 ), + MEMORY_PAGE_SIZE, + 1 ) ) + return; + + if( libspectrum_snap_opus_ram( snap, 0 ) ) { + memcpy( opus_ram, + libspectrum_snap_opus_ram( snap, 0 ), 0x800 ); + } + + /* ignore drive count for now, there will be an issue with loading snaps where + drives have been disabled + libspectrum_snap_opus_drive_count( snap ) + */ + + opus_fdc->direction = libspectrum_snap_opus_direction( snap ); + + wd_fdc_cr_write ( opus_fdc, libspectrum_snap_opus_status ( snap ) ); + wd_fdc_tr_write ( opus_fdc, libspectrum_snap_opus_track ( snap ) ); + wd_fdc_sec_write( opus_fdc, libspectrum_snap_opus_sector ( snap ) ); + wd_fdc_dr_write ( opus_fdc, libspectrum_snap_opus_data ( snap ) ); + data_reg_a = libspectrum_snap_opus_data_reg_a( snap ); + data_dir_a = libspectrum_snap_opus_data_dir_a( snap ); + control_a = libspectrum_snap_opus_control_a ( snap ); + data_reg_b = libspectrum_snap_opus_data_reg_b( snap ); + data_dir_b = libspectrum_snap_opus_data_dir_b( snap ); + control_b = libspectrum_snap_opus_control_b ( snap ); + + if( libspectrum_snap_opus_paged( snap ) ) { + opus_page(); + } else { + opus_unpage(); + } +} + +static void +opus_to_snapshot( libspectrum_snap *snap GCC_UNUSED ) +{ + libspectrum_byte *buffer; + int drive_count = 0; + + if( !periph_opus_active ) return; + + libspectrum_snap_set_opus_active( snap, 1 ); + + buffer = alloc_and_copy_page( memory_map_romcs[0].page ); + if( !buffer ) return; + libspectrum_snap_set_opus_rom( snap, 0, buffer ); + if( memory_map_romcs[0].source == MEMORY_SOURCE_CUSTOMROM ) + libspectrum_snap_set_opus_custom_rom( snap, 1 ); + + buffer = alloc_and_copy_page( opus_ram ); + if( !buffer ) return; + libspectrum_snap_set_opus_ram( snap, 0, buffer ); + + drive_count++; /* Drive 1 is not removable */ + if( option_enumerate_diskoptions_drive_opus2_type() > 0 ) drive_count++; + libspectrum_snap_set_opus_drive_count( snap, drive_count ); + + libspectrum_snap_set_opus_paged ( snap, opus_active ); + libspectrum_snap_set_opus_direction ( snap, opus_fdc->direction ); + libspectrum_snap_set_opus_status ( snap, opus_fdc->status_register ); + libspectrum_snap_set_opus_track ( snap, opus_fdc->track_register ); + libspectrum_snap_set_opus_sector ( snap, opus_fdc->sector_register ); + libspectrum_snap_set_opus_data ( snap, opus_fdc->data_register ); + libspectrum_snap_set_opus_data_reg_a( snap, data_reg_a ); + libspectrum_snap_set_opus_data_dir_a( snap, data_dir_a ); + libspectrum_snap_set_opus_control_a ( snap, control_a ); + libspectrum_snap_set_opus_data_reg_b( snap, data_reg_b ); + libspectrum_snap_set_opus_data_dir_b( snap, data_dir_b ); + libspectrum_snap_set_opus_control_b ( snap, control_b ); +} Copied: trunk/fuse/disk/opus.h (from rev 609, vendor/fuse-emulator/current/fuse/disk/opus.h) =================================================================== --- trunk/fuse/disk/opus.h (rev 0) +++ trunk/fuse/disk/opus.h 2009-08-02 10:35:36 UTC (rev 610) @@ -0,0 +1,65 @@ +/* opus.h: Routines for handling the Opus Discovery interface + Copyright (c) 2005-2009 Stuart Brady, Fredrick Meunier + + $Id: opus.h 4012 2009-04-16 12:42:14Z fredm $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + Philip: phi...@sh... + + Stuart: sd...@nt... + +*/ + +#ifndef FUSE_OPUS_H +#define FUSE_OPUS_H + +#include <config.h> + +typedef enum opus_drive_number { + OPUS_DRIVE_1 = 0, + OPUS_DRIVE_2, +} opus_drive_number; + +#include <libspectrum.h> + +#include "periph.h" +#include "disk/fdd.h" + +extern int opus_available; /* Is the Opus available for use? */ +extern int opus_active; /* Opus enabled? */ + +int opus_init( void ); +void opus_end( void ); + +void opus_page( void ); +void opus_unpage( void ); + +libspectrum_byte opus_read( libspectrum_word address ); +void opus_write( libspectrum_word address, libspectrum_byte b ); + +libspectrum_byte opus_joy_read( libspectrum_word port, int *attached ); + +int opus_disk_insert( opus_drive_number which, const char *filename, + int autoload ); +int opus_disk_eject( opus_drive_number which, int write ); +int opus_disk_write( opus_drive_number which, const char *filename ); +int opus_disk_flip( opus_drive_number which, int flip ); +int opus_disk_writeprotect( opus_drive_number which, int wrprot ); +fdd_t *opus_get_fdd( opus_drive_number which ); + +#endif /* #ifndef FUSE_OPUS_H */ Modified: trunk/fuse/disk/plusd.c =================================================================== --- trunk/fuse/disk/plusd.c 2009-08-01 14:03:19 UTC (rev 609) +++ trunk/fuse/disk/plusd.c 2009-08-02 10:35:36 UTC (rev 610) @@ -2,7 +2,7 @@ Copyright (c) 1999-2007 Stuart Brady, Fredrick Meunier, Philip Kendall, Dmitry Sanarin, Darren Salt - $Id: plusd.c 4012 2009-04-16 12:42:14Z fredm $ + $Id: plusd.c 4060 2009-07-30 13:21:38Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -654,8 +654,13 @@ libspectrum_snap_plusd_ram( snap, 0 ), 0x2000 ); } - plusd_fdc->direction = libspectrum_snap_beta_direction( snap ); + /* ignore drive count for now, there will be an issue with loading snaps where + drives have been disabled + libspectrum_snap_plusd_drive_count( snap ) + */ + plusd_fdc->direction = libspectrum_snap_plusd_direction( snap ); + plusd_cr_write ( 0x00e3, libspectrum_snap_plusd_status ( snap ) ); plusd_tr_write ( 0x00eb, libspectrum_snap_plusd_track ( snap ) ); plusd_sec_write( 0x00f3, libspectrum_snap_plusd_sector ( snap ) ); @@ -673,6 +678,7 @@ pl... [truncated message content] |
From: <fr...@us...> - 2009-08-02 11:03:33
|
Revision: 611 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=611&view=rev Author: fredm Date: 2009-08-02 11:03:25 +0000 (Sun, 02 Aug 2009) Log Message: ----------- Updates to UTI list for OPD and OPU, small fix for RAW type. Modified Paths: -------------- trunk/FuseGenerator/Info.plist trunk/FuseImporter/Info.plist trunk/fuse/fusepb/Info-Fuse.plist Modified: trunk/FuseGenerator/Info.plist =================================================================== --- trunk/FuseGenerator/Info.plist 2009-08-02 10:35:36 UTC (rev 610) +++ trunk/FuseGenerator/Info.plist 2009-08-02 11:03:25 UTC (rev 611) @@ -11,23 +11,32 @@ <string>QLGenerator</string> <key>LSItemContentTypes</key> <array> + <string>net.sourceforge.projects.fuse-emulator.Cartridge</string> + <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> <string>net.sourceforge.projects.fuse-emulator.Snapshot</string> <string>net.sourceforge.projects.fuse-emulator.Tape</string> - <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> - <string>net.sourceforge.projects.fuse-emulator.Cartridge</string> + <string>net.sourceforge.projects.fuse-emulator.csw</string> <string>net.sourceforge.projects.fuse-emulator.dck</string> - <string>net.sourceforge.projects.fuse-emulator.csw</string> + <string>net.sourceforge.projects.fuse-emulator.dsk</string> <string>net.sourceforge.projects.fuse-emulator.hdf</string> - <string>net.sourceforge.projects.fuse-emulator.dsk</string> + <string>net.sourceforge.projects.fuse-emulator.img</string> + <string>net.sourceforge.projects.fuse-emulator.ltp</string> + <string>net.sourceforge.projects.fuse-emulator.mdr</string> <string>net.sourceforge.projects.fuse-emulator.mgt</string> + <string>net.sourceforge.projects.fuse-emulator.mgtsnp</string> + <string>net.sourceforge.projects.fuse-emulator.opd</string> + <string>net.sourceforge.projects.fuse-emulator.opu</string> + <string>net.sourceforge.projects.fuse-emulator.raw</string> <string>net.sourceforge.projects.fuse-emulator.rzx</string> <string>net.sourceforge.projects.fuse-emulator.scl</string> <string>net.sourceforge.projects.fuse-emulator.scr</string> <string>net.sourceforge.projects.fuse-emulator.slt</string> <string>net.sourceforge.projects.fuse-emulator.sna</string> + <string>net.sourceforge.projects.fuse-emulator.snp</string> <string>net.sourceforge.projects.fuse-emulator.sp</string> + <string>net.sourceforge.projects.fuse-emulator.spc</string> + <string>net.sourceforge.projects.fuse-emulator.sta</string> <string>net.sourceforge.projects.fuse-emulator.szx</string> - <string>net.sourceforge.projects.fuse-emulator.snp</string> <string>net.sourceforge.projects.fuse-emulator.tap</string> <string>net.sourceforge.projects.fuse-emulator.trd</string> <string>net.sourceforge.projects.fuse-emulator.tzx</string> Modified: trunk/FuseImporter/Info.plist =================================================================== --- trunk/FuseImporter/Info.plist 2009-08-02 10:35:36 UTC (rev 610) +++ trunk/FuseImporter/Info.plist 2009-08-02 11:03:25 UTC (rev 611) @@ -13,10 +13,10 @@ <string>MDImporter</string> <key>LSItemContentTypes</key> <array> + <string>net.sourceforge.projects.fuse-emulator.Cartridge</string> + <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> <string>net.sourceforge.projects.fuse-emulator.Snapshot</string> <string>net.sourceforge.projects.fuse-emulator.Tape</string> - <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> - <string>net.sourceforge.projects.fuse-emulator.Cartridge</string> <string>net.sourceforge.projects.fuse-emulator.csw</string> <string>net.sourceforge.projects.fuse-emulator.dck</string> <string>net.sourceforge.projects.fuse-emulator.dsk</string> @@ -26,8 +26,10 @@ <string>net.sourceforge.projects.fuse-emulator.mdr</string> <string>net.sourceforge.projects.fuse-emulator.mgt</string> <string>net.sourceforge.projects.fuse-emulator.mgtsnp</string> + <string>net.sourceforge.projects.fuse-emulator.opd</string> + <string>net.sourceforge.projects.fuse-emulator.opu</string> + <string>net.sourceforge.projects.fuse-emulator.raw</string> <string>net.sourceforge.projects.fuse-emulator.rzx</string> - <string>net.sourceforge.projects.fuse-emulator.raw</string> <string>net.sourceforge.projects.fuse-emulator.scl</string> <string>net.sourceforge.projects.fuse-emulator.scr</string> <string>net.sourceforge.projects.fuse-emulator.slt</string> @@ -561,38 +563,57 @@ <dict> <key>UTTypeConformsTo</key> <array> + <string>net.sourceforge.projects.fuse-emulator.Tape</string> + </array> + <key>UTTypeDescription</key> + <string>ZX Spectrum RAW Tape Image</string> + <key>UTTypeIdentifier</key> + <string>net.sourceforge.projects.fuse-emulator.raw</string> + <key>UTTypeTagSpecification</key> + <dict> + <key>public.filename-extension</key> + <array> + <string>raw</string> + </array> + </dict> + </dict> + <dict> + <key>UTTypeConformsTo</key> + <array> <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> </array> <key>UTTypeDescription</key> - <string>ZX Spectrum DISCiPLE/+D Disk Image</string> + <string>ZX Spectrum Opus Discovery Disk Image</string> <key>UTTypeIdentifier</key> - <string>net.sourceforge.projects.fuse-emulator.img</string> + <string>net.sourceforge.projects.fuse-emulator.opd</string> <key>UTTypeReferenceURL</key> <string>http://www.worldofspectrum.org/faq/reference/formats.htm</string> <key>UTTypeTagSpecification</key> <dict> <key>public.filename-extension</key> <array> - <string>img</string> + <string>opd</string> </array> </dict> </dict> <dict> - <key>CFBundleTypeExtensions</key> + <key>UTTypeConformsTo</key> <array> - <string>raw</string> - <string>RAW</string> + <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> </array> - <key>CFBundleTypeIconFile</key> - <string>raw</string> - <key>CFBundleTypeName</key> - <string>ZX Spectrum Tape Image</string> - <key>CFBundleTypeRole</key> - <string>Viewer</string> - <key>LSItemContentTypes</key> - <array> - <string>net.sourceforge.projects.fuse-emulator.raw</string> - </array> + <key>UTTypeDescription</key> + <string>ZX Spectrum Opus Discovery Disk Image</string> + <key>UTTypeIdentifier</key> + <string>net.sourceforge.projects.fuse-emulator.opu</string> + <key>UTTypeReferenceURL</key> + <string>http://www.worldofspectrum.org/faq/reference/formats.htm</string> + <key>UTTypeTagSpecification</key> + <dict> + <key>public.filename-extension</key> + <array> + <string>opu</string> + </array> + </dict> </dict> </array> </dict> Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2009-08-02 10:35:36 UTC (rev 610) +++ trunk/fuse/fusepb/Info-Fuse.plist 2009-08-02 11:03:25 UTC (rev 611) @@ -456,6 +456,40 @@ <string>net.sourceforge.projects.fuse-emulator.mgt</string> </array> </dict> + <dict> + <key>CFBundleTypeExtensions</key> + <array> + <string>opd</string> + <string>OPD</string> + </array> + <key>CFBundleTypeIconFile</key> + <string>blank</string> + <key>CFBundleTypeName</key> + <string>ZX Spectrum Disk Image</string> + <key>CFBundleTypeRole</key> + <string>Viewer</string> + <key>LSItemContentTypes</key> + <array> + <string>net.sourceforge.projects.fuse-emulator.opd</string> + </array> + </dict> + <dict> + <key>CFBundleTypeExtensions</key> + <array> + <string>opu</string> + <string>OPU</string> + </array> + <key>CFBundleTypeIconFile</key> + <string>blank</string> + <key>CFBundleTypeName</key> + <string>ZX Spectrum Disk Image</string> + <key>CFBundleTypeRole</key> + <string>Viewer</string> + <key>LSItemContentTypes</key> + <array> + <string>net.sourceforge.projects.fuse-emulator.opu</string> + </array> + </dict> </array> <key>CFBundleExecutable</key> <string>Fuse</string> @@ -883,6 +917,61 @@ </array> </dict> </dict> + <dict> + <key>UTTypeConformsTo</key> + <array> + <string>net.sourceforge.projects.fuse-emulator.Tape</string> + </array> + <key>UTTypeDescription</key> + <string>ZX Spectrum RAW Tape Image</string> + <key>UTTypeIdentifier</key> + <string>net.sourceforge.projects.fuse-emulator.raw</string> + <key>UTTypeTagSpecification</key> + <dict> + <key>public.filename-extension</key> + <array> + <string>raw</string> + </array> + </dict> + </dict> + <dict> + <key>UTTypeConformsTo</key> + <array> + <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> + </array> + <key>UTTypeDescription</key> + <string>ZX Spectrum Opus Discovery Disk Image</string> + <key>UTTypeIdentifier</key> + <string>net.sourceforge.projects.fuse-emulator.opd</string> + <key>UTTypeReferenceURL</key> + <string>http://www.worldofspectrum.org/faq/reference/formats.htm</string> + <key>UTTypeTagSpecification</key> + <dict> + <key>public.filename-extension</key> + <array> + <string>opd</string> + </array> + </dict> + </dict> + <dict> + <key>UTTypeConformsTo</key> + <array> + <string>net.sourceforge.projects.fuse-emulator.MassStorage</string> + </array> + <key>UTTypeDescription</key> + <string>ZX Spectrum Opus Discovery Disk Image</string> + <key>UTTypeIdentifier</key> + <string>net.sourceforge.projects.fuse-emulator.opu</string> + <key>UTTypeReferenceURL</key> + <string>http://www.worldofspectrum.org/faq/reference/formats.htm</string> + <key>UTTypeTagSpecification</key> + <dict> + <key>public.filename-extension</key> + <array> + <string>opu</string> + </array> + </dict> + </dict> </array> </dict> </plist> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2009-09-05 10:44:55
|
Revision: 620 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=620&view=rev Author: fredm Date: 2009-09-05 10:44:44 +0000 (Sat, 05 Sep 2009) Log Message: ----------- Add x86_64 target to Universal Binary. This involves: * Drop competition mode RZX and libgcrypt - this is because the feature is rarely used and it is not trivial to make a x86_64 libgcrypt framework along with all the other targets, so I don't think it is worth the effort to retain. Will revisit if someone else makes a suitable framework. * Move to clang as the compiler for all libraries and plugins * Move to llvm-gcc42 as the compiler for Fuse * Switch to NSNumber rather than int where applicable * Move to 10.5 SDK as the target for all binaries * Add a macro to select the appropriate GINT_TO_POINTER/POINTER_TO_GINT implementation per target Modified Paths: -------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj trunk/FuseImporter/libspectrum.h trunk/README trunk/audiofile/audiofile.xcodeproj/project.pbxproj trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/nibs/Preferences.nib/designable.nib trunk/fuse/fusepb/nibs/Preferences.nib/keyedobjects.nib trunk/fuse/fusepb/resources/Fuse Help/html/preferences.html trunk/fuse/settings.pl trunk/libspectrum/config.h trunk/libspectrum/libspectrum.h trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj Removed Paths: ------------- trunk/libgcrypt/ Property Changed: ---------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/ trunk/FuseImporter/FuseImporter.xcodeproj/ trunk/audiofile/audiofile.xcodeproj/ Property changes on: trunk/FuseGenerator/FuseGenerator.xcodeproj ___________________________________________________________________ Modified: svn:ignore - *.pbxuser *.mode1v3 + *.pbxuser *.mode1v3 *.perspectivev3 Modified: trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2009-09-05 10:44:44 UTC (rev 620) @@ -525,10 +525,10 @@ isa = XCBuildConfiguration; buildSettings = { ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "ppc i386 ppc64 x86_64"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEAD_CODE_STRIPPING = YES; GCC_C_LANGUAGE_STANDARD = c99; - GCC_VERSION = 4.2; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; PREBINDING = NO; Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/FuseGenerator/libspectrum.h 2009-09-05 10:44:44 UTC (rev 620) @@ -200,8 +200,13 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#if defined __x86_64__ || defined __ppc64__ +#define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) +#define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#endif /* Library capabilities */ Property changes on: trunk/FuseImporter/FuseImporter.xcodeproj ___________________________________________________________________ Modified: svn:ignore - *.mode1 *.pbxuser + *.mode1 *.pbxuser *.perspectivev3 Modified: trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2009-09-05 10:44:44 UTC (rev 620) @@ -545,34 +545,34 @@ B6B0E30108CC65D5001D8411 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEBUG_INFORMATION_FORMAT = dwarf; - GCC_VERSION = 4.0; - SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; }; name = Development; }; B6B0E30208CC65D5001D8411 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; - GCC_VERSION = 4.0; - SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; }; name = Deployment; }; B6B0E30308CC65D5001D8411 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEBUG_INFORMATION_FORMAT = dwarf; - GCC_VERSION = 4.0; - SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; }; name = Default; }; Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/FuseImporter/libspectrum.h 2009-09-05 10:44:44 UTC (rev 620) @@ -200,8 +200,13 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#if defined __x86_64__ || defined __ppc64__ +#define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) +#define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#endif /* Library capabilities */ Modified: trunk/README =================================================================== --- trunk/README 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/README 2009-09-05 10:44:44 UTC (rev 620) @@ -21,9 +21,6 @@ cd audiofile xcodebuild -configuration Deployment cd .. -cd libgcrypt -xcodebuild -configuration Deployment -cd .. cd libspectrum xcodebuild -configuration Deployment cd .. Property changes on: trunk/audiofile/audiofile.xcodeproj ___________________________________________________________________ Modified: svn:ignore - *.mode1 *.pbxuser + *.mode1 *.pbxuser *.perspectivev3 Modified: trunk/audiofile/audiofile.xcodeproj/project.pbxproj =================================================================== --- trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2009-09-05 10:44:44 UTC (rev 620) @@ -392,50 +392,48 @@ B62395480C1CF4F8003B8E87 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = NO; FRAMEWORK_VERSION = 0.2.6; - GCC_VERSION = 4.0; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; MACOSX_DEPLOYMENT_TARGET = 10.4; - SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; + SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; }; name = Development; }; B62395490C1CF4F8003B8E87 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; FRAMEWORK_VERSION = 0.2.6; - GCC_VERSION = 4.0; - MACOSX_DEPLOYMENT_TARGET = 10.4; - SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + MACOSX_DEPLOYMENT_TARGET = 10.5; + SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; }; name = Deployment; }; B623954A0C1CF4F8003B8E87 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = NO; FRAMEWORK_VERSION = 0.2.6; - GCC_VERSION = 4.0; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; MACOSX_DEPLOYMENT_TARGET = 10.4; - SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; + SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; }; name = Default; }; B62395BD0C1CF586003B8E87 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; COPY_PHASE_STRIP = NO; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; @@ -444,7 +442,6 @@ GCC_ENABLE_FIX_AND_CONTINUE = YES; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 2; GCC_PREPROCESSOR_DEFINITIONS = ( HAVE_CONFIG_H, NDEBUG, @@ -477,8 +474,6 @@ B62395BE0C1CF586003B8E87 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; COPY_PHASE_STRIP = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; @@ -486,7 +481,6 @@ GCC_ENABLE_FIX_AND_CONTINUE = NO; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 2; GCC_PREPROCESSOR_DEFINITIONS = ( HAVE_CONFIG_H, NDEBUG, @@ -519,14 +513,11 @@ B62395BF0C1CF586003B8E87 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; FRAMEWORK_VERSION = 0.2.6; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 2; GCC_PREPROCESSOR_DEFINITIONS = ( HAVE_CONFIG_H, NDEBUG, Modified: trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj =================================================================== --- trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2009-09-05 10:44:44 UTC (rev 620) @@ -29,7 +29,6 @@ B61F459D09121DF100C8096C /* tape_plus2a.szx in CopyFiles */ = {isa = PBXBuildFile; fileRef = B650C4060765984000DE7E81 /* tape_plus2a.szx */; }; B61F459F09121DF100C8096C /* tape_scorpion.szx in CopyFiles */ = {isa = PBXBuildFile; fileRef = B650C40A0765988200DE7E81 /* tape_scorpion.szx */; }; B61F45A209121DF100C8096C /* spectrum.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = F541C04303963A9F01C2A5B9 /* spectrum.framework */; }; - B61F45A609121DF100C8096C /* gcrypt.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = B6BA1A8B04E4F3290017354F /* gcrypt.framework */; }; B61F45FF09121DF100C8096C /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */; }; B61F460009121DF100C8096C /* Credits.html in Resources */ = {isa = PBXBuildFile; fileRef = F5F291060396932B01730B00 /* Credits.html */; }; B61F460109121DF100C8096C /* Debugger.nib in Resources */ = {isa = PBXBuildFile; fileRef = B62E1BC303E298B200A80002 /* Debugger.nib */; }; @@ -162,7 +161,6 @@ B61F469B09121DF100C8096C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 29B97325FDCFA39411CA2CEA /* Foundation.framework */; }; B61F469C09121DF100C8096C /* AppKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 29B97324FDCFA39411CA2CEA /* AppKit.framework */; }; B61F469D09121DF100C8096C /* spectrum.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F541C04303963A9F01C2A5B9 /* spectrum.framework */; }; - B61F46A109121DF100C8096C /* gcrypt.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B6BA1A8B04E4F3290017354F /* gcrypt.framework */; }; B61F46A409121DF100C8096C /* FuseImporter.mdimporter in CopyFiles */ = {isa = PBXBuildFile; fileRef = B64FEA96084F8EC300879389 /* FuseImporter.mdimporter */; }; B6251C3E0C2EB24500BD5543 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B6251C3D0C2EB24500BD5543 /* QuartzCore.framework */; }; B62B19E10DD31DF500D42AAF /* scalers16.c in Sources */ = {isa = PBXBuildFile; fileRef = B62B19E00DD31DF500D42AAF /* scalers16.c */; }; @@ -296,7 +294,6 @@ files = ( B6FA75C60C1D76A5007F5A10 /* audiofile.framework in CopyFiles */, B61F45A209121DF100C8096C /* spectrum.framework in CopyFiles */, - B61F45A609121DF100C8096C /* gcrypt.framework in CopyFiles */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -488,7 +485,6 @@ B6B076B00B59FE9A00D4F95C /* Emulator.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = Emulator.h; sourceTree = "<group>"; }; B6B076B10B59FE9A00D4F95C /* Emulator.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = Emulator.m; sourceTree = "<group>"; }; B6B99F890B5F798700EE408F /* cocoadisplay.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = cocoadisplay.m; sourceTree = "<group>"; }; - B6BA1A8B04E4F3290017354F /* gcrypt.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = gcrypt.framework; path = ../../libgcrypt/build/Deployment/gcrypt.framework; sourceTree = SOURCE_ROOT; }; B6BA1A9404E4F88F0017354F /* uijoystick.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = uijoystick.h; path = ../ui/uijoystick.h; sourceTree = SOURCE_ROOT; }; B6BA6F0207B1E04200E44C8D /* Preferences.nib */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = Preferences.nib; path = nibs/Preferences.nib; sourceTree = "<group>"; }; B6C3479F044B091100E1BBA7 /* ts2068.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = ts2068.png; path = resources/ts2068.png; sourceTree = SOURCE_ROOT; }; @@ -662,7 +658,6 @@ B61F469B09121DF100C8096C /* Foundation.framework in Frameworks */, B61F469C09121DF100C8096C /* AppKit.framework in Frameworks */, B61F469D09121DF100C8096C /* spectrum.framework in Frameworks */, - B61F46A109121DF100C8096C /* gcrypt.framework in Frameworks */, B64E2A170A6534A3006863D9 /* Carbon.framework in Frameworks */, B6A6F0EE0B3D5F9E000B88E9 /* CoreAudio.framework in Frameworks */, B6A6F0F30B3D602F000B88E9 /* AudioUnit.framework in Frameworks */, @@ -696,7 +691,6 @@ isa = PBXGroup; children = ( B6FA759C0C1D7507007F5A10 /* audiofile.framework */, - B6BA1A8B04E4F3290017354F /* gcrypt.framework */, F541C04303963A9F01C2A5B9 /* spectrum.framework */, ); name = "Linked Frameworks"; @@ -1697,13 +1691,13 @@ B63319B4086803BA00732AA3 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; - GCC_VERSION = 4.0; + GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; YACCFLAGS = "-d"; @@ -1715,14 +1709,14 @@ B63319B5086803BA00732AA3 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; - GCC_VERSION = 4.0; + GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; YACCFLAGS = "-d"; @@ -1734,13 +1728,13 @@ B63319B6086803BA00732AA3 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; - GCC_VERSION = 4.0; + GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; YACCFLAGS = "-d"; Modified: trunk/fuse/fusepb/nibs/Preferences.nib/designable.nib =================================================================== --- trunk/fuse/fusepb/nibs/Preferences.nib/designable.nib 2009-09-04 22:58:49 UTC (rev 619) +++ trunk/fuse/fusepb/nibs/Preferences.nib/designable.nib 2009-09-05 10:44:44 UTC (rev 620) @@ -1,16 +1,20 @@ <?xml version="1.0" encoding="UTF-8"?> -<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.03"> +<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.10"> <data> <int key="IBDocument.SystemTarget">1050</int> - <string key="IBDocument.SystemVersion">9J61</string> - <string key="IBDocument.InterfaceBuilderVersion">677</string> - <string key="IBDocument.AppKitVersion">949.46</string> - <string key="IBDocument.HIToolboxVersion">353.00</string> + <string key="IBDocument.SystemVersion">10A432</string> + <string key="IBDocument.InterfaceBuilderVersion">732</string> + <string key="IBDocument.AppKitVersion">1038</string> + <string key="IBDocument.HIToolboxVersion">437.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string> + <string key="NS.object.0">732</string> + </object> <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="1347"/> <integer value="1446"/> <integer value="6"/> - <integer value="1347"/> </object> <object class="NSArray" key="IBDocument.PluginDependencies"> <bool key="EncodedWithXMLCoder">YES</bool> @@ -18,7 +22,7 @@ </object> <object class="NSMutableDictionary" key="IBDocument.Metadata"> <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> + <object class="NSArray" key="dict.sortedKeys" id="0"> <bool key="EncodedWithXMLCoder">YES</bool> </object> <object class="NSMutableArray" key="dict.values"> @@ -56,7 +60,7 @@ <int key="NSToolbarSizeMode">1</int> <object class="NSMutableDictionary" key="NSToolbarIBIdentifiedItems"> <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSMutableArray" key="dict.sortedKeys"> + <object class="NSArray" key="dict.sortedKeys"> <bool key="EncodedWithXMLCoder">YES</bool> <string>1D3C684F-4B0A-4828-ADF3-E4106D08C1CD</string> <string>2C4BF74A-9900-4A0E-A2FC-50ADDA64B166</string> @@ -269,11 +273,9 @@ <reference ref="943816128"/> <reference ref="141636598"/> </object> - <object class="NSMutableArray" key="NSToolbarIBSelectableItems"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> + <reference key="NSToolbarIBSelectableItems" ref="0"/> </object> - <string key="NSWindowContentMaxSize">{3.40282e+38, 3.40282e+38}</string> + <string key="NSWindowContentMaxSize">{1.79769e+308, 1.79769e+308}</string> <string key="NSWindowContentMinSize">{213, 107}</string> <object class="NSView" key="NSWindowView" id="41054612"> <reference key="NSNextResponder"/> @@ -283,7 +285,7 @@ </object> <string key="NSScreenRect">{{0, 0}, {1280, 778}}</string> <string key="NSMinSize">{213, 184}</string> - <string key="NSMaxSize">{3.40282e+38, 3.40282e+38}</string> + <string key="NSMaxSize">{1.79769e+308, 1.79769e+308}</string> <string key="NSFrameAutosaveName"/> </object> <object class="NSCustomView" id="869768206"> @@ -303,7 +305,7 @@ <string key="NSContents">Confirm actions</string> <object class="NSFont" key="NSSupport" id="447006373"> <string key="NSName">LucidaGrande</string> - <double key="NSSize">1.300000e+01</double> + <double key="NSSize">13</double> <int key="NSfFlags">1044</int> </object> <reference key="NSControlView" ref="382408068"/> @@ -483,7 +485,7 @@ <object class="NSNumberFormatter" key="NSFormatter" id="815687010"> <object class="NSMutableDictionary" key="NS.attributes"> <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSMutableArray" key="dict.sortedKeys"> + <object class="NSArray" key="dict.sortedKeys"> <bool key="EncodedWithXMLCoder">YES</bool> <string>allowsFloats</string> <string>decimalSeparator</string> @@ -498,14 +500,14 @@ </object> <object class="NSMutableArray" key="dict.values"> <bool key="EncodedWithXMLCoder">YES</bool> - <integer value="1" id="9"/> + <integer value="1"/> <string>.</string> <integer value="1000"/> <string>,</string> - <reference ref="9"/> - <reference ref="9"/> + <integer value="1"/> + <integer value="1"/> <string>-#,##0.00</string> - <integer value="3" id="11"/> + <integer value="3"/> <string>#,##0%</string> <boolean value="YES"/> </object> @@ -516,11 +518,9 @@ <nil key="NS.negativeattrs"/> <object class="NSAttributedString" key="NS.zero"> <string key="NSString">0</string> - <object class="NSDictionary" key="NSAttributes" id="625184385"> + <object class="NSDictionary" key="NSAttributes" id="833979005"> <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> + <reference key="dict.sortedKeys" ref="0"/> <object class="NSMutableArray" key="dict.values"> <bool key="EncodedWithXMLCoder">YES</bool> </object> @@ -531,9 +531,9 @@ </object> <object class="NSAttributedString" key="NS.nan"> <string key="NSString">NaN</string> - <reference key="NSAttributes" ref="625184385"/> + <reference key="NSAttributes" ref="833979005"/> </object> - <reference key="NS.min" ref="9"/> + <integer value="1" key="NS.min"/> <object class="NSDecimalNumberPlaceholder" key="NS.max" id="648108068"> <int key="NS.exponent">0</int> <int key="NS.length">0</int> @@ -550,12 +550,13 @@ <bool key="NS.allowsfloats">YES</bool> </object> <reference key="NSControlView" ref="418457192"/> - <double key="NSTitleWidth">1.610000e+02</double> + <double key="NSTitleWidth">161</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> <string key="NSContents">Emulation speed:</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="418457192"/> </object> </object> <object class="NSFormCell" id="319020855"> @@ -565,39 +566,39 @@ <object class="NSNumberFormatter" key="NSFormatter" id="657991658"> <object class="NSMutableDictionary" key="NS.attributes"> <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSMutableArray" key="dict.sortedKeys"> + <object class="NSArray" key="dict.sortedKeys"> <bool key="EncodedWithXMLCoder">YES</bool> <string>allowsFloats</string> <string>formatterBehavior</string> + <string>locale</string> <string>maximum</string> <string>minimum</string> <string>numberStyle</string> </object> <object class="NSMutableArray" key="dict.values"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="9"/> - <integer value="1040" id="736002568"/> - <real value="5.000000e+01" id="754928329"/> - <reference ref="9"/> - <integer value="0" id="8"/> + <integer value="1"/> + <integer value="1040"/> + <object class="NSLocale" id="514081757"> + <string key="NS.identifier"/> + </object> + <real value="50"/> + <integer value="1"/> + <integer value="0"/> </object> </object> <string key="NS.positiveformat">#</string> <string key="NS.negativeformat">#</string> <nil key="NS.positiveattrs"/> <nil key="NS.negativeattrs"/> - <object class="NSAttributedString" key="NS.zero"> - <nil key="NSString"/> - </object> - <object class="NSAttributedString" key="NS.nil"> - <nil key="NSString"/> - </object> + <nil key="NS.zero"/> + <nil key="NS.nil"/> <object class="NSAttributedString" key="NS.nan"> <string key="NSString">NaN</string> - <reference key="NSAttributes" ref="625184385"/> + <reference key="NSAttributes" ref="833979005"/> </object> - <reference key="NS.min" ref="9"/> - <reference key="NS.max" ref="754928329"/> + <integer value="1" key="NS.min"/> + <real value="50" key="NS.max"/> <object class="NSDecimalNumberHandler" key="NS.rounding"> <int key="NS.roundingmode">3</int> <bool key="NS.raise.overflow">YES</bool> @@ -607,17 +608,18 @@ <string key="NS.decimal">.</string> <string key="NS.thousand">,</string> <bool key="NS.hasthousands">NO</bool> - <bool key="NS.localized">YES</bool> + <bool key="NS.localized">NO</bool> <bool key="NS.allowsfloats">YES</bool> </object> + <reference key="NSControlView" ref="418457192"/> <int key="NSTag">1</int> - <reference key="NSControlView" ref="418457192"/> - <double key="NSTitleWidth">1.610000e+02</double> + <double key="NSTitleWidth">161</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> <string key="NSContents">Screen refresh rate (1:n):</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="418457192"/> </object> </object> </object> @@ -630,7 +632,7 @@ <int key="NSCellFlags2">205521920</int> <string key="NSContents"/> <reference key="NSSupport" ref="447006373"/> - <double key="NSTitleWidth">1.610000e+02</double> + <double key="NSTitleWidth">161</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> @@ -646,7 +648,7 @@ <string key="NSColorName">controlColor</string> <object class="NSColor" key="NSColor" id="429360493"> <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MC42NjY2NjY2OQA</bytes> + <bytes key="NSWhite">MC42NjY2NjY2NjY3AA</bytes> </object> </object> <object class="NSColor" key="NSCellBackgroundColor" id="70288484"> @@ -828,14 +830,14 @@ </object> <object class="NSFont" key="NSSupport" id="333640230"> <string key="NSName">Helvetica</string> - <double key="NSSize">1.200000e+01</double> + <double key="NSSize">12</double> <int key="NSfFlags">16</int> </object> <reference key="NSControlView" ref="524220653"/> - <double key="NSMaxValue">1.000000e+02</double> - <double key="NSMinValue">0.000000e+00</double> - <double key="NSValue">1.000000e+02</double> - <double key="NSAltIncValue">0.000000e+00</double> + <double key="NSMaxValue">100</double> + <double key="NSMinValue">0.0</double> + <double key="NSValue">100</double> + <double key="NSAltIncValue">0.0</double> <int key="NSNumberOfTickMarks">10</int> <int key="NSTickMarkPosition">0</int> <bool key="NSAllowsTickMarkValuesOnly">YES</bool> @@ -901,10 +903,10 @@ </object> <reference key="NSSupport" ref="333640230"/> <reference key="NSControlView" ref="1032556491"/> - <double key="NSMaxValue">1.000000e+02</double> - <double key="NSMinValue">0.000000e+00</double> - <double key="NSValue">1.000000e+02</double> - <double key="NSAltIncValue">0.000000e+00</double> + <double key="NSMaxValue">100</double> + <double key="NSMinValue">0.0</double> + <double key="NSValue">100</double> + <double key="NSAltIncValue">0.0</double> <int key="NSNumberOfTickMarks">10</int> <int key="NSTickMarkPosition">0</int> <bool key="NSAllowsTickMarkValuesOnly">YES</bool> @@ -1128,7 +1130,7 @@ <object class="NSMutableArray" key="NSCells"> <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSButtonCell" id="949804708"> - <int key="NSCellFlags">67239424</int> + <int key="NSCellFlags">-2080244224</int> <int key="NSCellFlags2">0</int> <string key="NSContents">None</string> <reference key="NSSupport" ref="447006373"/> @@ -1148,8 +1150,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">Interface I</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">1</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <reference key="NSAlternateImage" ref="32434582"/> @@ -1165,8 +1167,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">Simple 8-bit IDE</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">2</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <object class="NSImage" key="NSNormalImage"> @@ -1176,7 +1178,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -1202,7 +1204,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFugEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA</bytes> </object> </object> @@ -1222,8 +1224,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">ZXATASP interface</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">3</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <object class="NSImage" key="NSNormalImage"> @@ -1233,7 +1235,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -1259,7 +1261,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFugEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA</bytes> </object> </object> @@ -1276,8 +1278,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">ZXCF interface</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">4</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <object class="NSImage" key="NSNormalImage"> @@ -1287,7 +1289,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -1313,7 +1315,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFugEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA</bytes> </object> </object> @@ -1330,8 +1332,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">DivIDE</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">5</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <object class="NSImage" key="NSNormalImage"> @@ -1341,7 +1343,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -1367,7 +1369,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFxgEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFzodzAAcAAAwYAAAF1gAAAAAACAAIAAgACAABAAEAAQABAAAMGGFw cGwCAAAAbW50clJHQiBYWVogB9UABAAdABcANAAGYWNzcEFQUEwAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAPbWAAEAAAAA0y1hcHBsFNph5E4SJug5D71eq3yMqAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA @@ -1436,8 +1438,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">+D</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">6</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <reference key="NSAlternateImage" ref="32434582"/> @@ -1451,8 +1453,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">Beta 128</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">7</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <reference key="NSAlternateImage" ref="32434582"/> @@ -1466,8 +1468,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">Opus Discovery</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="833825163"/> <int key="NSTag">8</int> - <reference key="NSControlView" ref="833825163"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">0</int> <object class="NSImage" key="NSNormalImage"> @@ -1477,7 +1479,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -1503,7 +1505,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFxgEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFzodzAAcAAA8kAAAF1gAAAAAACAAIAAgACAABAAEAAQABAAAPJGFw cGwCAAAAbW50clJHQiBYWVogB9gACwAIABYALwApYWNzcEFQUEwAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAPbWAAEAAAAA0y1hcHBsijokxhhXhf8T3nB/TjyUvQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA @@ -1599,7 +1601,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -1625,7 +1627,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFxgEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFzodzAAcAAA8MAAAF1gAAAAAACAAIAAgACAABAAEAAQABAAAPDGFw cGwCAAAAbW50clJHQiBYWVogB9gAAQAKABIAGgAiYWNzcEFQUEwAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAPbWAAEAAAAA0y1hcHBsUwOvPlG1ySS6QFVbfQWioQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA @@ -1702,8 +1704,7 @@ <int key="NSPeriodicDelay">400</int> <int key="NSPeriodicInterval">75</int> </object> - <int key="NSSelectedRow">8</int> - <reference key="NSSelectedCell" ref="766217337"/> + <reference key="NSSelectedCell" ref="949804708"/> <reference key="NSBackgroundColor" ref="519317542"/> <reference key="NSCellBackgroundColor" ref="70288484"/> <reference key="NSFont" ref="447006373"/> @@ -1810,36 +1811,34 @@ <object class="NSNumberFormatter" key="NSFormatter" id="219085684"> <object class="NSMutableDictionary" key="NS.attributes"> <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSMutableArray" key="dict.sortedKeys"> + <object class="NSArray" key="dict.sortedKeys"> <bool key="EncodedWithXMLCoder">YES</bool> <string>allowsFloats</string> <string>formatterBehavior</string> + <string>locale</string> <string>maximumIntegerDigits</string> <string>minimum</string> </object> <object class="NSMutableArray" key="dict.values"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="9"/> - <reference ref="736002568"/> - <reference ref="11"/> - <reference ref="8"/> + <integer value="1"/> + <integer value="1040"/> + <reference ref="514081757"/> + <integer value="3"/> + <integer value="0"/> </object> </object> <string key="NS.positiveformat">#</string> <string key="NS.negativeformat">#</string> <nil key="NS.positiveattrs"/> <nil key="NS.negativeattrs"/> - <object class="NSAttributedString" key="NS.zero"> - <nil key="NSString"/> - </object> - <object class="NSAttributedString" key="NS.nil"> - <nil key="NSString"/> - </object> + <nil key="NS.zero"/> + <nil key="NS.nil"/> <object class="NSAttributedString" key="NS.nan"> <string key="NSString">NaN</string> - <reference key="NSAttributes" ref="625184385"/> + <reference key="NSAttributes" ref="833979005"/> </object> - <reference key="NS.min" ref="8"/> + <integer value="0" key="NS.min"/> <reference key="NS.max" ref="648108068"/> <object class="NSDecimalNumberHandler" key="NS.rounding"> <int key="NS.roundingmode">3</int> @@ -1850,16 +1849,17 @@ <string key="NS.decimal">.</string> <string key="NS.thousand">,</string> <bool key="NS.hasthousands">NO</bool> - <bool key="NS.localized">YES</bool> + <bool key="NS.localized">NO</bool> <bool key="NS.allowsfloats">YES</bool> </object> <reference key="NSControlView" ref="566156961"/> - <double key="NSTitleWidth">1.220000e+02</double> + <double key="NSTitleWidth">122</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> <string key="NSContents">MDR cartridge len:</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="566156961"/> </object> </object> </object> @@ -1872,7 +1872,7 @@ <int key="NSCellFlags2">205521920</int> <string key="NSContents"/> <reference key="NSSupport" ref="447006373"/> - <double key="NSTitleWidth">1.220000e+02</double> + <double key="NSTitleWidth">122</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> @@ -1900,7 +1900,7 @@ <string key="NSContents">Mass storage</string> <object class="NSFont" key="NSSupport" id="26"> <string key="NSName">LucidaGrande</string> - <double key="NSSize">1.100000e+01</double> + <double key="NSSize">11</double> <int key="NSfFlags">3100</int> </object> <object class="NSColor" key="NSBackgroundColor" id="553561812"> @@ -1942,13 +1942,13 @@ <int key="NSCellFlags2">137887744</int> <string key="NSContents">Choose...</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="816191277"/> <int key="NSTag">1</int> - <reference key="NSControlView" ref="816191277"/> <int key="NSButtonFlags">-2038284033</int> <int key="NSButtonFlags2">1</int> <object class="NSFont" key="NSAlternateImage" id="76913610"> <string key="NSName">Helvetica</string> - <double key="NSSize">1.300000e+01</double> + <double key="NSSize">13</double> <int key="NSfFlags">16</int> </object> <string key="NSAlternateContents"/> @@ -1998,12 +1998,13 @@ <string key="NSContents"/> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="158300595"/> - <double key="NSTitleWidth">1.310000e+02</double> + <double key="NSTitleWidth">131</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> <string key="NSContents">Graphic Output File:</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="158300595"/> </object> </object> <object class="NSFormCell" id="700509585"> @@ -2011,14 +2012,15 @@ <int key="NSCellFlags2">205521920</int> <string key="NSContents"/> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="158300595"/> <int key="NSTag">1</int> - <reference key="NSControlView" ref="158300595"/> - <double key="NSTitleWidth">1.310000e+02</double> + <double key="NSTitleWidth">131</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> <string key="NSContents">Text Output File:</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="158300595"/> </object> </object> </object> @@ -2031,7 +2033,7 @@ <int key="NSCellFlags2">205521920</int> <string key="NSContents"/> <reference key="NSSupport" ref="447006373"/> - <double key="NSTitleWidth">1.310000e+02</double> + <double key="NSTitleWidth">131</double> <object class="NSCell" key="NSTitleCell"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">67108864</int> @@ -2130,8 +2132,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">Fuller</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="159048013"/> <int key="NSTag">1</int> - <reference key="NSControlView" ref="159048013"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">128</int> <object class="NSImage" key="NSNormalImage"> @@ -2141,7 +2143,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -2167,10 +2169,10 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFxgEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFzodzAAcAAAwYAAAF1gAAAAAACAAIAAgACAABAAEAAQABAAAMGGFw cGwCAAAAbW50clJHQiBYWVogB9YABAADABMALAASYWNzcEFQUEwAAAAAAAAAAAAAAAAAAAAAAAAAAAAA -AAAAAPbWAAEAAAAA0y1hcHBs2U706y3Sst1fqit5+wYbUQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAPbWAAEAAAAA0y1hcHBsAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAOclhZWgAAASwAAAAUZ1hZWgAAAUAAAAAUYlhZWgAAAVQAAAAUd3RwdAAAAWgAAAAUY2hhZAAA AXwAAAAsclRSQwAAAagAAAAOZ1RSQwAAAbgAAAAOYlRSQwAAAcgAAAAOdmNndAAAAdgAAAMSbmRpbgAA BOwAAAY+ZGVzYwAACywAAABkZHNjbQAAC5AAAAAubW1vZAAAC8AAAAAoY3BydAAAC+gAAAAtWFlaIAAA @@ -2236,8 +2238,8 @@ <int key="NSCellFlags2">0</int> <string key="NSContents">Melodik</string> <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="159048013"/> <int key="NSTag">2</int> - <reference key="NSControlView" ref="159048013"/> <int key="NSButtonFlags">1211912703</int> <int key="NSButtonFlags2">128</int> <object class="NSImage" key="NSNormalImage"> @@ -2247,7 +2249,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -2273,7 +2275,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFxgEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFzodzAAcAAA8kAAAF1gAAAAAACAAIAAgACAABAAEAAQABAAAPJGFw cGwCAAAAbW50clJHQiBYWVogB9gACwAIABYALwApYWNzcEFQUEwAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAPbWAAEAAAAA0y1hcHBsijokxhhXhf8T3nB/TjyUvQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA @@ -2369,7 +2371,7 @@ <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray"> <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="8"/> + <integer value="0"/> <object class="NSBitmapImageRep"> <object class="NSData" key="NSTIFFRepresentation"> <bytes key="NS.bytes">TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA @@ -2395,7 +2397,7 @@ AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQEAAAMAAAABABIAAAEB AAMAAAABABIAAAECAAMAAAAEAAAFugEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES -AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABBxwAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA</bytes> </object> </object> @@ -2443,36 +2445,16 @@ <string key="NSClassName">NSView</string> </object> <object class="NSCustomView" id="76952719"> - <nil key="NSNextResponder"/> + <reference key="NSNextResponder"/> <int key="NSvFlags">268</int> <object class="NSMutableArray" key="NSSubviews"> <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSButton" id="676399466"> - <reference key="NSNextResponder" ref="76952719"/> - <int key="NSvFlags">256</int> - <string key="NSFrame">{{183, 70}, {145, 18}}</string> - <reference key="NSSuperview" ref="76952719"/> - <bool key="NSEnabled">YES</bool> - <object class="NSButtonCell" key="NSCell" id="807308919"> - <int key="NSCellFlags">67239424</int> - <int key="NSCellFlags2">0</int> - <string key="NSContents">Competition mode</string> - <reference key="NSSupport" ref="447006373"/> - <reference key="NSControlView" ref="676399466"/> - <int key="NSButtonFlags">1211912703</int> - <int key="NSButtonFlags2">2</int> - <reference key="NSAlternateImage" ref="529831564"/> - <string key="NSAlternateContents"/> - <string key="NSKeyEquivalent"/> - <int key="NSPeriodicDelay">200</int> - <int key="NSPeriodicInterval">25</int> - </object> - </object> <object class="NSButton" id="785777834"> <reference key="NSNextResponder" ref="76952719"/> <int key="NSvFlags">256</int> <string key="NSFrame">{{183, 90}, {145, 18}}</string> <reference key="NSSuperview" ref="76952719"/> + <reference key="NSWindow"/> <bool key="NSEnabled">YES</bool> <object class="NSButtonCell" key="NSCell" id="825652056"> <int key="NSCellFlags">67239424</int> @@ -2489,102 +2471,12 @@ <int key="NSPeriodicInterval">25</int> </object> </object> - <object class="NSForm" id="240510804"> - <reference key="NSNextResponder" ref="76952719"/> - <int key="NSvFlags">256</int> - <string key="NSFrame">{{185, 42}, {256, 22}}</string> - <reference key="NSSuperview" ref="76952719"/> - <bool key="NSEnabled">YES</bool> - <int key="NSNumRows">1</int> - <int key="NSNumCols">1</int> - <object class="NSMutableArray" key="NSCells"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSFormCell" id="555787033"> - <int key="NSCellFlags">-1804468671</int> - <int key="NSCellFlags2">205521920</int> - <reference key="NSSupport" ref="447006373"/> - <object class="NSNumberFormatter" key="NSFormatter" id="781258197"> - <object class="NSMutableDictionary" key="NS.attributes"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSMutableArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>allowsFloats</string> - <string>formatterBehavior</string> - <string>minimum</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="9"/> - <reference ref="736002568"/> - <reference ref="8"/> - </object> - </object> - <string key="NS.positiveformat">#</string> - <string key="NS.negativeformat">#</string> - <nil key="NS.positiveattrs"/> - <nil key="NS.negativeattrs"/> - <object class="NSAttributedString" key="NS.zero"> - <nil key="NSString"/> - </object> - <object class="NSAttributedString" key="NS.nil"> - <nil key="NSString"/> - </object> - <object class="NSAttributedString" key="NS.nan"> - <string key="NSString">NaN</string> - <reference key="NSAttributes" ref="625184385"/> - </object> - <reference key="NS.min" ref="8"/> - <reference key="NS.max" ref="648108068"/> - <object class="NSDecimalNumberHandler" key="NS.rounding"> - <int key="NS.roundingmode">3</int> - <bool key="NS.raise.overflow">YES</bool> - <bool key="NS.raise.underflow">YES</bool> - <bool key="NS.raise.dividebyzero">YES</bool> - </object> - <string key="NS.decimal">.</string> - <string key="NS.thousand">,</string> - <bool key="NS.hasthousands">NO</bool> - <bool key="NS.localized">YES</bool> - <bool key="NS.allowsfloats">YES</bool> - </object> - <reference key="NSControlView" ref="240510804"/> - <double key="NSTitleWidth">1.210000e+02</double> - <object class="NSCell" key="NSTitleCell"> - <int key="NSCellFlags">67239424</int> - <int key="NSCellFlags2">67108864</int> - <string key="NSContents">Competition code:</string> - <reference key="NSSupport" ref="447006373"/> - </object> - </object> - </object> - <string key="NSCellSize">{256, 22}</string> - <string key="NSIntercellSpacing">{1, 8}</string> - <int key="NSMatrixFlags">67633152</int> - <string key="NSCellClass">NSActionCell</string> - <object class="NSFormCell" key="NSProtoCell" id="1016506225"> - <int key="NSCellFlags">343014976</int> - <int key="NSCellFlags2">205521920</int> - <string key="NSContents"/> - <reference key="NSSupport" ref="447006373"/> - <double key="NSTitleWidth">1.210000e+02</double> - <object class="NSCell" key="NSTitleCell"> - <int key="NSCellFlags">67239424</int> - <int key="NSCellFlags2">67108864</int> - <string key="NSContents">Field:</string> - <reference key="NSSupport" ref="447006373"/> - </object> - </object> - <int key="NSSelectedRow">-1</int> - <int key="NSSelectedCol">-1</int> - <reference key="NSBackgroundColor" ref="519317542"/> - <reference key="NSCellBackgroundColor" ref="70288484"/> - <reference key="NSFont" ref="447006373"/> - </object> <object class="NSButton" id="742175854"> <reference key="NSNextResponder" ref="76952719"/> <int key="NSvFlags">256</int> - <string key="NSFrame">{{183, 18}, {175, 18}}</string> + <string key="NSFrame">{{183, 70}, {175, 18}}</string> <reference key="NSSuperview" ref="76952719"/> + <reference key="NSWindow"/> <bool key="NSEnabled">YES</bool> <object class="NSButtonCell" key="NSCell" id="167661398"> <int ... [truncated message content] |
From: <fr...@us...> - 2009-09-05 11:17:49
|
Revision: 621 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=621&view=rev Author: fredm Date: 2009-09-05 11:17:43 +0000 (Sat, 05 Sep 2009) Log Message: ----------- Use TargetConditionals.h macro rather than possibly gcc only macros. Modified Paths: -------------- trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/libspectrum.h trunk/libspectrum/libspectrum.h Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2009-09-05 10:44:44 UTC (rev 620) +++ trunk/FuseGenerator/libspectrum.h 2009-09-05 11:17:43 UTC (rev 621) @@ -38,6 +38,8 @@ #include <stdlib.h> #include <stdio.h> +#include <TargetConditionals.h> + #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN /* Exclude rarely used stuff from Windows @@ -200,7 +202,7 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); -#if defined __x86_64__ || defined __ppc64__ +#ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) #else Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2009-09-05 10:44:44 UTC (rev 620) +++ trunk/FuseImporter/libspectrum.h 2009-09-05 11:17:43 UTC (rev 621) @@ -38,6 +38,8 @@ #include <stdlib.h> #include <stdio.h> +#include <TargetConditionals.h> + #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN /* Exclude rarely used stuff from Windows @@ -200,7 +202,7 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); -#if defined __x86_64__ || defined __ppc64__ +#ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) #else Modified: trunk/libspectrum/libspectrum.h =================================================================== --- trunk/libspectrum/libspectrum.h 2009-09-05 10:44:44 UTC (rev 620) +++ trunk/libspectrum/libspectrum.h 2009-09-05 11:17:43 UTC (rev 621) @@ -38,6 +38,8 @@ #include <stdlib.h> #include <stdio.h> +#include <TargetConditionals.h> + #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN /* Exclude rarely used stuff from Windows @@ -199,7 +201,7 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); -#if defined __x86_64__ || defined __ppc64__ +#ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) #else This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2009-09-05 13:13:03
|
Revision: 622 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=622&view=rev Author: fredm Date: 2009-09-05 12:13:59 +0000 (Sat, 05 Sep 2009) Log Message: ----------- Remember that libspectrum.h is generated from generate.pl. Now the gcrypt removal sticks. Modified Paths: -------------- trunk/FuseGenerator/generate.pl trunk/FuseImporter/generate.pl trunk/libspectrum/generate.pl trunk/libspectrum/libspectrum.h Modified: trunk/FuseGenerator/generate.pl =================================================================== --- trunk/FuseGenerator/generate.pl 2009-09-05 11:17:43 UTC (rev 621) +++ trunk/FuseGenerator/generate.pl 2009-09-05 12:13:59 UTC (rev 622) @@ -141,8 +141,15 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#include <TargetConditionals.h> + +#ifdef TARGET_RT_64_BIT +#define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) +#define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#endif CODE } Modified: trunk/FuseImporter/generate.pl =================================================================== --- trunk/FuseImporter/generate.pl 2009-09-05 11:17:43 UTC (rev 621) +++ trunk/FuseImporter/generate.pl 2009-09-05 12:13:59 UTC (rev 622) @@ -141,8 +141,15 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#include <TargetConditionals.h> + +#ifdef TARGET_RT_64_BIT +#define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) +#define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#endif CODE } Modified: trunk/libspectrum/generate.pl =================================================================== --- trunk/libspectrum/generate.pl 2009-09-05 11:17:43 UTC (rev 621) +++ trunk/libspectrum/generate.pl 2009-09-05 12:13:59 UTC (rev 622) @@ -141,20 +141,27 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#include <TargetConditionals.h> + +#ifdef TARGET_RT_64_BIT +#define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) +#define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#endif CODE } if( /LIBSPECTRUM_INCLUDE_GCRYPT/ ) { - $_ = "#include <gcrypt.h>\n"; + $_ = ''; } if( /LIBSPECTRUM_SIGNATURE_PARAMETERS/ ) { - $_ = " /* The DSA signature parameters 'r' and 's' */\n gcry_mpi_t r, s;\n"; + $_ = "/* Signature parameters not stored as libgcrypt is not present */\n"; } Modified: trunk/libspectrum/libspectrum.h =================================================================== --- trunk/libspectrum/libspectrum.h 2009-09-05 11:17:43 UTC (rev 621) +++ trunk/libspectrum/libspectrum.h 2009-09-05 12:13:59 UTC (rev 622) @@ -38,8 +38,6 @@ #include <stdlib.h> #include <stdio.h> -#include <TargetConditionals.h> - #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN /* Exclude rarely used stuff from Windows @@ -64,6 +62,7 @@ #define DEPRECATED #endif /* #ifdef __GNUC__ */ + /* Standard typedefs */ #include <stdint.h> @@ -201,6 +200,8 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#include <TargetConditionals.h> + #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) @@ -855,8 +856,7 @@ int WIN32_DLL libspectrum_snap_fuller_box_active( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_fuller_box_active( libspectrum_snap *snap, int fuller_box_active ); int WIN32_DLL libspectrum_snap_melodik_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int - melodik_active ); +void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int melodik_active ); /* * Tape handling routines This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2009-09-05 13:33:28
|
Revision: 623 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=623&view=rev Author: fredm Date: 2009-09-05 13:33:22 +0000 (Sat, 05 Sep 2009) Log Message: ----------- Move to XCode 3.1 as the base version for the project files. Modified Paths: -------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj trunk/audiofile/audiofile.xcodeproj/project.pbxproj trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj Modified: trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2009-09-05 12:13:59 UTC (rev 622) +++ trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2009-09-05 13:33:22 UTC (rev 623) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 44; + objectVersion = 45; objects = { /* Begin PBXBuildFile section */ @@ -357,7 +357,7 @@ 089C1669FE841209C02AAC07 /* Project object */ = { isa = PBXProject; buildConfigurationList = 2CA326220896AD4900168862 /* Build configuration list for PBXProject "FuseGenerator" */; - compatibilityVersion = "Xcode 3.0"; + compatibilityVersion = "Xcode 3.1"; hasScannedForEncodings = 1; mainGroup = 089C166AFE841209C02AAC07 /* FuseGenerator */; projectDirPath = ""; @@ -509,30 +509,29 @@ 2CA326230896AD4900168862 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "ppc i386 ppc64 x86_64"; DEAD_CODE_STRIPPING = YES; GCC_C_LANGUAGE_STANDARD = c99; - GCC_VERSION = 4.2; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; PREBINDING = NO; - SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk"; + SDKROOT = macosx10.5; }; name = Debug; }; 2CA326240896AD4900168862 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEAD_CODE_STRIPPING = YES; GCC_C_LANGUAGE_STANDARD = c99; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; PREBINDING = NO; - SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk"; + SDKROOT = macosx10.5; }; name = Release; }; Modified: trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2009-09-05 12:13:59 UTC (rev 622) +++ trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2009-09-05 13:33:22 UTC (rev 623) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 42; + objectVersion = 45; objects = { /* Begin PBXBuildFile section */ @@ -332,7 +332,7 @@ 089C1669FE841209C02AAC07 /* Project object */ = { isa = PBXProject; buildConfigurationList = B6B0E30008CC65D5001D8411 /* Build configuration list for PBXProject "FuseImporter" */; - compatibilityVersion = "Xcode 2.4"; + compatibilityVersion = "Xcode 3.1"; hasScannedForEncodings = 1; mainGroup = 089C166AFE841209C02AAC07 /* FuseImporter */; projectDirPath = ""; @@ -545,34 +545,31 @@ B6B0E30108CC65D5001D8411 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; }; name = Development; }; B6B0E30208CC65D5001D8411 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; }; name = Deployment; }; B6B0E30308CC65D5001D8411 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; }; name = Default; }; Modified: trunk/audiofile/audiofile.xcodeproj/project.pbxproj =================================================================== --- trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2009-09-05 12:13:59 UTC (rev 622) +++ trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2009-09-05 13:33:22 UTC (rev 623) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 42; + objectVersion = 45; objects = { /* Begin PBXBuildFile section */ @@ -303,7 +303,7 @@ 000000000000000016601A90 /* Project object */ = { isa = PBXProject; buildConfigurationList = B62395470C1CF4F8003B8E87 /* Build configuration list for PBXProject "audiofile" */; - compatibilityVersion = "Xcode 2.4"; + compatibilityVersion = "Xcode 3.1"; hasScannedForEncodings = 1; mainGroup = 0000000000000000166142F0; projectDirPath = ""; @@ -392,42 +392,39 @@ B62395480C1CF4F8003B8E87 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = NO; FRAMEWORK_VERSION = 0.2.6; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - MACOSX_DEPLOYMENT_TARGET = 10.4; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + MACOSX_DEPLOYMENT_TARGET = 10.5; + SDKROOT = macosx10.5; }; name = Development; }; B62395490C1CF4F8003B8E87 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; FRAMEWORK_VERSION = 0.2.6; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; MACOSX_DEPLOYMENT_TARGET = 10.5; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; }; name = Deployment; }; B623954A0C1CF4F8003B8E87 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = NO; FRAMEWORK_VERSION = 0.2.6; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - MACOSX_DEPLOYMENT_TARGET = 10.4; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + MACOSX_DEPLOYMENT_TARGET = 10.5; + SDKROOT = macosx10.5; }; name = Default; }; Modified: trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj =================================================================== --- trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2009-09-05 12:13:59 UTC (rev 622) +++ trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2009-09-05 13:33:22 UTC (rev 623) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 42; + objectVersion = 45; objects = { /* Begin PBXBuildFile section */ @@ -1316,7 +1316,7 @@ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; buildConfigurationList = B63319B3086803BA00732AA3 /* Build configuration list for PBXProject "Fuse" */; - compatibilityVersion = "Xcode 2.4"; + compatibilityVersion = "Xcode 3.1"; hasScannedForEncodings = 1; mainGroup = 29B97314FDCFA39411CA2CEA /* Fuse */; projectDirPath = ""; @@ -1691,15 +1691,14 @@ B63319B4086803BA00732AA3 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; YACCFLAGS = "-d"; YACC_GENERATED_FILE_STEM = InputFileStem; ZERO_LINK = YES; @@ -1709,8 +1708,7 @@ B63319B5086803BA00732AA3 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; @@ -1718,7 +1716,7 @@ GCC_DYNAMIC_NO_PIC = YES; GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; YACCFLAGS = "-d"; YACC_GENERATED_FILE_STEM = InputFileStem; ZERO_LINK = NO; @@ -1728,15 +1726,14 @@ B63319B6086803BA00732AA3 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEAD_CODE_STRIPPING = YES; DEBUG_INFORMATION_FORMAT = dwarf; GCC_AUTO_VECTORIZATION = NO; GCC_DYNAMIC_NO_PIC = YES; GCC_VERSION = com.apple.compilers.llvmgcc42; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; YACCFLAGS = "-d"; YACC_GENERATED_FILE_STEM = InputFileStem; ZERO_LINK = NO; Modified: trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj =================================================================== --- trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj 2009-09-05 12:13:59 UTC (rev 622) +++ trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj 2009-09-05 13:33:22 UTC (rev 623) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 42; + objectVersion = 45; objects = { /* Begin PBXBuildFile section */ @@ -271,7 +271,7 @@ 000000000000000016410950 /* Project object */ = { isa = PBXProject; buildConfigurationList = B69A010D0A5F3BF500EEA5ED /* Build configuration list for PBXProject "libspectrum" */; - compatibilityVersion = "Xcode 2.4"; + compatibilityVersion = "Xcode 3.1"; hasScannedForEncodings = 1; mainGroup = 0000000000000000164109E0; projectDirPath = ""; @@ -351,34 +351,31 @@ B69A010E0A5F3BF500EEA5ED /* Development */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; }; name = Development; }; B69A010F0A5F3BF500EEA5ED /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; }; name = Deployment; }; B69A01100A5F3BF500EEA5ED /* Default */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "x86_64 i386 ppc"; + ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = /Developer/SDKs/MacOSX10.5.sdk; + SDKROOT = macosx10.5; }; name = Default; }; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2010-03-17 11:02:59
|
Revision: 633 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=633&view=rev Author: fredm Date: 2010-03-17 11:02:52 +0000 (Wed, 17 Mar 2010) Log Message: ----------- Statically link libspectrum as there doesn't seem to be any benefit to using the framework. Modified Paths: -------------- trunk/README trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/config.h Added Paths: ----------- trunk/fuse/fusepb/generate.pl trunk/fuse/fusepb/libspectrum trunk/fuse/fusepb/libspectrum.h Modified: trunk/README =================================================================== --- trunk/README 2010-01-16 09:34:06 UTC (rev 632) +++ trunk/README 2010-03-17 11:02:52 UTC (rev 633) @@ -6,23 +6,12 @@ Your Mac is expected to be running OS X 10.6 with the Xcode development environment. -The directory structure is expected to be: -fuse/ - FuseGenerator - FuseImporter - audiofile - fuse - libspectrum - Full build instructions: Uncompress the source package, and cd into the directory created. Then: cd audiofile xcodebuild -configuration Deployment cd .. -cd libspectrum -xcodebuild -configuration Deployment -cd .. cd FuseGenerator xcodebuild -configuration Release cd .. Modified: trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj =================================================================== --- trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2010-01-16 09:34:06 UTC (rev 632) +++ trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2010-03-17 11:02:52 UTC (rev 633) @@ -28,7 +28,6 @@ B61F459C09121DF100C8096C /* tape_plus3.szx in CopyFiles */ = {isa = PBXBuildFile; fileRef = B650C4080765986A00DE7E81 /* tape_plus3.szx */; }; B61F459D09121DF100C8096C /* tape_plus2a.szx in CopyFiles */ = {isa = PBXBuildFile; fileRef = B650C4060765984000DE7E81 /* tape_plus2a.szx */; }; B61F459F09121DF100C8096C /* tape_scorpion.szx in CopyFiles */ = {isa = PBXBuildFile; fileRef = B650C40A0765988200DE7E81 /* tape_scorpion.szx */; }; - B61F45A209121DF100C8096C /* spectrum.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = F541C04303963A9F01C2A5B9 /* spectrum.framework */; }; B61F45FF09121DF100C8096C /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */; }; B61F460009121DF100C8096C /* Credits.html in Resources */ = {isa = PBXBuildFile; fileRef = F5F291060396932B01730B00 /* Credits.html */; }; B61F460C09121DF100C8096C /* 48.rom in Resources */ = {isa = PBXBuildFile; fileRef = F559854C0389212301A804BA /* 48.rom */; }; @@ -148,9 +147,9 @@ B61F469A09121DF100C8096C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */; }; B61F469B09121DF100C8096C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 29B97325FDCFA39411CA2CEA /* Foundation.framework */; }; B61F469C09121DF100C8096C /* AppKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 29B97324FDCFA39411CA2CEA /* AppKit.framework */; }; - B61F469D09121DF100C8096C /* spectrum.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F541C04303963A9F01C2A5B9 /* spectrum.framework */; }; B61F46A409121DF100C8096C /* FuseImporter.mdimporter in CopyFiles */ = {isa = PBXBuildFile; fileRef = B64FEA96084F8EC300879389 /* FuseImporter.mdimporter */; }; B6251C3E0C2EB24500BD5543 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B6251C3D0C2EB24500BD5543 /* QuartzCore.framework */; }; + B629532E114FB265007808E0 /* libspectrum.h.in in Resources */ = {isa = PBXBuildFile; fileRef = B6DCBB7A114FA0E700DC9A11 /* libspectrum.h.in */; }; B62B19E10DD31DF500D42AAF /* scalers16.c in Sources */ = {isa = PBXBuildFile; fileRef = B62B19E00DD31DF500D42AAF /* scalers16.c */; }; B62B1A280DD6655800D42AAF /* fuse.c in Sources */ = {isa = PBXBuildFile; fileRef = B62B1A270DD6655800D42AAF /* fuse.c */; }; B62B1A2A0DD667EC00D42AAF /* main.mm in Sources */ = {isa = PBXBuildFile; fileRef = B62B1A290DD667EC00D42AAF /* main.mm */; }; @@ -235,6 +234,42 @@ B6CE3A190CD218A6005ACDC8 /* gluck.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6CE3A180CD218A6005ACDC8 /* gluck.rom */; }; B6CE7F420B2830A300EB65B3 /* cocoajoystick.c in Sources */ = {isa = PBXBuildFile; fileRef = B6CE7F3C0B2830A300EB65B3 /* cocoajoystick.c */; }; B6CE7FCE0B28FBD600EB65B3 /* DisplayOpenGLView.m in Sources */ = {isa = PBXBuildFile; fileRef = B6CE7FCC0B28FBD600EB65B3 /* DisplayOpenGLView.m */; }; + B6DCBBBF114FA0E700DC9A11 /* bzip2.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB62114FA0E700DC9A11 /* bzip2.c */; }; + B6DCBBC4114FA0E700DC9A11 /* creator.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB67114FA0E700DC9A11 /* creator.c */; }; + B6DCBBC5114FA0E700DC9A11 /* crypto.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB68114FA0E700DC9A11 /* crypto.c */; }; + B6DCBBC6114FA0E700DC9A11 /* csw.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB69114FA0E700DC9A11 /* csw.c */; }; + B6DCBBC7114FA0E700DC9A11 /* dck.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB6A114FA0E700DC9A11 /* dck.c */; }; + B6DCBBD2114FA0E700DC9A11 /* ide.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB77114FA0E700DC9A11 /* ide.c */; }; + B6DCBBD3114FA0E700DC9A11 /* internals.h in Headers */ = {isa = PBXBuildFile; fileRef = B6DCBB78114FA0E700DC9A11 /* internals.h */; }; + B6DCBBD4114FA0E700DC9A11 /* libspectrum.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB79114FA0E700DC9A11 /* libspectrum.c */; }; + B6DCBBD9114FA0E700DC9A11 /* memory.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB7E114FA0E700DC9A11 /* memory.c */; }; + B6DCBBDA114FA0E700DC9A11 /* microdrive.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB7F114FA0E700DC9A11 /* microdrive.c */; }; + B6DCBBDC114FA0E700DC9A11 /* garray.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB82114FA0E700DC9A11 /* garray.c */; }; + B6DCBBDD114FA0E700DC9A11 /* ghash.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB83114FA0E700DC9A11 /* ghash.c */; }; + B6DCBBDE114FA0E700DC9A11 /* gslist.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB84114FA0E700DC9A11 /* gslist.c */; }; + B6DCBBE0114FA0E700DC9A11 /* plusd.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB86114FA0E700DC9A11 /* plusd.c */; }; + B6DCBBE2114FA0E700DC9A11 /* rzx.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB88114FA0E700DC9A11 /* rzx.c */; }; + B6DCBBE3114FA0E700DC9A11 /* sna.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB89114FA0E700DC9A11 /* sna.c */; }; + B6DCBBE5114FA0E700DC9A11 /* snapshot.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB8B114FA0E700DC9A11 /* snapshot.c */; }; + B6DCBBE6114FA0E700DC9A11 /* snp.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB8C114FA0E700DC9A11 /* snp.c */; }; + B6DCBBE7114FA0E700DC9A11 /* sp.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB8D114FA0E700DC9A11 /* sp.c */; }; + B6DCBBE8114FA0E700DC9A11 /* symbol_table.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB8E114FA0E700DC9A11 /* symbol_table.c */; }; + B6DCBBE9114FA0E700DC9A11 /* szx.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB8F114FA0E700DC9A11 /* szx.c */; }; + B6DCBBEA114FA0E700DC9A11 /* tap.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB90114FA0E700DC9A11 /* tap.c */; }; + B6DCBBEB114FA0E700DC9A11 /* tape.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB91114FA0E700DC9A11 /* tape.c */; }; + B6DCBBEE114FA0E700DC9A11 /* tape_block.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB94114FA0E700DC9A11 /* tape_block.c */; }; + B6DCBBEF114FA0E700DC9A11 /* tape_block.h in Headers */ = {isa = PBXBuildFile; fileRef = B6DCBB95114FA0E700DC9A11 /* tape_block.h */; }; + B6DCBC0B114FA0E700DC9A11 /* timings.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB2114FA0E700DC9A11 /* timings.c */; }; + B6DCBC0C114FA0E700DC9A11 /* tzx_read.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB3114FA0E700DC9A11 /* tzx_read.c */; }; + B6DCBC0D114FA0E700DC9A11 /* tzx_write.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB4114FA0E700DC9A11 /* tzx_write.c */; }; + B6DCBC0E114FA0E700DC9A11 /* warajevo_read.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB5114FA0E700DC9A11 /* warajevo_read.c */; }; + B6DCBC0F114FA0E700DC9A11 /* wav.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB6114FA0E700DC9A11 /* wav.c */; }; + B6DCBC10114FA0E700DC9A11 /* z80.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB7114FA0E700DC9A11 /* z80.c */; }; + B6DCBC11114FA0E700DC9A11 /* z80em.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB8114FA0E700DC9A11 /* z80em.c */; }; + B6DCBC12114FA0E700DC9A11 /* zlib.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBB9114FA0E700DC9A11 /* zlib.c */; }; + B6DCBC13114FA0E700DC9A11 /* zxs.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBBBA114FA0E700DC9A11 /* zxs.c */; }; + B6DCBC96114FA67200DC9A11 /* tape_accessors.txt in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBC14114FA19F00DC9A11 /* tape_accessors.txt */; }; + B6DCBC97114FA67200DC9A11 /* snap_accessors.txt in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBC16114FA1AF00DC9A11 /* snap_accessors.txt */; }; B6DDE53C0D67963600D6F905 /* ui.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DDE53B0D67963600D6F905 /* ui.c */; }; B6E0252C0B38AFE500E23A0F /* keysyms.m in Sources */ = {isa = PBXBuildFile; fileRef = B6E0252B0B38AFE500E23A0F /* keysyms.m */; }; B6F047F60952A6D6006D8005 /* tape_se.szx in CopyFiles */ = {isa = PBXBuildFile; fileRef = B6F047F20952A6BA006D8005 /* tape_se.szx */; }; @@ -251,6 +286,43 @@ B6FA75C60C1D76A5007F5A10 /* audiofile.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = B6FA759C0C1D7507007F5A10 /* audiofile.framework */; }; /* End PBXBuildFile section */ +/* Begin PBXBuildRule section */ + B6DCBC42114FA33300DC9A11 /* PBXBuildRule */ = { + isa = PBXBuildRule; + compilerSpec = com.apple.compilers.proxy.script; + filePatterns = "*ibspectrum.h.in"; + fileType = pattern.proxy; + isEditable = 1; + outputFiles = ( + "${SRCROOT}/libspectrum.h", + ); + script = "perl -p ${SRCROOT}/generate.pl ${INPUT_FILE_PATH} > ${SRCROOT}/libspectrum.h"; + }; + B6DCBC47114FA3E100DC9A11 /* PBXBuildRule */ = { + isa = PBXBuildRule; + compilerSpec = com.apple.compilers.proxy.script; + filePatterns = "*ape_accessors.txt"; + fileType = pattern.proxy; + isEditable = 1; + outputFiles = ( + "$(DERIVED_FILE_DIR)/$(INPUT_FILE_BASE).c", + "$(DERIVED_FILE_DIR)/tape_set.c", + ); + script = "perl ${SRCROOT}/libspectrum/tape_accessors.pl ${INPUT_FILE_PATH} > ${DERIVED_FILE_DIR}/${INPUT_FILE_BASE}.c\nperl ${SRCROOT}/libspectrum/tape_set.pl ${INPUT_FILE_PATH} > ${DERIVED_FILE_DIR}/tape_set.c"; + }; + B6DCBC48114FA3E100DC9A11 /* PBXBuildRule */ = { + isa = PBXBuildRule; + compilerSpec = com.apple.compilers.proxy.script; + filePatterns = "*nap_accessors.txt"; + fileType = pattern.proxy; + isEditable = 1; + outputFiles = ( + "$(DERIVED_FILE_DIR)/$(INPUT_FILE_BASE).c", + ); + script = "perl ${SRCROOT}/libspectrum/accessor.pl ${INPUT_FILE_PATH} > ${DERIVED_FILE_DIR}/${INPUT_FILE_BASE}.c"; + }; +/* End PBXBuildRule section */ + /* Begin PBXCopyFilesBuildPhase section */ B604B2190DC1827200981CC7 /* CopyFiles */ = { isa = PBXCopyFilesBuildPhase; @@ -293,7 +365,6 @@ dstSubfolderSpec = 10; files = ( B6FA75C60C1D76A5007F5A10 /* audiofile.framework in CopyFiles */, - B61F45A209121DF100C8096C /* spectrum.framework in CopyFiles */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -541,6 +612,43 @@ B6CE7FCC0B28FBD600EB65B3 /* DisplayOpenGLView.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = DisplayOpenGLView.m; sourceTree = "<group>"; }; B6D2989105B061CB00C2AA14 /* MemoryBrowserController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MemoryBrowserController.h; path = controllers/MemoryBrowserController.h; sourceTree = "<group>"; }; B6D2989205B061CB00C2AA14 /* MemoryBrowserController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryBrowserController.m; path = controllers/MemoryBrowserController.m; sourceTree = "<group>"; }; + B6DCBB62114FA0E700DC9A11 /* bzip2.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bzip2.c; sourceTree = "<group>"; }; + B6DCBB67114FA0E700DC9A11 /* creator.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = creator.c; sourceTree = "<group>"; }; + B6DCBB68114FA0E700DC9A11 /* crypto.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = crypto.c; sourceTree = "<group>"; }; + B6DCBB69114FA0E700DC9A11 /* csw.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = csw.c; sourceTree = "<group>"; }; + B6DCBB6A114FA0E700DC9A11 /* dck.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = dck.c; sourceTree = "<group>"; }; + B6DCBB77114FA0E700DC9A11 /* ide.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = ide.c; sourceTree = "<group>"; }; + B6DCBB78114FA0E700DC9A11 /* internals.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = internals.h; sourceTree = "<group>"; }; + B6DCBB79114FA0E700DC9A11 /* libspectrum.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = libspectrum.c; sourceTree = "<group>"; }; + B6DCBB7A114FA0E700DC9A11 /* libspectrum.h.in */ = {isa = PBXFileReference; explicitFileType = text; fileEncoding = 4; path = libspectrum.h.in; sourceTree = "<group>"; }; + B6DCBB7E114FA0E700DC9A11 /* memory.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = memory.c; sourceTree = "<group>"; }; + B6DCBB7F114FA0E700DC9A11 /* microdrive.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = microdrive.c; sourceTree = "<group>"; }; + B6DCBB82114FA0E700DC9A11 /* garray.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = garray.c; sourceTree = "<group>"; }; + B6DCBB83114FA0E700DC9A11 /* ghash.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = ghash.c; sourceTree = "<group>"; }; + B6DCBB84114FA0E700DC9A11 /* gslist.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = gslist.c; sourceTree = "<group>"; }; + B6DCBB86114FA0E700DC9A11 /* plusd.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = plusd.c; sourceTree = "<group>"; }; + B6DCBB88114FA0E700DC9A11 /* rzx.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = rzx.c; sourceTree = "<group>"; }; + B6DCBB89114FA0E700DC9A11 /* sna.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = sna.c; sourceTree = "<group>"; }; + B6DCBB8B114FA0E700DC9A11 /* snapshot.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = snapshot.c; sourceTree = "<group>"; }; + B6DCBB8C114FA0E700DC9A11 /* snp.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = snp.c; sourceTree = "<group>"; }; + B6DCBB8D114FA0E700DC9A11 /* sp.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = sp.c; sourceTree = "<group>"; }; + B6DCBB8E114FA0E700DC9A11 /* symbol_table.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = symbol_table.c; sourceTree = "<group>"; }; + B6DCBB8F114FA0E700DC9A11 /* szx.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = szx.c; sourceTree = "<group>"; }; + B6DCBB90114FA0E700DC9A11 /* tap.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tap.c; sourceTree = "<group>"; }; + B6DCBB91114FA0E700DC9A11 /* tape.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tape.c; sourceTree = "<group>"; }; + B6DCBB94114FA0E700DC9A11 /* tape_block.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tape_block.c; sourceTree = "<group>"; }; + B6DCBB95114FA0E700DC9A11 /* tape_block.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tape_block.h; sourceTree = "<group>"; }; + B6DCBBB2114FA0E700DC9A11 /* timings.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = timings.c; sourceTree = "<group>"; }; + B6DCBBB3114FA0E700DC9A11 /* tzx_read.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tzx_read.c; sourceTree = "<group>"; }; + B6DCBBB4114FA0E700DC9A11 /* tzx_write.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tzx_write.c; sourceTree = "<group>"; }; + B6DCBBB5114FA0E700DC9A11 /* warajevo_read.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = warajevo_read.c; sourceTree = "<group>"; }; + B6DCBBB6114FA0E700DC9A11 /* wav.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = wav.c; sourceTree = "<group>"; }; + B6DCBBB7114FA0E700DC9A11 /* z80.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = z80.c; sourceTree = "<group>"; }; + B6DCBBB8114FA0E700DC9A11 /* z80em.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = z80em.c; sourceTree = "<group>"; }; + B6DCBBB9114FA0E700DC9A11 /* zlib.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = zlib.c; sourceTree = "<group>"; }; + B6DCBBBA114FA0E700DC9A11 /* zxs.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = zxs.c; sourceTree = "<group>"; }; + B6DCBC14114FA19F00DC9A11 /* tape_accessors.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = tape_accessors.txt; path = ../../libspectrum/libspectrum/tape_accessors.txt; sourceTree = SOURCE_ROOT; }; + B6DCBC16114FA1AF00DC9A11 /* snap_accessors.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = snap_accessors.txt; path = ../../libspectrum/libspectrum/snap_accessors.txt; sourceTree = SOURCE_ROOT; }; B6DDE5280D64D96E00D6F905 /* pentagon.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = pentagon.h; path = machines/pentagon.h; sourceTree = "<group>"; }; B6DDE53B0D67963600D6F905 /* ui.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; path = ui.c; sourceTree = "<group>"; }; B6E0252B0B38AFE500E23A0F /* keysyms.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = keysyms.m; sourceTree = "<group>"; }; @@ -579,7 +687,6 @@ B6FEA44F0444C3370013916D /* tc2068.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = tc2068.c; path = ../machines/tc2068.c; sourceTree = SOURCE_ROOT; }; F520C8BC038D022E01A804BA /* OpenGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGL.framework; path = /System/Library/Frameworks/OpenGL.framework; sourceTree = "<absolute>"; }; F536B56503A0C275011517A0 /* utils.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = utils.c; path = ../utils.c; sourceTree = SOURCE_ROOT; }; - F541C04303963A9F01C2A5B9 /* spectrum.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = spectrum.framework; path = ../../libspectrum/build/Deployment/spectrum.framework; sourceTree = SOURCE_ROOT; }; F541FB5E03B0B33401FF8235 /* scaler.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = scaler.h; path = ../ui/scaler/scaler.h; sourceTree = SOURCE_ROOT; }; F54670EB03A3F3E70143EC2C /* settings.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = settings.m; sourceTree = SOURCE_ROOT; }; F559854C0389212301A804BA /* 48.rom */ = {isa = PBXFileReference; lastKnownFileType = file; name = 48.rom; path = ../roms/48.rom; sourceTree = SOURCE_ROOT; }; @@ -657,7 +764,6 @@ B61F469A09121DF100C8096C /* Cocoa.framework in Frameworks */, B61F469B09121DF100C8096C /* Foundation.framework in Frameworks */, B61F469C09121DF100C8096C /* AppKit.framework in Frameworks */, - B61F469D09121DF100C8096C /* spectrum.framework in Frameworks */, B64E2A170A6534A3006863D9 /* Carbon.framework in Frameworks */, B6A6F0EE0B3D5F9E000B88E9 /* CoreAudio.framework in Frameworks */, B6A6F0F30B3D602F000B88E9 /* AudioUnit.framework in Frameworks */, @@ -691,7 +797,6 @@ isa = PBXGroup; children = ( B6FA759C0C1D7507007F5A10 /* audiofile.framework */, - F541C04303963A9F01C2A5B9 /* spectrum.framework */, ); name = "Linked Frameworks"; sourceTree = "<group>"; @@ -736,6 +841,7 @@ 29B97315FDCFA39411CA2CEA /* Other Sources */ = { isa = PBXGroup; children = ( + B6DCBB5D114FA0E700DC9A11 /* libspectrum */, B64BD1060FF6EB27000B82AE /* ide */, B63225E50C66B9D500BB081B /* compat */, B68CB2BC03DD91D800A804BA /* debugger */, @@ -1079,6 +1185,59 @@ path = views; sourceTree = "<group>"; }; + B6DCBB5D114FA0E700DC9A11 /* libspectrum */ = { + isa = PBXGroup; + children = ( + B6DCBB7A114FA0E700DC9A11 /* libspectrum.h.in */, + B6DCBC14114FA19F00DC9A11 /* tape_accessors.txt */, + B6DCBC16114FA1AF00DC9A11 /* snap_accessors.txt */, + B6DCBB80114FA0E700DC9A11 /* myglib */, + B6DCBB62114FA0E700DC9A11 /* bzip2.c */, + B6DCBB67114FA0E700DC9A11 /* creator.c */, + B6DCBB68114FA0E700DC9A11 /* crypto.c */, + B6DCBB69114FA0E700DC9A11 /* csw.c */, + B6DCBB6A114FA0E700DC9A11 /* dck.c */, + B6DCBB77114FA0E700DC9A11 /* ide.c */, + B6DCBB78114FA0E700DC9A11 /* internals.h */, + B6DCBB79114FA0E700DC9A11 /* libspectrum.c */, + B6DCBB7E114FA0E700DC9A11 /* memory.c */, + B6DCBB7F114FA0E700DC9A11 /* microdrive.c */, + B6DCBB86114FA0E700DC9A11 /* plusd.c */, + B6DCBB88114FA0E700DC9A11 /* rzx.c */, + B6DCBB89114FA0E700DC9A11 /* sna.c */, + B6DCBB8B114FA0E700DC9A11 /* snapshot.c */, + B6DCBB8C114FA0E700DC9A11 /* snp.c */, + B6DCBB8D114FA0E700DC9A11 /* sp.c */, + B6DCBB8E114FA0E700DC9A11 /* symbol_table.c */, + B6DCBB8F114FA0E700DC9A11 /* szx.c */, + B6DCBB90114FA0E700DC9A11 /* tap.c */, + B6DCBB91114FA0E700DC9A11 /* tape.c */, + B6DCBB94114FA0E700DC9A11 /* tape_block.c */, + B6DCBB95114FA0E700DC9A11 /* tape_block.h */, + B6DCBBB2114FA0E700DC9A11 /* timings.c */, + B6DCBBB3114FA0E700DC9A11 /* tzx_read.c */, + B6DCBBB4114FA0E700DC9A11 /* tzx_write.c */, + B6DCBBB5114FA0E700DC9A11 /* warajevo_read.c */, + B6DCBBB6114FA0E700DC9A11 /* wav.c */, + B6DCBBB7114FA0E700DC9A11 /* z80.c */, + B6DCBBB8114FA0E700DC9A11 /* z80em.c */, + B6DCBBB9114FA0E700DC9A11 /* zlib.c */, + B6DCBBBA114FA0E700DC9A11 /* zxs.c */, + ); + name = libspectrum; + path = fusepb/libspectrum; + sourceTree = "<group>"; + }; + B6DCBB80114FA0E700DC9A11 /* myglib */ = { + isa = PBXGroup; + children = ( + B6DCBB82114FA0E700DC9A11 /* garray.c */, + B6DCBB83114FA0E700DC9A11 /* ghash.c */, + B6DCBB84114FA0E700DC9A11 /* gslist.c */, + ); + path = myglib; + sourceTree = "<group>"; + }; B6DD457908134943008E9F7E /* Content Arrays */ = { isa = PBXGroup; children = ( @@ -1280,6 +1439,8 @@ B64BD1290FF701AA000B82AE /* options.h in Headers */, B64BD1790FF8E89B000B82AE /* options_cocoa.h in Headers */, B631BA0010257CA400BE1EE1 /* opus.h in Headers */, + B6DCBBD3114FA0E700DC9A11 /* internals.h in Headers */, + B6DCBBEF114FA0E700DC9A11 /* tape_block.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1301,6 +1462,9 @@ B604B2190DC1827200981CC7 /* CopyFiles */, ); buildRules = ( + B6DCBC47114FA3E100DC9A11 /* PBXBuildRule */, + B6DCBC48114FA3E100DC9A11 /* PBXBuildRule */, + B6DCBC42114FA33300DC9A11 /* PBXBuildRule */, ); dependencies = ( ); @@ -1346,6 +1510,7 @@ B6CE3A190CD218A6005ACDC8 /* gluck.rom in Resources */, B61F461509121DF100C8096C /* if1-1.rom in Resources */, B61F461609121DF100C8096C /* if1-2.rom in Resources */, + B631BA0F1025878600BE1EE1 /* opus.rom in Resources */, B61F461709121DF100C8096C /* plus2-0.rom in Resources */, B61F461809121DF100C8096C /* plus2-1.rom in Resources */, B61F461909121DF100C8096C /* plus3-0.rom in Resources */, @@ -1400,7 +1565,6 @@ B61159C70EEE9A080029FEA3 /* RZX.png in Resources */, B61159C90EEE9A140029FEA3 /* Select_ROMs.png in Resources */, B61159CB0EEE9A1E0029FEA3 /* Sound.png in Resources */, - B631BA0F1025878600BE1EE1 /* opus.rom in Resources */, B665EE031052A29F00FCFED8 /* Debugger.xib in Resources */, B665EE081052A34700FCFED8 /* JoystickConfiguration.xib in Resources */, B665EE0B1052A39000FCFED8 /* Keyboard.xib in Resources */, @@ -1413,6 +1577,7 @@ B665EE221052A4F200FCFED8 /* MainMenu.xib in Resources */, B665EE251052A51B00FCFED8 /* TapeBrowser.xib in Resources */, B665EE281052A53C00FCFED8 /* SavePanelAccessoryView.xib in Resources */, + B629532E114FB265007808E0 /* libspectrum.h.in in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1435,6 +1600,8 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( + B6DCBC96114FA67200DC9A11 /* tape_accessors.txt in Sources */, + B6DCBC97114FA67200DC9A11 /* snap_accessors.txt in Sources */, B61F463909121DF100C8096C /* z80_ops.c in Sources */, B61F463A09121DF100C8096C /* z80.c in Sources */, B61F463B09121DF100C8096C /* ay.c in Sources */, @@ -1557,6 +1724,38 @@ B64BD11E0FF6EF98000B82AE /* native.c in Sources */, B64BD1650FF8D284000B82AE /* options.m in Sources */, B631B9FF10257CA400BE1EE1 /* opus.c in Sources */, + B6DCBBBF114FA0E700DC9A11 /* bzip2.c in Sources */, + B6DCBBC4114FA0E700DC9A11 /* creator.c in Sources */, + B6DCBBC5114FA0E700DC9A11 /* crypto.c in Sources */, + B6DCBBC6114FA0E700DC9A11 /* csw.c in Sources */, + B6DCBBC7114FA0E700DC9A11 /* dck.c in Sources */, + B6DCBBD2114FA0E700DC9A11 /* ide.c in Sources */, + B6DCBBD4114FA0E700DC9A11 /* libspectrum.c in Sources */, + B6DCBBD9114FA0E700DC9A11 /* memory.c in Sources */, + B6DCBBDA114FA0E700DC9A11 /* microdrive.c in Sources */, + B6DCBBDC114FA0E700DC9A11 /* garray.c in Sources */, + B6DCBBDD114FA0E700DC9A11 /* ghash.c in Sources */, + B6DCBBDE114FA0E700DC9A11 /* gslist.c in Sources */, + B6DCBBE0114FA0E700DC9A11 /* plusd.c in Sources */, + B6DCBBE2114FA0E700DC9A11 /* rzx.c in Sources */, + B6DCBBE3114FA0E700DC9A11 /* sna.c in Sources */, + B6DCBBE5114FA0E700DC9A11 /* snapshot.c in Sources */, + B6DCBBE6114FA0E700DC9A11 /* snp.c in Sources */, + B6DCBBE7114FA0E700DC9A11 /* sp.c in Sources */, + B6DCBBE8114FA0E700DC9A11 /* symbol_table.c in Sources */, + B6DCBBE9114FA0E700DC9A11 /* szx.c in Sources */, + B6DCBBEA114FA0E700DC9A11 /* tap.c in Sources */, + B6DCBBEB114FA0E700DC9A11 /* tape.c in Sources */, + B6DCBBEE114FA0E700DC9A11 /* tape_block.c in Sources */, + B6DCBC0B114FA0E700DC9A11 /* timings.c in Sources */, + B6DCBC0C114FA0E700DC9A11 /* tzx_read.c in Sources */, + B6DCBC0D114FA0E700DC9A11 /* tzx_write.c in Sources */, + B6DCBC0E114FA0E700DC9A11 /* warajevo_read.c in Sources */, + B6DCBC0F114FA0E700DC9A11 /* wav.c in Sources */, + B6DCBC10114FA0E700DC9A11 /* z80.c in Sources */, + B6DCBC11114FA0E700DC9A11 /* z80em.c in Sources */, + B6DCBC12114FA0E700DC9A11 /* zlib.c in Sources */, + B6DCBC13114FA0E700DC9A11 /* zxs.c in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1580,8 +1779,6 @@ COPY_PHASE_STRIP = NO; FRAMEWORK_SEARCH_PATHS = ( "$(HOME)/Library/Frameworks", - ../../libspectrum/build/Deployment, - ../../libgcrypt/build/Deployment, ../../, "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", ); @@ -1595,14 +1792,17 @@ GCC_MODEL_CPU = G3; GCC_OPTIMIZATION_LEVEL = 0; HEADER_SEARCH_PATHS = ( - ../../libspectrum/build/Deployment/spectrum.framework/Headers, - ../../libgcrypt/build/Deployment/gcrypt.framework/Headers, + "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)/audiofile.framework/Headers", .., ); INFOPLIST_FILE = "Info-Fuse.plist"; INSTALL_PATH = "$(HOME)/Applications"; LIBRARY_SEARCH_PATHS = .; OTHER_CFLAGS_ppc = "-mmultiple -mpowerpc-gfxopt -falign-loops=16"; + OTHER_LDFLAGS = ( + "-lbz2", + "-lz", + ); PRODUCT_NAME = Fuse; SECTORDER_FLAGS = ""; USE_ALTIVEC = 1; @@ -1619,8 +1819,6 @@ COPY_PHASE_STRIP = YES; FRAMEWORK_SEARCH_PATHS = ( "$(HOME)/Library/Frameworks", - ../../libspectrum/build/Deployment, - ../../libgcrypt/build/Deployment, ../../, "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", ); @@ -1633,14 +1831,17 @@ GCC_MODEL_CPU = G3; GCC_OPTIMIZATION_LEVEL = 2; HEADER_SEARCH_PATHS = ( - ../../libspectrum/build/Deployment/spectrum.framework/Headers, - ../../libgcrypt/build/Deployment/gcrypt.framework/Headers, + "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)/audiofile.framework/Headers", .., ); INFOPLIST_FILE = "Info-Fuse.plist"; INSTALL_PATH = "$(HOME)/Applications"; LIBRARY_SEARCH_PATHS = .; OTHER_CFLAGS_ppc = "-mmultiple -mpowerpc-gfxopt -falign-loops=16"; + OTHER_LDFLAGS = ( + "-lbz2", + "-lz", + ); PREBINDING = NO; PRODUCT_NAME = Fuse; SECTORDER_FLAGS = ""; @@ -1656,10 +1857,6 @@ buildSettings = { FRAMEWORK_SEARCH_PATHS = ( "$(HOME)/Library/Frameworks", - ../../libspectrum/build/Deployment, - ../../lib765/build/Deployment, - ../../libgcrypt/build/Deployment, - ../../bzip2/build/Deployment, ../../, "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", ); @@ -1669,17 +1866,17 @@ GCC_ENABLE_OBJC_EXCEPTIONS = NO; GCC_OPTIMIZATION_LEVEL = 2; HEADER_SEARCH_PATHS = ( - ../../lib765/build/Deployment/765.framework/Headers, - ../../libspectrum/build/Deployment/spectrum.framework/Headers, - ../../libgcrypt/build/Deployment/gcrypt.framework/Headers, - ../../SDL.framework/Headers, - ../../bzip2/build/Deployment/libbz2.framework/Headers, + "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)/audiofile.framework/Headers", .., ); INFOPLIST_FILE = "Info-Fuse.plist"; INSTALL_PATH = "$(HOME)/Applications"; LIBRARY_SEARCH_PATHS = .; OTHER_CFLAGS_ppc = "-mmultiple -mpowerpc-gfxopt -falign-loops=16"; + OTHER_LDFLAGS = ( + "-lbz2", + "-lz", + ); PRODUCT_NAME = Fuse; SECTORDER_FLAGS = ""; WARNING_CFLAGS = "-Wall"; Modified: trunk/fuse/fusepb/config.h =================================================================== --- trunk/fuse/fusepb/config.h 2010-01-16 09:34:06 UTC (rev 632) +++ trunk/fuse/fusepb/config.h 2010-03-17 11:02:52 UTC (rev 633) @@ -175,3 +175,36 @@ #ifndef __cplusplus /* #undef inline */ #endif + +/* Define to 1 if you have the <dlfcn.h> header file. */ +#define HAVE_DLFCN_H 1 + +/* Define to 1 if you have the <gcrypt.h> header file. */ +/* #undef HAVE_GCRYPT_H */ + +/* Define to 1 if you have the `bz2' library (-lbz2). */ +#define HAVE_LIBBZ2 1 + +/* Defined if we've got audiofile */ +#define HAVE_LIB_AUDIOFILE 1 + +/* Define to 1 if you have the `snprintf' function. */ +#define HAVE_SNPRINTF 1 + +/* Define to 1 if you have the `strcasecmp' function. */ +#define HAVE_STRCASECMP 1 + +/* Define to 1 if you have the `strncasecmp' function. */ +#define HAVE_STRNCASECMP 1 + +/* Define to 1 if you have the <zlib.h> header file. */ +#define HAVE_ZLIB_H 1 + +/* Define to 1 if you have the `_snprintf' function. */ +/* #undef HAVE__SNPRINTF */ + +/* Define to 1 if you have the `_stricmp' function. */ +/* #undef HAVE__STRICMP */ + +/* Define to 1 if you have the `_strnicmp' function. */ +/* #undef HAVE__STRNICMP */ Copied: trunk/fuse/fusepb/generate.pl (from rev 623, trunk/FuseImporter/generate.pl) =================================================================== --- trunk/fuse/fusepb/generate.pl (rev 0) +++ trunk/fuse/fusepb/generate.pl 2010-03-17 11:02:52 UTC (rev 633) @@ -0,0 +1,256 @@ +if( /LIBSPECTRUM_DEFINE_TYPES/ ) { + + $_ = << "CODE"; +#include <stdint.h> + +typedef uint8_t libspectrum_byte; +typedef int8_t libspectrum_signed_byte; +typedef uint16_t libspectrum_word; +typedef int16_t libspectrum_signed_word; +typedef uint32_t libspectrum_dword; +typedef int32_t libspectrum_signed_dword; +typedef uint64_t libspectrum_qword; +typedef int64_t libspectrum_signed_qword; +CODE +} + +if( /LIBSPECTRUM_GLIB_REPLACEMENT/ ) { + + $_ = << "CODE"; +#ifndef FALSE +#define FALSE (0) +#endif + +#ifndef TRUE +#define TRUE (!FALSE) +#endif + +typedef char gchar; +typedef int gint; +typedef long glong; +typedef gint gboolean; +typedef unsigned int guint; +typedef const void * gconstpointer; +typedef void * gpointer; + +typedef struct _GSList GSList; + +struct _GSList { + gpointer data; + GSList *next; +}; + +typedef void (*GFunc) (gpointer data, + gpointer user_data); + +typedef gint (*GCompareFunc) (gconstpointer a, + gconstpointer b); + + +GSList WIN32_DLL *g_slist_insert_sorted (GSList *list, + gpointer data, + GCompareFunc func); + +GSList WIN32_DLL *g_slist_insert (GSList *list, + gpointer data, + gint position); + +GSList WIN32_DLL *g_slist_append (GSList *list, + gpointer data); + +GSList WIN32_DLL *g_slist_prepend (GSList *list, + gpointer data); + +GSList WIN32_DLL *g_slist_remove (GSList *list, + gpointer data); + +GSList WIN32_DLL *g_slist_delete_link (GSList *list, + GSList *link); + +guint WIN32_DLL g_slist_length (GSList *list); + +void WIN32_DLL g_slist_foreach (GSList *list, + GFunc func, + gpointer user_data); + +void WIN32_DLL g_slist_free (GSList *list); + +GSList WIN32_DLL *g_slist_last (GSList *list); + +GSList WIN32_DLL *g_slist_reverse (GSList *list); + +GSList WIN32_DLL *g_slist_nth (GSList *list, + guint n); + +GSList WIN32_DLL * g_slist_find_custom (GSList *list, + gpointer data, + GCompareFunc func ); + +gint WIN32_DLL g_slist_position (GSList *list, + GSList *llink); + +typedef struct _GHashTable GHashTable; + +typedef guint (*GHashFunc) (gconstpointer key); + +typedef gboolean (*GHRFunc) (gpointer key, + gpointer value, + gpointer user_data); + +gint WIN32_DLL g_int_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_int_hash (gconstpointer v); +gint WIN32_DLL g_str_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_str_hash (gconstpointer v); + +GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, + GCompareFunc key_compare_func); + +void WIN32_DLL g_hash_table_destroy (GHashTable *hash_table); + +void WIN32_DLL g_hash_table_insert (GHashTable *hash_table, + gpointer key, + gpointer value); + +gpointer WIN32_DLL g_hash_table_lookup (GHashTable *hash_table, + gconstpointer key); + +guint WIN32_DLL g_hash_table_foreach_remove (GHashTable *hash_table, + GHRFunc func, + gpointer user_data); + +guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); + +typedef struct _GArray GArray; + +struct _GArray { + /* Public */ + gchar *data; + size_t len; + + /* Private */ + guint element_size; + size_t allocated; +}; + +GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); +#define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); +GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +#define g_array_index(a,t,i) (*(((t*)a->data)+i)) +GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); + +#include <TargetConditionals.h> + +#ifdef TARGET_RT_64_BIT +#define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) +#define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#else +#define GINT_TO_POINTER(i) ((gpointer) (i)) +#define GPOINTER_TO_INT(p) ((gint) (p)) +#endif +CODE +} + +if( /LIBSPECTRUM_INCLUDE_GCRYPT/ ) { + + $_ = ''; + +} + +if( /LIBSPECTRUM_SIGNATURE_PARAMETERS/ ) { + + $_ = "/* Signature parameters not stored as libgcrypt is not present */ +"; + +} + +if( /LIBSPECTRUM_CAPABILITIES/ ) { + + $_ = << "CODE"; + +/* we support snapshots etc. requiring zlib (e.g. compressed szx) */ +#define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) +CODE +} + +if( /LIBSPECTRUM_SNAP_ACCESSORS/ ) { + + open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; + + $_ = ''; + while( <DATAFILE> ) { + + next if /^\s*$/; next if /^\s*#/; + + my( $type, $name, $indexed ) = split; + + my $return_type; + if( $type =~ /^(.*)\*/ ) { + $return_type = "$1 WIN32_DLL *"; + } else { + $return_type = "$type WIN32_DLL"; + } + + if( $indexed ) { + + print << "CODE"; +$return_type libspectrum_snap_$name( libspectrum_snap *snap, int idx ); +void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); +CODE + + } else { + + print << "CODE"; +$return_type libspectrum_snap_$name( libspectrum_snap *snap ); +void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); +CODE + + } + } +} + +if( /LIBSPECTRUM_TAPE_ACCESSORS/ ) { + + open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) + or die "Couldn't open `$ENV{SRCROOT}/libspectrum/tape_accessors.txt': $!"; + + $_ = ''; + while( <DATAFILE> ) { + + # Remove comments and blank lines + s/#.*//; + next if /^\s*$/; + + # Skip which block types each accessor applies to + next if /^\s/; + + my( $type, $name, $indexed, undef ) = split; + + my $return_type; + if( $type =~ /^(.*)\*/ ) { + $return_type = "$1 WIN32_DLL *"; + } else { + $return_type = "$type WIN32_DLL"; + } + + if( $indexed ) { + + print << "CODE"; +$return_type libspectrum_tape_block_$name( libspectrum_tape_block *block, size_t idx ); +libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); +CODE + + } else { + + print << "CODE"; +$return_type libspectrum_tape_block_$name( libspectrum_tape_block *block ); +libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); +CODE + + } + } + + close DATAFILE or die "Couldn't close `$ENV{SRCROOT}/libspectrum/tape_accessors.txt': $!"; +} Added: trunk/fuse/fusepb/libspectrum =================================================================== --- trunk/fuse/fusepb/libspectrum (rev 0) +++ trunk/fuse/fusepb/libspectrum 2010-03-17 11:02:52 UTC (rev 633) @@ -0,0 +1 @@ +link ../../libspectrum/libspectrum \ No newline at end of file Property changes on: trunk/fuse/fusepb/libspectrum ___________________________________________________________________ Added: svn:special + * Copied: trunk/fuse/fusepb/libspectrum.h (from rev 623, trunk/libspectrum/libspectrum.h) =================================================================== --- trunk/fuse/fusepb/libspectrum.h (rev 0) +++ trunk/fuse/fusepb/libspectrum.h 2010-03-17 11:02:52 UTC (rev 633) @@ -0,0 +1,1419 @@ +/* libspectrum.h: the library for dealing with ZX Spectrum emulator files + Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier + + $Id: libspectrum.h.in 4060 2009-07-30 13:21:38Z fredm $ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + Author contact information: + + E-mail: phi...@sh... + +*/ + +/* NB: This file is autogenerated from libspectrum.h.in. Do not edit + unless you know what you're doing */ + +#ifndef LIBSPECTRUM_LIBSPECTRUM_H +#define LIBSPECTRUM_LIBSPECTRUM_H + +#ifdef __cplusplus +extern "C" { +#endif /* #ifdef __cplusplus */ + +#include <stdarg.h> +#include <stddef.h> +#include <stdlib.h> +#include <stdio.h> + +#ifdef _WIN32 + +#define WIN32_LEAN_AND_MEAN /* Exclude rarely used stuff from Windows + headers */ +#include <windows.h> + +#ifdef LIBSPECTRUM_EXPORTS +#define WIN32_DLL __declspec( dllexport ) +#else /* #ifdef LIBSPECTRUM_EXPORTS */ +#define WIN32_DLL __declspec( dllimport ) +#endif /* #ifdef LIBSPECTRUM_EXPORTS */ + +#else /* #ifdef _WIN32 */ + +#define WIN32_DLL + +#endif /* #ifdef _WIN32 */ + +#ifdef __GNUC__ +#define DEPRECATED __attribute__((deprecated)) +#else /* #ifdef __GNUC__ */ +#define DEPRECATED +#endif /* #ifdef __GNUC__ */ + + +/* Standard typedefs */ +#include <stdint.h> + +typedef uint8_t libspectrum_byte; +typedef int8_t libspectrum_signed_byte; +typedef uint16_t libspectrum_word; +typedef int16_t libspectrum_signed_word; +typedef uint32_t libspectrum_dword; +typedef int32_t libspectrum_signed_dword; +typedef uint64_t libspectrum_qword; +typedef int64_t libspectrum_signed_qword; + +/* glib replacement (if necessary) */ +#ifndef FALSE +#define FALSE (0) +#endif + +#ifndef TRUE +#define TRUE (!FALSE) +#endif + +typedef char gchar; +typedef int gint; +typedef long glong; +typedef gint gboolean; +typedef unsigned int guint; +typedef const void * gconstpointer; +typedef void * gpointer; + +typedef struct _GSList GSList; + +struct _GSList { + gpointer data; + GSList *next; +}; + +typedef void (*GFunc) (gpointer data, + gpointer user_data); + +typedef gint (*GCompareFunc) (gconstpointer a, + gconstpointer b); + + +GSList WIN32_DLL *g_slist_insert_sorted (GSList *list, + gpointer data, + GCompareFunc func); + +GSList WIN32_DLL *g_slist_insert (GSList *list, + gpointer data, + gint position); + +GSList WIN32_DLL *g_slist_append (GSList *list, + gpointer data); + +GSList WIN32_DLL *g_slist_prepend (GSList *list, + gpointer data); + +GSList WIN32_DLL *g_slist_remove (GSList *list, + gpointer data); + +GSList WIN32_DLL *g_slist_delete_link (GSList *list, + GSList *link); + +guint WIN32_DLL g_slist_length (GSList *list); + +void WIN32_DLL g_slist_foreach (GSList *list, + GFunc func, + gpointer user_data); + +void WIN32_DLL g_slist_free (GSList *list); + +GSList WIN32_DLL *g_slist_last (GSList *list); + +GSList WIN32_DLL *g_slist_reverse (GSList *list); + +GSList WIN32_DLL *g_slist_nth (GSList *list, + guint n); + +GSList WIN32_DLL * g_slist_find_custom (GSList *list, + gpointer data, + GCompareFunc func ); + +gint WIN32_DLL g_slist_position (GSList *list, + GSList *llink); + +typedef struct _GHashTable GHashTable; + +typedef guint (*GHashFunc) (gconstpointer key); + +typedef gboolean (*GHRFunc) (gpointer key, + gpointer value, + gpointer user_data); + +gint WIN32_DLL g_int_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_int_hash (gconstpointer v); +gint WIN32_DLL g_str_equal (gconstpointer v, + gconstpointer v2); +guint WIN32_DLL g_str_hash (gconstpointer v); + +GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, + GCompareFunc key_compare_func); + +void WIN32_DLL g_hash_table_destroy (GHashTable *hash_table); + +void WIN32_DLL g_hash_table_insert (GHashTable *hash_table, + gpointer key, + gpointer value); + +gpointer WIN32_DLL g_hash_table_lookup (GHashTable *hash_table, + gconstpointer key); + +guint WIN32_DLL g_hash_table_foreach_remove (GHashTable *hash_table, + GHRFunc func, + gpointer user_data); + +guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); + +typedef struct _GArray GArray; + +struct _GArray { + /* Public */ + gchar *data; + size_t len; + + /* Private */ + guint element_size; + size_t allocated; +}; + +GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); +#define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); +GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +#define g_array_index(a,t,i) (*(((t*)a->data)+i)) +GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); + +#include <TargetConditionals.h> + +#ifdef TARGET_RT_64_BIT +#define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) +#define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#else +#define GINT_TO_POINTER(i) ((gpointer) (i)) +#define GPOINTER_TO_INT(p) ((gint) (p)) +#endif + +/* Library capabilities */ + +/* we support snapshots etc. requiring zlib (e.g. compressed szx) */ +#define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) + +/* + * General libspectrum routines + */ + +/* Error handling */ + +/* The various errors which can occur */ +typedef enum libspectrum_error { + + LIBSPECTRUM_ERROR_NONE = 0, + + LIBSPECTRUM_ERROR_WARNING, + + LIBSPECTRUM_ERROR_MEMORY, + LIBSPECTRUM_ERROR_UNKNOWN, + LIBSPECTRUM_ERROR_CORRUPT, + LIBSPECTRUM_ERROR_SIGNATURE, + LIBSPECTRUM_ERROR_SLT, /* .slt data found at end of a .z80 file */ + LIBSPECTRUM_ERROR_INVALID, /* Invalid parameter supplied */ + + LIBSPECTRUM_ERROR_LOGIC = -1, + +} libspectrum_error; + +/* Initialisation */ + +libspectrum_error WIN32_DLL libspectrum_init( void ); + +/* Version checking */ + +int WIN32_DLL libspectrum_check_version( const char *version ); +const char WIN32_DLL *libspectrum_version( void ); +const char WIN32_DLL *libspectrum_gcrypt_version( void ); + +/* Error handling */ +typedef libspectrum_error +(*libspectrum_error_function_t)( libspectrum_error error, + const char *format, va_list ap ); + +extern libspectrum_error_function_t WIN32_DLL libspectrum_error_function; + +libspectrum_error WIN32_DLL +libspectrum_default_error_function( libspectrum_error error, + const char *format, va_list ap ); + +/* Memory allocators */ + +typedef void* (*libspectrum_malloc_fn_t)( size_t size ); +typedef void* (*libspectrum_calloc_fn_t)( size_t nmemb, size_t size ); +typedef void* (*libspectrum_realloc_fn_t)( void *ptr, size_t size ); +typedef void (*libspectrum_free_fn_t)( void *ptr ); + +typedef struct libspectrum_mem_vtable_t { + libspectrum_malloc_fn_t malloc; + libspectrum_calloc_fn_t calloc; + libspectrum_realloc_fn_t realloc; + libspectrum_free_fn_t free; +} libspectrum_mem_vtable_t; + +void* WIN32_DLL libspectrum_malloc( size_t size ); +void* WIN32_DLL libspectrum_calloc( size_t nmemb, size_t size ); +void* WIN32_DLL libspectrum_realloc( void *ptr, size_t size ); +void WIN32_DLL libspectrum_free( void *ptr ); + +void WIN32_DLL libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ); + +/* Attempt to identify a given file */ + +/* Various types of file we might manage to identify */ +typedef enum libspectrum_id_t { + + /* These types present in all versions of libspectrum */ + + LIBSPECTRUM_ID_UNKNOWN = 0, /* Unidentified file */ + LIBSPECTRUM_ID_RECORDING_RZX, /* RZX input recording */ + LIBSPECTRUM_ID_SNAPSHOT_SNA, /* .sna snapshot */ + LIBSPECTRUM_ID_SNAPSHOT_Z80, /* .z80 snapshot */ + LIBSPECTRUM_ID_TAPE_TAP, /* Z80-style .tap tape image */ + LIBSPECTRUM_ID_TAPE_TZX, /* TZX tape image */ + + /* Below here, present only in 0.1.1 and later */ + + /* The next entry is deprecated in favour of the more specific + LIBSPECTRUM_ID_DISK_CPC and LIBSPECTRUM_ID_DISK_ECPC */ + LIBSPECTRUM_ID_DISK_DSK, /* .dsk +3 disk image */ + + LIBSPECTRUM_ID_DISK_SCL, /* .scl TR-DOS disk image */ + LIBSPECTRUM_ID_DISK_TRD, /* .trd TR-DOS disk image */ + LIBSPECTRUM_ID_CARTRIDGE_DCK, /* .dck Timex cartridge image */ + + /* Below here, present only in 0.2.0 and later */ + + LIBSPECTRUM_ID_TAPE_WARAJEVO, /* Warajevo-style .tap tape image */ + + LIBSPECTRUM_ID_SNAPSHOT_PLUSD, /* DISCiPLE/+D snapshot */ + LIBSPECTRUM_ID_SNAPSHOT_SP, /* .sp snapshot */ + LIBSPECTRUM_ID_SNAPSHOT_SNP, /* .snp snapshot */ + LIBSPECTRUM_ID_SNAPSHOT_ZXS, /* .zxs snapshot (zx32) */ + LIBSPECTRUM_ID_SNAPSHOT_SZX, /* .szx snapshot (Spectaculator) */ + + /* Below here, present only in 0.2.1 and later */ + + LIBSPECTRUM_ID_COMPRESSED_BZ2, /* bzip2 compressed file */ + LIBSPECTRUM_ID_COMPRESSED_GZ, /* gzip compressed file */ + + /* Below here, present only in 0.2.2 and later */ + + LIBSPECTRUM_ID_HARDDISK_HDF, /* .hdf hard disk image */ + LIBSPECTRUM_ID_CARTRIDGE_IF2, /* .rom Interface II cartridge image */ + + /* Below here, present only in 0.3.0 and later */ + + LIBSPECTRUM_ID_MICRODRIVE_MDR, /* .mdr microdrive cartridge */ + LIBSPECTRUM_ID_TAPE_CSW, /* .csw tape image */ + LIBSPECTRUM_ID_TAPE_Z80EM, /* Z80Em tape image */ + + /* Below here, present only in 0.4.0 and later */ + + LIBSPECTRUM_ID_TAPE_WAV, /* .wav tape image */ + LIBSPECTRUM_ID_TAPE_SPC, /* SP-style .spc tape image */ + LIBSPECTRUM_ID_TAPE_STA, /* Speculator-style .sta tape image */ + LIBSPECTRUM_ID_TAPE_LTP, /* Nuclear ZX-style .ltp tape image */ + LIBSPECTRUM_ID_COMPRESSED_XFD, /* xfdmaster (Amiga) compressed file */ + LIBSPECTRUM_ID_DISK_IMG, /* .img DISCiPLE/+D disk image */ + LIBSPECTRUM_ID_DISK_MGT, /* .mgt DISCiPLE/+D disk image */ + + /* Below here, present only in 0.5.0 and later */ + + LIBSPECTRUM_ID_DISK_UDI, /* .udi generic disk image */ + LIBSPECTRUM_ID_DISK_FDI, /* .fdi generic disk image */ + LIBSPECTRUM_ID_DISK_CPC, /* .dsk plain CPC +3 disk image */ + LIBSPECTRUM_ID_DISK_ECPC, /* .dsk extended CPC +3 disk image */ + LIBSPECTRUM_ID_DISK_SAD, /* .sad generic disk image */ + LIBSPECTRUM_ID_DISK_TD0, /* .td0 generic disk image */ + + LIBSPECTRUM_ID_DISK_OPD, /* .opu/.opd Opus Discovery disk image */ + + LIBSPECTRUM_ID_SCREEN_SCR, /* .scr screen file */ + +} libspectrum_id_t; + +/* And 'classes' of file */ +typedef enum libspectrum_class_t { + + LIBSPECTRUM_CLASS_UNKNOWN, + + LIBSPECTRUM_CLASS_CARTRIDGE_TIMEX, /* Timex cartridges */ + LIBSPECTRUM_CLASS_DISK_PLUS3, /* +3 disk */ + LIBSPECTRUM_CLASS_DISK_TRDOS, /* TR-DOS disk */ + LIBSPECTRUM_CLASS_DISK_OPUS, /* Opus Discovery disk*/ + LIBSPECTRUM_CLASS_RECORDING, /* Input recording */ + LIBSPECTRUM_CLASS_SNAPSHOT, /* Snapshot */ + LIBSPECTRUM_CLASS_TAPE, /* Tape */ + + /* Below here, present only in 0.2.1 and later */ + + LIBSPECTRUM_CLASS_COMPRESSED, /* A compressed file */ + + /* Below here, present only in 0.2.2 and later */ + + LIBSPECTRUM_CLASS_HARDDISK, /* A hard disk image */ + LIBSPECTRUM_CLASS_CARTRIDGE_IF2, /* Interface II cartridges */ + + /* Below here, present only in 0.3.0 and later */ + + LIBSPECTRUM_CLASS_MICRODRIVE, /* Microdrive cartridges */ + + /* Below here, present only in 0.4.0 and later */ + + LIBSPECTRUM_CLASS_DISK_PLUSD, /* DISCiPLE/+D disk image */ + + /* Below here, present only in 0.5.0 and later */ + + LIBSPECTRUM_CLASS_DISK_GENERIC, /* generic disk image */ + + LIBSPECTRUM_CLASS_SCREENSHOT, /* Screenshot */ + +} libspectrum_class_t; + +libspectrum_error WIN32_DLL +libspectrum_identify_file( libspectrum_id_t *type, const char *filename, + const unsigned char *buffer, size_t length ); + +libspectrum_error WIN32_DLL +libspectrum_identify_file_with_class( + libspectrum_id_t *type, libspectrum_class_t *libspectrum_class, + const char *filename, const unsigned char *buffer, size_t length ); + +libspectrum_error WIN32_DLL +libspectrum_identify_file_raw( libspectrum_id_t *type, const char *filename, + const unsigned char *buffer, size_t length ); + +libspectrum_error WIN32_DLL +libspectrum_identify_class( libspectrum_class_t *libspectrum_class, + libspectrum_id_t type ); + +/* Different Spectrum variants and their capabilities */ + +/* The machine types we can handle */ +typedef enum libspectrum_machine { + + LIBSPECTRUM_MACHINE_48, + LIBSPECTRUM_MACHINE_TC2048, + LIBSPECTRUM_MACHINE_128, + LIBSPECTRUM_MACHINE_PLUS2, + LIBSPECTRUM_MACHINE_PENT, + LIBSPECTRUM_MACHINE_PLUS2A, + LIBSPECTRUM_MACHINE_PLUS3, + + /* Used by libspectrum_tape_guess_hardware if we can't work out what + hardware should be used */ + LIBSPECTRUM_MACHINE_UNKNOWN, + + LIBSPECTRUM_MACHINE_16, + LIBSPECTRUM_MACHINE_TC2068, + + LIBSPECTRUM_MACHINE_SCORP, + LIBSPECTRUM_MACHINE_PLUS3E, + LIBSPECTRUM_MACHINE_SE, + + LIBSPECTRUM_MACHINE_TS2068, + + LIBSPECTRUM_MACHINE_PENT512, + LIBSPECTRUM_MACHINE_PENT1024, + +} libspectrum_machine; + +const char* WIN32_DLL libspectrum_machine_name( libspectrum_machine type ); + +/* The various capabilities of the different machines */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_AY; /* AY-3-8192 */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_128_MEMORY; /* 128-style memory paging */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_PLUS3_MEMORY; /* +3-style memory paging */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_PLUS3_DISK; /* +3-style disk drive */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_MEMORY; /* Timex-style memory paging */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_VIDEO; /* Timex-style video modes */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_TRDOS_DISK; /* TRDOS-style disk drive */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_DOCK; /* T[SC]2068-style cartridge port */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_SINCLAIR_JOYSTICK; + /* Sinclair-style joystick ports */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_KEMPSTON_JOYSTICK; + /* Kempston-style joystick ports */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_SCORP_MEMORY; /* Scorpion-style memory paging */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_EVEN_M1; + /* M1 cycles always start on even tstate counts */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_SE_MEMORY; /* SE-style memory paging */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_NTSC; /* NTSC display */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_PENT512_MEMORY; /* Pentagon 512 memory paging */ +extern const int WIN32_DLL +LIBSPECTRUM_MACHINE_CAPABILITY_PENT1024_MEMORY; + /* Pentagon 1024 memory paging */ + +/* Get the capabilities of a machine */ +int WIN32_DLL libspectrum_machine_capabilities( libspectrum_machine type ); + +/* Get the timings of a machine */ +libspectrum_dword WIN32_DLL +libspectrum_timings_processor_speed( libspectrum_machine machine ); +libspectrum_dword WIN32_DLL +libspectrum_timings_ay_speed( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_left_border( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_horizontal_screen( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_right_border( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_horizontal_retrace( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_top_border( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_vertical_screen( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_bottom_border( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_vertical_retrace( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_interrupt_length( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_top_left_pixel( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_tstates_per_line( libspectrum_machine machine ); +libspectrum_word WIN32_DLL +libspectrum_timings_lines_per_frame( libspectrum_machine machine ); +libspectrum_dword WIN32_DLL +libspectrum_timings_tstates_per_frame( libspectrum_machine machine ); + +/* Creator information */ + +typedef struct libspectrum_creator libspectrum_creator; + +libspectrum_creator* WIN32_DLL +libspectrum_creator_alloc( void ); +libspectrum_error WIN32_DLL +libspectrum_creator_free( libspectrum_creator *creator ); + +libspectrum_error WIN32_DLL +libspectrum_creator_set_program( libspectrum_creator *creator, + const char *program ); +const char WIN32_DLL * +libspectrum_creator_program( libspectrum_creator *creator ); + +libspectrum_error WIN32_DLL +libspectrum_creator_set_major( libspectrum_creator *creator, + libspectrum_word major ); +libspectrum_word WIN32_DLL +libspectrum_creator_major( libspectrum_creator *creator ); + +libspectrum_error WIN32_DLL +libspectrum_creator_set_minor( libspectrum_creator *creator, + libspectrum_word minor ); +libspectrum_word WIN32_DLL +libspectrum_creator_minor( libspectrum_creator *creator ); + +libspectrum_error WIN32_DLL +libspectrum_creator_set_competition_code( libspectrum_creator *creator, + libspectrum_dword competition_code ); +libspectrum_dword WIN32_DLL +libspectrum_creator_competition_code( libspectrum_creator *creator ); + +libspectrum_error WIN32_DLL +libspectrum_creator_set_custom( libspectrum_creator *creator, + libspectrum_byte *data, size_t length ); + +libspectrum_byte WIN32_DLL * +libspectrum_creator_custom( libspectrum_creator *creator ); + +size_t WIN32_DLL +libspectrum_creator_custom_length( libspectrum_creator *creator ); + +/* + * Snap handling routines + */ + +typedef struct libspectrum_snap libspectrum_snap; + +libspectrum_snap* WIN32_DLL libspectrum_snap_alloc( void ); +libspectrum_error WIN32_DLL libspectrum_snap_free( libspectrum_snap *snap ); + +/* Read in a snapshot, optionally guessing what type it is */ +libspectrum_error WIN32_DLL +libspectrum_snap_read( libspectrum_snap *snap, const libspectrum_byte *buffer, + size_t length, libspectrum_id_t type, + const char *filename ); + +/* Write a snapshot */ +libspectrum_error WIN32_DLL +libspectrum_snap_write( libspectrum_byte **buffer, size_t *length, + int *out_flags, libspectrum_snap *snap, + libspectrum_id_t type, libspectrum_creator *creator, + int in_flags ); + +/* The flags that can be given to libspectrum_snap_write() */ +extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_NO_COMPRESSION; +extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_ALWAYS_COMPRESS; + +/* The flags that may be returned from libspectrum_snap_write() */ +extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_MINOR_INFO_LOSS; +extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; + +/* The joystick types we can handle */ +typedef enum libspectrum_joystick { + + LIBSPECTRUM_JOYSTICK_NONE, + + LIBSPECTRUM_JOYSTICK_CURSOR, + LIBSPECTRUM_JOYSTICK_KEMPSTON, + LIBSPECTRUM_JOYSTICK_SINCLAIR_1, + LIBSPECTRUM_JOYSTICK_SINCLAIR_2, + LIBSPECTRUM_JOYSTICK_TIMEX_1, + LIBSPECTRUM_JOYSTICK_TIMEX_2, + LIBSPECTRUM_JOYSTICK_FULLER, + +} libspectrum_joystick; + +const char* WIN32_DLL libspectrum_joystick_name( libspectrum_joystick type ); + +extern const int WIN32_DLL... [truncated message content] |
From: <fr...@us...> - 2010-05-24 14:23:46
|
Revision: 639 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=639&view=rev Author: fredm Date: 2010-05-24 14:23:37 +0000 (Mon, 24 May 2010) Log Message: ----------- Merge up to vendor revision 4135. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=4135&view=rev Modified Paths: -------------- trunk/FuseGenerator/generate.pl trunk/FuseImporter/generate.pl trunk/fuse/ChangeLog trunk/fuse/Makefile.am trunk/fuse/README trunk/fuse/compat/unix/file.c trunk/fuse/compat/wii/paths.c trunk/fuse/compat.h trunk/fuse/configure.in trunk/fuse/debugger/command.c trunk/fuse/debugger/commandl.l trunk/fuse/debugger/debugger_internals.h trunk/fuse/debugger/disassemble.c trunk/fuse/disk/beta.c trunk/fuse/disk/beta.h trunk/fuse/disk/disk.c trunk/fuse/disk/disk.h trunk/fuse/disk/fdd.c trunk/fuse/disk/fdd.h trunk/fuse/disk/opus.c trunk/fuse/disk/plusd.c trunk/fuse/disk/upd_fdc.c trunk/fuse/disk/upd_fdc.h trunk/fuse/display.c trunk/fuse/fuse.c trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/generate.pl trunk/fuse/fusepb/libspectrum.h trunk/fuse/hacking/ChangeLog trunk/fuse/ide/divide.c trunk/fuse/ide/zxatasp.c trunk/fuse/ide/zxcf.c trunk/fuse/if1.c trunk/fuse/if2.c trunk/fuse/input.c trunk/fuse/input.h trunk/fuse/keyboard.c trunk/fuse/keysyms.dat trunk/fuse/keysyms.pl trunk/fuse/machines/pentagon.c trunk/fuse/machines/pentagon1024.c trunk/fuse/machines/pentagon512.c trunk/fuse/machines/scorpion.c trunk/fuse/machines/specplus3.c trunk/fuse/machines/specplus3.h trunk/fuse/man/fuse.1 trunk/fuse/memory.c trunk/fuse/memory.h trunk/fuse/menu.c trunk/fuse/menu.h trunk/fuse/menu_data.dat trunk/fuse/periph.c trunk/fuse/printer.c trunk/fuse/rzx.c trunk/fuse/settings-header.pl trunk/fuse/settings.dat trunk/fuse/settings.pl trunk/fuse/sound/Makefile.am trunk/fuse/sound/coreaudiosound.c trunk/fuse/tape.c trunk/fuse/ui/fb/fbkeyboard.c trunk/fuse/ui/fb/fbui.c trunk/fuse/ui/gtk/gtkkeyboard.c trunk/fuse/ui/gtk/gtkui.c trunk/fuse/ui/gtk/picture.c trunk/fuse/ui/options.dat trunk/fuse/ui/sdl/sdldisplay.c trunk/fuse/ui/sdl/sdlkeyboard.c trunk/fuse/ui/sdl/sdlui.c trunk/fuse/ui/svga/svgadisplay.c trunk/fuse/ui/svga/svgakeyboard.c trunk/fuse/ui/svga/svgaui.c trunk/fuse/ui/ui.h trunk/fuse/ui/uijoystick.c trunk/fuse/ui/widget/browse.c trunk/fuse/ui/widget/debugger.c trunk/fuse/ui/widget/error.c trunk/fuse/ui/widget/filesel.c trunk/fuse/ui/widget/memory.c trunk/fuse/ui/widget/menu.c trunk/fuse/ui/widget/options.pl trunk/fuse/ui/widget/picture.c trunk/fuse/ui/widget/pokefinder.c trunk/fuse/ui/widget/query.c trunk/fuse/ui/widget/roms.c trunk/fuse/ui/widget/select.c trunk/fuse/ui/widget/text.c trunk/fuse/ui/widget/widget.c trunk/fuse/ui/widget/widget.h trunk/fuse/ui/wii/wiidisplay.c trunk/fuse/ui/wii/wiikeyboard.c trunk/fuse/ui/wii/wiiui.c trunk/fuse/ui/win32/confirm.c trunk/fuse/ui/win32/options-header.pl trunk/fuse/ui/win32/options-resource.pl trunk/fuse/ui/win32/options.pl trunk/fuse/ui/win32/picture.c trunk/fuse/ui/xlib/xdisplay.c trunk/fuse/ui/xlib/xerror.c trunk/fuse/ui/xlib/xkeyboard.c trunk/fuse/ui/xlib/xui.c trunk/fuse/ui.c trunk/fuse/ula.c trunk/fuse/utils.c trunk/fuse/windres.rc trunk/fuse/z80/z80.c trunk/libspectrum/generate.pl trunk/libspectrum/libspectrum/dck.c trunk/libspectrum/libspectrum/dll.c trunk/libspectrum/libspectrum/generate.pl.in trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/internals.h trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/make-perl.c trunk/libspectrum/libspectrum/myglib/ghash.c trunk/libspectrum/libspectrum/plusd.c trunk/libspectrum/libspectrum/rzx.c trunk/libspectrum/libspectrum/snapshot.c trunk/libspectrum/libspectrum/szx.c trunk/libspectrum/libspectrum/tape.c trunk/libspectrum/libspectrum/warajevo_read.c trunk/libspectrum/libspectrum/wav.c trunk/libspectrum/libspectrum.h trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj trunk/libspectrum/libspectrumpb/libspectrum.xcodeproj/project.pbxproj Added Paths: ----------- trunk/fuse/rectangle.c trunk/fuse/rectangle.h trunk/fuse/sound/blipbuffer.c trunk/fuse/sound/blipbuffer.h trunk/fuse/sound.c Removed Paths: ------------- trunk/fuse/sound/Blip_Buffer.cpp trunk/fuse/sound/Blip_Buffer.h trunk/fuse/sound.cpp Property Changed: ---------------- trunk/fuse/ trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/generate.pl =================================================================== --- trunk/FuseGenerator/generate.pl 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/FuseGenerator/generate.pl 2010-05-24 14:23:37 UTC (rev 639) @@ -172,6 +172,17 @@ /* we support snapshots etc. requiring zlib (e.g. compressed szx) */ #define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) + +/* zlib (de)compression routines */ + +WIN32_DLL libspectrum_error +libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, + libspectrum_byte **outptr, size_t *outlength ); + +WIN32_DLL libspectrum_error +libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, + libspectrum_byte **gzptr, size_t *gzlength ); + CODE } Modified: trunk/FuseImporter/generate.pl =================================================================== --- trunk/FuseImporter/generate.pl 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/FuseImporter/generate.pl 2010-05-24 14:23:37 UTC (rev 639) @@ -172,6 +172,17 @@ /* we support snapshots etc. requiring zlib (e.g. compressed szx) */ #define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) + +/* zlib (de)compression routines */ + +WIN32_DLL libspectrum_error +libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, + libspectrum_byte **outptr, size_t *outlength ); + +WIN32_DLL libspectrum_error +libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, + libspectrum_byte **gzptr, size_t *gzlength ); + CODE } Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-609 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-638 Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/ChangeLog 2010-05-24 14:23:37 UTC (rev 639) @@ -1,13 +1,13 @@ -2009-xx-xx Philip Kendall <phi...@sh...> +2010-xx-xx Philip Kendall <phi...@sh...> - * Fuse ?.??.? released + * Fuse 0.11.0 released - FIXME: Just a start, mostly changes visible on Fuse for OS X at the - moment * Add Opus Discovery disk interface support (Gergely Szasz and Fredrick Meunier). - * Wii support. - * Many improvements to Win32 UI (Marek Januszewski). + * Wii support (Bjoern Giesler, Philip Kendall, Marek Januszewski). + * Many improvements to Win32 UI, including an installer (Marek + Januszewski). + * Support weak data in +3 disk images (Gergely Szasz). * Add support for flipping disk images in single sided drives (Gergely Szasz). * Add support for automatically merging both both disk images where @@ -25,6 +25,16 @@ that use the 128K sound ports (Fredrick Meunier). * Add support for Pentagon 1024SL v2.2 16 colour mode (Fredrick Meunier). + * Implement GTK+ drag and drop support (Dmitry Semyonov). + * Better support for international keyboards (Michal Jurica). + * Allow svgalib UI to use full range of bit depths and scalers (Gergely + Szasz). + * Allow GTK+ scalers to set window size in GTK+ UI (rkd77, Fredrick + Meunier). + * Allow selection of "TV speaker" or "beeper"-style sound output + (Fredrick Meunier) + * Allow hot-key switching between full-screen and windowed mode in + SDL UI (György Szombathelyi). * Miscellaneous improvements: * Preformat new disks on +3 to allow the format command on +3 to work @@ -37,7 +47,51 @@ notebooks (thanks, Andrew Owen) (Fredrick Meunier). * Fixes for speed estimation (Gergely Szasz). * Fix border colour in Timex HiRes screenshots (Fredrick Meunier). + * Fix accelerated loaders when compiling with gcc 3.x (Carlos + Almeida, Alberto Garcia and Philip Kendall). + * Allow "combo" boxes in widget UI (Gergely Szasz). + * Allow Home and End keys to work in widget UI (Gergely Szasz). + * Fix poke finder passing the wrong page to the debugger (Marek + Januszewski). + * Ensure joystick code always activates fire buttons correctly + (thanks, anonymous user) + * Don't fire joystick fire button events unless they've actually + changed (Fredrick Meunier; thanks, Phil Reynolds). + * Make svgalib UI use event interface rather than polling (thanks, + anonymous user). + * Ensure empty XML elements can't cause a segfault (thanks, + anonymous user). + * Tweak sector padding to fix Opus ATC+Technician Ted.dsk (Gergely + Szasz; thanks, Simon Owen). + * Z80 NMI should take some time (Fredrick Meunier). + * Ensure netbooks always recognise the enter key (Fredrick Meunier; + thanks, Marce). + * Add a --without-png option to configure for Gentoo (José Manuel + Ferrer Ortiz) + * Many other things I forgot. If you contributed something and would + like to be mentioned here, please mail me. + +2009-01-14 Philip Kendall <phi...@sh...> + + * Fuse 0.10.0.2 released + + * Make loader acceleration work on all compilers (Philip Kendall; + thanks, Carlos Almeida, Alberto Garcia and Alexander Yurchenko). + + * Make the "Don't Save" option in the widget UI do the right thing + (Frederick Meunier). + + * Allow both +3 disk drives to be used at once (Gergely Szasz). + + * Allow both +D disk drives to be used at once (Gergely Szasz). + + * Make .dsk code handle missing newline on "Track-Info" header + (Gergely Szasz; thanks, Simon Owen). + + * Remove unnecessary 'use' directive when building widget options + header file; fixes some build issues (Frederick Meunier) + 2008-12-10 Philip Kendall <phi...@sh...> * Fuse 0.10.0.1 released @@ -981,4 +1035,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 4060 2009-07-30 13:21:38Z fredm $ +$Id: ChangeLog 4134 2010-05-21 13:16:19Z fredm $ Modified: trunk/fuse/Makefile.am =================================================================== --- trunk/fuse/Makefile.am 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/Makefile.am 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ # Process this file with automake to produce Makefile.in ## Copyright (c) 1999-2009 Philip Kendall -## $Id: Makefile.am 4032 2009-06-10 11:09:44Z fredm $ +## $Id: Makefile.am 4112 2010-01-08 11:03:43Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -81,13 +81,14 @@ printer.c \ profile.c \ psg.c \ + rectangle.c \ rzx.c \ scld.c \ screenshot.c \ settings.c \ slt.c \ snapshot.c \ - sound.cpp \ + sound.c \ spectrum.c \ tape.c \ ui.c \ @@ -149,8 +150,8 @@ BUILT_SOURCES = options.h settings.c settings.h -windres.o: windres.rc winfuse.ico - @WINDRES@ -I$(srcdir) -I. $(srcdir)/windres.rc windres.o +windres.o: windres.rc winfuse.ico ui/win32/*.rc + @WINDRES@ -I$(srcdir) -I. $(srcdir)/windres.rc @LIBSPEC_CFLAGS@ @CPPFLAGS@ windres.o settings.c: settings.pl settings.dat @PERL@ -I$(srcdir)/perl $(srcdir)/settings.pl $(srcdir)/settings.dat > $@.tmp && mv $@.tmp $@ @@ -191,6 +192,7 @@ module.h \ periph.h \ psg.h \ + rectangle.h \ rzx.h \ screenshot.h \ settings.h \ Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/README 2010-05-24 14:23:37 UTC (rev 639) @@ -1,4 +1,4 @@ -The Free Unix Spectrum Emulator (Fuse) 0.10.0.1 +The Free Unix Spectrum Emulator (Fuse) 0.10.0.2 =============================================== Fuse (the Free Unix Spectrum Emulator) was originally, and somewhat @@ -111,9 +111,9 @@ Once you've got Fuse configured and built, read the man page :-) -Note that if you're using version of Fuse from CVS rather than one of -the released tarballs, you'll need to run `autogen.sh' before running -'configure' for the first time. +Note that if you're using version of Fuse from Subversion rather than +one of the released tarballs, you'll need to run `autogen.sh' before +running 'configure' for the first time. Building the OS X version of Fuse --------------------------------- @@ -138,7 +138,7 @@ --with-wii \ --without-libxml2 --without-libiconv --without-gpm \ --without-x --without-glib \ - CFLAGS="-g -I$DEVKITPPC/include -I$DEVKITPRO/libogc/include" \ + CFLAGS="-g -I$DEVKITPPC/include -I$DEVKITPRO/libogc/include -DGEKKO" \ LDFLAGS="-g -mrvl -mcpu=750 -meabi -mhard-float \ -Wl,-Map,fuse.elf.map -L$DEVKITPPC/lib \ -L$DEVKITPRO/libogc/lib/wii" \ @@ -151,6 +151,42 @@ This should build fuse.elf, which you can run on your Wii via the usual methods. +Building the Win32 version of Fuse on Linux +-------------------------------- + +You'll need to have the standard MinGW programming tool set. e.g. on Debian +`apt-get install mingw32 mingw-binutils mingw32-runtime' + <http://www.mingw.org/> + +First, have to compile libspectrum: + +./configure --host=i586-mingw32msvc --without-libaudiofile --without-zlib \ + --without-libgcrypt --without-bzip2 --without-glib --prefix=`pwd` +make install + +This should compile libspectrum without any external lib, and `install' into the +source directory. All of the external libs needed by libspectrum and fuse +compile with successfully with MingGW environment - in case of problems +with compiling any of the libs please refer to the lib's homepage for help. + +Then, compile fuse: + +./configure --host=i586-mingw32msvc --without-glib --prefix=`pwd` \ + --with-libspectrum-prefix=`pwd`/../libspectrum --with-win32 \ + --without-libxml2 --without-x +make + +You have to use the real path of libspectrum with `--with-libspectrum-prefix='. +This should build `fuse.exe' without any external lib, but you can run it on +Windows or Linux (with Wine). + +Note: you need `libspectrum-7.dll' and the `roms' directory and the `lib' + directory to `fuse' run perfectly. You may copy this file and directories + into that directory where `fuse.exe' exists. On windows you may need to + copy all files from `lib/uncompressed' into `lib'. + With wine you need `fltmgr.sys' in Windows `system32' directory. (e.g.: + ~/.wine/c_drive/windows/system32). + Closing comments ---------------- @@ -178,6 +214,6 @@ ( http://www.worldofspectrum.org/faq/index.html ) first! Philip Kendall <phi...@sh...> -10 December 2008 +14 January 2009 -$Id: README 4060 2009-07-30 13:21:38Z fredm $ +$Id: README 4132 2010-05-20 12:06:53Z fredm $ Modified: trunk/fuse/compat/unix/file.c =================================================================== --- trunk/fuse/compat/unix/file.c 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/compat/unix/file.c 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* file.c: File-related compatibility routines Copyright (c) 2008 Philip Kendall - $Id: file.c 4040 2009-06-27 09:32:42Z fredm $ + $Id: file.c 4072 2009-08-31 15:42:26Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -41,7 +41,7 @@ compat_fd compat_file_open( const char *path, int write ) { - return fopen( path, write ? "w" : "r" ); + return fopen( path, write ? "wb" : "rb" ); } off_t Modified: trunk/fuse/compat/wii/paths.c =================================================================== --- trunk/fuse/compat/wii/paths.c 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/compat/wii/paths.c 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* paths.c: Path-related compatibility routines Copyright (c) 1999-2009 Philip Kendall, Bjoern Giesler - $Id: paths.c 3970 2009-01-19 03:47:02Z specu $ + $Id: paths.c 4065 2009-08-13 18:33:21Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -50,5 +50,8 @@ if(strlen(path) >= strlen("fat:/") && strncmp(path, "fat:/", strlen("fat:/")) == 0) return 1; + if(strlen(path) >= strlen("sd:/") && + strncmp(path, "sd:/", strlen("sd:/")) == 0) + return 1; return 0; } Modified: trunk/fuse/compat.h =================================================================== --- trunk/fuse/compat.h 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/compat.h 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* compat.h: various compatibility bits Copyright (c) 2003-2008 Philip Kendall - $Id: compat.h 4040 2009-06-27 09:32:42Z fredm $ + $Id: compat.h 4068 2009-08-30 19:30:19Z specu $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -78,11 +78,11 @@ typedef FILE* compat_fd; -#ifndef UI_WII +#ifndef GEKKO typedef DIR* compat_dir; -#else /* #ifndef UI_WII */ +#else /* #ifndef GEKKO */ typedef DIR_ITER* compat_dir; -#endif /* #ifndef UI_WII */ +#endif /* #ifndef GEKKO */ extern const compat_fd COMPAT_FILE_OPEN_FAILED; Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/configure.in 2010-05-24 14:23:37 UTC (rev 639) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 4028 2009-05-31 13:15:52Z fredm $ +dnl $Id: configure.in 4132 2010-05-20 12:06:53Z fredm $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -24,11 +24,10 @@ AC_CANONICAL_SYSTEM dnl Use automake to produce `Makefile.in' -AM_INIT_AUTOMAKE(fuse, 0.10.0.1) +AM_INIT_AUTOMAKE(fuse, 0.10.0.2) dnl Checks for programs. AC_PROG_CC -AC_PROG_CXX AC_PROG_RANLIB AC_PATH_PROG(PERL, perl) AC_SUBST(PERL) @@ -308,10 +307,7 @@ ac_save_CPPFLAGS="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $LIBSPEC_CFLAGS" AC_TRY_COMPILE([#include <libspectrum.h>],[ -void test() -{ int test = LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION; -} ], AUTOLOAD_SNAPS=compressed; AC_MSG_RESULT(yes), AUTOLOAD_SNAPS=uncompressed; AC_MSG_RESULT(no)) @@ -348,33 +344,41 @@ lib/tape_ts2068.szx]) dnl Check if a version of libpng which supplies png_write_png is available -AC_PATH_PROG([LIBPNG_CONFIG], [libpng-config]) -if test -n "$LIBPNG_CONFIG"; then - PNG_CFLAGS=`libpng-config --cflags` - PNG_LIBS=`libpng-config --ldflags` - PNG_LIBS=`echo " $PNG_LIBS" | sed 's/ -l[[^ ]][[^ ]]*//g'` -fi +AC_MSG_CHECKING(whether PNG support requested) +AC_ARG_WITH(png, +[ --without-png don't use libpng], +if test "$withval" = no; then libpng=no; else libpng=yes; fi, +libpng=yes) +AC_MSG_RESULT($libpng) +if test "$libpng" = yes; then + AC_PATH_PROG([LIBPNG_CONFIG], [libpng-config]) + if test -n "$LIBPNG_CONFIG"; then + PNG_CFLAGS=`libpng-config --cflags` + PNG_LIBS=`libpng-config --ldflags` + PNG_LIBS=`echo " $PNG_LIBS" | sed 's/ -l[[^ ]][[^ ]]*//g'` + fi -ac_save_CPPFLAGS="$CPPFLAGS" -CPPFLAGS="$CPPFLAGS $PNG_CFLAGS" -ac_save_LDFLAGS="$LDFLAGS" -LDFLAGS="$PNG_LIBS $LDFLAGS" + ac_save_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS $PNG_CFLAGS" + ac_save_LDFLAGS="$LDFLAGS" + LDFLAGS="$PNG_LIBS $LDFLAGS" -AC_CHECK_LIB( png, png_write_png, - [AC_CHECK_HEADER( - png.h, - [AC_DEFINE([USE_LIBPNG], 1, [Defined if we're going to be using the installed libpng]) PNG_LIBS='-lpng -lm -lz'], - [AC_CHECK_HEADERS(libpng/png.h, - [CPPFLAGS="$ac_save_CPPFLAGS $PNG_CFLAGS/libpng" - AC_DEFINE([USE_LIBPNG], 1, [Defined if we're going to be using the installed libpng]) PNG_LIBS='-lpng -lm -lz'], - [AC_MSG_WARN(png.h not found - saving screenshots disabled) - PNG_LIBS=''] + AC_CHECK_LIB( png, png_write_png, + [AC_CHECK_HEADER( + png.h, + [AC_DEFINE([USE_LIBPNG], 1, [Defined if we're going to be using the installed libpng]) PNG_LIBS='-lpng -lm -lz'], + [AC_CHECK_HEADERS(libpng/png.h, + [CPPFLAGS="$ac_save_CPPFLAGS $PNG_CFLAGS/libpng" + AC_DEFINE([USE_LIBPNG], 1, [Defined if we're going to be using the installed libpng]) PNG_LIBS='-lpng -lm -lz'], + [AC_MSG_WARN(png.h not found - saving screenshots disabled) + PNG_LIBS=''] + )], )], - )], - [AC_MSG_WARN(png_write_png not found - saving screenshots disabled) - PNG_LIBS=''] -) -AC_SUBST(PNG_LIBS) + [AC_MSG_WARN(png_write_png not found - saving screenshots disabled) + PNG_LIBS=''] + ) + AC_SUBST(PNG_LIBS) +fi LDFLAGS="$ac_save_LDFLAGS" @@ -554,7 +558,7 @@ if test "$libxml2" = yes; then AM_PATH_XML2(2.0.0,AC_DEFINE([HAVE_LIB_XML2], 1, [Defined if we've got libxml2]), - AC_WARN(libxml2 not found - config file use disabled)) + AC_WARN(libxml2 not found - config file will use ini format)) fi dnl Work out which timer routines to use Modified: trunk/fuse/debugger/command.c =================================================================== --- trunk/fuse/debugger/command.c 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/debugger/command.c 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* command.c: Parse a debugger command Copyright (c) 2002-2008 Philip Kendall - $Id: command.c 3631 2008-05-26 12:22:29Z pak21 $ + $Id: command.c 4125 2010-05-06 22:18:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/debugger/commandl.l =================================================================== --- trunk/fuse/debugger/commandl.l 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/debugger/commandl.l 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* commandl.l: Debugger command lexical scanner Copyright (c) 2002-2008 Philip Kendall - $Id: commandl.l 3712 2008-07-06 11:45:24Z pak21 $ + $Id: commandl.l 4130 2010-05-18 12:06:19Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -37,7 +37,9 @@ #define YY_INPUT(buf,result,max_size) \ { \ - if( !debugger_command_input( buf, &result, max_size ) ) result = YY_NULL; \ + int retval; \ + if( !debugger_command_input( buf, &retval, max_size ) ) retval = YY_NULL; \ + result = (yy_size_t)retval; \ } #define YY_NO_INPUT Modified: trunk/fuse/debugger/debugger_internals.h =================================================================== --- trunk/fuse/debugger/debugger_internals.h 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/debugger/debugger_internals.h 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* debugger_internals.h: The internals of Fuse's monitor/debugger Copyright (c) 2002-2008 Philip Kendall - $Id: debugger_internals.h 3681 2008-06-16 09:40:29Z pak21 $ + $Id: debugger_internals.h 4125 2010-05-06 22:18:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/debugger/disassemble.c =================================================================== --- trunk/fuse/debugger/disassemble.c 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/debugger/disassemble.c 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* disassemble.c: Fuse's disassembler Copyright (c) 2002-2003 Darren Salt, Philip Kendall - $Id: disassemble.c 3115 2007-08-19 02:49:14Z fredm $ + $Id: disassemble.c 4087 2009-09-02 13:42:00Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -161,7 +161,7 @@ case 0x00: case 0x08: if( b <= 0x08 ) { - snprintf( buffer, buflen, opcode_00xxx000[ b >> 3 ] ); *length = 1; + snprintf( buffer, buflen, "%s", opcode_00xxx000[ b >> 3 ] ); *length = 1; } else { get_offset( buffer2, 40, address + 2, readbyte_internal( address + 1 ) ); snprintf( buffer, buflen, "%s%s", opcode_00xxx000[ b >> 3 ], buffer2 ); @@ -540,7 +540,7 @@ break; case 0x07: case 0x0f: - snprintf( buffer, buflen, opcode_01xxx111[ ( b >> 3 ) & 0x07 ] ); + snprintf( buffer, buflen, "%s", opcode_01xxx111[ ( b >> 3 ) & 0x07 ] ); *length = 1; break; @@ -560,7 +560,7 @@ snprintf( buffer, buflen, "NOPD" ); *length = 1; *length = 1; } else { /* Note: 0xbc to 0xbf already removed */ - snprintf( buffer, buflen, opcode_101xxxxx[ b & 0x1f ] ); *length = 1; + snprintf( buffer, buflen, "%s", opcode_101xxxxx[ b & 0x1f ] ); *length = 1; } } @@ -713,7 +713,7 @@ return 1; } else { const char *regs[] = { "B", "C", "D", "E", "H", "L", "(HL)", "A" }; - snprintf( buffer, buflen, regs[i] ); + snprintf( buffer, buflen, "%s", regs[i] ); return 0; } } Modified: trunk/fuse/disk/beta.c =================================================================== --- trunk/fuse/disk/beta.c 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/disk/beta.c 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* beta.c: Routines for handling the Beta disk interface Copyright (c) 2004-2008 Stuart Brady - $Id: beta.c 4060 2009-07-30 13:21:38Z fredm $ + $Id: beta.c 4131 2010-05-19 10:52:37Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -58,6 +58,9 @@ #define DISK_TRY_MERGE(heads) ( option_enumerate_diskoptions_disk_try_merge() == 2 || \ ( option_enumerate_diskoptions_disk_try_merge() == 1 && heads == 1 ) ) +/* Two 8Kb memory chunks accessible by the Z80 when /ROMCS is low */ +memory_page beta_memory_map_romcs[2]; + int beta_available = 0; int beta_active = 0; int beta_builtin = 0; @@ -124,8 +127,8 @@ { if( !beta_active ) return; - memory_map_read[0] = memory_map_write[0] = memory_map_romcs[ 0 ]; - memory_map_read[1] = memory_map_write[1] = memory_map_romcs[ 1 ]; + memory_map_read[0] = memory_map_write[0] = beta_memory_map_romcs[0]; + memory_map_read[1] = memory_map_write[1] = beta_memory_map_romcs[1]; } static void @@ -150,7 +153,7 @@ for( i = 0; i < BETA_NUM_DRIVES; i++ ) { d = &beta_drives[ i ]; - fdd_init( &d->fdd, FDD_SHUGART, 0, 0, 0 ); /* drive geometry 'autodetect' */ + fdd_init( &d->fdd, FDD_SHUGART, NULL, 0 ); /* drive geometry 'autodetect' */ d->disk.flag = DISK_FLAG_NONE; } beta_select_drive( 0 ); @@ -165,6 +168,7 @@ if( index_event == -1 ) return 1; module_register( &beta_module_info ); + for( i = 0; i < 2; i++ ) beta_memory_map_romcs[i].bank = MEMORY_BANK_ROMCS; return 0; } @@ -199,15 +203,15 @@ } if( !beta_builtin ) { - machine_load_rom_bank( memory_map_romcs, 0, 0, + machine_load_rom_bank( beta_memory_map_romcs, 0, 0, settings_current.rom_beta128, settings_default.rom_beta128, 0x4000 ); - memory_map_romcs[ 0 ].writable = 0; - memory_map_romcs[ 1 ].writable = 0; + beta_memory_map_romcs[ 0 ].writable = 0; + beta_memory_map_romcs[ 1 ].writable = 0; - memory_map_romcs[0].source = MEMORY_SOURCE_PERIPHERAL; - memory_map_romcs[1].source = MEMORY_SOURCE_PERIPHERAL; + beta_memory_map_romcs[0].source = MEMORY_SOURCE_PERIPHERAL; + beta_memory_map_romcs[1].source = MEMORY_SOURCE_PERIPHERAL; beta_active = 0; @@ -225,8 +229,7 @@ /* We can eject disks only if they are currently present */ dt = &fdd_params[ option_enumerate_diskoptions_drive_beta128a_type() + 1 ]; /* +1 => there is no `Disabled' */ - fdd_init( &beta_drives[ BETA_DRIVE_A ].fdd, FDD_SHUGART, - dt->heads, dt->cylinders, 1 ); + fdd_init( &beta_drives[ BETA_DRIVE_A ].fdd, FDD_SHUGART, dt, 1 ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_A, dt->enabled ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_A_EJECT, beta_drives[ BETA_DRIVE_A ].fdd.loaded ); @@ -237,8 +240,7 @@ dt = &fdd_params[ option_enumerate_diskoptions_drive_beta128b_type() ]; - fdd_init( &beta_drives[ BETA_DRIVE_B ].fdd, dt->enabled ? FDD_SHUGART : FDD_TYPE_NONE, - dt->heads, dt->cylinders, 1 ); + fdd_init( &beta_drives[ BETA_DRIVE_B ].fdd, dt->enabled ? FDD_SHUGART : FDD_TYPE_NONE, dt, 1 ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_B, dt->enabled ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_B_FLIP_SET, !beta_drives[ BETA_DRIVE_B ].fdd.upsidedown ); @@ -249,8 +251,7 @@ dt = &fdd_params[ option_enumerate_diskoptions_drive_beta128c_type() ]; - fdd_init( &beta_drives[ BETA_DRIVE_C ].fdd, dt->enabled ? FDD_SHUGART : FDD_TYPE_NONE, - dt->heads, dt->cylinders, 1 ); + fdd_init( &beta_drives[ BETA_DRIVE_C ].fdd, dt->enabled ? FDD_SHUGART : FDD_TYPE_NONE, dt, 1 ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_C, dt->enabled ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_C_FLIP_SET, !beta_drives[ BETA_DRIVE_C ].fdd.upsidedown ); @@ -261,8 +262,7 @@ dt = &fdd_params[ option_enumerate_diskoptions_drive_beta128d_type() ]; - fdd_init( &beta_drives[ BETA_DRIVE_D ].fdd, dt->enabled ? FDD_SHUGART : FDD_TYPE_NONE, - dt->heads, dt->cylinders, 1 ); + fdd_init( &beta_drives[ BETA_DRIVE_D ].fdd, dt->enabled ? FDD_SHUGART : FDD_TYPE_NONE, dt, 1 ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_D, dt->enabled ); ui_menu_activate( UI_MENU_ITEM_MEDIA_DISK_BETA_D_FLIP_SET, !beta_drives[ BETA_DRIVE_D ].fdd.upsidedown ); @@ -702,7 +702,7 @@ if( libspectrum_snap_beta_custom_rom( snap ) && libspectrum_snap_beta_rom( snap, 0 ) && machine_load_rom_bank_from_buffer( - memory_map_romcs, 0, 0, + beta_memory_map_romcs, 0, 0, libspectrum_snap_beta_rom( snap, 0 ), MEMORY_PAGE_SIZE * 2, 1 ) ) @@ -734,7 +734,7 @@ libspectrum_snap_set_beta_active( snap, 1 ); - if( memory_map_romcs[0].source == MEMORY_SOURCE_CUSTOMROM ) { + if( beta_memory_map_romcs[0].source == MEMORY_SOURCE_CUSTOMROM ) { size_t rom_length = MEMORY_PAGE_SIZE * 2; buffer = malloc( rom_length ); @@ -743,8 +743,8 @@ return; } - memcpy( buffer, memory_map_romcs[0].page, MEMORY_PAGE_SIZE ); - memcpy( buffer + MEMORY_PAGE_SIZE, memory_map_romcs[1].page, + memcpy( buffer, beta_memory_map_romcs[0].page, MEMORY_PAGE_SIZE ); + memcpy( buffer + MEMORY_PAGE_SIZE, beta_memory_map_romcs[1].page, MEMORY_PAGE_SIZE ); libspectrum_snap_set_beta_rom( snap, 0, buffer ); Modified: trunk/fuse/disk/beta.h =================================================================== --- trunk/fuse/disk/beta.h 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/disk/beta.h 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* beta.h: Routines for handling the Beta disk interface Copyright (c) 2003-2004 Fredrick Meunier, Philip Kendall - $Id: beta.h 4029 2009-06-05 13:50:55Z fredm $ + $Id: beta.h 4099 2009-10-22 10:59:02Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -30,6 +30,7 @@ #include <libspectrum.h> +#include "memory.h" #include "periph.h" #include "disk/fdd.h" @@ -37,6 +38,9 @@ extern int beta_active; /* Is the Beta disk interface enabled? */ extern int beta_builtin; /* Is the Beta disk interface built-in? */ +/* Two 8Kb memory chunks accessible by the Z80 when /ROMCS is low */ +extern memory_page beta_memory_map_romcs[2]; + extern libspectrum_word beta_pc_mask; /* Bits to mask in PC for enable check */ extern libspectrum_word beta_pc_value; /* Value to compare masked PC against */ Modified: trunk/fuse/disk/disk.c =================================================================== --- trunk/fuse/disk/disk.c 2010-05-24 12:05:28 UTC (rev 638) +++ trunk/fuse/disk/disk.c 2010-05-24 14:23:37 UTC (rev 639) @@ -1,7 +1,7 @@ /* disk.c: Routines for handling disk images - Copyright (c) 2007 Gergely Szasz + Copyright (c) 2007-2010 Gergely Szasz - $Id: disk.c 4061 2009-07-30 23:37:29Z fredm $ + $Id: disk.c 4114 2010-01-15 13:45:51Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -53,7 +53,7 @@ "Cannot close file", /* DISK_CLOSE */ "Cannot write disk image", /* DISK_WRFILE */ "Partially written file", /* DISK_WRPART */ - + "Unknown error code" /* DISK_LAST_ERROR */ }; @@ -135,7 +135,7 @@ id_read( disk_t *d, int *head, int *track, int *sector, int *length ) { int a1mark = 0; - + while( d->i < d->bpt ) { if( d->track[ d->i ] == 0xa1 && bitmap_test( d->clocks, d->i ) ) { /* 0xa1 with clock */ @@ -210,9 +210,8 @@ { int s; int del; - - d->track = d->data + ( ( d->sides * track + head ) * d->tlen ); - d->clocks = d->track + d->bpt; + + DISK_SET_TRACK( d, head, track ); d->i = 0; for( s = sector_base; s < sector_base + sectors; s++ ) { if( id_seek( d, s ) ) { @@ -232,9 +231,8 @@ { int h, t, s, seclen; int del; - - d->track = d->data + ( ( d->sides * track + head ) * d->tlen ); - d->clocks = d->track + d->bpt; + + DISK_SET_TRACK( d, head, track ); d->i = 0; while( id_read( d, &h, &t, &s, &seclen ) ) { if( datamark_read( d, &del ) ) { /* write data if we have data */ @@ -253,6 +251,8 @@ #define DISK_DDAM 32 #define DISK_CORRUPT_SECTOR 64 #define DISK_UNFORMATTED_TRACK 128 +#define DISK_FM_DATA 256 +#define DISK_WEAK_DATA 512 static int guess_track_geom( disk_t *d, int head, int track, int *sector_base, @@ -266,8 +266,7 @@ *seclen = -1; *mfm = -1; - d->track = d->data + ( d->sides * track + head ) * d->tlen; - d->clocks = d->track + d->bpt; + DISK_SET_TRACK( d, head, track ); d->i = 0; while( id_read( d, &h, &t, &s, &sl ) ) { if( *sector_base == -1 ) @@ -294,6 +293,31 @@ return r; } +static void +update_tracks_mode( disk_t *d ) +{ + int i, j, bpt; + int mfm, fm, weak; + + for( i = 0; i < d->cylinders * d->sides; i++ ) { + DISK_SET_TRACK_IDX( d, i ); + mfm = 0, fm = 0, weak = 0; + bpt = d->track[-3] + 256 * d->track[-2]; + for( j = DISK_CLEN( bpt ) - 1; j >= 0; j-- ) { + mfm |= ~d->fm[j]; + fm |= d->fm[j]; + weak |= d->weak[j]; + } + if( mfm && !fm ) d->track[-1] = 0x00; + if( !mfm && fm ) d->track[-1] = 0x01; + if( mfm && fm ) d->track[-1] = 0x02; + if( weak ) { + d->track[-1] |= 0x80; + d->have_weak = 1; + } + } +} + static int check_disk_geom( disk_t *d, int *sector_base, int *sectors, int *seclen, int *mfm, int *unf ) @@ -301,7 +325,7 @@ int h, t, s, slen, sbase, m; int r = 0; - d->track = d->data; d->clocks = d->track + d->bpt; + DISK_SET_TRACK_IDX( d, 0 ); d->i = 0; *sector_base = -1; *sectors = -1; @@ -310,6 +334,9 @@ *unf = -1; for( t = 0; t < d->cylinders; t++ ) { for( h = 0; h < d->sides; h++ ) { + r |= ( d->track[-1] & 0x80 ) ? DISK_WEAK_DATA : 0; + r |= ( d->track[-1] & 0x03 ) == 0x02 ? DISK_MFM_VARI : 0; + r |= ( d->track[-1] & 0x03 ) == 0x01 ? DISK_FM_DATA : 0; r |= guess_track_geom( d, h, t, &sbase, &s, &slen, &m ); if( *sector_base == -1 ) *sector_base = sbase; @@ -512,7 +539,7 @@ /* if 'buffer' == NULL, then copy data bytes from 'data' */ static int data_add( disk_t *d, buffer_t *buffer, unsigned char *data, int len, int ddam, - int gaptype, int crc_error, int autofill ) + int gaptype, int crc_error, int autofill, int *start_data ) { int length; libspectrum_word crc = 0xffff; @@ -532,6 +559,7 @@ if( d->i + len + 2 >= d->bpt ) /* too many data bytes */ return 1; /*------------------------------ data ------------------------------*/ + if( start_data != NULL ) *start_data = d->i; /* record data start position */ if( buffer == NULL ) { memcpy( d->track + d->i, data, len ); length = len; @@ -580,6 +608,19 @@ return len; } +static int +calc_lenid( int sector_length ) +{ + int id = 0; + + while( sector_length > 0x80 ) { + id++; + sector_length >>= 1; + } + + return id; +} + #define NO_INTERLEAVE 1 #define INTERLEAVE_2 2 #define INTERLEAVE_OPUS 13 @@ -597,8 +638,7 @@ int idx; d->i = 0; - d->track = d->data + ( ( d->sides * track + head ) * d->tlen ); - d->clocks = d->track + d->bpt; + DISK_SET_TRACK( d, head, track ); if( preindex && preindex_add( d, gap ) ) return 1; if( postindex_add( d, gap ) ) @@ -608,9 +648,9 @@ pos = i = 0; for( s = sector_base; s < sector_base + sectors; s++ ) { d->i = idx + pos * slen; - if( id_add( d, head, track, s, sector_length >> 8, gap, CRC_OK ) ) + if( id_add( d, head, track, s, calc_lenid( sector_length ), gap, CRC_OK ) ) return 1; - if( data_add( d, buffer, NULL, sector_length, NO_DDAM, gap, CRC_OK, autofill ) ) + if( data_add( d, buffer, NULL, sector_length, NO_DDAM, gap, CRC_OK, autofill, NULL ) ) return 1; pos += interleave; if( pos >= sectors ) { /* wrap around */ @@ -672,8 +712,8 @@ } if( d->bpt > 0 ) - d->tlen = d->bpt + d->bpt / 8 + ( d->bpt % 8 ? 1 : 0 ); - dlen = d->sides * d->cylinders * d->tlen; /* track len with clock marks */ + d->tlen = 4 + d->bpt + 3 * DISK_CLEN( d->bpt ); + dlen = d->sides * d->cylinders * d->tlen; /* track len with clock and other marks */ if( ( d->data = calloc( 1, dlen ) ) == NULL ) return d->status = DISK_MEM; @@ -739,11 +779,221 @@ if( d->sides < 1 || d->sides > 2 || \ d->cylinders < 1 || d->cylinders > 85 ) return d->status = DISK_GEOM +#ifdef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION static int +udi_read_compressed( const libspectrum_byte *buffer, + size_t compr_size, size_t uncompr_size, + libspectrum_byte **data, size_t *data_size ) +{ + libspectrum_error error; + libspectrum_byte *tmp; + size_t olength = uncompr_size; + + tmp = NULL; + + error = libspectrum_zlib_inflate( buffer, compr_size, &tmp, &olength ); + if( error ) { + if( *data ) free( *data ); + *data_size = 0; + return error; + } + if( *data_size < uncompr_size ) { + *data = libspectrum_realloc( *data, uncompr_size ); + *data_size = uncompr_size; + } + memcpy( *data, tmp, uncompr_size ); + libspectrum_free( tmp ); + + return 0; +} + +static int +udi_write_compressed( const libspectrum_byte *buffer, + size_t uncompr_size, size_t *compr_size, + libspectrum_byte **data, size_t *data_size ) +{ + libspectrum_error error; + libspectrum_byte *tmp; + + tmp = NULL; + error = libspectrum_zlib_compress( buffer, uncompr_size, + &tmp, compr_size ); + if( error ) return error; + + if( *data_size < *compr_size ) { + *data = libspectrum_realloc( *data, *compr_size ); + *data_size = *compr_size; + } + memcpy( *data, tmp, *compr_size ); + libspectrum_free( tmp ); + + return LIBSPECTRUM_ERROR_NONE; +} +#endif /* #ifdef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION */ + +static void +udi_pack_tracks( disk_t *d ) +{ + int i, tlen, clen, ttyp; + libspectrum_byte *tmp; + + for( i = 0; i < d->sides * d->cylinders; i++ ) { + DISK_SET_TRACK_IDX( d, i ); + tmp = d->track; + ttyp = tmp[-1]; + tlen = tmp[-3] + 256 * tmp[-2]; + clen = DISK_CLEN( tlen ); + tmp += tlen; + /* copy clock if needed */ + if( tmp != d->clocks ) + memcpy( tmp, d->clocks, clen ); + if( ttyp == 0x00 || ttyp == 0x01 ) continue; + tmp += clen; + if( ttyp & 0x02 ) { /* copy FM marks */ + if( tmp != d->fm ) + memcpy( tmp, d->fm, clen ); + tmp += clen; + } + if( ! ( ttyp & 0x80 ) ) continue; + if( tmp != d->weak ) /* copy WEAK marks*/ + memcpy( tmp, d->weak, clen ); + } +} + +static void +udi_unpack_tracks( disk_t *d ) +{ + int i, tlen, clen, ttyp; + libspectrum_byte *tmp; + libspectrum_byte mask[] = { 0xff, 0x80, 0xc0, 0xe0, 0xf0, 0xf8, 0xfc, 0xfe }; + + for( i = 0; i < d->sides * d->cylinders; i++ ) { + DISK_SET_TRACK_IDX( d, i ); + tmp = d->track; + ttyp = tmp[-1]; + tlen = tmp[-3] + 256 * tmp[-2]; + clen = DISK_CLEN( tlen ); + tmp += tlen; + if( ttyp & 0x80 ) tmp += clen; + if( ttyp & 0x02 ) tmp += clen; + if( ( ttyp & 0x80 ) ) { /* copy WEAK marks*/ + if( tmp != d->weak ) + memcpy( d->weak, tmp, clen ); + tmp -= clen; + } else { /* clear WEAK marks*/ + memset( d->weak, 0, clen ); + } + if( ttyp & 0x02 ) { /* copy FM marks */ + if( tmp != d->fm ) + memcpy( d->fm, tmp, clen ); + tmp -= clen; + } else { /* set/clear FM marks*/ + memset( d->fm, ttyp & 0x01 ? 0xff : 0, clen ); + if( tlen % 8 ) { /* adjust last byte */ + d->fm[clen - 1] &= mask[ tlen % 8 ]; + } + } + /* copy clock if needed */ + if( tmp != d->clocks ) + memcpy( d->clocks, tmp, clen ); + } +} + +/* calculate track len from type, if type eq. 0x00/0x01/0x02/0x80/0x81/0x82 + !!! not for 0x83 nor 0xf0 !!! +*/ +#define UDI_TLEN( type, bpt ) ( ( bpt ) + DISK_CLEN( bpt ) * ( 1 + \ + ( type & 0x02 ? 1 : 0 ) + \ + ( type & 0x80 ? 1 : 0 ) ) ) + +static int +udi_uncompress_tracks( disk_t *d ) +{ + int i; + libspectrum_byte *data = NULL; +#ifdef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION + size_t data_size = 0; + int bpt, tlen, clen, ttyp; +#endif /* #ifdef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION */ + + for( i = 0; i < d->sides * d->cylinders; i++ ) { + DISK_SET_TRACK_IDX( d, i ); + if( d->track[-1] != 0xf0 ) continue; /* if not compressed */ + +#ifndef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION + /* if libspectrum cannot support */ + return d->status = DISK_UNSUP; +#else /* #ifndef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION */ + clen = d->track[-3] + 256 * d->track[-2] + 1; + ttyp = d->track[0]; /* compressed track type */ + bpt = d->track[1] + 256 * d->track[2]; /* compressed track len... */ + tlen = UDI_TLEN( ttyp, bpt ); + d->track[-1] = ttyp; + d->track[-3] = d->track[1]; + d->track[-2] = d->track[2]; + if( udi_read_compressed( d->track + 3, clen, tlen, &data, &data_size ) ) { + if( data ) libspectrum_free( data ); + return d->status = DISK_UNSUP; + } + memcpy( d->track, data, tlen ); /* read track */ +#endif /* #ifndef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION */ + } + if( data ) libspectrum_free( data ); + return DISK_OK; +} + +#ifdef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION +static int +udi_compress_tracks( disk_t *d ) +{ + int i, tlen; + libspectrum_byte *data = NULL; + size_t clen, data_size = 0; + + for( i = 0; i < d->sides * d->cylinders; i++ ) { + DISK_SET_TRACK_IDX( d, i ); + if( d->track[-1] == 0xf0 ) continue; /* already compressed??? */ + + tlen = UDI_TLEN( d->track[-1], d->track[-3] + 256 * d->track[-2] ); + /* if fail to compress, skip ... */ + if( udi_write_compressed( d->track, tlen, &clen, &data, &data_size ) || + clen < 1 ) continue; + /* if compression too large, skip... */ + if( clen > 65535 || clen >= tlen ) continue; + d->track[0] = d->track[-1]; /* track type... */ + d->track[1] = d->track[-3]; /* compressed track len... */ + d->track[2] = d->track[-2]; /* compressed track len... */ + memcpy( d->track + 3, data, clen ); /* read track */ + clen--; + d->track[-1] = 0xf0; + d->track[-3] = clen & 0xff; + d->track[-2] = ( clen >> 8 ) & 0xff; + } + if( data ) libspectrum_free( data ); + return DISK_OK; +} +#endif /* #ifdef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION */ + +static int open_udi( buffer_t *buffer, disk_t *d ) { - int i, j, bpt; + int i, bpt, ttyp, tlen, error; + size_t clen, eof; + libspectrum_dword crc; + crc = ~(libspectrum_dword) 0; + + /* check file length */ + eof = buff[4] + 256 * buff[5] + 65536 * buff[6] + 16777216 * buff[7]; + if( eof != buffer->file.length - 4 ) + return d->status = DISK_OPEN; + /* check CRC32 */ + for( i = 0; i < eof; i++ ) + crc = crc_udi( crc, buff[i] ); + if( crc != buff[eof] + 256 * buff[eof + 1] + 65536 * buff[eof + 2] + + 16777216 * buff[eof + 3] ) + return d->status = DISK_OPEN; + d->sides = buff[10] + 1; d->cylinders = buff[9] + 1; GEOM_CHECK; @@ -752,15 +1002,35 @@ d->bpt = 0; /* scan file for the longest track */ - for( i = 0; i < d->sides * d->cylinders; i++ ) { + for( i = 0; buffer->index < eof; i++ ) { if( buffavail( buffer ) < 3 ) return d->status = DISK_OPEN; - if( buff[0] != 0x00 ) + ttyp = buff[0]; + if( ttyp != 0x00 && ttyp != 0x01 && ttyp != 0x02 && ttyp != 0x80 && + ttyp != 0x81 && ttyp != 0x82 && ttyp != 0x83 && ttyp != 0xf0 ) return d->status = DISK_UNSUP; - bpt = buff[1] + 256 * buff[2]; /* current track len... */ + + /* if libspectrum cannot suppot*/ +#ifndef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION + if( ttyp == 0xf0 ) d->status = DISK_UNSUP; +#endif /* #ifndef LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION */ + if( ttyp == 0x83 ) { /* multiple read */ + if( i == 0 ) return d->status = DISK_GEOM; /* cannot be first track */ + i--; bpt = 0; /* not a real track */ + tlen = buff[1] + 256 * buff[2]; /* current track len... */ + tlen = ( tlen & 0xfff8 ) * ( tlen & 0x07 ); + } else if( ttyp == 0xf0 ) { /* compressed track */ + if( buffavail( buffer ) < 7 ) + return d->status = DISK_OPEN; + bpt = buff[4] + 256 * buff[5]; + tlen = 7 + buff[1] + 256 * buff[2]; + } else { + bpt = buff[1] + 256 * buff[2]; /* current track len... */ + tlen = 3 + UDI_TLEN( ttyp, bpt ); + } if( bpt > d->bpt ) d->bpt = bpt; - if( buffseek( buffer, 3 + bpt + bpt / 8 + ( bpt % 8 ? 1 : 0 ), SEEK_CUR ) == -1 ) + if( buffseek( buffer, tlen, SEEK_CUR ) == -1 ) return d->status = DISK_OPEN; } @@ -768,33 +1038,46 @@ return d->status = DISK_GEOM; bpt = d->bpt; /* save the maximal value */ - d->tlen = bpt + bpt / 8 + ( bpt % 8 ? 1 : 0 ); + d->tlen = 3 + bpt + 3 * DISK_CLEN( bpt ); d->bpt = 0; /* we know exactly the track len... */ if( disk_alloc( d ) != DISK_OK ) return d->status; d->bpt = bpt; /* restore the maximal byte per track */ buffer->index = 16; - d->track = d->data; - for( i = 0; i < d->sides * d->cylinders; i++ ) { + for( i = 0; buffer->index < eof; i++ ) { + DISK_SET_TRACK_IDX( d, i ); + ttyp = buff[0]; bpt = buff[1] + 256 * buff[2]; /* current track len... */ - buffer->index += 3; + clen = DISK_CLEN( bpt ); + + memset( d->track, d->bpt, 0x4e ); /* fillup */ /* read track + clocks */ - if( d->bpt == bpt ) { /* if udi track length equal with the maximal track length */ - buffread( d->track, bpt + bpt / 8 + ( bpt % 8 ? 1 : 0 ), buffer ); + if( ttyp == 0x83 ) { /* multiple read */ + i--; /* not a real track */ + DISK_SET_TRACK_IDX( d, i ); /* back to previouse track */ + d->weak += buff[3] + 256 * buff[4]; /* add offset to weak */ + tlen = ( buff[1] + 256 * buff[2] ) >> 3; /* weak len in bytes */ + for( tlen--; tlen >= 0; tlen-- ) + d->weak[tlen] = 0xff; + tlen = buff[1] + 256 * buff[2]; /* current track len... */ + tlen = ( tlen & 0xfff8 ) * ( tlen & 0x07 ); + buffseek( buffer, tlen, SEEK_CUR ); } else { - buffread( d->track, bpt, buffer ); /* first the data */ - d->track += bpt; - for( j = d->bpt - bpt; j > 0; j--, d->track++ ) - *d->track = 0x4e; /* fill track data with 0x4e */ - buffread( d->track, bpt / 8 + ( bpt % 8 ? 1 : 0 ), buffer ); - d->track += bpt / 8 + ( bpt % 8 ? 1 : 0 ); - for( j = ( d->bpt / 8 + ( d->bpt % 8 ? 1 : 0 ) ) - - ( bpt / 8 + ( bpt % 8 ? 1 : 0 ) ); j > 0; j--, d->track++ ) - *d->track = 0x00; /* fill the clocks with 0x00 */ + if( ttyp == 0xf0 ) /* compressed */ + tlen = bpt + 4; + else + tlen = UDI_TLEN( ttyp, bpt ); + d->track[-1] = ttyp; + d->track[-3] = buff[1]; + d->track[-2] = buff[2]; + buffer->index += 3; + buffread( d->track, tlen, buffer ); /* first read data */ } - d->track += d->tlen; } + error = udi_uncompress_tracks( d ); + if( error ) return error; + udi_unpack_tracks( d ); return d->status = DISK_OK; } @@ -990,12 +1273,11 @@ buffread( head, 7, buffer ); /* 7 = track head */ track_offset = head[0x00] + 256 * head[0x01] + 65536 * head[0x02] + 16777216 * head[0x03]; - d->track = d->data + i * d->tlen; d->clocks = d->track + d->bpt; + DISK_SET_TRACK_IDX( d, i ); d->i = 0; if( preindex ) preindex_add( d, gap ); postindex_add( d, gap ); - bpt = 0; for( j = 0; j < head[0x06]; j++ ) { if( j % 35 == 0 ) { /* if we have more than 35 sector in a track, we have to seek back to the next sector @@ -1012,7 +1294,7 @@ data_add( d, buffer, NULL, ( head[ 0x0b + 7 * ( j % 35 ) ] & 0x3f ) == 0 ? -1 : 0x80 << head[ 0x0a + 7 * ( j % 35 ) ], head[ 0x0b + 7 * ( j % 35 ) ] & 0x80 ? DDAM : NO_DDAM, - gap, CRC_OK, NO_AUTOFILL ); + gap, CRC_OK, NO_AUTOFILL, NULL ); } head_offset += 7 + 7 * head[0x06]; gap4_add( d, gap ); @@ -1020,6 +1302,28 @@ return d->status = DISK_OK; } +static void +cpc_set_weak_range( disk_t *d, int idx, buffer_t *buffer, int n, int len ) +{ + int i, j, first = -1, last = -1; + libspectrum_byte *t, *w; + + t = d->track + idx; + w = buffer->file.buffer + buffer->index; + + for( i = 0; i < len; i++, t++, w++ ) { + for( j = 0; j < n - 1; j ++ ) { + if( *t != w[j * len] ) { + if( first == -1 ) first = idx + i; + last = idx + i; + } + } + } + for( ; first <= last; first++ ) { + bitmap_set( d->weak, first ); + } +} + #define CPC_ISSUE_NONE 0 #define CPC_ISSUE_1 1 #define CPC_ISSUE_2 2 @@ -1030,7 +1334,7 @@ static int open_cpc( buffer_t *buffer, disk_t *d, int preindex ) { - int i, j, seclen, idlen, gap, sector_pad; + int i, j, seclen, idlen, gap, sector_pad, idx; int bpt, max_bpt = 0, trlen; int fix[84], plus3_fix; unsigned char *hdrb; @@ -1122,7 +1426,7 @@ if( disk_alloc( d ) != DISK_OK ) return d->status; - d->track = d->data; d->clocks = d->track + d->bpt; + DISK_SET_TRACK_IDX( d, 0 ); buffer->index = 256; /* rewind to first track */ for( i = 0; i < d->sides*d->cylinders; i++ ) { hdrb = buff; @@ -1130,7 +1434,7 @@ gap = (unsigned char)hdrb[0x16] == 0xff ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM; i = hdrb[0x10] * d->sides + hdrb[0x11]; /* adjust track No. */ - d->track = d->data + i * d->tlen; d->clocks = d->track + d->bpt; + DISK_SET_TRACK_IDX( d, i ); d->i = 0; if( preindex) preindex_add( d, gap ); @@ -1158,7 +1462,7 @@ data_add( d, buffer, NULL, seclen, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? - CRC_ERROR : CRC_OK, 0x00 ); + CRC_ERROR : CRC_OK, 0x00, NULL ); } else if( i < 84 && fix[i] == CPC_ISSUE_2 && j == 0 ) { /* 6144, 10x512 */ datamark_add( d, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap ); gap_add( d, 2, gap ); @@ -1167,13 +1471,13 @@ data_add( d, buffer, NULL, 128, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? - CRC_ERROR : CRC_OK, 0x00 ); + CRC_ERROR : CRC_OK, 0x00, NULL ); buffer->index += seclen - 128; } else if( i < 84 && fix[i] == CPC_ISSUE_4 ) { /* Nx8192 (max 6384 byte ) */ data_add( d, buffer, NULL, 6384, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? - CRC_ERROR : CRC_OK, 0x00 ); + CRC_ERROR : CRC_OK, 0x00, NULL ); buffer->index += seclen - 6384; } else if( i < 84 && fix[i] == CPC_ISSUE_5 ) { /* 9x512 */ /* 512 256 512 256 512 256 512 256 512 */ @@ -1181,22 +1485,22 @@ data_add( d, NULL, buff, 512, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? - CRC_ERROR : CRC_OK, 0x00 ); + CRC_ERROR : CRC_OK, 0x00, NULL ); buffer->index += idlen; } else { data_add( d, buffer, NULL, idlen, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? - CRC_ERROR : CRC_OK, 0x00 ); + CRC_ERROR : CRC_OK, 0x00, NULL ); } } else { data_add( d, buffer, NULL, seclen > idlen ? idlen : seclen, hdrb[ 0x1d + 8 * j ] & 0x40 ? DDAM : NO_DDAM, gap, hdrb[ 0x1c + 8 * j ] & 0x20 && hdrb[ 0x1d + 8 * j ] & 0x20 ? - CRC_ERROR : CRC_OK, 0x00 ); + CRC_ERROR : CRC_OK, 0x00, &idx ); if( seclen > idlen ) { /* weak sector with multiple copy */ - buffer->index +=( seclen / ( 0x80 << hdrb[ 0x1b + 8 * j ] ) - 1 ) * - ( 0x80 << hdrb[ 0x1b + 8 * j ] ); + cpc_set_weak_range( d, idx, buffer, seclen / idlen, idlen ); + buffer->index += ( seclen / idlen - 1 ) * idlen; /* ( ( N * len ) / len - 1 ) * len */ } } @@ -1236,8 +1540,7 @@ return d->status = DISK_GEOM; /* too many file */ buffer->index = 9; /* read SCL entries */ - d->track = d->data; /* track 0 */ - d->clocks = d->track + d->bpt; + DISK_SET_TRACK_IDX( d, 0 ); d->i = 0; postindex_add( d, GAP_TRDOS ); scl_i = d->i; /* the position of first sector */ @@ -1266,7 +1569,7 @@ if( j == 256 ) { /* one sector ready */ d->i = scl_i + ( ( s - 1 ) % 8 * 2 + ( s - 1 ) / 8 ) * seclen; /* 1 9 2 10 3 ... */ id_add( d, 0, 0, s, SECLEN_256, GAP_TRDOS, CRC_OK ); - data_add( d, NULL, head, 256, NO_DDAM, GAP_TRDOS, CRC_OK, NO_AUTOFILL ); + data_add( d, NULL, head, 256, NO_DDAM, GAP_TRDOS, CRC_OK, NO_AUTOFILL, NULL ); memset( head, 0, 256 ); s++; j = 0; @@ -1276,7 +1579,7 @@ if( j != 0 ) { /* we have to add this sector */ d->i = scl_i + ( ( s - 1 ) % 8 * 2 + ( s - 1 ) / 8 ) * seclen; /* 1 9 2 10 3 ... */ id_add( d, 0, 0, s, SECLEN_256, GAP_TRDOS, CRC_OK ); - data_add( d, NULL, head, 256, NO_DDAM, GAP_TRDOS, CRC_OK, NO_AUTOFILL ); + data_add( d, NULL, head, 256, NO_DDAM, GAP_TRDOS, CRC_OK, NO_AUTOFILL, NULL ); s++; } /* and add empty sectors up to No. 16 */ @@ -1296,7 +1599,7 @@ head[244] = scl_deleted; /* number of deleted files */ memcpy( head + 245, "FUSE-SCL", 8 ); } - data_add( d, NULL, head, 256, NO_DDAM, GAP_TRDOS, CRC_OK, NO_AUTOFILL ); + data_add( d, NULL, head, 256, NO_DDAM, GAP_TRDOS, CRC_OK, NO_AUTOFILL, NULL ); if( s == 9 ) memset( head, 0, 256 ); /* clear sector data... */ } @@ -1346,7 +1649,6 @@ return d->status = DISK_OPEN; if( buff[1] + 1 > d->cylinders ) /* find the biggest cylinder number */ d->cylinders = buff[1] + 1; - bpt = 0; sector_offset = track_offset + 4; mfm = buff[2] & 0x80 ? 0 : 1; /* 0x80 == 1 => SD track */ bpt = postindex_len( d, mfm_old || mfm ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM ) + @@ -1382,15 +1684,14 @@ if( disk_alloc( d ) != DISK_OK ) return d->status; - d->track = d->data; d->clocks = d->track + d->bpt; + DISK_SET_TRACK_IDX( d, 0 ); buffer->index = data_offset; /* first track header */ while( 1 ) { if( ( sectors = buff[0] ) == 255 ) /* sector number 255 => end of tracks */ break; - d->track = d->data + ( d->sides * buff[1] + ( buff[2] & 0x01 ) ) * d->tlen; - d->clocks = d->track + d->bpt; + DISK_SET_TRACK( d, ( buff[2] & 0x01 ), buff[1] ); d->i = 0; /* later teledisk -> if buff[2] & 0x80 -> FM track */ gap = mfm_old || buff[2] & 0x80 ? GAP_MINIMAL_FM : GAP_MINIMAL_MFM; @@ -1418,7 +1719,7 @@ return d->status = DISK_OPEN; } if( data_add( d, buffer, NULL, hdrb[6] + 256 * hdrb[7] - 1, - hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { + hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL, NULL ) ) { if( uncomp_buff ) free( uncomp_buff ); return d->status = DISK_OPEN; @@ -1443,7 +1744,7 @@ i += 2 * ( hdrb[9] + 256 * hdrb[10] ); } if( data_add( d, NULL, uncomp_buff, hdrb[6] + 256 * hdrb[7] - 1, - hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { + hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL, NULL ) ) { free( uncomp_buff ); return d->status = DISK_OPEN; } @@ -1482,7 +1783,7 @@ } } if( data_add( d, NULL, uncomp_buff, hdrb[6] + 256 * hdrb[7] - 1, - hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL ) ) { + hdrb[4] & 0x04 ? DDAM : NO_DDAM, gap, CRC_OK, NO_AUTOFILL, NULL ) ) { free( uncomp_buff ); return d->status = DISK_OPEN; } @@ -1503,6 +1804,21 @@ return d->status = DISK_OK; } +/* update tracks TLEN */ +void +disk_update_tlens( disk_t *d ) +{ + int i; + + for( i = 0; i < d->sides * d->cylinders; i++ ) { /* check tracks */ + DISK_SET_TRACK_IDX( d, i ); + if( d->track[-3] + 256 * d->track[-2] == 0 ) { + d->track[-3] = d->bpt & 0xff; + d->track[-2] = ( d->bpt >> 8 ) & 0xff; + } + } +} + /* open a disk image file, read and convert to our format * if preindex != 0 we generate preindex gap if needed */ @@ -1513,14 +1829,14 @@ libspectrum_id_t type; int error; -#ifdef UI_WII /* Wii doesn't have access() */ +#ifdef GEKKO /* Wii doesn't have access() */ d->wrprot = 0; -#else /* #ifdef UI_WII */ +#else /* #ifdef GEKKO */ if( access( filename, W_OK ) == -1 ) /* file read only */ d->wrprot = 1; else d->wrprot = 0; -#endif /* #ifdef UI_WII */ +#endif /* #ifdef GEKKO */ if( utils_read_file( filename, &buffer.file ) ) return d->status = DISK_OPEN; @@ -1582,6 +1898,8 @@ } utils_close_file( &buffer.file ); d->dirty = 0; + disk_update_tlens( d ); + update_tracks_mode( d ); return d->status = DISK_OK; } @@ -1610,7 +1928,7 @@ if( disk_alloc( d ) != DISK_OK ) return d->status; - clen = d->bpt / 8 + ( d->bpt % 8 ? 1 : 0 ); + clen = DISK_CLEN( d->bpt ); d->track = d->data; d1->track = d1->data; d2->track = d2->data; @@ -1618,19 +1936,25 @@ if( i < d1->cylinders ) memcpy( d->track, d1->track, d->tlen ); else { - memset( d->track, d->bpt, autofill & 0xff ); /* fill data */ - memset( d->track + d->bpt, clen, 0x00 ); /* no clock marks */ + d->track[0] = d->bpt & 0xff; + d->track[1] = ( d->bpt >> 8 ) & 0xff; + d->track[2] = 0x00; + memset( d->track + 3, d->bpt, autofill & 0xff ); /* fill data */ + memset( d->track + 3 + d->bpt, ... [truncated message content] |
From: <fr...@us...> - 2010-05-26 12:46:47
|
Revision: 640 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=640&view=rev Author: fredm Date: 2010-05-26 12:46:40 +0000 (Wed, 26 May 2010) Log Message: ----------- Update libspectrum.h for FuseGenerator and FuseImporter. Modified Paths: -------------- trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/libspectrum.h Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2010-05-24 14:23:37 UTC (rev 639) +++ trunk/FuseGenerator/libspectrum.h 2010-05-26 12:46:40 UTC (rev 640) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4060 2009-07-30 13:21:38Z fredm $ + $Id: libspectrum.h.in 4120 2010-02-21 05:06:56Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -38,8 +38,6 @@ #include <stdlib.h> #include <stdio.h> -#include <TargetConditionals.h> - #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN /* Exclude rarely used stuff from Windows @@ -202,6 +200,8 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#include <TargetConditionals.h> + #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) @@ -210,11 +210,6 @@ #define GPOINTER_TO_INT(p) ((gint) (p)) #endif -/* Library capabilities */ - -/* we support snapshots etc. requiring zlib (e.g. compressed szx) */ -#define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) - /* * General libspectrum routines */ @@ -239,24 +234,40 @@ } libspectrum_error; +/* Library capabilities */ + +/* we support snapshots etc. requiring zlib (e.g. compressed szx) */ +#define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) + +/* zlib (de)compression routines */ + +WIN32_DLL libspectrum_error +libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, + libspectrum_byte **outptr, size_t *outlength ); + +WIN32_DLL libspectrum_error +libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, + libspectrum_byte **gzptr, size_t *gzlength ); + + /* Initialisation */ -libspectrum_error WIN32_DLL libspectrum_init( void ); +WIN32_DLL libspectrum_error libspectrum_init( void ); /* Version checking */ -int WIN32_DLL libspectrum_check_version( const char *version ); -const char WIN32_DLL *libspectrum_version( void ); -const char WIN32_DLL *libspectrum_gcrypt_version( void ); +WIN32_DLL int libspectrum_check_version( const char *version ); +WIN32_DLL const char *libspectrum_version( void ); +WIN32_DLL const char *libspectrum_gcrypt_version( void ); /* Error handling */ typedef libspectrum_error (*libspectrum_error_function_t)( libspectrum_error error, const char *format, va_list ap ); -extern libspectrum_error_function_t WIN32_DLL libspectrum_error_function; +extern WIN32_DLL libspectrum_error_function_t libspectrum_error_function; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_default_error_function( libspectrum_error error, const char *format, va_list ap ); @@ -274,12 +285,12 @@ libspectrum_free_fn_t free; } libspectrum_mem_vtable_t; -void* WIN32_DLL libspectrum_malloc( size_t size ); -void* WIN32_DLL libspectrum_calloc( size_t nmemb, size_t size ); -void* WIN32_DLL libspectrum_realloc( void *ptr, size_t size ); -void WIN32_DLL libspectrum_free( void *ptr ); +WIN32_DLL void* libspectrum_malloc( size_t size ); +WIN32_DLL void* libspectrum_calloc( size_t nmemb, size_t size ); +WIN32_DLL void* libspectrum_realloc( void *ptr, size_t size ); +WIN32_DLL void libspectrum_free( void *ptr ); -void WIN32_DLL libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ); +WIN32_DLL void libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ); /* Attempt to identify a given file */ @@ -394,20 +405,20 @@ } libspectrum_class_t; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_file( libspectrum_id_t *type, const char *filename, const unsigned char *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_file_with_class( libspectrum_id_t *type, libspectrum_class_t *libspectrum_class, const char *filename, const unsigned char *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_file_raw( libspectrum_id_t *type, const char *filename, const unsigned char *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_class( libspectrum_class_t *libspectrum_class, libspectrum_id_t type ); @@ -442,122 +453,122 @@ } libspectrum_machine; -const char* WIN32_DLL libspectrum_machine_name( libspectrum_machine type ); +WIN32_DLL const char* libspectrum_machine_name( libspectrum_machine type ); /* The various capabilities of the different machines */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_AY; /* AY-3-8192 */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_128_MEMORY; /* 128-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PLUS3_MEMORY; /* +3-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PLUS3_DISK; /* +3-style disk drive */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_MEMORY; /* Timex-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_VIDEO; /* Timex-style video modes */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TRDOS_DISK; /* TRDOS-style disk drive */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_DOCK; /* T[SC]2068-style cartridge port */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_SINCLAIR_JOYSTICK; /* Sinclair-style joystick ports */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_KEMPSTON_JOYSTICK; /* Kempston-style joystick ports */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_SCORP_MEMORY; /* Scorpion-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_EVEN_M1; /* M1 cycles always start on even tstate counts */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_SE_MEMORY; /* SE-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_NTSC; /* NTSC display */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PENT512_MEMORY; /* Pentagon 512 memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PENT1024_MEMORY; /* Pentagon 1024 memory paging */ /* Get the capabilities of a machine */ -int WIN32_DLL libspectrum_machine_capabilities( libspectrum_machine type ); +WIN32_DLL int libspectrum_machine_capabilities( libspectrum_machine type ); /* Get the timings of a machine */ -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_timings_processor_speed( libspectrum_machine machine ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_timings_ay_speed( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_left_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_horizontal_screen( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_right_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_horizontal_retrace( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_top_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_vertical_screen( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_bottom_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_vertical_retrace( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_interrupt_length( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_top_left_pixel( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_tstates_per_line( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_lines_per_frame( libspectrum_machine machine ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_timings_tstates_per_frame( libspectrum_machine machine ); /* Creator information */ typedef struct libspectrum_creator libspectrum_creator; -libspectrum_creator* WIN32_DLL +WIN32_DLL libspectrum_creator* libspectrum_creator_alloc( void ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_free( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_program( libspectrum_creator *creator, const char *program ); -const char WIN32_DLL * +WIN32_DLL const char * libspectrum_creator_program( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_major( libspectrum_creator *creator, libspectrum_word major ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_creator_major( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_minor( libspectrum_creator *creator, libspectrum_word minor ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_creator_minor( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_competition_code( libspectrum_creator *creator, libspectrum_dword competition_code ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_creator_competition_code( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_custom( libspectrum_creator *creator, libspectrum_byte *data, size_t length ); -libspectrum_byte WIN32_DLL * +WIN32_DLL libspectrum_byte * libspectrum_creator_custom( libspectrum_creator *creator ); -size_t WIN32_DLL +WIN32_DLL size_t libspectrum_creator_custom_length( libspectrum_creator *creator ); /* @@ -566,29 +577,29 @@ typedef struct libspectrum_snap libspectrum_snap; -libspectrum_snap* WIN32_DLL libspectrum_snap_alloc( void ); -libspectrum_error WIN32_DLL libspectrum_snap_free( libspectrum_snap *snap ); +WIN32_DLL libspectrum_snap* libspectrum_snap_alloc( void ); +WIN32_DLL libspectrum_error libspectrum_snap_free( libspectrum_snap *snap ); /* Read in a snapshot, optionally guessing what type it is */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_snap_read( libspectrum_snap *snap, const libspectrum_byte *buffer, size_t length, libspectrum_id_t type, const char *filename ); /* Write a snapshot */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_snap_write( libspectrum_byte **buffer, size_t *length, int *out_flags, libspectrum_snap *snap, libspectrum_id_t type, libspectrum_creator *creator, int in_flags ); /* The flags that can be given to libspectrum_snap_write() */ -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_NO_COMPRESSION; -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_ALWAYS_COMPRESS; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_NO_COMPRESSION; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_ALWAYS_COMPRESS; /* The flags that may be returned from libspectrum_snap_write() */ -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_MINOR_INFO_LOSS; -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_MINOR_INFO_LOSS; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; /* The joystick types we can handle */ typedef enum libspectrum_joystick { @@ -605,12 +616,12 @@ } libspectrum_joystick; -const char* WIN32_DLL libspectrum_joystick_name( libspectrum_joystick type ); +WIN32_DLL const char* libspectrum_joystick_name( libspectrum_joystick type ); -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_NONE; -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_KEYBOARD; -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_1; -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_2; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_NONE; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_KEYBOARD; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_1; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_2; /* Accessor functions */ libspectrum_machine WIN32_DLL libspectrum_snap_machine( libspectrum_snap *snap ); @@ -856,8 +867,7 @@ int WIN32_DLL libspectrum_snap_fuller_box_active( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_fuller_box_active( libspectrum_snap *snap, int fuller_box_active ); int WIN32_DLL libspectrum_snap_melodik_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int - melodik_active ); +void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int melodik_active ); /* * Tape handling routines @@ -911,15 +921,15 @@ typedef struct _GSList *libspectrum_tape_iterator; /* Some flags */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_BLOCK; /* End of block */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_STOP; /* Stop tape */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_STOP48; /* Stop tape if in 48K mode */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_NO_EDGE; /* Edge isn't really an edge */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LEVEL_LOW; /* Set level low */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LEVEL_HIGH; /* Set level high */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_SHORT; -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_LONG; -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_TAPE; /* Tape has finished */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_BLOCK; /* End of block */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_STOP; /* Stop tape */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_STOP48; /* Stop tape if in 48K mode */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_NO_EDGE; /* Edge isn't really an edge */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LEVEL_LOW; /* Set level low */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LEVEL_HIGH; /* Set level high */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LENGTH_SHORT; +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LENGTH_LONG; +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_TAPE; /* Tape has finished */ /* The states which a block can be in */ typedef enum libspectrum_tape_state_type { @@ -936,28 +946,28 @@ } libspectrum_tape_state_type; /* Routines to manipulate tape blocks */ -libspectrum_tape_block* WIN32_DLL +WIN32_DLL libspectrum_tape_block* libspectrum_tape_block_alloc( libspectrum_tape_type type ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_free( libspectrum_tape_block *block ); -libspectrum_tape_type WIN32_DLL +WIN32_DLL libspectrum_tape_type libspectrum_tape_block_type( libspectrum_tape_block *block ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_set_type( libspectrum_tape_block *block, libspectrum_tape_type type ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_init( libspectrum_tape_block *block, libspectrum_tape_block_state *state ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_description( char *buffer, size_t length, libspectrum_tape_block *block ); -int WIN32_DLL +WIN32_DLL int libspectrum_tape_block_metadata( libspectrum_tape_block *block ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_tape_block_length( libspectrum_tape_block *block ); /* Accessor functions */ @@ -1019,86 +1029,86 @@ /* A linked list of tape blocks */ typedef struct libspectrum_tape libspectrum_tape; -libspectrum_tape* WIN32_DLL libspectrum_tape_alloc( void ); -libspectrum_error WIN32_DLL libspectrum_tape_clear( libspectrum_tape *tape ); -libspectrum_error WIN32_DLL libspectrum_tape_free( libspectrum_tape *tape ); +WIN32_DLL libspectrum_tape* libspectrum_tape_alloc( void ); +WIN32_DLL libspectrum_error libspectrum_tape_clear( libspectrum_tape *tape ); +WIN32_DLL libspectrum_error libspectrum_tape_free( libspectrum_tape *tape ); /* Read in a tape file, optionally guessing what sort of file it is */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_read( libspectrum_tape *tape, const libspectrum_byte *buffer, size_t length, libspectrum_id_t type, const char *filename ); /* Write a tape file */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_write( libspectrum_byte **buffer, size_t *length, libspectrum_tape *tape, libspectrum_id_t type ); /* Does this tape structure actually contain a tape? */ -int WIN32_DLL libspectrum_tape_present( const libspectrum_tape *tape ); +WIN32_DLL int libspectrum_tape_present( const libspectrum_tape *tape ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_get_next_edge( libspectrum_dword *tstates, int *flags, libspectrum_tape *tape ); /* Get the current block from the tape */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_current_block( libspectrum_tape *tape ); /* Get the state of the active block on the tape */ -libspectrum_tape_state_type WIN32_DLL +WIN32_DLL libspectrum_tape_state_type libspectrum_tape_state( libspectrum_tape *tape ); /* Set the state of the active block on the tape */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_set_state( libspectrum_tape *tape, libspectrum_tape_state_type state ); /* Peek at the next block on the tape */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_peek_next_block( libspectrum_tape *tape ); /* Peek at the last block on the tape */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_peek_last_block( libspectrum_tape *tape ); /* Cause the next block on the tape to be active, initialise it and return it */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_select_next_block( libspectrum_tape *tape ); /* Get the position on the tape of the current block */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_position( int *n, libspectrum_tape *tape ); /* Select the nth block on the tape */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_nth_block( libspectrum_tape *tape, int n ); /* Append a block to the current tape */ -void WIN32_DLL +WIN32_DLL void libspectrum_tape_append_block( libspectrum_tape *tape, libspectrum_tape_block *block ); -void WIN32_DLL +WIN32_DLL void libspectrum_tape_remove_block( libspectrum_tape *tape, libspectrum_tape_iterator it ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_insert_block( libspectrum_tape *tape, libspectrum_tape_block *block, size_t position ); /*** Routines for iterating through a tape ***/ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_iterator_init( libspectrum_tape_iterator *iterator, libspectrum_tape *tape ); -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_iterator_current( libspectrum_tape_iterator iterator ); -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_iterator_next( libspectrum_tape_iterator *iterator ); /*** Routines for handling the TZX generalised data block symbol table @@ -1115,13 +1125,13 @@ typedef struct libspectrum_tape_generalised_data_symbol libspectrum_tape_generalised_data_symbol; -libspectrum_dword WIN32_DLL libspectrum_tape_generalised_data_symbol_table_symbols_in_block( const libspectrum_tape_generalised_data_symbol_table *table ); -libspectrum_byte WIN32_DLL libspectrum_tape_generalised_data_symbol_table_max_pulses( const libspectrum_tape_generalised_data_symbol_table *table ); -libspectrum_word WIN32_DLL libspectrum_tape_generalised_data_symbol_table_symbols_in_table( const libspectrum_tape_generalised_data_symbol_table *table ); -libspectrum_tape_generalised_data_symbol* WIN32_DLL libspectrum_tape_generalised_data_symbol_table_symbol( const libspectrum_tape_generalised_data_symbol_table *table, size_t which ); +WIN32_DLL libspectrum_dword libspectrum_tape_generalised_data_symbol_table_symbols_in_block( const libspectrum_tape_generalised_data_symbol_table *table ); +WIN32_DLL libspectrum_byte libspectrum_tape_generalised_data_symbol_table_max_pulses( const libspectrum_tape_generalised_data_symbol_table *table ); +WIN32_DLL libspectrum_word libspectrum_tape_generalised_data_symbol_table_symbols_in_table( const libspectrum_tape_generalised_data_symbol_table *table ); +WIN32_DLL libspectrum_tape_generalised_data_symbol* libspectrum_tape_generalised_data_symbol_table_symbol( const libspectrum_tape_generalised_data_symbol_table *table, size_t which ); -libspectrum_tape_generalised_data_symbol_edge_type WIN32_DLL libspectrum_tape_generalised_data_symbol_type( const libspectrum_tape_generalised_data_symbol *symbol ); -libspectrum_word WIN32_DLL libspectrum_tape_generalised_data_symbol_pulse( const libspectrum_tape_generalised_data_symbol *symbol, size_t which ); +WIN32_DLL libspectrum_tape_generalised_data_symbol_edge_type libspectrum_tape_generalised_data_symbol_type( const libspectrum_tape_generalised_data_symbol *symbol ); +WIN32_DLL libspectrum_word libspectrum_tape_generalised_data_symbol_pulse( const libspectrum_tape_generalised_data_symbol *symbol, size_t which ); /* @@ -1130,40 +1140,40 @@ typedef struct libspectrum_rzx libspectrum_rzx; -libspectrum_rzx* WIN32_DLL libspectrum_rzx_alloc( void ); -libspectrum_error WIN32_DLL libspectrum_rzx_free( libspectrum_rzx *rzx ); +WIN32_DLL libspectrum_rzx* libspectrum_rzx_alloc( void ); +WIN32_DLL libspectrum_error libspectrum_rzx_free( libspectrum_rzx *rzx ); -void WIN32_DLL +WIN32_DLL void libspectrum_rzx_start_input( libspectrum_rzx *rzx, libspectrum_dword tstates ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_stop_input( libspectrum_rzx *rzx ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_add_snap( libspectrum_rzx *rzx, libspectrum_snap *snap, int automatic ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_rollback( libspectrum_rzx *rzx, libspectrum_snap **snap ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_rollback_to( libspectrum_rzx *rzx, libspectrum_snap **snap, size_t which ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_store_frame( libspectrum_rzx *rzx, size_t instructions, size_t count, libspectrum_byte *in_bytes ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_start_playback( libspectrum_rzx *rzx, int which, libspectrum_snap **snap ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_playback_frame( libspectrum_rzx *rzx, int *finished, libspectrum_snap **snap ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_playback( libspectrum_rzx *rzx, libspectrum_byte *byte ); /* Get and set the tstate counter */ -size_t WIN32_DLL libspectrum_rzx_tstates( libspectrum_rzx *rzx ); +WIN32_DLL size_t libspectrum_rzx_tstates( libspectrum_rzx *rzx ); /* Get the current frame's instruction count */ -size_t WIN32_DLL libspectrum_rzx_instructions( libspectrum_rzx *rzx ); +WIN32_DLL size_t libspectrum_rzx_instructions( libspectrum_rzx *rzx ); -libspectrum_dword WIN32_DLL libspectrum_rzx_get_keyid( libspectrum_rzx *rzx ); +WIN32_DLL libspectrum_dword libspectrum_rzx_get_keyid( libspectrum_rzx *rzx ); typedef struct libspectrum_signature { @@ -1174,7 +1184,7 @@ } libspectrum_signature; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_get_signature( libspectrum_rzx *rzx, libspectrum_signature *signature ); @@ -1186,11 +1196,11 @@ } libspectrum_rzx_dsa_key; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_read( libspectrum_rzx *rzx, const libspectrum_byte *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_write( libspectrum_byte **buffer, size_t *length, libspectrum_rzx *rzx, libspectrum_id_t snap_format, libspectrum_creator *creator, int compress, @@ -1217,22 +1227,22 @@ libspectrum_rzx_insert_snap( libspectrum_rzx *rzx, libspectrum_snap *snap, int where ); -libspectrum_rzx_iterator WIN32_DLL +WIN32_DLL libspectrum_rzx_iterator libspectrum_rzx_iterator_begin( libspectrum_rzx *rzx ); -libspectrum_rzx_iterator WIN32_DLL +WIN32_DLL libspectrum_rzx_iterator libspectrum_rzx_iterator_next( libspectrum_rzx_iterator it ); -libspectrum_rzx_block_id WIN32_DLL +WIN32_DLL libspectrum_rzx_block_id libspectrum_rzx_iterator_get_type( libspectrum_rzx_iterator it ); -size_t WIN32_DLL +WIN32_DLL size_t libspectrum_rzx_iterator_get_frames( libspectrum_rzx_iterator it ); -void WIN32_DLL +WIN32_DLL void libspectrum_rzx_iterator_delete( libspectrum_rzx *rzx, libspectrum_rzx_iterator it ); -libspectrum_snap* WIN32_DLL +WIN32_DLL libspectrum_snap* libspectrum_rzx_iterator_get_snap( libspectrum_rzx_iterator it ); -int WIN32_DLL +WIN32_DLL int libspectrum_rzx_iterator_snap_is_automatic( libspectrum_rzx_iterator it ); /* @@ -1252,41 +1262,41 @@ /* Constructor/destructor */ -libspectrum_microdrive* WIN32_DLL +WIN32_DLL libspectrum_microdrive* libspectrum_microdrive_alloc( void ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_microdrive_free( libspectrum_microdrive *microdrive ); /* Accessors */ -libspectrum_byte WIN32_DLL +WIN32_DLL libspectrum_byte libspectrum_microdrive_data( const libspectrum_microdrive *microdrive, size_t which ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_set_data( libspectrum_microdrive *microdrive, size_t which, libspectrum_byte data ); -int WIN32_DLL +WIN32_DLL int libspectrum_microdrive_write_protect( const libspectrum_microdrive *microdrive ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_set_write_protect( libspectrum_microdrive *microdrive, int write_protect ); -libspectrum_byte WIN32_DLL +WIN32_DLL libspectrum_byte libspectrum_microdrive_cartridge_len( const libspectrum_microdrive *microdrive ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_set_cartridge_len( libspectrum_microdrive *microdrive, libspectrum_byte len ); /* .mdr format routines */ -int WIN32_DLL +WIN32_DLL int libspectrum_microdrive_checksum( libspectrum_microdrive *microdrive, libspectrum_byte what ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_microdrive_mdr_read( libspectrum_microdrive *microdrive, libspectrum_byte *buffer, size_t length ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_mdr_write( const libspectrum_microdrive *microdrive, libspectrum_byte **buffer, size_t *length ); @@ -1322,17 +1332,17 @@ libspectrum_dck_block *dck[256]; /* dck block data */ } libspectrum_dck; -libspectrum_dck* WIN32_DLL libspectrum_dck_alloc( void ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_dck* libspectrum_dck_alloc( void ); +WIN32_DLL libspectrum_error libspectrum_dck_free( libspectrum_dck *dck, int keep_pages ); /* Read in a DCK file */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_dck_read( libspectrum_dck *dck, const libspectrum_byte *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_dck_read2( libspectrum_dck *dck, const libspectrum_byte *buffer, size_t length, const char *filename ); @@ -1340,10 +1350,10 @@ * Crypto functions */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_verify_signature( libspectrum_signature *signature, libspectrum_rzx_dsa_key *key ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_signature_free( libspectrum_signature *signature ); /* @@ -1382,33 +1392,33 @@ typedef struct libspectrum_ide_channel libspectrum_ide_channel; -libspectrum_ide_channel* WIN32_DLL +WIN32_DLL libspectrum_ide_channel* libspectrum_ide_alloc( libspectrum_ide_databus databus ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_ide_free( libspectrum_ide_channel *chn ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_ide_insert( libspectrum_ide_channel *chn, libspectrum_ide_unit unit, const char *filename ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_ide_commit( libspectrum_ide_channel *chn, libspectrum_ide_unit unit ); -int WIN32_DLL +WIN32_DLL int libspectrum_ide_dirty( libspectrum_ide_channel *chn, libspectrum_ide_unit unit ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_ide_eject( libspectrum_ide_channel *chn, libspectrum_ide_unit unit ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_ide_reset( libspectrum_ide_channel *chn ); -libspectrum_byte WIN32_DLL +WIN32_DLL libspectrum_byte libspectrum_ide_read( libspectrum_ide_channel *chn, libspectrum_ide_register reg ); -void WIN32_DLL +WIN32_DLL void libspectrum_ide_write( libspectrum_ide_channel *chn, libspectrum_ide_register reg, libspectrum_byte data ); Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2010-05-24 14:23:37 UTC (rev 639) +++ trunk/FuseImporter/libspectrum.h 2010-05-26 12:46:40 UTC (rev 640) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4060 2009-07-30 13:21:38Z fredm $ + $Id: libspectrum.h.in 4120 2010-02-21 05:06:56Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -38,8 +38,6 @@ #include <stdlib.h> #include <stdio.h> -#include <TargetConditionals.h> - #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN /* Exclude rarely used stuff from Windows @@ -202,6 +200,8 @@ #define g_array_index(a,t,i) (*(((t*)a->data)+i)) GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +#include <TargetConditionals.h> + #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) @@ -210,11 +210,6 @@ #define GPOINTER_TO_INT(p) ((gint) (p)) #endif -/* Library capabilities */ - -/* we support snapshots etc. requiring zlib (e.g. compressed szx) */ -#define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) - /* * General libspectrum routines */ @@ -239,24 +234,40 @@ } libspectrum_error; +/* Library capabilities */ + +/* we support snapshots etc. requiring zlib (e.g. compressed szx) */ +#define LIBSPECTRUM_SUPPORTS_ZLIB_COMPRESSION (1) + +/* zlib (de)compression routines */ + +WIN32_DLL libspectrum_error +libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, + libspectrum_byte **outptr, size_t *outlength ); + +WIN32_DLL libspectrum_error +libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, + libspectrum_byte **gzptr, size_t *gzlength ); + + /* Initialisation */ -libspectrum_error WIN32_DLL libspectrum_init( void ); +WIN32_DLL libspectrum_error libspectrum_init( void ); /* Version checking */ -int WIN32_DLL libspectrum_check_version( const char *version ); -const char WIN32_DLL *libspectrum_version( void ); -const char WIN32_DLL *libspectrum_gcrypt_version( void ); +WIN32_DLL int libspectrum_check_version( const char *version ); +WIN32_DLL const char *libspectrum_version( void ); +WIN32_DLL const char *libspectrum_gcrypt_version( void ); /* Error handling */ typedef libspectrum_error (*libspectrum_error_function_t)( libspectrum_error error, const char *format, va_list ap ); -extern libspectrum_error_function_t WIN32_DLL libspectrum_error_function; +extern WIN32_DLL libspectrum_error_function_t libspectrum_error_function; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_default_error_function( libspectrum_error error, const char *format, va_list ap ); @@ -274,12 +285,12 @@ libspectrum_free_fn_t free; } libspectrum_mem_vtable_t; -void* WIN32_DLL libspectrum_malloc( size_t size ); -void* WIN32_DLL libspectrum_calloc( size_t nmemb, size_t size ); -void* WIN32_DLL libspectrum_realloc( void *ptr, size_t size ); -void WIN32_DLL libspectrum_free( void *ptr ); +WIN32_DLL void* libspectrum_malloc( size_t size ); +WIN32_DLL void* libspectrum_calloc( size_t nmemb, size_t size ); +WIN32_DLL void* libspectrum_realloc( void *ptr, size_t size ); +WIN32_DLL void libspectrum_free( void *ptr ); -void WIN32_DLL libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ); +WIN32_DLL void libspectrum_mem_set_vtable( libspectrum_mem_vtable_t *table ); /* Attempt to identify a given file */ @@ -394,20 +405,20 @@ } libspectrum_class_t; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_file( libspectrum_id_t *type, const char *filename, const unsigned char *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_file_with_class( libspectrum_id_t *type, libspectrum_class_t *libspectrum_class, const char *filename, const unsigned char *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_file_raw( libspectrum_id_t *type, const char *filename, const unsigned char *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_identify_class( libspectrum_class_t *libspectrum_class, libspectrum_id_t type ); @@ -442,122 +453,122 @@ } libspectrum_machine; -const char* WIN32_DLL libspectrum_machine_name( libspectrum_machine type ); +WIN32_DLL const char* libspectrum_machine_name( libspectrum_machine type ); /* The various capabilities of the different machines */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_AY; /* AY-3-8192 */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_128_MEMORY; /* 128-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PLUS3_MEMORY; /* +3-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PLUS3_DISK; /* +3-style disk drive */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_MEMORY; /* Timex-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_VIDEO; /* Timex-style video modes */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TRDOS_DISK; /* TRDOS-style disk drive */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_TIMEX_DOCK; /* T[SC]2068-style cartridge port */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_SINCLAIR_JOYSTICK; /* Sinclair-style joystick ports */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_KEMPSTON_JOYSTICK; /* Kempston-style joystick ports */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_SCORP_MEMORY; /* Scorpion-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_EVEN_M1; /* M1 cycles always start on even tstate counts */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_SE_MEMORY; /* SE-style memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_NTSC; /* NTSC display */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PENT512_MEMORY; /* Pentagon 512 memory paging */ -extern const int WIN32_DLL +extern WIN32_DLL const int LIBSPECTRUM_MACHINE_CAPABILITY_PENT1024_MEMORY; /* Pentagon 1024 memory paging */ /* Get the capabilities of a machine */ -int WIN32_DLL libspectrum_machine_capabilities( libspectrum_machine type ); +WIN32_DLL int libspectrum_machine_capabilities( libspectrum_machine type ); /* Get the timings of a machine */ -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_timings_processor_speed( libspectrum_machine machine ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_timings_ay_speed( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_left_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_horizontal_screen( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_right_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_horizontal_retrace( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_top_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_vertical_screen( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_bottom_border( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_vertical_retrace( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_interrupt_length( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_top_left_pixel( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_tstates_per_line( libspectrum_machine machine ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_timings_lines_per_frame( libspectrum_machine machine ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_timings_tstates_per_frame( libspectrum_machine machine ); /* Creator information */ typedef struct libspectrum_creator libspectrum_creator; -libspectrum_creator* WIN32_DLL +WIN32_DLL libspectrum_creator* libspectrum_creator_alloc( void ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_free( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_program( libspectrum_creator *creator, const char *program ); -const char WIN32_DLL * +WIN32_DLL const char * libspectrum_creator_program( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_major( libspectrum_creator *creator, libspectrum_word major ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_creator_major( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_minor( libspectrum_creator *creator, libspectrum_word minor ); -libspectrum_word WIN32_DLL +WIN32_DLL libspectrum_word libspectrum_creator_minor( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_competition_code( libspectrum_creator *creator, libspectrum_dword competition_code ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_creator_competition_code( libspectrum_creator *creator ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_creator_set_custom( libspectrum_creator *creator, libspectrum_byte *data, size_t length ); -libspectrum_byte WIN32_DLL * +WIN32_DLL libspectrum_byte * libspectrum_creator_custom( libspectrum_creator *creator ); -size_t WIN32_DLL +WIN32_DLL size_t libspectrum_creator_custom_length( libspectrum_creator *creator ); /* @@ -566,29 +577,29 @@ typedef struct libspectrum_snap libspectrum_snap; -libspectrum_snap* WIN32_DLL libspectrum_snap_alloc( void ); -libspectrum_error WIN32_DLL libspectrum_snap_free( libspectrum_snap *snap ); +WIN32_DLL libspectrum_snap* libspectrum_snap_alloc( void ); +WIN32_DLL libspectrum_error libspectrum_snap_free( libspectrum_snap *snap ); /* Read in a snapshot, optionally guessing what type it is */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_snap_read( libspectrum_snap *snap, const libspectrum_byte *buffer, size_t length, libspectrum_id_t type, const char *filename ); /* Write a snapshot */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_snap_write( libspectrum_byte **buffer, size_t *length, int *out_flags, libspectrum_snap *snap, libspectrum_id_t type, libspectrum_creator *creator, int in_flags ); /* The flags that can be given to libspectrum_snap_write() */ -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_NO_COMPRESSION; -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_ALWAYS_COMPRESS; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_NO_COMPRESSION; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_ALWAYS_COMPRESS; /* The flags that may be returned from libspectrum_snap_write() */ -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_MINOR_INFO_LOSS; -extern const int WIN32_DLL LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_MINOR_INFO_LOSS; +extern WIN32_DLL const int LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; /* The joystick types we can handle */ typedef enum libspectrum_joystick { @@ -605,12 +616,12 @@ } libspectrum_joystick; -const char* WIN32_DLL libspectrum_joystick_name( libspectrum_joystick type ); +WIN32_DLL const char* libspectrum_joystick_name( libspectrum_joystick type ); -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_NONE; -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_KEYBOARD; -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_1; -extern const int WIN32_DLL LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_2; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_NONE; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_KEYBOARD; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_1; +extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_2; /* Accessor functions */ libspectrum_machine WIN32_DLL libspectrum_snap_machine( libspectrum_snap *snap ); @@ -856,8 +867,7 @@ int WIN32_DLL libspectrum_snap_fuller_box_active( libspectrum_snap *snap ); void WIN32_DLL libspectrum_snap_set_fuller_box_active( libspectrum_snap *snap, int fuller_box_active ); int WIN32_DLL libspectrum_snap_melodik_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int - melodik_active ); +void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int melodik_active ); /* * Tape handling routines @@ -911,15 +921,15 @@ typedef struct _GSList *libspectrum_tape_iterator; /* Some flags */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_BLOCK; /* End of block */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_STOP; /* Stop tape */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_STOP48; /* Stop tape if in 48K mode */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_NO_EDGE; /* Edge isn't really an edge */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LEVEL_LOW; /* Set level low */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LEVEL_HIGH; /* Set level high */ -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_SHORT; -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_LENGTH_LONG; -extern const int WIN32_DLL LIBSPECTRUM_TAPE_FLAGS_TAPE; /* Tape has finished */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_BLOCK; /* End of block */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_STOP; /* Stop tape */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_STOP48; /* Stop tape if in 48K mode */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_NO_EDGE; /* Edge isn't really an edge */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LEVEL_LOW; /* Set level low */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LEVEL_HIGH; /* Set level high */ +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LENGTH_SHORT; +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_LENGTH_LONG; +extern WIN32_DLL const int LIBSPECTRUM_TAPE_FLAGS_TAPE; /* Tape has finished */ /* The states which a block can be in */ typedef enum libspectrum_tape_state_type { @@ -936,28 +946,28 @@ } libspectrum_tape_state_type; /* Routines to manipulate tape blocks */ -libspectrum_tape_block* WIN32_DLL +WIN32_DLL libspectrum_tape_block* libspectrum_tape_block_alloc( libspectrum_tape_type type ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_free( libspectrum_tape_block *block ); -libspectrum_tape_type WIN32_DLL +WIN32_DLL libspectrum_tape_type libspectrum_tape_block_type( libspectrum_tape_block *block ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_set_type( libspectrum_tape_block *block, libspectrum_tape_type type ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_init( libspectrum_tape_block *block, libspectrum_tape_block_state *state ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_block_description( char *buffer, size_t length, libspectrum_tape_block *block ); -int WIN32_DLL +WIN32_DLL int libspectrum_tape_block_metadata( libspectrum_tape_block *block ); -libspectrum_dword WIN32_DLL +WIN32_DLL libspectrum_dword libspectrum_tape_block_length( libspectrum_tape_block *block ); /* Accessor functions */ @@ -1019,86 +1029,86 @@ /* A linked list of tape blocks */ typedef struct libspectrum_tape libspectrum_tape; -libspectrum_tape* WIN32_DLL libspectrum_tape_alloc( void ); -libspectrum_error WIN32_DLL libspectrum_tape_clear( libspectrum_tape *tape ); -libspectrum_error WIN32_DLL libspectrum_tape_free( libspectrum_tape *tape ); +WIN32_DLL libspectrum_tape* libspectrum_tape_alloc( void ); +WIN32_DLL libspectrum_error libspectrum_tape_clear( libspectrum_tape *tape ); +WIN32_DLL libspectrum_error libspectrum_tape_free( libspectrum_tape *tape ); /* Read in a tape file, optionally guessing what sort of file it is */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_read( libspectrum_tape *tape, const libspectrum_byte *buffer, size_t length, libspectrum_id_t type, const char *filename ); /* Write a tape file */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_write( libspectrum_byte **buffer, size_t *length, libspectrum_tape *tape, libspectrum_id_t type ); /* Does this tape structure actually contain a tape? */ -int WIN32_DLL libspectrum_tape_present( const libspectrum_tape *tape ); +WIN32_DLL int libspectrum_tape_present( const libspectrum_tape *tape ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_get_next_edge( libspectrum_dword *tstates, int *flags, libspectrum_tape *tape ); /* Get the current block from the tape */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_current_block( libspectrum_tape *tape ); /* Get the state of the active block on the tape */ -libspectrum_tape_state_type WIN32_DLL +WIN32_DLL libspectrum_tape_state_type libspectrum_tape_state( libspectrum_tape *tape ); /* Set the state of the active block on the tape */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_set_state( libspectrum_tape *tape, libspectrum_tape_state_type state ); /* Peek at the next block on the tape */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_peek_next_block( libspectrum_tape *tape ); /* Peek at the last block on the tape */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_peek_last_block( libspectrum_tape *tape ); /* Cause the next block on the tape to be active, initialise it and return it */ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_select_next_block( libspectrum_tape *tape ); /* Get the position on the tape of the current block */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_position( int *n, libspectrum_tape *tape ); /* Select the nth block on the tape */ -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_nth_block( libspectrum_tape *tape, int n ); /* Append a block to the current tape */ -void WIN32_DLL +WIN32_DLL void libspectrum_tape_append_block( libspectrum_tape *tape, libspectrum_tape_block *block ); -void WIN32_DLL +WIN32_DLL void libspectrum_tape_remove_block( libspectrum_tape *tape, libspectrum_tape_iterator it ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_tape_insert_block( libspectrum_tape *tape, libspectrum_tape_block *block, size_t position ); /*** Routines for iterating through a tape ***/ -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_iterator_init( libspectrum_tape_iterator *iterator, libspectrum_tape *tape ); -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_iterator_current( libspectrum_tape_iterator iterator ); -libspectrum_tape_block WIN32_DLL * +WIN32_DLL libspectrum_tape_block * libspectrum_tape_iterator_next( libspectrum_tape_iterator *iterator ); /*** Routines for handling the TZX generalised data block symbol table @@ -1115,13 +1125,13 @@ typedef struct libspectrum_tape_generalised_data_symbol libspectrum_tape_generalised_data_symbol; -libspectrum_dword WIN32_DLL libspectrum_tape_generalised_data_symbol_table_symbols_in_block( const libspectrum_tape_generalised_data_symbol_table *table ); -libspectrum_byte WIN32_DLL libspectrum_tape_generalised_data_symbol_table_max_pulses( const libspectrum_tape_generalised_data_symbol_table *table ); -libspectrum_word WIN32_DLL libspectrum_tape_generalised_data_symbol_table_symbols_in_table( const libspectrum_tape_generalised_data_symbol_table *table ); -libspectrum_tape_generalised_data_symbol* WIN32_DLL libspectrum_tape_generalised_data_symbol_table_symbol( const libspectrum_tape_generalised_data_symbol_table *table, size_t which ); +WIN32_DLL libspectrum_dword libspectrum_tape_generalised_data_symbol_table_symbols_in_block( const libspectrum_tape_generalised_data_symbol_table *table ); +WIN32_DLL libspectrum_byte libspectrum_tape_generalised_data_symbol_table_max_pulses( const libspectrum_tape_generalised_data_symbol_table *table ); +WIN32_DLL libspectrum_word libspectrum_tape_generalised_data_symbol_table_symbols_in_table( const libspectrum_tape_generalised_data_symbol_table *table ); +WIN32_DLL libspectrum_tape_generalised_data_symbol* libspectrum_tape_generalised_data_symbol_table_symbol( const libspectrum_tape_generalised_data_symbol_table *table, size_t which ); -libspectrum_tape_generalised_data_symbol_edge_type WIN32_DLL libspectrum_tape_generalised_data_symbol_type( const libspectrum_tape_generalised_data_symbol *symbol ); -libspectrum_word WIN32_DLL libspectrum_tape_generalised_data_symbol_pulse( const libspectrum_tape_generalised_data_symbol *symbol, size_t which ); +WIN32_DLL libspectrum_tape_generalised_data_symbol_edge_type libspectrum_tape_generalised_data_symbol_type( const libspectrum_tape_generalised_data_symbol *symbol ); +WIN32_DLL libspectrum_word libspectrum_tape_generalised_data_symbol_pulse( const libspectrum_tape_generalised_data_symbol *symbol, size_t which ); /* @@ -1130,40 +1140,40 @@ typedef struct libspectrum_rzx libspectrum_rzx; -libspectrum_rzx* WIN32_DLL libspectrum_rzx_alloc( void ); -libspectrum_error WIN32_DLL libspectrum_rzx_free( libspectrum_rzx *rzx ); +WIN32_DLL libspectrum_rzx* libspectrum_rzx_alloc( void ); +WIN32_DLL libspectrum_error libspectrum_rzx_free( libspectrum_rzx *rzx ); -void WIN32_DLL +WIN32_DLL void libspectrum_rzx_start_input( libspectrum_rzx *rzx, libspectrum_dword tstates ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_stop_input( libspectrum_rzx *rzx ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_add_snap( libspectrum_rzx *rzx, libspectrum_snap *snap, int automatic ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_rollback( libspectrum_rzx *rzx, libspectrum_snap **snap ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_rollback_to( libspectrum_rzx *rzx, libspectrum_snap **snap, size_t which ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_store_frame( libspectrum_rzx *rzx, size_t instructions, size_t count, libspectrum_byte *in_bytes ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_start_playback( libspectrum_rzx *rzx, int which, libspectrum_snap **snap ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_playback_frame( libspectrum_rzx *rzx, int *finished, libspectrum_snap **snap ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_playback( libspectrum_rzx *rzx, libspectrum_byte *byte ); /* Get and set the tstate counter */ -size_t WIN32_DLL libspectrum_rzx_tstates( libspectrum_rzx *rzx ); +WIN32_DLL size_t libspectrum_rzx_tstates( libspectrum_rzx *rzx ); /* Get the current frame's instruction count */ -size_t WIN32_DLL libspectrum_rzx_instructions( libspectrum_rzx *rzx ); +WIN32_DLL size_t libspectrum_rzx_instructions( libspectrum_rzx *rzx ); -libspectrum_dword WIN32_DLL libspectrum_rzx_get_keyid( libspectrum_rzx *rzx ); +WIN32_DLL libspectrum_dword libspectrum_rzx_get_keyid( libspectrum_rzx *rzx ); typedef struct libspectrum_signature { @@ -1174,7 +1184,7 @@ } libspectrum_signature; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_get_signature( libspectrum_rzx *rzx, libspectrum_signature *signature ); @@ -1186,11 +1196,11 @@ } libspectrum_rzx_dsa_key; -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_read( libspectrum_rzx *rzx, const libspectrum_byte *buffer, size_t length ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_rzx_write( libspectrum_byte **buffer, size_t *length, libspectrum_rzx *rzx, libspectrum_id_t snap_format, libspectrum_creator *creator, int compress, @@ -1217,22 +1227,22 @@ libspectrum_rzx_insert_snap( libspectrum_rzx *rzx, libspectrum_snap *snap, int where ); -libspectrum_rzx_iterator WIN32_DLL +WIN32_DLL libspectrum_rzx_iterator libspectrum_rzx_iterator_begin( libspectrum_rzx *rzx ); -libspectrum_rzx_iterator WIN32_DLL +WIN32_DLL libspectrum_rzx_iterator libspectrum_rzx_iterator_next( libspectrum_rzx_iterator it ); -libspectrum_rzx_block_id WIN32_DLL +WIN32_DLL libspectrum_rzx_block_id libspectrum_rzx_iterator_get_type( libspectrum_rzx_iterator it ); -size_t WIN32_DLL +WIN32_DLL size_t libspectrum_rzx_iterator_get_frames( libspectrum_rzx_iterator it ); -void WIN32_DLL +WIN32_DLL void libspectrum_rzx_iterator_delete( libspectrum_rzx *rzx, libspectrum_rzx_iterator it ); -libspectrum_snap* WIN32_DLL +WIN32_DLL libspectrum_snap* libspectrum_rzx_iterator_get_snap( libspectrum_rzx_iterator it ); -int WIN32_DLL +WIN32_DLL int libspectrum_rzx_iterator_snap_is_automatic( libspectrum_rzx_iterator it ); /* @@ -1252,41 +1262,41 @@ /* Constructor/destructor */ -libspectrum_microdrive* WIN32_DLL +WIN32_DLL libspectrum_microdrive* libspectrum_microdrive_alloc( void ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_microdrive_free( libspectrum_microdrive *microdrive ); /* Accessors */ -libspectrum_byte WIN32_DLL +WIN32_DLL libspectrum_byte libspectrum_microdrive_data( const libspectrum_microdrive *microdrive, size_t which ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_set_data( libspectrum_microdrive *microdrive, size_t which, libspectrum_byte data ); -int WIN32_DLL +WIN32_DLL int libspectrum_microdrive_write_protect( const libspectrum_microdrive *microdrive ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_set_write_protect( libspectrum_microdrive *microdrive, int write_protect ); -libspectrum_byte WIN32_DLL +WIN32_DLL libspectrum_byte libspectrum_microdrive_cartridge_len( const libspectrum_microdrive *microdrive ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_set_cartridge_len( libspectrum_microdrive *microdrive, libspectrum_byte len ); /* .mdr format routines */ -int WIN32_DLL +WIN32_DLL int libspectrum_microdrive_checksum( libspectrum_microdrive *microdrive, libspectrum_byte what ); -libspectrum_error WIN32_DLL +WIN32_DLL libspectrum_error libspectrum_microdrive_mdr_read( libspectrum_microdrive *microdrive, libspectrum_byte *buffer, size_t length ); -void WIN32_DLL +WIN32_DLL void libspectrum_microdrive_mdr_write( const libspectrum_microdrive *microdrive, libspectrum_byte **buffer, size_t *length ); @@ -1322,17 +1332,17 @@ libspectrum_dck_block *dck[256]; /* dck block data */ } libspectrum_dck; -libspectrum_dck* WIN32_DLL libspectrum_dck_alloc( void ); -libspectrum_error ... [truncated message content] |
From: <fr...@us...> - 2010-10-08 13:06:43
|
Revision: 650 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=650&view=rev Author: fredm Date: 2010-10-08 13:06:33 +0000 (Fri, 08 Oct 2010) Log Message: ----------- Merge up to vendor revision 4178. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=4178&view=rev Modified Paths: -------------- trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/libspectrum.h trunk/fuse/ChangeLog trunk/fuse/README trunk/fuse/configure.in trunk/fuse/disk/beta.c trunk/fuse/disk/disk.c trunk/fuse/fuse.c trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/config.h trunk/fuse/fusepb/controllers/FuseController.m trunk/fuse/fusepb/libspectrum.h trunk/fuse/fusepb/models/Emulator.m trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html trunk/fuse/fusepb/xibs/Preferences.xib trunk/fuse/hacking/ChangeLog trunk/fuse/ide/divide.c trunk/fuse/ide/divide.h trunk/fuse/ide/ide.c trunk/fuse/ide/ide.h trunk/fuse/ide/simpleide.c trunk/fuse/ide/simpleide.h trunk/fuse/ide/zxatasp.c trunk/fuse/ide/zxatasp.h trunk/fuse/ide/zxcf.c trunk/fuse/ide/zxcf.h trunk/fuse/lib/Makefile.am trunk/fuse/lib/compressed/disk_plus3.szx trunk/fuse/lib/compressed/tape_128.szx trunk/fuse/lib/compressed/tape_16.szx trunk/fuse/lib/compressed/tape_2048.szx trunk/fuse/lib/compressed/tape_2068.szx trunk/fuse/lib/compressed/tape_48.szx trunk/fuse/lib/compressed/tape_pentagon.szx trunk/fuse/lib/compressed/tape_plus2.szx trunk/fuse/lib/compressed/tape_plus2a.szx trunk/fuse/lib/compressed/tape_plus3.szx trunk/fuse/lib/compressed/tape_plus3e.szx trunk/fuse/lib/compressed/tape_scorpion.szx trunk/fuse/lib/compressed/tape_se.szx trunk/fuse/lib/compressed/tape_ts2068.szx trunk/fuse/lib/uncompressed/disk_plus3.szx trunk/fuse/lib/uncompressed/tape_128.szx trunk/fuse/lib/uncompressed/tape_16.szx trunk/fuse/lib/uncompressed/tape_2048.szx trunk/fuse/lib/uncompressed/tape_2068.szx trunk/fuse/lib/uncompressed/tape_48.szx trunk/fuse/lib/uncompressed/tape_pentagon.szx trunk/fuse/lib/uncompressed/tape_plus2.szx trunk/fuse/lib/uncompressed/tape_plus2a.szx trunk/fuse/lib/uncompressed/tape_plus3.szx trunk/fuse/lib/uncompressed/tape_plus3e.szx trunk/fuse/lib/uncompressed/tape_scorpion.szx trunk/fuse/lib/uncompressed/tape_se.szx trunk/fuse/lib/uncompressed/tape_ts2068.szx trunk/fuse/machine.c trunk/fuse/machines/Makefile.am trunk/fuse/machines/machines.h trunk/fuse/man/fuse.1 trunk/fuse/menu.c trunk/fuse/menu.h trunk/fuse/rzx.c trunk/fuse/rzx.h trunk/fuse/sound/coreaudiosound.c trunk/fuse/tape.c trunk/fuse/ui/gtk/gtkdisplay.c trunk/fuse/ui/gtk/gtkkeyboard.c trunk/fuse/ui/gtk/gtkui.c trunk/fuse/ui/gtk/statusbar.c trunk/fuse/ui/gtk/stock.c trunk/fuse/ui/win32/installer/fuse.nsi trunk/fuse/ui.c trunk/fuse/utils.c trunk/fuse/utils.h trunk/fuse/windres.rc trunk/libspectrum/libspectrum/ChangeLog trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/README trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/libspectrum.c trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/rzx.c trunk/libspectrum/libspectrum/sna.c trunk/libspectrum/libspectrum/szx.c trunk/libspectrum/libspectrum/tape_block.c trunk/libspectrum/libspectrum/test/test.c trunk/libspectrum/libspectrum/timings.c trunk/libspectrum/libspectrum/z80.c trunk/libspectrum/libspectrum.h Added Paths: ----------- trunk/fuse/lib/compressed/tape_48_ntsc.szx trunk/fuse/lib/uncompressed/tape_48_ntsc.szx trunk/fuse/machines/spec48_ntsc.c trunk/libspectrum/libspectrum/test/empty.szx trunk/libspectrum/libspectrum/test/plus3.z80 trunk/libspectrum/libspectrum/windres.rc Property Changed: ---------------- trunk/fuse/ trunk/fuse/fusepb/libspectrum.h trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/FuseGenerator/libspectrum.h 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4120 2010-02-21 05:06:56Z fredm $ + $Id: libspectrum.h.in 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -451,6 +451,8 @@ LIBSPECTRUM_MACHINE_PENT512, LIBSPECTRUM_MACHINE_PENT1024, + LIBSPECTRUM_MACHINE_48_NTSC, + } libspectrum_machine; WIN32_DLL const char* libspectrum_machine_name( libspectrum_machine type ); Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/FuseImporter/libspectrum.h 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4120 2010-02-21 05:06:56Z fredm $ + $Id: libspectrum.h.in 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -451,6 +451,8 @@ LIBSPECTRUM_MACHINE_PENT512, LIBSPECTRUM_MACHINE_PENT1024, + LIBSPECTRUM_MACHINE_48_NTSC, + } libspectrum_machine; WIN32_DLL const char* libspectrum_machine_name( libspectrum_machine type ); Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-638 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-649 Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ChangeLog 2010-10-08 13:06:33 UTC (rev 650) @@ -1,6 +1,6 @@ -2010-xx-xx Philip Kendall <phi...@sh...> +2010-10-xx Philip Kendall <phi...@sh...> - * Fuse 0.11.0 released + * Fuse 1.0.0 released. * Add Opus Discovery disk interface support (Gergely Szasz and Fredrick Meunier). @@ -8,6 +8,8 @@ * Many improvements to Win32 UI, including an installer (Marek Januszewski). * Support weak data in +3 disk images (Gergely Szasz). + * NTSC Spectrum support (Philip Kendall, with thanks to Claudio + Bernet). * Add support for flipping disk images in single sided drives (Gergely Szasz). * Add support for automatically merging both both disk images where @@ -47,8 +49,6 @@ notebooks (thanks, Andrew Owen) (Fredrick Meunier). * Fixes for speed estimation (Gergely Szasz). * Fix border colour in Timex HiRes screenshots (Fredrick Meunier). - * Fix accelerated loaders when compiling with gcc 3.x (Carlos - Almeida, Alberto Garcia and Philip Kendall). * Allow "combo" boxes in widget UI (Gergely Szasz). * Allow Home and End keys to work in widget UI (Gergely Szasz). * Fix poke finder passing the wrong page to the debugger (Marek @@ -1035,4 +1035,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 4134 2010-05-21 13:16:19Z fredm $ +$Id: ChangeLog 4165 2010-09-30 21:55:05Z pak21 $ Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/README 2010-10-08 13:06:33 UTC (rev 650) @@ -1,5 +1,5 @@ -The Free Unix Spectrum Emulator (Fuse) 0.10.0.2 -=============================================== +The Free Unix Spectrum Emulator (Fuse) 1.0.0 +============================================ Fuse (the Free Unix Spectrum Emulator) was originally, and somewhat unsurprisingly, an emulator of the ZX Spectrum (a popular 1980s home @@ -209,11 +209,11 @@ and the Fuse project page on SourceForge, http://sourceforge.net/projects/fuse-emulator/ -If you're interested in more general Speccy related discussions, visit -the Usenet group 'comp.sys.sinclair', but do read the FAQ -( http://www.worldofspectrum.org/faq/index.html ) first! +For Spectrum discussions not directly related to Fuse, visit either the +Usenet newsgroup `comp.sys.sinclair' or the World of Spectrum forums +<http://www.worldofspectrum.org/forums/>. Philip Kendall <phi...@sh...> -14 January 2009 +FIXME October 2010 -$Id: README 4132 2010-05-20 12:06:53Z fredm $ +$Id: README 4172 2010-10-03 22:51:59Z pak21 $ Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/configure.in 2010-10-08 13:06:33 UTC (rev 650) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 4132 2010-05-20 12:06:53Z fredm $ +dnl $Id: configure.in 4175 2010-10-06 10:44:19Z fredm $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -23,8 +23,10 @@ AM_CONFIG_HEADER(config.h) AC_CANONICAL_SYSTEM +define(FUSE_VERSION, [0.10.0.2]) + dnl Use automake to produce `Makefile.in' -AM_INIT_AUTOMAKE(fuse, 0.10.0.2) +AM_INIT_AUTOMAKE(fuse, FUSE_VERSION) dnl Checks for programs. AC_PROG_CC @@ -40,8 +42,10 @@ AC_SUBST(WINDRES) if test "$WINDRES" != no; then WINDRES_OBJ="windres.o" + AC_DEFINE([VERSION_WIN32], [translit(FUSE_VERSION, [.], [,])], [Define version information for win32 executable]) fi AC_SUBST(WINDRES_OBJ) +AM_SUBST_NOTMAKE(WINDRES_OBJ) dnl Generate commandy.h YFLAGS="$YFLAGS -d" @@ -247,7 +251,11 @@ fi dnl Check for the MIT-SHM extension - AC_CHECK_HEADERS( X11/extensions/XShm.h ) + AC_CHECK_HEADERS( X11/extensions/XShm.h,,,[[ + #include <sys/ipc.h> + #include <sys/shm.h> + #include <X11/Xlib.h> + ]]) AC_CHECK_LIB( Xext, XShmAttach, LIBS="$LIBS -lXext" ) AC_DEFINE([UI_X], 1, [Defined if Xlib UI in use]) Modified: trunk/fuse/disk/beta.c =================================================================== --- trunk/fuse/disk/beta.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/disk/beta.c 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* beta.c: Routines for handling the Beta disk interface Copyright (c) 2004-2008 Stuart Brady - $Id: beta.c 4131 2010-05-19 10:52:37Z fredm $ + $Id: beta.c 4147 2010-08-19 12:25:15Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -65,6 +65,8 @@ int beta_active = 0; int beta_builtin = 0; +static libspectrum_byte beta_system_register; /* FDC system register */ + libspectrum_word beta_pc_mask; libspectrum_word beta_pc_value; @@ -365,6 +367,8 @@ fdd_set_head( &beta_fdc->current_drive->fdd, ( ( b & 0x10 ) ? 0 : 1 ) ); /* 0x20 = density, reset = FM, set = MFM */ beta_fdc->dden = b & 0x20 ? 1 : 0; + + beta_system_register = b; } libspectrum_byte @@ -725,7 +729,6 @@ void beta_to_snapshot( libspectrum_snap *snap ) { - int attached; wd_fdc *f = beta_fdc; libspectrum_byte *buffer; int drive_count = 0; @@ -759,9 +762,9 @@ libspectrum_snap_set_beta_paged ( snap, beta_active ); libspectrum_snap_set_beta_direction( snap, beta_fdc->direction ); - libspectrum_snap_set_beta_status( snap, beta_sr_read( 0x001f, &attached ) ); + libspectrum_snap_set_beta_status( snap, f->status_register ); libspectrum_snap_set_beta_track ( snap, f->track_register ); libspectrum_snap_set_beta_sector( snap, f->sector_register ); libspectrum_snap_set_beta_data ( snap, f->data_register ); - libspectrum_snap_set_beta_system( snap, beta_sp_read( 0x00ff, &attached ) ); + libspectrum_snap_set_beta_system( snap, beta_system_register ); } Modified: trunk/fuse/disk/disk.c =================================================================== --- trunk/fuse/disk/disk.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/disk/disk.c 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* disk.c: Routines for handling disk images Copyright (c) 2007-2010 Gergely Szasz - $Id: disk.c 4114 2010-01-15 13:45:51Z fredm $ + $Id: disk.c 4141 2010-07-19 11:30:21Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -102,6 +102,8 @@ size_t index; } buffer_t; +void disk_update_tlens( disk_t *d ); + const char * disk_strerror( int error ) { @@ -742,6 +744,7 @@ d->wrprot = 0; d->dirty = 0; + disk_update_tlens( d ); return d->status = DISK_OK; } Modified: trunk/fuse/fuse.c =================================================================== --- trunk/fuse/fuse.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fuse.c 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* fuse.c: The Free Unix Spectrum Emulator - Copyright (c) 1999-2009 Philip Kendall + Copyright (c) 1999-2010 Philip Kendall and others - $Id: fuse.c 4109 2009-12-27 06:15:10Z fredm $ + $Id: fuse.c 4165 2010-09-30 21:55:05Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -383,7 +383,7 @@ printf( "\n" ); fuse_show_version(); printf( - "Copyright (c) 1999-2009 Philip Kendall and others; see the file\n" + "Copyright (c) 1999-2010 Philip Kendall and others; see the file\n" "'AUTHORS' for more details.\n" "\n" "For help, please mail <fus...@li...> or use\n" @@ -628,7 +628,7 @@ static int do_start_files( start_files_t *start_files ) { - int autoload, error, i; + int autoload, error, i, check_snapshot; /* Can't do both input recording and playback */ if( start_files->playback && start_files->recording ) { @@ -773,7 +773,8 @@ /* Input recordings */ if( start_files->playback ) { - error = utils_open_file( start_files->playback, autoload, NULL ); + check_snapshot = start_files->snapshot ? 0 : 1; + error = rzx_start_playback( start_files->playback, check_snapshot ); if( error ) return error; } Modified: trunk/fuse/fusepb/English.lproj/InfoPlist.strings =================================================================== (Binary files differ) Modified: trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj =================================================================== --- trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2010-10-08 13:06:33 UTC (rev 650) @@ -218,6 +218,8 @@ B6A6F1200B3EA737000B88E9 /* cocoascreenshot.m in Sources */ = {isa = PBXBuildFile; fileRef = B6A6F11E0B3EA737000B88E9 /* cocoascreenshot.m */; }; B6B076B30B59FE9A00D4F95C /* Emulator.m in Sources */ = {isa = PBXBuildFile; fileRef = B6B076B10B59FE9A00D4F95C /* Emulator.m */; }; B6B99F8A0B5F798700EE408F /* cocoadisplay.m in Sources */ = {isa = PBXBuildFile; fileRef = B6B99F890B5F798700EE408F /* cocoadisplay.m */; }; + B6BDE2D3125DF48000B81C58 /* tape_48_ntsc.szx in CopyFiles */ = {isa = PBXBuildFile; fileRef = B6BDE2D2125DF48000B81C58 /* tape_48_ntsc.szx */; }; + B6BDE2DB125DF4A800B81C58 /* spec48_ntsc.c in Sources */ = {isa = PBXBuildFile; fileRef = B6BDE2DA125DF4A800B81C58 /* spec48_ntsc.c */; }; B6CA27A70C2CDBC500F06FB3 /* dirty.c in Sources */ = {isa = PBXBuildFile; fileRef = B6CA27A50C2CDBC500F06FB3 /* dirty.c */; }; B6CA2A230C33F84A0003CF90 /* module.c in Sources */ = {isa = PBXBuildFile; fileRef = B6CA2A210C33F8490003CF90 /* module.c */; }; B6CA2A260C33F8800003CF90 /* plusd.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6CA2A250C33F8800003CF90 /* plusd.rom */; }; @@ -347,6 +349,7 @@ B61F459309121DF100C8096C /* Fuse Help in CopyFiles */, B61F459409121DF100C8096C /* disk_plus3.szx in CopyFiles */, B61F459509121DF100C8096C /* tape_16.szx in CopyFiles */, + B6BDE2D3125DF48000B81C58 /* tape_48_ntsc.szx in CopyFiles */, B61F459609121DF100C8096C /* tape_48.szx in CopyFiles */, B61F459709121DF100C8096C /* tape_128.szx in CopyFiles */, B61F459809121DF100C8096C /* tape_2048.szx in CopyFiles */, @@ -573,6 +576,8 @@ B6B076B10B59FE9A00D4F95C /* Emulator.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = Emulator.m; sourceTree = "<group>"; }; B6B99F890B5F798700EE408F /* cocoadisplay.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = cocoadisplay.m; sourceTree = "<group>"; }; B6BA1A9404E4F88F0017354F /* uijoystick.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = uijoystick.h; path = ../ui/uijoystick.h; sourceTree = SOURCE_ROOT; }; + B6BDE2D2125DF48000B81C58 /* tape_48_ntsc.szx */ = {isa = PBXFileReference; lastKnownFileType = file; name = tape_48_ntsc.szx; path = ../lib/compressed/tape_48_ntsc.szx; sourceTree = "<group>"; }; + B6BDE2DA125DF4A800B81C58 /* spec48_ntsc.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = spec48_ntsc.c; path = machines/spec48_ntsc.c; sourceTree = "<group>"; }; B6C3479F044B091100E1BBA7 /* ts2068.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = ts2068.png; path = resources/ts2068.png; sourceTree = SOURCE_ROOT; }; B6C57E0005ECA05B0056F1D0 /* periph.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = periph.c; path = ../periph.c; sourceTree = SOURCE_ROOT; }; B6C57E0105ECA05B0056F1D0 /* periph.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = periph.h; path = ../periph.h; sourceTree = SOURCE_ROOT; }; @@ -1108,6 +1113,7 @@ B66050F80606AB0B00247454 /* scorpion.c */, B66050F90606AB0B00247454 /* scorpion.h */, B6EEA76F03CEF1D500FE73F2 /* spec16.c */, + B6BDE2DA125DF4A800B81C58 /* spec48_ntsc.c */, F559860D0389234A01A804BA /* spec48.c */, F559860E0389234A01A804BA /* spec48.h */, F559860F0389234A01A804BA /* spec128.c */, @@ -1314,6 +1320,7 @@ children = ( B650C3F2076596C700DE7E81 /* disk_plus3.szx */, B650C3F4076596FD00DE7E81 /* tape_16.szx */, + B6BDE2D2125DF48000B81C58 /* tape_48_ntsc.szx */, B650C3F60765971300DE7E81 /* tape_48.szx */, B650C3F80765972E00DE7E81 /* tape_128.szx */, B650C3FA0765974600DE7E81 /* tape_2048.szx */, @@ -1495,7 +1502,14 @@ isa = PBXProject; buildConfigurationList = B63319B3086803BA00732AA3 /* Build configuration list for PBXProject "Fuse" */; compatibilityVersion = "Xcode 3.1"; + developmentRegion = English; hasScannedForEncodings = 1; + knownRegions = ( + English, + Japanese, + French, + German, + ); mainGroup = 29B97314FDCFA39411CA2CEA /* Fuse */; projectDirPath = ""; projectRoot = ""; @@ -1772,6 +1786,7 @@ B6501DF411AABD6800898AD1 /* blipbuffer.c in Sources */, B6501DF711AABD9300898AD1 /* sound.c in Sources */, B6501DFC11AABE2300898AD1 /* rectangle.c in Sources */, + B6BDE2DB125DF4A800B81C58 /* spec48_ntsc.c in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/Info-Fuse.plist 2010-10-08 13:06:33 UTC (rev 650) @@ -510,11 +510,11 @@ <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleShortVersionString</key> - <string>20090605</string> + <string>20101007</string> <key>CFBundleSignature</key> <string>FUSE</string> <key>CFBundleVersion</key> - <string>20090605</string> + <string>20101007</string> <key>NSMainNibFile</key> <string>MainMenu</string> <key>NSPrincipalClass</key> Modified: trunk/fuse/fusepb/config.h =================================================================== --- trunk/fuse/fusepb/config.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/config.h 2010-10-08 13:06:33 UTC (rev 650) @@ -152,7 +152,7 @@ /* #undef USE_WIDGET */ /* Version number of package */ -#define VERSION "0.10.0" +#define VERSION "1.0.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Modified: trunk/fuse/fusepb/controllers/FuseController.m =================================================================== --- trunk/fuse/fusepb/controllers/FuseController.m 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/controllers/FuseController.m 2010-10-08 13:06:33 UTC (rev 650) @@ -629,7 +629,7 @@ display_refresh_all(); - ui_menu_activate( UI_MENU_ITEM_RECORDING, 1 ); + if( rzx_playback ) ui_menu_activate( UI_MENU_ITEM_RECORDING, 1 ); [[DisplayOpenGLView instance] unpause]; } @@ -2021,6 +2021,7 @@ -(int) plus3DiskWrite:(specplus3_drive_number)which { + int err; char drive, *filename = NULL; drive = which == SPECPLUS3_DRIVE_A ? 'A' : 'B'; @@ -2033,7 +2034,7 @@ if( !filename ) { [[DisplayOpenGLView instance] unpause]; return 1; } /* We will be calling this from the Emulator thread */ - specplus3_disk_write( which, filename ); + err = specplus3_disk_write( which, filename ); [self addRecentSnapshotWithString:[NSString stringWithUTF8String:filename]]; @@ -2041,11 +2042,12 @@ [[DisplayOpenGLView instance] unpause]; - return 0; + return err; } -(int) betaDiskWrite:(beta_drive_number)which { + int err; char drive, *filename = NULL; switch( which ) { @@ -2067,7 +2069,7 @@ if( !filename ) { [[DisplayOpenGLView instance] unpause]; return 1; } /* We will be calling this from the main thread with emulator paused */ - beta_disk_write( which, filename ); + err = beta_disk_write( which, filename ); [self addRecentSnapshotWithString:[NSString stringWithUTF8String:filename]]; @@ -2075,11 +2077,12 @@ [[DisplayOpenGLView instance] unpause]; - return 0; + return err; } -(int) opusDiskWrite:(opus_drive_number)which { + int err; char drive, *filename = NULL; switch( which ) { @@ -2099,7 +2102,7 @@ if( !filename ) { [[DisplayOpenGLView instance] unpause]; return 1; } /* We will be calling this from the main thread with emulator paused */ - opus_disk_write( which, filename ); + err = opus_disk_write( which, filename ); [self addRecentSnapshotWithString:[NSString stringWithUTF8String:filename]]; @@ -2107,11 +2110,12 @@ [[DisplayOpenGLView instance] unpause]; - return 0; + return err; } -(int) plusdDiskWrite:(plusd_drive_number)which { + int err; char drive, *filename = NULL; switch( which ) { @@ -2131,7 +2135,7 @@ if( !filename ) { [[DisplayOpenGLView instance] unpause]; return 1; } /* We will be calling this from the main thread with emulator paused */ - plusd_disk_write( which, filename ); + err = plusd_disk_write( which, filename ); [self addRecentSnapshotWithString:[NSString stringWithUTF8String:filename]]; @@ -2139,11 +2143,12 @@ [[DisplayOpenGLView instance] unpause]; - return 0; + return err; } -(int) if1MdrWrite:(int)which { + int err; char *filename = NULL; [[DisplayOpenGLView instance] pause]; @@ -2154,7 +2159,7 @@ if( !filename ) { [[DisplayOpenGLView instance] unpause]; return 1; } /* We will be calling this from the main thread with emulator paused */ - if1_mdr_write( which, filename ); + err = if1_mdr_write( which, filename ); [self addRecentSnapshotWithString:[NSString stringWithUTF8String:filename]]; @@ -2162,7 +2167,7 @@ [[DisplayOpenGLView instance] unpause]; - return 0; + return err; } -(ui_confirm_joystick_t) confirmJoystick:(libspectrum_joystick)type inputs:(int)theInputs @@ -2468,6 +2473,12 @@ return error; } +char * +ui_get_open_filename( const char *title ) +{ + return cocoaui_openpanel_get_filename( @"Load Snapshot", snapFileTypes ); +} + /* Function to (de)activate specific menu items */ int ui_menu_activate( ui_menu_item item, int active ) Modified: trunk/fuse/fusepb/libspectrum.h =================================================================== --- trunk/fuse/fusepb/libspectrum.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/libspectrum.h 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4120 2010-02-21 05:06:56Z fredm $ + $Id: libspectrum.h.in 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -451,6 +451,8 @@ LIBSPECTRUM_MACHINE_PENT512, LIBSPECTRUM_MACHINE_PENT1024, + LIBSPECTRUM_MACHINE_48_NTSC, + } libspectrum_machine; WIN32_DLL const char* libspectrum_machine_name( libspectrum_machine type ); Property changes on: trunk/fuse/fusepb/libspectrum.h ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 + /vendor/fuse-emulator/current/fuse/fusepb/libspectrum.h:638-649 /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 Modified: trunk/fuse/fusepb/models/Emulator.m =================================================================== --- trunk/fuse/fusepb/models/Emulator.m 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/models/Emulator.m 2010-10-08 13:06:33 UTC (rev 650) @@ -457,7 +457,7 @@ -(int) rzxStartPlayback:(const char *)filename { - return rzx_start_playback( filename ); + return rzx_start_playback( filename, 1 ); } -(void) rzxInsertSnap Modified: trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2010-10-08 13:06:33 UTC (rev 650) @@ -14,7 +14,7 @@ name="What's New In Fuse?" id="What's New In Fuse?"></a><!-- AppleSegDescription="This section describes the changes for version 0.10.0 of the Fuse emulator." --></font><br> <div class="refsect1" xml:lang="en" lang="en"> <h2><font face="Lucida Grande,Helvetica,Arial">What's new in Fuse -For Mac OS X Beta 20100???</font></h2> +For Mac OS X Beta 201010??</font></h2> <ul> <li><font face="Lucida Grande,Helvetica,Arial">Changes since last beta:</font></li> @@ -37,7 +37,20 @@ before loading a file from a double click/drag-n-drop when Fuse is already running (Fredrick Meunier).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Add x86_64 target to -Universal Binary (Fredrick Meunier).<br> +Universal Binary (Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Set track lengths +when inserting a new disk (Gergely Szasz).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Correct writing of +status and system registers to snapshots (Patrik Rak).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Add support for NTSC +ZX Spectrum 48K (Philip Kendall).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Fix autoload +snapshots (thanks, Gergely Szasz) (Fred).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Query for an initial +snapshot when opening a RZX file which doesn't have one as is common in +competition mode RZX files (Sergio Baldovi).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Don't close a disk +or mdr if a write fails (thanks, Crisis) (Gergely Szasz).<br> </font></li> </ul> </ul> Modified: trunk/fuse/fusepb/xibs/Preferences.xib =================================================================== --- trunk/fuse/fusepb/xibs/Preferences.xib 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/fusepb/xibs/Preferences.xib 2010-10-08 13:06:33 UTC (rev 650) @@ -2,38 +2,33 @@ <archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.10"> <data> <int key="IBDocument.SystemTarget">1050</int> - <string key="IBDocument.SystemVersion">10D2094</string> - <string key="IBDocument.InterfaceBuilderVersion">762</string> + <string key="IBDocument.SystemVersion">10F569</string> + <string key="IBDocument.InterfaceBuilderVersion">804</string> <string key="IBDocument.AppKitVersion">1038.29</string> - <string key="IBDocument.HIToolboxVersion">460.00</string> + <string key="IBDocument.HIToolboxVersion">461.00</string> <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string> - <string key="NS.object.0">762</string> + <string key="NS.object.0">804</string> </object> <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> <bool key="EncodedWithXMLCoder">YES</bool> - <integer value="1836"/> + <integer value="1582"/> <integer value="1347"/> + <integer value="1714"/> <integer value="1506"/> - <integer value="1714"/> - <integer value="6"/> <integer value="1488"/> + <integer value="1836"/> <integer value="1408"/> - <integer value="1582"/> <integer value="1686"/> + <integer value="6"/> </object> <object class="NSArray" key="IBDocument.PluginDependencies"> <bool key="EncodedWithXMLCoder">YES</bool> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> </object> <object class="NSMutableDictionary" key="IBDocument.Metadata"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys" id="0"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> + <string key="NS.key.0">PluginDependencyRecalculationVersion</string> + <integer value="1" key="NS.object.0"/> </object> <object class="NSMutableArray" key="IBDocument.RootObjects" id="729263285"> <bool key="EncodedWithXMLCoder">YES</bool> @@ -279,7 +274,9 @@ <reference ref="943816128"/> <reference ref="141636598"/> </object> - <reference key="NSToolbarIBSelectableItems" ref="0"/> + <object class="NSArray" key="NSToolbarIBSelectableItems" id="0"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> </object> <string key="NSWindowContentMaxSize">{1.79769e+308, 1.79769e+308}</string> <string key="NSWindowContentMinSize">{213, 107}</string> @@ -3936,15 +3933,15 @@ <object class="NSMatrix" id="145521076"> <reference key="NSNextResponder" ref="453171511"/> <int key="NSvFlags">260</int> - <string key="NSFrame">{{246, 20}, {134, 298}}</string> + <string key="NSFrame">{{246, 20}, {200, 318}}</string> <reference key="NSSuperview" ref="453171511"/> <bool key="NSEnabled">YES</bool> - <int key="NSNumRows">15</int> + <int key="NSNumRows">16</int> <int key="NSNumCols">1</int> <object class="NSMutableArray" key="NSCells"> <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSButtonCell" id="698615207"> - <int key="NSCellFlags">-2080244224</int> + <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> <string key="NSContents">Spectrum 16K</string> <reference key="NSSupport" ref="447006373"/> @@ -3977,7 +3974,7 @@ <object class="NSButtonCell" id="895598075"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Spectrum 128K</string> + <string key="NSContents">Spectrum 48K (NTSC)</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">2</int> @@ -4033,7 +4030,7 @@ <object class="NSButtonCell" id="256002398"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Spectrum +2</string> + <string key="NSContents">Spectrum 128K</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">3</int> @@ -4052,7 +4049,7 @@ <object class="NSButtonCell" id="728047119"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Spectrum +2A</string> + <string key="NSContents">Spectrum +2</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">5</int> @@ -4068,7 +4065,7 @@ <object class="NSButtonCell" id="582602011"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Spectrum +3</string> + <string key="NSContents">Spectrum +2A</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">6</int> @@ -4084,7 +4081,7 @@ <object class="NSButtonCell" id="1043922712"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Spectrum +3e</string> + <string key="NSContents">Spectrum +3</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">11</int> @@ -4140,7 +4137,7 @@ <object class="NSButtonCell" id="207861972"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Timex TC2048</string> + <string key="NSContents">Spectrum +3e</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">1</int> @@ -4194,9 +4191,9 @@ <int key="NSPeriodicInterval">75</int> </object> <object class="NSButtonCell" id="298116252"> - <int key="NSCellFlags">67239424</int> + <int key="NSCellFlags">-2080244224</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Timex TC2068</string> + <string key="NSContents">Timex TC2048</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">9</int> @@ -4252,7 +4249,7 @@ <object class="NSButtonCell" id="977182889"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Timex TS2068</string> + <string key="NSContents">Timex TC2068</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">13</int> @@ -4267,7 +4264,7 @@ <object class="NSButtonCell" id="27596798"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Pentagon 128K</string> + <string key="NSContents">Timex TS2068</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">4</int> @@ -4282,7 +4279,7 @@ <object class="NSButtonCell" id="1044447402"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Pentagon 512K</string> + <string key="NSContents">Pentagon 128K</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">14</int> @@ -4297,7 +4294,7 @@ <object class="NSButtonCell" id="849588984"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Pentagon 1024K</string> + <string key="NSContents">Pentagon 512K</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">15</int> @@ -4312,7 +4309,7 @@ <object class="NSButtonCell" id="348598096"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Scorpion ZS 256</string> + <string key="NSContents">Pentagon 1024K</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">10</int> @@ -4327,7 +4324,7 @@ <object class="NSButtonCell" id="287925355"> <int key="NSCellFlags">67239424</int> <int key="NSCellFlags2">0</int> - <string key="NSContents">Spectrum SE</string> + <string key="NSContents">Scorpion ZS 256</string> <reference key="NSSupport" ref="447006373"/> <reference key="NSControlView" ref="145521076"/> <int key="NSTag">12</int> @@ -4339,10 +4336,22 @@ <int key="NSPeriodicDelay">400</int> <int key="NSPeriodicInterval">75</int> </object> + <object class="NSButtonCell" id="545389380"> + <int key="NSCellFlags">67239424</int> + <int key="NSCellFlags2">0</int> + <string key="NSContents">Spectrum SE</string> + <reference key="NSSupport" ref="447006373"/> + <reference key="NSControlView" ref="145521076"/> + <int key="NSButtonFlags">1211912703</int> + <int key="NSButtonFlags2">0</int> + <reference key="NSAlternateImage" ref="32434582"/> + <int key="NSPeriodicDelay">400</int> + <int key="NSPeriodicInterval">75</int> + </object> </object> - <string key="NSCellSize">{134, 18}</string> + <string key="NSCellSize">{200, 18}</string> <string key="NSIntercellSpacing">{4, 2}</string> - <int key="NSMatrixFlags">1143472128</int> + <int key="NSMatrixFlags">1151868928</int> <string key="NSCellClass">NSActionCell</string> <object class="NSButtonCell" key="NSProtoCell" id="947390470"> <int key="NSCellFlags">67239424</int> @@ -4461,13 +4470,14 @@ <int key="NSPeriodicDelay">400</int> <int key="NSPeriodicInterval">75</int> </object> - <reference key="NSSelectedCell" ref="698615207"/> + <int key="NSSelectedRow">8</int> + <reference key="NSSelectedCell" ref="298116252"/> <reference key="NSBackgroundColor" ref="519317542"/> <reference key="NSCellBackgroundColor" ref="70288484"/> <reference key="NSFont" ref="447006373"/> </object> </object> - <string key="NSFrameSize">{627, 338}</string> + <string key="NSFrameSize">{627, 358}</string> <reference key="NSSuperview"/> <string key="NSClassName">NSView</string> </object> @@ -8667,6 +8677,7 @@ <reference ref="895598075"/> <reference ref="850511965"/> <reference ref="698615207"/> + <reference ref="545389380"/> </object> <reference key="parent" ref="453171511"/> </object> @@ -9117,6 +9128,11 @@ <reference key="object" ref="766217337"/> <reference key="parent" ref="833825163"/> </object> + <object class="IBObjectRecord"> + <int key="objectID">1882</int> + <reference key="object" ref="545389380"/> + <reference key="parent" ref="145521076"/> + </object> </object> </object> <object class="NSMutableDictionary" key="flattenedProperties"> @@ -9942,7 +9958,7 @@ <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> - <string>{{31, 211}, {627, 338}}</string> + <string>{{31, 191}, {627, 358}}</string> <string>com.apple.InterfaceBuilder.CocoaPlugin</string> <string>{628, 654}</string> <string>{{217, 442}, {480, 272}}</string> @@ -10102,7 +10118,7 @@ </object> </object> <nil key="sourceID"/> - <int key="maxID">1881</int> + <int key="maxID">1882</int> </object> <object class="IBClassDescriber" key="IBDocument.Classes"> <object class="NSMutableArray" key="referencedPartialClassDescriptions"> @@ -10153,6 +10169,60 @@ <string>id</string> </object> </object> + <object class="NSMutableDictionary" key="actionInfosByName"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>chooseFile:</string> + <string>chooseROMFile:</string> + <string>externalSoundTypeClicked:</string> + <string>massStorageTypeClicked:</string> + <string>resetROMFile:</string> + <string>resetUserDefaults:</string> + <string>selectPrefPanel:</string> + <string>setup:</string> + <string>showWindow:</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBActionInfo"> + <string key="name">chooseFile:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">chooseROMFile:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">externalSoundTypeClicked:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">massStorageTypeClicked:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">resetROMFile:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">resetUserDefaults:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">selectPrefPanel:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">setup:</string> + <string key="candidateClassName">id</string> + </object> + <object class="IBActionInfo"> + <string key="name">showWindow:</string> + <string key="candidateClassName">id</string> + </object> + </object> + </object> <object class="NSMutableDictionary" key="outlets"> <bool key="EncodedWithXMLCoder">YES</bool> <object class="NSArray" key="dict.sortedKeys"> @@ -10196,6 +10266,100 @@ <string>NSToolbar</string> </object> </object> + <object class="NSMutableDictionary" key="toOneOutletInfosByName"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>externalSoundType</string> + <string>filterPrefsView</string> + <string>generalPrefsView</string> + <string>joysticksPrefsView</string> + <string>machinePrefsView</string> + <string>machineRomsController</string> + <string>massStorageType</string> + <string>peripheralsPrefsView</string> + <string>rom0Filename</string> + <string>rom1Filename</string> + <string>rom2Filename</string> + <string>rom3Filename</string> + <string>romPrefsView</string> + <string>rzxPrefsView</string> + <string>soundPrefsView</string> + <string>tabView</string> + <string>toolbar</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBToOneOutletInfo"> + <string key="name">externalSoundType</string> + <string key="candidateClassName">NSMatrix</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">filterPrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">generalPrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">joysticksPrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">machinePrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">machineRomsController</string> + <string key="candidateClassName">NSArrayController</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">massStorageType</string> + <string key="candidateClassName">NSMatrix</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">peripheralsPrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">rom0Filename</string> + <string key="candidateClassName">NSFormCell</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">rom1Filename</string> + <string key="candidateClassName">NSFormCell</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">rom2Filename</string> + <string key="candidateClassName">NSFormCell</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">rom3Filename</string> + <string key="candidateClassName">NSFormCell</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">romPrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">rzxPrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">soundPrefsView</string> + <string key="candidateClassName">NSView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">tabView</string> + <string key="candidateClassName">NSTabView</string> + </object> + <object class="IBToOneOutletInfo"> + <string key="name">toolbar</string> + <string key="candidateClassName">NSToolbar</string> + </object> + </object> + </object> <object class="IBClassDescriptionSource" key="sourceIdentifier"> <string key="majorKey">IBProjectSource</string> <string key="minorKey">controllers/PreferencesController.h</string> @@ -10845,6 +11009,13 @@ <string key="NS.key.0">showWindow:</string> <string key="NS.object.0">id</string> </object> + <object class="NSMutableDictionary" key="actionInfosByName"> + <string key="NS.key.0">showWindow:</string> + <object class="IBActionInfo" key="NS.object.0"> + <string key="name">showWindow:</string> + <string key="candidateClassName">id</string> + </object> + </object> <object class="IBClassDescriptionSource" key="sourceIdentifier"> <string key="majorKey">IBFrameworkSource</string> <string key="minorKey">AppKit.framework/Headers/NSWindowController.h</string> Modified: trunk/fuse/hacking/ChangeLog =================================================================== --- trunk/fuse/hacking/ChangeLog 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/hacking/ChangeLog 2010-10-08 13:06:33 UTC (rev 650) @@ -3299,3 +3299,55 @@ changes from 0.10.0.2 onto trunk (Fred). 20100521 ChangeLog: remove duplicate entry (Fred). 20100522 sound.c: allow a little more treble in the TV Speaker mode (Fred). +20100527 sound/coreaudiosound.c: add some casts in output statements to avoid + annoying warnings about format mismatches (Fred). +20100530 ChangeLog: remove another duplicate entry (Fred). +20100627 ui/gtk/gtkdisplay.c: ensure an appropriate scaler is selected when + the Fuse window is resized by the user. +20100719 disk/disk.c: set track lengths when inserting a new disk (fixes bug + #3031299) (Gergely Szasz). +20100819 disk/beta.c: correct writing of status and system regeisters to + snapshots (Patrik Rak). +20100825 machine.c,machines/{Makefile.am,machines.h},tape.c: reintegrate + NTSC Spectrum branch. +20100831 lib/[un]compressed/{disk_plus3.szx,tape_128.szx,tape_16.szx, + tape_2048.szx,tape_2068.szx,tape_48.szx,tape_pentagon.szx, + tape_plus2.szx,tape_plus2a.szx,tape_plus3.szx,tape_plus3e.szx, + tape_scorpion.szx,tape_se.szx,tape_ts2068.szx}: swap A and F and A' + and F' registers in autoload snapshots which were written when + libspectrum still suffered from bug #2857419 (fixes bug #3040262) + (thanks, Gergely Szasz) (Fred). +20100831 machines/spec48_ntsc.c: add some more peripherals and add display + setup code (Fred). +20100901 lib/{[un]compressed/tape_48_ntsc.szx,Makefile.am}: add autoload + snapshot for NTSC Spectrum (Fred). +20100905 tape.c: remove obsolete reference to munmap (Fred). +20100909 settings.pl: remove the 80 character limit in ini file settings + names+values and change 256 char path lengths to MAX_PATH (patch + #3013768) (Gergely Szasz). +20100912 menu.c,rzx.[ch]: query for an initial snapshot when opening a rzx file + which doesn't have one as is common in competition mode rzx files + (patch #3054536) (Sergio Baldovi). +20100912 configure.in,windres.rc: enhancements to Windows version encoding + (patch #3061430) (Sergio Baldovi). +20100913 fuse.c,menu.[ch],rzx.[ch],utils.[ch]: extend RZX playback handling of + files without initial embedded snapshots to cover File->Open, the + command line and some miscellaneous RZX playback initialisation bugs + (more from patch #3054536) (Sergio Baldovi). +20100919 ui/win32/installer/fuse.nsi: windows installer improvements; correct + uninstall registry key, parameterise installation directory path, add + version information fields, optionally register file types, make start + menu shortcuts optional and add desktop shortcut (patch #3069264) + (Sergio Baldovi). +20100930 ChangeLog,fuse.c,man/fuse.1,README: first updates for a "1.0" release. +20101002 lib/{compressed,uncompressed}/*.szx: update libspectrum signature in + each file so we know they don't have the A-F swap bug. +20101003 README: small update to mention WoS forums. +20101006 configure.in: update header check for XShm.h (patch #3081497) (Gergely + Szasz). +20101006 ui/gtk/{gtkkeyboard.c,gtkui.c,statusbar.c,stock.c}: use F1 as shortcut to + open menus, set window dialogs as transient for the main window and set a + fixed width for the emulation speed display (patch #3081729) (Sergio + Baldovi). +20101007 ui.c: don't close a disk or mdr if a write fails (patch #3058156) (thanks, + Crisis) (Gergely Szasz). Modified: trunk/fuse/ide/divide.c =================================================================== --- trunk/fuse/ide/divide.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/divide.c 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* divide.c: DivIDE interface routines Copyright (c) 2005-2008 Matthew Westcott, Philip Kendall - $Id: divide.c 4099 2009-10-22 10:59:02Z fredm $ + $Id: divide.c 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/divide.h =================================================================== --- trunk/fuse/ide/divide.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/divide.h 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* divide.h: DivIDE interface routines Copyright (c) 2005 Matthew Westcott - $Id: divide.h 4060 2009-07-30 13:21:38Z fredm $ + $Id: divide.h 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/ide.c =================================================================== --- trunk/fuse/ide/ide.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/ide.c 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* ide.c: Generic routines shared between the various IDE devices Copyright (c) 2005 Philip Kendall - $Id: ide.c 4060 2009-07-30 13:21:38Z fredm $ + $Id: ide.c 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/ide.h =================================================================== --- trunk/fuse/ide/ide.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/ide.h 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* ide.h: Generic routines shared between the various IDE devices Copyright (c) 2005 Philip Kendall - $Id: ide.h 4060 2009-07-30 13:21:38Z fredm $ + $Id: ide.h 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/simpleide.c =================================================================== --- trunk/fuse/ide/simpleide.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/simpleide.c 2010-10-08 13:06:33 UTC (rev 650) @@ -3,7 +3,7 @@ 2004 Philip Kendall, 2008 Fredrick Meunier - $Id: simpleide.c 4060 2009-07-30 13:21:38Z fredm $ + $Id: simpleide.c 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/simpleide.h =================================================================== --- trunk/fuse/ide/simpleide.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/simpleide.h 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* simpleide.h: Simple 8-bit IDE interface routines Copyright (c) 2003-2004 Garry Lancaster - $Id: simpleide.h 4060 2009-07-30 13:21:38Z fredm $ + $Id: simpleide.h 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxatasp.c =================================================================== --- trunk/fuse/ide/zxatasp.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/zxatasp.c 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* zxatasp.c: ZXATASP interface routines Copyright (c) 2003-2008 Garry Lancaster and Philip Kendall - $Id: zxatasp.c 4099 2009-10-22 10:59:02Z fredm $ + $Id: zxatasp.c 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxatasp.h =================================================================== --- trunk/fuse/ide/zxatasp.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/zxatasp.h 2010-10-08 13:06:33 UTC (rev 650) @@ -2,7 +2,7 @@ Copyright (c) 2003-2004 Garry Lancaster, 2004 Philip Kendall - $Id: zxatasp.h 4060 2009-07-30 13:21:38Z fredm $ + $Id: zxatasp.h 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxcf.c =================================================================== --- trunk/fuse/ide/zxcf.c 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/zxcf.c 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ /* zxcf.c: ZXCF interface routines Copyright (c) 2003-2008 Garry Lancaster and Philip Kendall - $Id: zxcf.c 4099 2009-10-22 10:59:02Z fredm $ + $Id: zxcf.c 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxcf.h =================================================================== --- trunk/fuse/ide/zxcf.h 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/ide/zxcf.h 2010-10-08 13:06:33 UTC (rev 650) @@ -2,7 +2,7 @@ Copyright (c) 2003-2004 Garry Lancaster, 2004 Philip Kendall - $Id: zxcf.h 4060 2009-07-30 13:21:38Z fredm $ + $Id: zxcf.h 4148 2010-08-25 21:20:50Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/lib/Makefile.am =================================================================== --- trunk/fuse/lib/Makefile.am 2010-10-07 11:32:42 UTC (rev 649) +++ trunk/fuse/lib/Makefile.am 2010-10-08 13:06:33 UTC (rev 650) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 1999-2004 Philip Kendall -## $Id: Makefile.am 3150 2007-09-05 14:05:00Z pak21 $ +## $Id: Makefile.am 4154 2010-08-31 14:14:34Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -33,6 +33,7 @@ @AUTOLOAD_SNAPS@/tape_2048.szx \ @AUTOLOAD_SNAPS@/tape_2068.szx \ @AUTOLOAD_SNAPS@/tape_48.szx \ + @AUTOLOAD_SNAPS@/tape_48_ntsc.szx \ @AUTOLOAD_SNAPS@/tape_plus2.szx \ @AUTOLOAD_SNAPS@/tape_plus2a.szx \ @AUTOLOAD_SNAPS@/tape_plus3.szx \ @@ -51,6 +52,7 @@ compressed/tape_2048.szx \ compressed/tape_2068.szx \ compressed/tape_48.szx \ + compressed/tape_48_ntsc.szx \ compressed/tape_plus2.szx \ compressed/tape_plus2a.szx \ compressed/tape_plus3.szx \ @@ -65,6 +67,7 @@ uncompressed/tape_2048.szx \ uncompressed/tape_2068.szx \ uncompressed/tape_48.szx \ + uncompressed/tape_48_ntsc.szx \ uncompressed/tape_plus2.szx \ uncompressed/tape_plus2a.szx \ uncompressed/tape_plus3.szx \ Modified: trunk/fuse/lib/compressed/disk_plus3.szx =================================================================== (Binary files differ) Modified: trunk/fuse/lib/compressed/tape_128.szx =================================================================== (Binary files differ) Modified: trunk/fuse/lib/compressed/tape_16.szx =================================================================== (Binary files differ) Modified: trunk/fuse/lib/compressed/tape_2048.szx =================================================================== (Binary files differ) Modified: trunk/fuse/lib/compressed/tape_2068.szx =================================================================== (Binary files differ) Modified: trunk/fuse/lib/compressed/tape_48.szx =================================================================== (Binary files dif... [truncated message content] |
From: <fr...@us...> - 2010-12-08 11:29:53
|
Revision: 660 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=660&view=rev Author: fredm Date: 2010-12-08 11:29:46 +0000 (Wed, 08 Dec 2010) Log Message: ----------- Merge up to vendor revision 4209. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=4209&view=rev Modified Paths: -------------- trunk/fuse/fusepb/resources/Fuse Help/html/about.html trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html trunk/fuse/fusepb/resources/Fuse Help/html/machine.html trunk/fuse/fusepb/resources/Fuse Help/html/opus.html trunk/fuse/fusepb/resources/Fuse Help/html/plusd.html trunk/fuse/fusepb/resources/Fuse Help/html/trdos.html trunk/fuse/hacking/ChangeLog trunk/fuse/man/fuse.1 trunk/fuse/memory.c trunk/fuse/ui/fb/fbdisplay.c trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/warajevo_read.c Property Changed: ---------------- trunk/fuse/ trunk/fuse/fusepb/libspectrum.h trunk/libspectrum/libspectrum/ Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-655 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-659 Property changes on: trunk/fuse/fusepb/libspectrum.h ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/current/fuse/fusepb/libspectrum.h:638-655 /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 + /vendor/fuse-emulator/current/fuse/fusepb/libspectrum.h:638-659 /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 Modified: trunk/fuse/fusepb/resources/Fuse Help/html/about.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/about.html 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/fusepb/resources/Fuse Help/html/about.html 2010-12-08 11:29:46 UTC (rev 660) @@ -1,7 +1,11 @@ -<!-- AppleSegStart="About Fuse" --> +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html> <head> + +<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"><!-- AppleSegStart="About Fuse" --> <title>About Fuse</title> </head> +<body> <div class="refentry" xml:lang="en" lang="en"> <font face="Lucida Grande,Helvetica,Arial"><a name="About Fuse"></a><!-- AppleSegDescription="This section describes the Fuse emulator." --></font> <div class="refsect1" xml:lang="en" lang="en"> @@ -18,17 +22,18 @@ snapshots and TZX and TAP tape files is supported. The SLT extension to the Z80 format is -partly supported (enough for multi-load games); however, loading of -the old DAT-file variant is not. DSK disk images are supported when -emulating a +3, TRD and SCL disk images are supported when -emulating a Pentagon or Scorpion ZS 256 and MGT and IMG disk images are -supported when emulating the +D interface. DCK cartridge images are -supported when emulating a Timex TC2068 or TS2068. Interface II ROM -cartriges are also -supported.</font></p> +partly supported (enough for multi-load games); however, loading of the +old DAT-file variant is not. DSK, UDI, FDI, TR0, SDF, MGT, IMG, SAD, +TRD, SCL and OPD disk images are supported when a disk interface is +being emulated, including the integrated disk drives on +3, Pentagon or +Scorpion machines as well as the +D, Opus Discovery and Beta 128 +interfaces. DCK cartridge images are supported when emulating a Timex +2068 variant. Interface II ROM cartridges are also supported.</font></p> <p><font face="Lucida Grande,Helvetica,Arial">Finally, there is also support for reading and writing the RZX input recording format.</font></p> </div> <!-- AppleSegEnd --> +</body> +</html> Modified: trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2010-12-08 11:29:46 UTC (rev 660) @@ -14,7 +14,7 @@ name="What's New In Fuse?" id="What's New In Fuse?"></a><!-- AppleSegDescription="This section describes the changes for version 0.10.0 of the Fuse emulator." --></font><br> <div class="refsect1" xml:lang="en" lang="en"> <h2><font face="Lucida Grande,Helvetica,Arial">What's new in Fuse -For Mac OS X Beta 201010??</font></h2> +For Mac OS X Beta 201012??</font></h2> <ul> <li><font face="Lucida Grande,Helvetica,Arial">Changes since last beta:</font></li> @@ -45,12 +45,18 @@ <li><font face="Lucida Grande,Helvetica,Arial">Add support for NTSC ZX Spectrum 48K (Philip Kendall).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Fix autoload -snapshots (thanks, Gergely Szasz) (Fred).</font></li> +snapshots (thanks, Gergely Szasz) (</font><font + face="Lucida Grande,Helvetica,Arial">Fredrick +Meunier</font><font face="Lucida Grande,Helvetica,Arial">).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Query for an initial snapshot when opening a RZX file which doesn't have one as is common in competition mode RZX files (Sergio Baldovi).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Don't close a disk -or mdr if a write fails (thanks, Crisis) (Gergely Szasz).<br> +or mdr if a write fails (thanks, Crisis) (Gergely Szasz).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">The Allow Writes to +ROM preference shouldn't affect the 16K machine "empty" page (thanks, +Andrew Owen) (</font><font face="Lucida Grande,Helvetica,Arial">Fredrick +Meunier</font><font face="Lucida Grande,Helvetica,Arial">).<br> </font></li> </ul> </ul> Modified: trunk/fuse/fusepb/resources/Fuse Help/html/machine.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/machine.html 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/fusepb/resources/Fuse Help/html/machine.html 2010-12-08 11:29:46 UTC (rev 660) @@ -19,7 +19,10 @@ more technical information -can be found at +can +be +found +at <a href="http://www.worldofspectrum.org/faq/reference/reference.htm">http://www.worldofspectrum.org/faq/reference/reference.htm</a>.</font></p> <p style="margin-left: 40px;"> <span class="emphasis"><font face="Lucida Grande,Helvetica,Arial"><em>Spectrum @@ -30,7 +33,15 @@ released by Sinclair in 1982 with 16 or 48K of RAM respectively.</font></p> <p style="margin-left: 40px;"> -<span class="emphasis"><font face="Lucida Grande,Helvetica,Arial"><em>Spectrum +<span class="emphasis"><font face="Lucida Grande,Helvetica,Arial"><font + face="Lucida Grande,Helvetica,Arial"><em>Spectrum 48K (NTSC)</em></font></font></span> +<font face="Lucida Grande,Helvetica,Arial"><font + face="Lucida Grande,Helvetica,Arial">The NTSC 48K machine released in +limited numbers in +parts of South America.</font></font> +</p> +<p style="margin-left: 40px;"><span class="emphasis"><font + face="Lucida Grande,Helvetica,Arial"><em>Spectrum 128K</em></font></span> <font face="Lucida Grande,Helvetica,Arial">The 128K machine as released by Sinclair in 1985 (Spain) or 1986 (UK).</font></p> @@ -91,7 +102,10 @@ of the Pentagon -Russian Spectrum clones which incorporate more +Russian +Spectrum +clones +which incorporate more memory and the "Mr Gluk Reset Service" ROM offering a more powerful firmware.</font></p> <p style="margin-left: 40px;"><span class="emphasis"><font @@ -102,13 +116,19 @@ of the Spectrum. -Some details can be found at +Some +details +can +be found at <a href="http://www.worldofspectrum.org/rusfaq/index.html">http://www.worldofspectrum.org/rusfaq/index.html</a>, like all the Russian -clones they have built in 3.5" disk drives, +clones +they +have +built in 3.5" disk drives, accessed via the Betadisk interface and TR-DOS (the Technology Research Disk Operating System). The most important distinction from the Pentagon Modified: trunk/fuse/fusepb/resources/Fuse Help/html/opus.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/opus.html 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/fusepb/resources/Fuse Help/html/opus.html 2010-12-08 11:29:46 UTC (rev 660) @@ -1,6 +1,8 @@ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> + +<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"> <!-- AppleSegStart="Opus Discovery Emulation" --> <title>Opus Discovery Emulation</title> </head> @@ -14,9 +16,11 @@ the Opus Discovery interface with the optional 2k RAM expansion and a second 40 track single sided disk drive.<br> </font></p> -<p><font face="Lucida Grande,Helvetica,Arial">Fuse supports .OPD and -.OPU -images in its Opus Discovery emulation. The Opus Discoveries' printer +<p><font face="Lucida Grande,Helvetica,Arial">See the <font + face="Lucida Grande,Helvetica,Arial"><span class="emphasis"><em>DISK +FILE FORMATS</em></span></font> +section for more details on supported disk file formats.</font><font + face="Lucida Grande,Helvetica,Arial"> The Opus Discoveries' printer port is also emulated for output only. (See the </font><font face="Lucida Grande,Helvetica,Arial"><span class="emphasis"><em>PRINTER EMULATION</em></span></font><font face="Lucida Grande,Helvetica,Arial"> Modified: trunk/fuse/fusepb/resources/Fuse Help/html/plusd.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/plusd.html 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/fusepb/resources/Fuse Help/html/plusd.html 2010-12-08 11:29:46 UTC (rev 660) @@ -1,14 +1,23 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html> <head> -<!-- AppleSegStart="+D Emulation" --> + +<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"><!-- AppleSegStart="+D Emulation" --> <title>+D Emulation</title> </head> +<body> <font face="Lucida Grande,Helvetica,Arial"><a name="+D EMULATION"></a><!-- AppleSegDescription="This section describes the +D interface emulation in Fuse." --></font> <div class="refsect1" xml:lang="en" lang="en"> <h2><font face="Lucida Grande,Helvetica,Arial">+D Emulation</font></h2> </div> <p> -<font face="Lucida Grande,Helvetica,Arial">Fuse supports .MGT and .IMG -images in its +D emulation. The +D's printer port is emulated. (See the +<font face="Lucida Grande,Helvetica,Arial">Fuse supports emulating the ++D disk and printer interface. See the <font + face="Lucida Grande,Helvetica,Arial"><span class="emphasis"><em>DISK +FILE FORMATS</em></span></font> +section for more details on supported disk file formats.</font><font + face="Lucida Grande,Helvetica,Arial"> The +D's printer port is +emulated. (See the </font><font face="Lucida Grande,Helvetica,Arial"><span class="emphasis"><em>PRINTER EMULATION</em></span></font><font face="Lucida Grande,Helvetica,Arial"> section for more details.) The +D may only be used with 48K, 128K and @@ -30,3 +39,5 @@ screenshots to be printed (in monochrome) if printer emulation is enabled.</font></p> <!-- AppleSegEnd --> +</body> +</html> Modified: trunk/fuse/fusepb/resources/Fuse Help/html/trdos.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/trdos.html 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/fusepb/resources/Fuse Help/html/trdos.html 2010-12-08 11:29:46 UTC (rev 660) @@ -1,6 +1,8 @@ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> + <meta http-equiv="content-type" + content="text/html; charset=ISO-8859-1"> <!-- AppleSegStart="Beta 128 Emulation" --> <title>Beta 128 Emulation</title> </head> @@ -10,15 +12,22 @@ <h2><font face="Lucida Grande,Helvetica,Arial">Beta 128 Emulation</font></h2> </div> <p> -<font face="Lucida Grande,Helvetica,Arial">Fuse supports .SCL and .TRD -images in its Pentagon and Scorpion emulation, and also under 128K and +<font face="Lucida Grande,Helvetica,Arial">Fuse supports Betadisk +emulation in its Pentagon and Scorpion emulation, and also under 128K +and +2 (but not +2A) emulation if the </font><font face="Lucida Grande,Helvetica,Arial"><span class="emphasis"><em>Beta 128 interface option</em></span></font><font face="Lucida Grande,Helvetica,Arial"> from the </font><font face="Lucida Grande,Helvetica,Arial"><span class="emphasis"><em>Preferences, Peripherals...</em></span></font><font - face="Lucida Grande,Helvetica,Arial"> dialog is enabled.</font></p> + face="Lucida Grande,Helvetica,Arial"> dialog is enabled.<br> +</font></p> +<p><font face="Lucida Grande,Helvetica,Arial">See the <font + face="Lucida Grande,Helvetica,Arial"><span class="emphasis"><em>DISK +FILE FORMATS</em></span></font> +section for more details on supported disk file formats.<br> +</font></p> <!-- AppleSegEnd --> </body> </html> Modified: trunk/fuse/hacking/ChangeLog =================================================================== --- trunk/fuse/hacking/ChangeLog 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/hacking/ChangeLog 2010-12-08 11:29:46 UTC (rev 660) @@ -3361,3 +3361,12 @@ 20101011 ui/gtk/gtkdisplay.c: resize window when machine selection switches between Timex and non-Timex modes (fixes bug #3084862) (thanks, Phil) (Fred). +20101025 memory.c: writable_roms preference shouldn't affect the 16K machine + "empty" page (thanks, Andrew Owen) (Fred). +20101029 man/fuse.1: some updates to bring things a bit more up to date (Fred). +20101102 man/fuse.1: remove reference to fixed issue in RZX playback command + line ordering (patch #3100707) (Sergio Baldovi). +20101129 ui/fb/fbdisplay.c: only call fbdisplay_end() when display is + initialised (fixes bug #3119382) (rkd77). +20101203 ui/fb/fbdisplay.c: improve fb colour handling and initialise scaler + system (fixes bugs #3124787 and #3124788) (rkd77). Modified: trunk/fuse/man/fuse.1 =================================================================== --- trunk/fuse/man/fuse.1 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/man/fuse.1 2010-12-08 11:29:46 UTC (rev 660) @@ -54,10 +54,12 @@ virtual-tape files. Saving to SZX, Z80 and SNA snapshots and TZX and TAP tape files is supported. The SLT extension to the Z80 format is partly supported (enough for multi-load games); however, loading of -the old DAT-file variant is not. DSK disk images are supported when -emulating a +3, TRD and SCL disk images are supported when emulating -a Pentagon or Scorpion and DCK cartridge images are supported when -emulating a Timex 2068 variant. Interface II ROM cartridges are also +the old DAT-file variant is not. DSK, UDI, FDI, TR0, SDF, MGT, IMG, +SAD, TRD, SCL and OPD disk images are supported when a disk interface +is being emulated, including the integrated disk drives on +3, +Pentagon or Scorpion machines as well as the +D, Opus Discovery and +Beta 128 interfaces. DCK cartridge images are supported when +emulating a Timex 2068 variant. Interface II ROM cartridges are also supported. .PP Finally, there is also support for reading and writing the RZX input recording @@ -435,6 +437,7 @@ a 48K Spectrum. The available options are .IR 16 , .IR 48 , +.IR 48_ntsc, .IR 128 , .IR plus2 , .IR plus2a , @@ -445,8 +448,9 @@ .IR pentagon , .IR pentagon512 , .IR pentagon1024 , +.IR scorpion and -.IR scorpion . +.IR se . .RE .PP .I "\-\-melodik" @@ -1669,9 +1673,9 @@ .RE .PP .I "AY volume" +.RS +Sets the relative volume of the AY-3-8912 chip from a range of 0-100%. .RE -Sets the relative volume of the AY-3-8912 chip from a range of 0-100%. -.RS .PP .I "Beeper volume" .RS @@ -2104,6 +2108,12 @@ of RAM respectively. .RE .PP +.I "Spectrum 48K (NTSC)" +.RS +The NTSC 48K machine released in limited numbers in parts of South +America. +.RE +.PP .I "Spectrum 128K" .RS The 128K machine as released by Sinclair in 1985 (Spain) or 1986 (UK). @@ -3494,13 +3504,16 @@ .\" .SH BETA 128 EMULATION .PP -Fuse supports .SCL and .TRD images in its Pentagon and Scorpion +Fuse supports Betadisk emulation in its Pentagon and Scorpion emulation, and also under 48K, TC2048, 128K and +2 (but not +2A) emulation if the .I Beta 128 interface option from the .I "Options, Peripherals..." dialog is enabled. +See the +.B "DISK FILE FORMATS" +section for mode details on supported disk file formats. .\" .\"------------------------------------------------------------------ .\" @@ -3508,7 +3521,9 @@ .PP By default, Fuse emulates the Opus Discovery interface with the optional 2k RAM expansion and a second 40 track single sided disk drive. -Fuse supports .OPD and .OPU images in its Opus Discovery emulation. The Opus +See the +.B "DISK FILE FORMATS" +section for mode details on supported disk file formats. The Opus Discovery's printer port is also emulated for output only. (See the .B "PRINTER EMULATION" section for more details.) The Opus Discovery may only be @@ -3519,7 +3534,9 @@ .\" .SH +D EMULATION .PP -Fuse supports .MGT and .IMG images in its +D emulation. The +D's +Fuse supports emulating the +D disk and printer interface. See the +.B "DISK FILE FORMATS" +section for mode details on supported disk file formats. The +D's printer port is emulated. (See the .B "PRINTER EMULATION" section for more details.) The +D may only be @@ -3674,13 +3691,6 @@ Selecting a startup filter doesn't work properly with user interfaces other than SDL and GTK+. .PP -Attempting to replay an RZX file without an embedded snapshot from the -command-line doesn't work if you do `./fuse -.IR "rzxfile snapshot" '. -`./fuse -.IR "snapshot rzxfile" ' -does work though, so use that instead. -.PP Changing virtual consoles when using SVGAlib for joystick support causes Fuse to exit. If this is a problem, compile Fuse with the .RI ` \-\-disable\-ui\-joystick ' Modified: trunk/fuse/memory.c =================================================================== --- trunk/fuse/memory.c 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/memory.c 2010-12-08 11:29:46 UTC (rev 660) @@ -1,7 +1,7 @@ /* memory.c: Routines for accessing memory Copyright (c) 1999-2004 Philip Kendall - $Id: memory.c 4099 2009-10-22 10:59:02Z fredm $ + $Id: memory.c 4186 2010-10-25 10:29:45Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -276,7 +276,9 @@ if( opus_active && address >= 0x2800 && address < 0x3800 ) { opus_write( address, b ); - } else if( mapping->writable || settings_current.writable_roms ) { + } else if( mapping->writable || + (mapping->bank != MEMORY_BANK_NONE && + settings_current.writable_roms) ) { libspectrum_word offset = address & 0x1fff; libspectrum_byte *memory = mapping->page; Modified: trunk/fuse/ui/fb/fbdisplay.c =================================================================== --- trunk/fuse/ui/fb/fbdisplay.c 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/fuse/ui/fb/fbdisplay.c 2010-12-08 11:29:46 UTC (rev 660) @@ -2,7 +2,7 @@ Copyright (c) 2000-2003 Philip Kendall, Matan Ziv-Av, Darren Salt, Witold Filipczyk - $Id: fbdisplay.c 3992 2009-03-29 11:28:17Z fredm $ + $Id: fbdisplay.c 4205 2010-12-03 10:39:39Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -27,6 +27,7 @@ #include <config.h> #include <errno.h> +#include <math.h> #include <stdio.h> #include <unistd.h> #include <stdlib.h> @@ -66,7 +67,7 @@ /* Are we in a Timex display mode? */ static int hires; -static int register_scalers( void ); +static void register_scalers( void ); /* probably 0rrrrrgggggbbbbb */ static short rgbs[16], greys[16]; @@ -77,6 +78,7 @@ static struct fb_fix_screeninfo fixed; static struct fb_var_screeninfo orig_display, display; static int got_orig_display = 0; +static int changed_palette = 0; unsigned long fb_resolution; /* == xres << 16 | yres */ #define FB_RES(X,Y) ((X) << 16 | (Y)) @@ -127,20 +129,20 @@ { 320, 240, 80000, 40, 28, 9, 2, 20, 3, 0, 1 }, ** 320x240-60 60.310 M tall { 320, 240, 55555, 52, 16, 12, 0, 28, 2, 0, 1 }, ** 320x240-85 85.177 M */ + +static unsigned short red16[256], green16[256], blue16[256], transp16[256]; +static struct fb_cmap orig_cmap = {0, 256, red16, green16, blue16, transp16}; + static int fb_set_mode( void ); int uidisplay_init( int width, int height ) { - int error; - hires = ( width == 640 ? 1 : 0 ); - scaler_register_clear(); - image_width = width; image_height = height; image_scale = width / DISPLAY_ASPECT_WIDTH; - error = register_scalers(); if( error ) return error; + register_scalers(); display_ui_initialised = 1; @@ -149,20 +151,40 @@ return 0; } -static int +static void register_scalers( void ) { - return 0; + scaler_register_clear(); + scaler_select_bitformat( 565 ); /* 16bit always */ + scaler_register( SCALER_NORMAL ); } +static void +linear_palette(struct fb_cmap *p_cmap) +{ + int i; + int rcols = 1 << display.red.length; + int gcols = 1 << display.green.length; + int bcols = 1 << display.blue.length; + + for (i = 0; i < rcols; i++) + p_cmap->red[i] = (65535 / (rcols - 1)) * i; + + for (i = 0; i < gcols; i++) + p_cmap->green[i] = (65535 / (gcols - 1)) * i; + + for (i = 0; i < bcols; i++) + p_cmap->blue[i] = (65535 / (bcols - 1)) * i; +} + int fbdisplay_init(void) { int i; const char *dev; - static libspectrum_word paldata[20] = { 0, 0xbbbb, 0xffff }; - static const struct fb_cmap fb_cmap = { - 0, 20, paldata, paldata, paldata, NULL + static libspectrum_word r16[256], g16[256], b16[256]; + static struct fb_cmap fb_cmap = { + 0, 256, r16, g16, b16, NULL }; dev = getenv( DEVICE_VARIABLE ); @@ -187,32 +209,41 @@ fputs( "\x1B[H\x1B[J", stdout ); /* clear tty */ memset( gm, 0, display.xres_virtual * display.yres_virtual * 2 ); - for( i = 0; i < 16; i++ ) { - int v = ( i & 8 ) ? 2 : 1; - rgbs[i] = ( ( i & 1 ) ? v << display.blue.offset : 0 ) - | ( ( i & 2 ) ? v << display.red.offset : 0 ) - | ( ( i & 4 ) ? v << display.green.offset : 0 ); - v = ( i & 8 ) ? 15 : 11; - paldata[i+4] = ( ( (i & 1) ? v * 7471 : 0) /* 0.114 */ - + ( (i & 2) ? v * 19595 : 0) /* 0.299 */ - + ( (i & 4) ? v * 38469 : 0) /* 0.587 */ - ) / 15; - greys[i] = (i + 4) << display.blue.offset - | (i + 4) << display.red.offset - | (i + 4) << display.green.offset; - } - display.activate = FB_ACTIVATE_NOW; - if( ioctl( fb_fd, FBIOPUT_VSCREENINFO, &display ) || - ioctl( fb_fd, FBIOPUTCMAP, &fb_cmap ) ) { + if( ioctl( fb_fd, FBIOPUT_VSCREENINFO, &display ) ) { fprintf( stderr, "%s: couldn't set mode for framebuffer device '%s'\n", fuse_progname, dev ); return 1; } - ioctl( fb_fd, FBIOGET_VSCREENINFO, &display ); + ioctl( fb_fd, FBIOGET_VSCREENINFO, &display); + for( i = 0; i < 16; i++ ) { + int v = ( i & 8 ) ? 0xff : 0xbf; + int c; + rgbs[i] = ( ( i & 1 ) ? (v >> (8 - display.blue.length)) << display.blue.offset : 0 ) + | ( ( i & 2 ) ? (v >> (8 - display.red.length)) << display.red.offset : 0 ) + | ( ( i & 4 ) ? (v >> (8 - display.green.length)) << display.green.offset : 0 ); + + c = (( i & 1 ) ? (v * 0.114) : 0.0) + + (( i & 2) ? (v * 0.299) : 0.0) + + (( i & 4) ? (v * 0.587) : 0.0) + 0.5; + greys[i] = (c >> (8 - display.red.length) << display.red.offset) + | (c >> (8 - display.green.length) << display.green.offset) + | (c >> (8 - display.blue.length) << display.blue.offset); + } + linear_palette(&fb_cmap); + + if (orig_display.bits_per_pixel == 8 || fixed.visual == FB_VISUAL_DIRECTCOLOR) { + ioctl( fb_fd, FBIOGETCMAP, &orig_cmap); + changed_palette = 1; + } + ioctl( fb_fd, FBIOGET_FSCREENINFO, &fixed); + if ( fixed.visual == FB_VISUAL_DIRECTCOLOR) { + ioctl( fb_fd, FBIOPUTCMAP, &fb_cmap ); + } sleep( 1 ); /* give the monitor time to sync before we start emulating */ + fputs( "\x1B[?25l", stdout ); /* hide cursor */ fflush( stdout ); @@ -396,8 +427,6 @@ int uidisplay_end( void ) { - fbdisplay_end(); - display_ui_initialised = 0; return 0; } @@ -405,7 +434,13 @@ fbdisplay_end( void ) { if( fb_fd != -1 ) { - if( got_orig_display ) ioctl( fb_fd, FBIOPUT_VSCREENINFO, &orig_display ); + if( got_orig_display ) { + ioctl( fb_fd, FBIOPUT_VSCREENINFO, &orig_display ); + if (changed_palette) { + ioctl( fb_fd, FBIOPUTCMAP, &orig_cmap); + changed_palette = 0; + } + } close( fb_fd ); fb_fd = -1; fputs( "\x1B[H\x1B[J\x1B[?25h", stdout ); /* clear screen, show cursor */ Property changes on: trunk/libspectrum/libspectrum ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-655 + /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-659 Modified: trunk/libspectrum/libspectrum/hacking/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/hacking/ChangeLog 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/libspectrum/libspectrum/hacking/ChangeLog 2010-12-08 11:29:46 UTC (rev 660) @@ -787,3 +787,4 @@ 20101003 szx.c,test/{empty.szx,test.c}: we also need to swap A' and F'. 20101010 configure.in: pad version number for Win32 if needed (patch #3084574) (Sergio Baldovi). +20101130 warajevo_read.c: remove potential signedness problem. Modified: trunk/libspectrum/libspectrum/warajevo_read.c =================================================================== --- trunk/libspectrum/libspectrum/warajevo_read.c 2010-12-07 12:36:15 UTC (rev 659) +++ trunk/libspectrum/libspectrum/warajevo_read.c 2010-12-08 11:29:46 UTC (rev 660) @@ -2,7 +2,7 @@ Copyright (c) 2001, 2002 Philip Kendall, Darren Salt Copyright (c) 2003 Fredrick Meunier - $Id: warajevo_read.c 4118 2010-02-21 04:36:17Z fredm $ + $Id: warajevo_read.c 4196 2010-11-30 18:45:18Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -150,17 +150,17 @@ static libspectrum_dword lsb2dword( const libspectrum_byte *mem ) { - return mem[0] + - mem[1] * 0x100 + - mem[2] * 0x10000 + - mem[3] * 0x1000000 ; + return ( mem[0] << 0 ) | + ( mem[1] << 8 ) | + ( mem[2] << 16 ) | + ( mem[3] << 24 ); } static libspectrum_word lsb2word( const libspectrum_byte *mem ) { - return mem[0] + - mem[1] * 0x100 ; + return ( mem[0] << 0 ) | + ( mem[1] << 8 ); } /* The main load function */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2010-12-18 01:05:14
|
Revision: 663 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=663&view=rev Author: fredm Date: 2010-12-18 01:05:06 +0000 (Sat, 18 Dec 2010) Log Message: ----------- Merge up to vendor tag 1.0.0 Modified Paths: -------------- trunk/FuseGenerator/config.h trunk/FuseImporter/config.h trunk/fuse/ChangeLog trunk/fuse/README trunk/fuse/configure.in trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html trunk/fuse/hacking/ChangeLog trunk/fuse/ide/divide.c trunk/fuse/ide/divide.h trunk/fuse/ide/ide.c trunk/fuse/ide/ide.h trunk/fuse/ide/simpleide.c trunk/fuse/ide/simpleide.h trunk/fuse/ide/zxatasp.c trunk/fuse/ide/zxatasp.h trunk/fuse/ide/zxcf.c trunk/fuse/ide/zxcf.h trunk/fuse/man/fuse.1 trunk/libspectrum/config.h trunk/libspectrum/libspectrum/ChangeLog trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/README trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/doc/libspectrum.3 trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/test/Makefile.am Property Changed: ---------------- trunk/fuse/ trunk/fuse/fusepb/libspectrum.h trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/config.h =================================================================== --- trunk/FuseGenerator/config.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/FuseGenerator/config.h 2010-12-18 01:05:06 UTC (rev 663) @@ -83,7 +83,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.5.0" +#define VERSION "1.0.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Modified: trunk/FuseImporter/config.h =================================================================== --- trunk/FuseImporter/config.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/FuseImporter/config.h 2010-12-18 01:05:06 UTC (rev 663) @@ -83,7 +83,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.5.0" +#define VERSION "1.0.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-659 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-662 Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ChangeLog 2010-12-18 01:05:06 UTC (rev 663) @@ -1,4 +1,4 @@ -2010-10-xx Philip Kendall <phi...@sh...> +2010-12-16 Philip Kendall <phi...@sh...> * Fuse 1.0.0 released. @@ -1035,4 +1035,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 4165 2010-09-30 21:55:05Z pak21 $ +$Id: ChangeLog 4220 2010-12-17 10:54:29Z fredm $ Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/README 2010-12-18 01:05:06 UTC (rev 663) @@ -214,6 +214,6 @@ <http://www.worldofspectrum.org/forums/>. Philip Kendall <phi...@sh...> -FIXME October 2010 +16 December 2010 -$Id: README 4172 2010-10-03 22:51:59Z pak21 $ +$Id: README 4220 2010-12-17 10:54:29Z fredm $ Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/configure.in 2010-12-18 01:05:06 UTC (rev 663) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 4181 2010-10-10 10:28:09Z fredm $ +dnl $Id: configure.in 4220 2010-12-17 10:54:29Z fredm $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -23,7 +23,7 @@ AM_CONFIG_HEADER(config.h) AC_CANONICAL_SYSTEM -define(FUSE_VERSION, [0.10.0.2]) +define(FUSE_VERSION, [1.0.0]) dnl Use automake to produce `Makefile.in' AM_INIT_AUTOMAKE(fuse, FUSE_VERSION) Modified: trunk/fuse/fusepb/English.lproj/InfoPlist.strings =================================================================== (Binary files differ) Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/fusepb/Info-Fuse.plist 2010-12-18 01:05:06 UTC (rev 663) @@ -510,11 +510,11 @@ <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleShortVersionString</key> - <string>20101007</string> + <string>1.0.0</string> <key>CFBundleSignature</key> <string>FUSE</string> <key>CFBundleVersion</key> - <string>20101007</string> + <string>1.0.0</string> <key>NSMainNibFile</key> <string>MainMenu</string> <key>NSPrincipalClass</key> Property changes on: trunk/fuse/fusepb/libspectrum.h ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/current/fuse/fusepb/libspectrum.h:638-659 /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 + /vendor/fuse-emulator/current/fuse/fusepb/libspectrum.h:638-662 /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 Modified: trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html =================================================================== --- trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html 2010-12-18 01:05:06 UTC (rev 663) @@ -11,56 +11,11 @@ <body> <font face="Lucida Grande,Helvetica,Arial"> <!-- AppleSegStart="What's New In Fuse?" --><a - name="What's New In Fuse?" id="What's New In Fuse?"></a><!-- AppleSegDescription="This section describes the changes for version 0.10.0 of the Fuse emulator." --></font><br> + name="What's New In Fuse?" id="What's New In Fuse?"></a><!-- AppleSegDescription="This section describes the changes for version 1.0.0 of the Fuse emulator." --></font><br> <div class="refsect1" xml:lang="en" lang="en"> <h2><font face="Lucida Grande,Helvetica,Arial">What's new in Fuse -For Mac OS X Beta 201012??</font></h2> +For Mac OS X 1.0.0</font></h2> <ul> - <li><font face="Lucida Grande,Helvetica,Arial">Changes since last -beta:</font></li> - <ul> - <li><font face="Lucida Grande,Helvetica,Arial">Support weak data in -+3 disk images (Gergely Szasz).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Extend 80 track -drives to accept disks up to 84 tracks and 40 track drives to accept -disks up to 42 tracks (Gergely Szasz).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Fix stuck key -problem with shfted extended punctuation keys <>:"_+ (Fredrick -Meunier).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Remove RZX -compression option (Fredrick Meunier).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Resolve hang when -double-clicking a file to open in Fuse (Fredrick Meunier).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Restore handling of -zoom titlebar button events (Fredrick Meunier).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Pause emulation -before loading a file from a double click/drag-n-drop when Fuse is -already running (Fredrick Meunier).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Add x86_64 target to -Universal Binary (Fredrick Meunier).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Set track lengths -when inserting a new disk (Gergely Szasz).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Correct writing of -status and system registers to snapshots (Patrik Rak).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Add support for NTSC -ZX Spectrum 48K (Philip Kendall).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Fix autoload -snapshots (thanks, Gergely Szasz) (</font><font - face="Lucida Grande,Helvetica,Arial">Fredrick -Meunier</font><font face="Lucida Grande,Helvetica,Arial">).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Query for an initial -snapshot when opening a RZX file which doesn't have one as is common in -competition mode RZX files (Sergio Baldovi).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">Don't close a disk -or mdr if a write fails (thanks, Crisis) (Gergely Szasz).</font></li> - <li><font face="Lucida Grande,Helvetica,Arial">The Allow Writes to -ROM preference shouldn't affect the 16K machine "empty" page (thanks, -Andrew Owen) (</font><font face="Lucida Grande,Helvetica,Arial">Fredrick -Meunier</font><font face="Lucida Grande,Helvetica,Arial">).<br> - </font></li> - </ul> -</ul> -<ul> <li><font face="Lucida Grande,Helvetica,Arial">New features:</font></li> <li @@ -68,6 +23,9 @@ <ul> <li><font face="Lucida Grande,Helvetica,Arial">Add Opus Discovery disk interface support (Gergely Szasz and Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Add support for +NTSC +ZX Spectrum 48K (Philip Kendall).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Support weak data in +3 disk images (Gergely Szasz). </font></li> <li><font face="Lucida Grande,Helvetica,Arial">Add support for @@ -148,8 +106,41 @@ face="Lucida Grande,Helvetica,Arial"> Fuse from quitting (Fredrick Meunier).</font></li> <li><font face="Lucida Grande,Helvetica,Arial">Make the keyboard -viewer resizable (Fredrick Meunier).<br> - </font></li> +viewer resizable (Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Extend 80 track +drives to accept disks up to 84 tracks and 40 track drives to accept +disks up to 42 tracks (Gergely Szasz).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Fix stuck key +problem with shfted extended punctuation keys <>:"_+ (Fredrick +Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Remove RZX +compression option (Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Resolve hang when +double-clicking a file to open in Fuse (Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Restore handling of +zoom titlebar button events (Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Pause emulation +before loading a file from a double click/drag-n-drop when Fuse is +already running (Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Add x86_64 target to +Universal Binary (Fredrick Meunier).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Set track lengths +when inserting a new disk (Gergely Szasz).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Correct writing of +status and system registers to snapshots (Patrik Rak).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Fix autoload +snapshots (thanks, Gergely Szasz) (</font><font + face="Lucida Grande,Helvetica,Arial">Fredrick +Meunier</font><font face="Lucida Grande,Helvetica,Arial">).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Query for an initial +snapshot when opening a RZX file which doesn't have one as is common in +competition mode RZX files (Sergio Baldovi).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">Don't close a disk +or MDR file if a write fails (thanks, Crisis) (Gergely Szasz).</font></li> + <li><font face="Lucida Grande,Helvetica,Arial">The Allow Writes to +ROM preference shouldn't affect the 16K machine "empty" page (thanks, +Andrew Owen) (</font><font face="Lucida Grande,Helvetica,Arial">Fredrick +Meunier</font><font face="Lucida Grande,Helvetica,Arial">).</font></li> </ul> <li><font face="Lucida Grande,Helvetica,Arial">Various other minor bugfixes.</font></li> Modified: trunk/fuse/hacking/ChangeLog =================================================================== --- trunk/fuse/hacking/ChangeLog 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/hacking/ChangeLog 2010-12-18 01:05:06 UTC (rev 663) @@ -3368,5 +3368,7 @@ line ordering (patch #3100707) (Sergio Baldovi). 20101129 ui/fb/fbdisplay.c: only call fbdisplay_end() when display is initialised (fixes bug #3119382) (rkd77). +20101129 ChangeLog,README,man/fuse.1: more 1.0 updates. 20101203 ui/fb/fbdisplay.c: improve fb colour handling and initialise scaler system (fixes bugs #3124787 and #3124788) (rkd77). +20101216 ChangeLog,README,configure.in,man/fuse.1: update for 1.0.0 release. Modified: trunk/fuse/ide/divide.c =================================================================== --- trunk/fuse/ide/divide.c 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/divide.c 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ /* divide.c: DivIDE interface routines Copyright (c) 2005-2008 Matthew Westcott, Philip Kendall - $Id: divide.c 4148 2010-08-25 21:20:50Z pak21 $ + $Id: divide.c 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/divide.h =================================================================== --- trunk/fuse/ide/divide.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/divide.h 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ /* divide.h: DivIDE interface routines Copyright (c) 2005 Matthew Westcott - $Id: divide.h 4148 2010-08-25 21:20:50Z pak21 $ + $Id: divide.h 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/ide.c =================================================================== --- trunk/fuse/ide/ide.c 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/ide.c 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ /* ide.c: Generic routines shared between the various IDE devices Copyright (c) 2005 Philip Kendall - $Id: ide.c 4148 2010-08-25 21:20:50Z pak21 $ + $Id: ide.c 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/ide.h =================================================================== --- trunk/fuse/ide/ide.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/ide.h 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ /* ide.h: Generic routines shared between the various IDE devices Copyright (c) 2005 Philip Kendall - $Id: ide.h 4148 2010-08-25 21:20:50Z pak21 $ + $Id: ide.h 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/simpleide.c =================================================================== --- trunk/fuse/ide/simpleide.c 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/simpleide.c 2010-12-18 01:05:06 UTC (rev 663) @@ -3,7 +3,7 @@ 2004 Philip Kendall, 2008 Fredrick Meunier - $Id: simpleide.c 4148 2010-08-25 21:20:50Z pak21 $ + $Id: simpleide.c 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/simpleide.h =================================================================== --- trunk/fuse/ide/simpleide.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/simpleide.h 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ /* simpleide.h: Simple 8-bit IDE interface routines Copyright (c) 2003-2004 Garry Lancaster - $Id: simpleide.h 4148 2010-08-25 21:20:50Z pak21 $ + $Id: simpleide.h 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxatasp.c =================================================================== --- trunk/fuse/ide/zxatasp.c 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/zxatasp.c 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ /* zxatasp.c: ZXATASP interface routines Copyright (c) 2003-2008 Garry Lancaster and Philip Kendall - $Id: zxatasp.c 4148 2010-08-25 21:20:50Z pak21 $ + $Id: zxatasp.c 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxatasp.h =================================================================== --- trunk/fuse/ide/zxatasp.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/zxatasp.h 2010-12-18 01:05:06 UTC (rev 663) @@ -2,7 +2,7 @@ Copyright (c) 2003-2004 Garry Lancaster, 2004 Philip Kendall - $Id: zxatasp.h 4148 2010-08-25 21:20:50Z pak21 $ + $Id: zxatasp.h 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxcf.c =================================================================== --- trunk/fuse/ide/zxcf.c 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/zxcf.c 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ /* zxcf.c: ZXCF interface routines Copyright (c) 2003-2008 Garry Lancaster and Philip Kendall - $Id: zxcf.c 4148 2010-08-25 21:20:50Z pak21 $ + $Id: zxcf.c 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxcf.h =================================================================== --- trunk/fuse/ide/zxcf.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/ide/zxcf.h 2010-12-18 01:05:06 UTC (rev 663) @@ -2,7 +2,7 @@ Copyright (c) 2003-2004 Garry Lancaster, 2004 Philip Kendall - $Id: zxcf.h 4148 2010-08-25 21:20:50Z pak21 $ + $Id: zxcf.h 4220 2010-12-17 10:54:29Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/man/fuse.1 =================================================================== --- trunk/fuse/man/fuse.1 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/fuse/man/fuse.1 2010-12-18 01:05:06 UTC (rev 663) @@ -23,7 +23,7 @@ .\" E-mail: phi...@sh... .\" .\" -.TH fuse 1 "FIXME October, 2010" "Version 1.0.0" "Emulators" +.TH fuse 1 "16th December, 2010" "Version 1.0.0" "Emulators" .\" .\"------------------------------------------------------------------ .\" Modified: trunk/libspectrum/config.h =================================================================== --- trunk/libspectrum/config.h 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/config.h 2010-12-18 01:05:06 UTC (rev 663) @@ -86,7 +86,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.5.0" +#define VERSION "1.0.0" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Property changes on: trunk/libspectrum/libspectrum ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-659 + /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-662 Modified: trunk/libspectrum/libspectrum/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/ChangeLog 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/ChangeLog 2010-12-18 01:05:06 UTC (rev 663) @@ -1,4 +1,4 @@ -2010-10-?? Philip Kendall <phi...@sh...> +2010-12-16 Philip Kendall <phi...@sh...> * libspectrum 1.0.0 released. @@ -310,5 +310,5 @@ * libspectrum separated from Fuse just before the 0.5.0 release of Fuse; see Fuse's ChangeLog for changes up to this point -$Id: ChangeLog 4165 2010-09-30 21:55:05Z pak21 $ +$Id: ChangeLog 4220 2010-12-17 10:54:29Z fredm $ Modified: trunk/libspectrum/libspectrum/Makefile.am =================================================================== --- trunk/libspectrum/libspectrum/Makefile.am 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/Makefile.am 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2001-2004 Philip Kendall -## $Id: Makefile.am 4158 2010-09-12 11:49:10Z fredm $ +## $Id: Makefile.am 4220 2010-12-17 10:54:29Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -58,7 +58,7 @@ zlib.c \ zxs.c -libspectrum_la_LDFLAGS = -version-info 7:0:0 -no-undefined @WINDRES_LDFLAGS@ +libspectrum_la_LDFLAGS = -version-info 8:0:0 -no-undefined @WINDRES_LDFLAGS@ libspectrum_la_LIBADD = @AUDIOFILE_LIBS@ -lm Modified: trunk/libspectrum/libspectrum/README =================================================================== --- trunk/libspectrum/libspectrum/README 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/README 2010-12-18 01:05:06 UTC (rev 663) @@ -67,6 +67,6 @@ Then, type "make" and if everything went well, "make install". Philip Kendall <phi...@sh...> -FIXME September 2010 +16 December 2010 -$Id: README 4165 2010-09-30 21:55:05Z pak21 $ +$Id: README 4220 2010-12-17 10:54:29Z fredm $ Modified: trunk/libspectrum/libspectrum/configure.in =================================================================== --- trunk/libspectrum/libspectrum/configure.in 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/configure.in 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ dnl Process this file with autoconf to produce a configure script. dnl Copyright (c) 1999-2008 Philip Kendall -dnl $Id: configure.in 4181 2010-10-10 10:28:09Z fredm $ +dnl $Id: configure.in 4220 2010-12-17 10:54:29Z fredm $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -24,7 +24,7 @@ AC_INIT(libspectrum.c) AM_CONFIG_HEADER(config.h) -define(LIBSPECTRUM_VERSION, [0.5.1]) +define(LIBSPECTRUM_VERSION, [1.0.0]) dnl Use automake to produce `Makefile.in' AM_INIT_AUTOMAKE(libspectrum, LIBSPECTRUM_VERSION) Modified: trunk/libspectrum/libspectrum/doc/libspectrum.3 =================================================================== --- trunk/libspectrum/libspectrum/doc/libspectrum.3 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/doc/libspectrum.3 2010-12-18 01:05:06 UTC (rev 663) @@ -22,7 +22,7 @@ .\" E-mail: phi...@sh... .\" .\" -.TH libspectrum 3 "3rd December, 2008" "Version 0.5.0" "Emulators" +.TH libspectrum 3 "16th December, 2010" "Version 1.0.0" "Emulators" .\" .\"------------------------------------------------------------------ .\" Modified: trunk/libspectrum/libspectrum/doc/libspectrum.txt =================================================================== --- trunk/libspectrum/libspectrum/doc/libspectrum.txt 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/doc/libspectrum.txt 2010-12-18 01:05:06 UTC (rev 663) @@ -1,4 +1,4 @@ -libspectrum 0.5.0 +libspectrum 1.0.0 ================= libspectrum is a fairly simple library designed to make the handling @@ -166,6 +166,7 @@ LIBSPECTRUM_MACHINE_16 16K Spectrum LIBSPECTRUM_MACHINE_48 48K Spectrum +LIBSPECTRUM_MACHINE_48_NTSC NTSC version of 48K Spectrum LIBSPECTRUM_MACHINE_128 (Original) 128K Spectrum LIBSPECTRUM_MACHINE_PLUS2 Spectrum +2 (the grey one) LIBSPECTRUM_MACHINE_PLUS2A Spectrum +2A (the black one) @@ -1744,4 +1745,4 @@ Write `data' to register `reg' of the IDE channel `chn'. -$Id: libspectrum.txt 4140 2010-07-11 13:02:58Z fredm $ +$Id: libspectrum.txt 4220 2010-12-17 10:54:29Z fredm $ Modified: trunk/libspectrum/libspectrum/hacking/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/hacking/ChangeLog 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/hacking/ChangeLog 2010-12-18 01:05:06 UTC (rev 663) @@ -787,4 +787,10 @@ 20101003 szx.c,test/{empty.szx,test.c}: we also need to swap A' and F'. 20101010 configure.in: pad version number for Win32 if needed (patch #3084574) (Sergio Baldovi). +20101129 ChangeLog,README,doc/libspectrum.{3,txt}: more 1.0 updates. 20101130 warajevo_read.c: remove potential signedness problem. +20101130 Makefile.am,configure.in: bump version numbers for 1.0 release. +20101216 README,configure.in,doc/libspectrum.3: bump version numbers and dates + for 1.0.0 release. +20101216 ChangeLog: update date here as well. +20101216 test/Makefile.am: ensure all test files are distributed. Modified: trunk/libspectrum/libspectrum/test/Makefile.am =================================================================== --- trunk/libspectrum/libspectrum/test/Makefile.am 2010-12-17 11:05:57 UTC (rev 662) +++ trunk/libspectrum/libspectrum/test/Makefile.am 2010-12-18 01:05:06 UTC (rev 663) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007 Philip Kendall -## $Id: Makefile.am 3832 2008-11-18 03:38:51Z fredm $ +## $Id: Makefile.am 4220 2010-12-17 10:54:29Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -44,6 +44,7 @@ test/complete-tzx.pl \ test/empty-drb.tzx \ test/empty.csw \ + test/empty.szx \ test/empty.z80 \ test/invalid-archiveinfo.tzx \ test/invalid-custominfo.tzx \ @@ -57,6 +58,7 @@ test/loop.tzx \ test/loop2.tzx \ test/loopend.tzx \ + test/plus3.z80 \ test/sp-2000.sna.gz \ test/sp-ffff.sna.gz \ test/turbo-zeropilot.tzx \ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2011-04-03 11:11:13
|
Revision: 670 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=670&view=rev Author: fredm Date: 2011-04-03 11:11:05 +0000 (Sun, 03 Apr 2011) Log Message: ----------- Merge in vendor release 1.0.0.1a changes - still need to address handling of missing ROMs. Modified Paths: -------------- trunk/FuseGenerator/config.h trunk/FuseImporter/config.h trunk/fuse/ChangeLog trunk/fuse/README trunk/fuse/configure.in trunk/fuse/debugger/breakpoint.c trunk/fuse/fuse.c trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/hacking/ChangeLog trunk/fuse/ide/divide.c trunk/fuse/ide/divide.h trunk/fuse/ide/ide.c trunk/fuse/ide/ide.h trunk/fuse/ide/simpleide.c trunk/fuse/ide/simpleide.h trunk/fuse/ide/zxatasp.c trunk/fuse/ide/zxatasp.h trunk/fuse/ide/zxcf.c trunk/fuse/ide/zxcf.h trunk/fuse/keysyms.pl trunk/fuse/man/fuse.1 trunk/fuse/memory.c trunk/fuse/roms/Makefile.am trunk/fuse/ui/fb/fbdisplay.c trunk/fuse/ui/widget/filesel.c trunk/libspectrum/config.h trunk/libspectrum/libspectrum/ChangeLog trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/README trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/test/Makefile.am trunk/libspectrum/libspectrum/warajevo_read.c Added Paths: ----------- trunk/fuse/roms/README.copyright Removed Paths: ------------- trunk/fuse/roms/128p-0.rom trunk/fuse/roms/128p-1.rom trunk/fuse/roms/256s-0.rom trunk/fuse/roms/256s-1.rom trunk/fuse/roms/256s-2.rom trunk/fuse/roms/256s-3.rom trunk/fuse/roms/gluck.rom trunk/fuse/roms/if1-1.rom trunk/fuse/roms/if1-2.rom trunk/fuse/roms/opus.rom trunk/fuse/roms/trdos.rom Property Changed: ---------------- trunk/fuse/ trunk/fuse/fusepb/libspectrum.h trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/config.h =================================================================== --- trunk/FuseGenerator/config.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/FuseGenerator/config.h 2011-04-03 11:11:05 UTC (rev 670) @@ -83,7 +83,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "1.0.0" +#define VERSION "1.0.0.1a" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Modified: trunk/FuseImporter/config.h =================================================================== --- trunk/FuseImporter/config.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/FuseImporter/config.h 2011-04-03 11:11:05 UTC (rev 670) @@ -83,7 +83,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "1.0.0" +#define VERSION "1.0.0.1a" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Property changes on: trunk/fuse ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-662 + /vendor/fuse-emulator/0.10.0/fuse:556-557 /vendor/fuse-emulator/0.10.0-pre1/fuse:545-546 /vendor/fuse-emulator/current/fuse:530-667 /vendor/fuse-emulator/fuse-1.0.0a/fuse:668-669 Modified: trunk/fuse/ChangeLog =================================================================== --- trunk/fuse/ChangeLog 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ChangeLog 2011-04-03 11:11:05 UTC (rev 670) @@ -1,3 +1,19 @@ +2011-04-01 Philip Kendall <phi...@sh...> + + * Fuse 1.0.0.1a released. + + * Remove all ROMs for which there isn't explicit permission to + distribute (Philip Kendall). + +2011-01-12 Philip Kendall <phi...@sh...> + + * Fuse 1.0.0.1 released. + + * Fix temporary breakpoints on platforms using replacement Glib + (Fredrick Meunier, Sergio Baldovi; thanks, Chris Cowley) + * Ensure Amiga port can load files (Chris Young) + * Fix SVGAlib compilation (rkd77) + 2010-12-16 Philip Kendall <phi...@sh...> * Fuse 1.0.0 released. @@ -1035,4 +1051,4 @@ * Version 0.1.0 released. -$Id: ChangeLog 4220 2010-12-17 10:54:29Z fredm $ +$Id: ChangeLog 4331 2011-04-01 07:47:06Z pak21 $ Modified: trunk/fuse/README =================================================================== --- trunk/fuse/README 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/README 2011-04-03 11:11:05 UTC (rev 670) @@ -1,5 +1,5 @@ -The Free Unix Spectrum Emulator (Fuse) 1.0.0 -============================================ +The Free Unix Spectrum Emulator (Fuse) 1.0.0.1a +=============================================== Fuse (the Free Unix Spectrum Emulator) was originally, and somewhat unsurprisingly, an emulator of the ZX Spectrum (a popular 1980s home @@ -214,6 +214,6 @@ <http://www.worldofspectrum.org/forums/>. Philip Kendall <phi...@sh...> -16 December 2010 +28 March 2011 -$Id: README 4220 2010-12-17 10:54:29Z fredm $ +$Id: README 4329 2011-03-27 22:26:07Z pak21 $ Modified: trunk/fuse/configure.in =================================================================== --- trunk/fuse/configure.in 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/configure.in 2011-04-03 11:11:05 UTC (rev 670) @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $Id: configure.in 4220 2010-12-17 10:54:29Z fredm $ +dnl $Id: configure.in 4329 2011-03-27 22:26:07Z pak21 $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by @@ -23,7 +23,7 @@ AM_CONFIG_HEADER(config.h) AC_CANONICAL_SYSTEM -define(FUSE_VERSION, [1.0.0]) +define(FUSE_VERSION, [1.0.0.1a]) dnl Use automake to produce `Makefile.in' AM_INIT_AUTOMAKE(fuse, FUSE_VERSION) Modified: trunk/fuse/debugger/breakpoint.c =================================================================== --- trunk/fuse/debugger/breakpoint.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/debugger/breakpoint.c 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* breakpoint.c: a debugger breakpoint Copyright (c) 2002-2008 Philip Kendall - $Id: breakpoint.c 3685 2008-06-21 12:37:24Z pak21 $ + $Id: breakpoint.c 4239 2011-01-01 15:41:13Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -237,19 +237,26 @@ debugger_check( debugger_breakpoint_type type, libspectrum_dword value ) { GSList *ptr; debugger_breakpoint *bp; + GSList *ptr_next; switch( debugger_mode ) { case DEBUGGER_MODE_INACTIVE: return 0; case DEBUGGER_MODE_ACTIVE: - for( ptr = debugger_breakpoints; ptr; ptr = ptr->next ) { + for( ptr = debugger_breakpoints; ptr; ptr = ptr_next ) { bp = ptr->data; + ptr_next = ptr->next; if( breakpoint_check( bp, type, value ) ) { - debugger_mode = DEBUGGER_MODE_HALTED; - debugger_command_evaluate( bp->commands ); + debugger_mode = DEBUGGER_MODE_HALTED; + debugger_command_evaluate( bp->commands ); + + if( bp->life == DEBUGGER_BREAKPOINT_LIFE_ONESHOT ) { + debugger_breakpoints = g_slist_remove( debugger_breakpoints, bp ); + free( bp ); + } } } @@ -352,11 +359,6 @@ if( bp->condition && !debugger_expression_evaluate( bp->condition ) ) return 0; - if( bp->life == DEBUGGER_BREAKPOINT_LIFE_ONESHOT ) { - debugger_breakpoints = g_slist_remove( debugger_breakpoints, bp ); - free( bp ); - } - if( bp->type == DEBUGGER_BREAKPOINT_TYPE_TIME ) bp->value.time.triggered = 1; Modified: trunk/fuse/fuse.c =================================================================== --- trunk/fuse/fuse.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/fuse.c 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* fuse.c: The Free Unix Spectrum Emulator Copyright (c) 1999-2010 Philip Kendall and others - $Id: fuse.c 4165 2010-09-30 21:55:05Z pak21 $ + $Id: fuse.c 4329 2011-03-27 22:26:07Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -383,7 +383,7 @@ printf( "\n" ); fuse_show_version(); printf( - "Copyright (c) 1999-2010 Philip Kendall and others; see the file\n" + "Copyright (c) 1999-2011 Philip Kendall and others; see the file\n" "'AUTHORS' for more details.\n" "\n" "For help, please mail <fus...@li...> or use\n" Modified: trunk/fuse/fusepb/English.lproj/InfoPlist.strings =================================================================== (Binary files differ) Modified: trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj =================================================================== --- trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2011-04-03 11:11:05 UTC (rev 670) @@ -33,14 +33,6 @@ B61F460C09121DF100C8096C /* 48.rom in Resources */ = {isa = PBXBuildFile; fileRef = F559854C0389212301A804BA /* 48.rom */; }; B61F460D09121DF100C8096C /* 128-0.rom in Resources */ = {isa = PBXBuildFile; fileRef = F559854D0389212301A804BA /* 128-0.rom */; }; B61F460E09121DF100C8096C /* 128-1.rom in Resources */ = {isa = PBXBuildFile; fileRef = F559854E0389212301A804BA /* 128-1.rom */; }; - B61F460F09121DF100C8096C /* 128p-0.rom in Resources */ = {isa = PBXBuildFile; fileRef = B66D5C9D03CF1B3C00FE73F2 /* 128p-0.rom */; }; - B61F461009121DF100C8096C /* 128p-1.rom in Resources */ = {isa = PBXBuildFile; fileRef = B66D5C9E03CF1B3C00FE73F2 /* 128p-1.rom */; }; - B61F461109121DF100C8096C /* 256s-0.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6E093F40607EEDC008B5DEC /* 256s-0.rom */; }; - B61F461209121DF100C8096C /* 256s-1.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6E093F50607EEDC008B5DEC /* 256s-1.rom */; }; - B61F461309121DF100C8096C /* 256s-2.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6E093F60607EEDC008B5DEC /* 256s-2.rom */; }; - B61F461409121DF100C8096C /* 256s-3.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6E093F70607EEDC008B5DEC /* 256s-3.rom */; }; - B61F461509121DF100C8096C /* if1-1.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6AE204307704CFD00990F65 /* if1-1.rom */; }; - B61F461609121DF100C8096C /* if1-2.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6AE204407704CFD00990F65 /* if1-2.rom */; }; B61F461709121DF100C8096C /* plus2-0.rom in Resources */ = {isa = PBXBuildFile; fileRef = F55985520389213E01A804BA /* plus2-0.rom */; }; B61F461809121DF100C8096C /* plus2-1.rom in Resources */ = {isa = PBXBuildFile; fileRef = F55985530389213E01A804BA /* plus2-1.rom */; }; B61F461909121DF100C8096C /* plus3-0.rom in Resources */ = {isa = PBXBuildFile; fileRef = F55985540389213E01A804BA /* plus3-0.rom */; }; @@ -56,7 +48,6 @@ B61F462309121DF100C8096C /* tc2048.rom in Resources */ = {isa = PBXBuildFile; fileRef = F55985580389213E01A804BA /* tc2048.rom */; }; B61F462409121DF100C8096C /* tc2068-0.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6FEA44B0444C2CC0013916D /* tc2068-0.rom */; }; B61F462509121DF100C8096C /* tc2068-1.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6FEA44C0444C2CC0013916D /* tc2068-1.rom */; }; - B61F462609121DF100C8096C /* trdos.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6AA8A3C03D2FC1C00FED55D /* trdos.rom */; }; B61F462909121DF100C8096C /* 48k.png in Resources */ = {isa = PBXBuildFile; fileRef = F56B6A6203A628A901CA65B5 /* 48k.png */; }; B61F462A09121DF100C8096C /* ts2068.png in Resources */ = {isa = PBXBuildFile; fileRef = B6C3479F044B091100E1BBA7 /* ts2068.png */; }; B61F462B09121DF100C8096C /* Fuse.icns in Resources */ = {isa = PBXBuildFile; fileRef = F5F4333103903ED801E7A043 /* Fuse.icns */; }; @@ -154,7 +145,6 @@ B62B1A2A0DD667EC00D42AAF /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = B62B1A290DD667EC00D42AAF /* main.m */; }; B631B9FF10257CA400BE1EE1 /* opus.c in Sources */ = {isa = PBXBuildFile; fileRef = B631B9FD10257CA400BE1EE1 /* opus.c */; }; B631BA0010257CA400BE1EE1 /* opus.h in Headers */ = {isa = PBXBuildFile; fileRef = B631B9FE10257CA400BE1EE1 /* opus.h */; }; - B631BA0F1025878600BE1EE1 /* opus.rom in Resources */ = {isa = PBXBuildFile; fileRef = B631BA0E1025878600BE1EE1 /* opus.rom */; }; B63225EC0C66BA1300BB081B /* osname.c in Sources */ = {isa = PBXBuildFile; fileRef = B63225EB0C66BA1300BB081B /* osname.c */; }; B63225EE0C66BA3700BB081B /* paths.c in Sources */ = {isa = PBXBuildFile; fileRef = B63225ED0C66BA3700BB081B /* paths.c */; }; B635EAE7116A0FE500A166F2 /* keystate.c in Sources */ = {isa = PBXBuildFile; fileRef = B635EAE5116A0FE500A166F2 /* keystate.c */; }; @@ -237,7 +227,6 @@ B6CE3A0C0CD2160A005ACDC8 /* fdd.c in Sources */ = {isa = PBXBuildFile; fileRef = B6CE3A040CD2160A005ACDC8 /* fdd.c */; }; B6CE3A100CD21617005ACDC8 /* wd_fdc.c in Sources */ = {isa = PBXBuildFile; fileRef = B6CE3A0E0CD21617005ACDC8 /* wd_fdc.c */; }; B6CE3A130CD217C2005ACDC8 /* pentagon1024.c in Sources */ = {isa = PBXBuildFile; fileRef = B6CE3A120CD217C2005ACDC8 /* pentagon1024.c */; }; - B6CE3A190CD218A6005ACDC8 /* gluck.rom in Resources */ = {isa = PBXBuildFile; fileRef = B6CE3A180CD218A6005ACDC8 /* gluck.rom */; }; B6CE7F420B2830A300EB65B3 /* cocoajoystick.c in Sources */ = {isa = PBXBuildFile; fileRef = B6CE7F3C0B2830A300EB65B3 /* cocoajoystick.c */; }; B6CE7FCE0B28FBD600EB65B3 /* DisplayOpenGLView.m in Sources */ = {isa = PBXBuildFile; fileRef = B6CE7FCC0B28FBD600EB65B3 /* DisplayOpenGLView.m */; }; B6DCBBBF114FA0E700DC9A11 /* bzip2.c in Sources */ = {isa = PBXBuildFile; fileRef = B6DCBB62114FA0E700DC9A11 /* bzip2.c */; }; @@ -1528,17 +1517,7 @@ B61F460009121DF100C8096C /* Credits.html in Resources */, B61F460D09121DF100C8096C /* 128-0.rom in Resources */, B61F460E09121DF100C8096C /* 128-1.rom in Resources */, - B61F460F09121DF100C8096C /* 128p-0.rom in Resources */, - B61F461009121DF100C8096C /* 128p-1.rom in Resources */, - B61F461109121DF100C8096C /* 256s-0.rom in Resources */, - B61F461209121DF100C8096C /* 256s-1.rom in Resources */, - B61F461309121DF100C8096C /* 256s-2.rom in Resources */, - B61F461409121DF100C8096C /* 256s-3.rom in Resources */, B61F460C09121DF100C8096C /* 48.rom in Resources */, - B6CE3A190CD218A6005ACDC8 /* gluck.rom in Resources */, - B61F461509121DF100C8096C /* if1-1.rom in Resources */, - B61F461609121DF100C8096C /* if1-2.rom in Resources */, - B631BA0F1025878600BE1EE1 /* opus.rom in Resources */, B61F461709121DF100C8096C /* plus2-0.rom in Resources */, B61F461809121DF100C8096C /* plus2-1.rom in Resources */, B61F461909121DF100C8096C /* plus3-0.rom in Resources */, @@ -1555,7 +1534,6 @@ B61F462309121DF100C8096C /* tc2048.rom in Resources */, B61F462409121DF100C8096C /* tc2068-0.rom in Resources */, B61F462509121DF100C8096C /* tc2068-1.rom in Resources */, - B61F462609121DF100C8096C /* trdos.rom in Resources */, B61F462909121DF100C8096C /* 48k.png in Resources */, B61F462A09121DF100C8096C /* ts2068.png in Resources */, B61F462B09121DF100C8096C /* Fuse.icns in Resources */, Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/fusepb/Info-Fuse.plist 2011-04-03 11:11:05 UTC (rev 670) @@ -514,7 +514,7 @@ <key>CFBundleSignature</key> <string>FUSE</string> <key>CFBundleVersion</key> - <string>1.0.0</string> + <string>1.0.0.1a</string> <key>NSMainNibFile</key> <string>MainMenu</string> <key>NSPrincipalClass</key> Property changes on: trunk/fuse/fusepb/libspectrum.h ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/current/fuse/fusepb/libspectrum.h:638-662 /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 + /vendor/fuse-emulator/current/fuse/fusepb/libspectrum.h:638-667 /vendor/fuse-emulator/current/libspectrum/libspectrum.h.in:538-600 /vendor/fuse-emulator/fuse-1.0.0a/fuse/fusepb/libspectrum.h:668-669 Modified: trunk/fuse/hacking/ChangeLog =================================================================== --- trunk/fuse/hacking/ChangeLog 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/hacking/ChangeLog 2011-04-03 11:11:05 UTC (rev 670) @@ -3372,3 +3372,22 @@ 20101203 ui/fb/fbdisplay.c: improve fb colour handling and initialise scaler system (fixes bugs #3124787 and #3124788) (rkd77). 20101216 ChangeLog,README,configure.in,man/fuse.1: update for 1.0.0 release. +20101217 keysyms.pl: fix SVGAlib compilation (rkd77). +20101229 debugger/breakpoint.c: don't free temporary breakpoint until after we have run + it (fixes bug #3084862) (thanks, Chris Cowley) (Fred). +20101230 debugger/breakpoint.c: stop evaluating breakpoints when we have hit a + temporary breakpoint (really fixes bug #3084862) (patch #3142840) + (Sergio Baldovi). +20110101 debugger/breakpoint.c: evaluate all breakpoints again, but store the + next breakpoint before deleteing the current one from the list + (really really fixes bug #3084862) (thanks, Phil) (Fred). +20110109 ui/widget/filesel.c: make Amiga work again (Chris Young). +20110112 ChangeLog,README,configure.in,man/fuse.1: updates for 1.0.0.1 release. +20110327 man/fuse.1,roms/{128p-[01].rom,256s-[0123].rom,Makefile.am, + README.copyright,gluck.rom,if1-[12].rom,opus.rom,trdos.rom, + Makefile.am}: remove ROMs that there is no formal permission to + distribute. +20110327 roms/Makefile.am: distribute README.copyright. +20110327 ChangeLog,README,configure.in,fuse.c,man/fuse.1: updates for 1.0.0.1a + release. +20110401 ChangeLog,man/fuse.1: didn't manage to release this earlier. Modified: trunk/fuse/ide/divide.c =================================================================== --- trunk/fuse/ide/divide.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/divide.c 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* divide.c: DivIDE interface routines Copyright (c) 2005-2008 Matthew Westcott, Philip Kendall - $Id: divide.c 4220 2010-12-17 10:54:29Z fredm $ + $Id: divide.c 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/divide.h =================================================================== --- trunk/fuse/ide/divide.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/divide.h 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* divide.h: DivIDE interface routines Copyright (c) 2005 Matthew Westcott - $Id: divide.h 4220 2010-12-17 10:54:29Z fredm $ + $Id: divide.h 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/ide.c =================================================================== --- trunk/fuse/ide/ide.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/ide.c 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* ide.c: Generic routines shared between the various IDE devices Copyright (c) 2005 Philip Kendall - $Id: ide.c 4220 2010-12-17 10:54:29Z fredm $ + $Id: ide.c 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/ide.h =================================================================== --- trunk/fuse/ide/ide.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/ide.h 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* ide.h: Generic routines shared between the various IDE devices Copyright (c) 2005 Philip Kendall - $Id: ide.h 4220 2010-12-17 10:54:29Z fredm $ + $Id: ide.h 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/simpleide.c =================================================================== --- trunk/fuse/ide/simpleide.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/simpleide.c 2011-04-03 11:11:05 UTC (rev 670) @@ -3,7 +3,7 @@ 2004 Philip Kendall, 2008 Fredrick Meunier - $Id: simpleide.c 4220 2010-12-17 10:54:29Z fredm $ + $Id: simpleide.c 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/simpleide.h =================================================================== --- trunk/fuse/ide/simpleide.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/simpleide.h 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* simpleide.h: Simple 8-bit IDE interface routines Copyright (c) 2003-2004 Garry Lancaster - $Id: simpleide.h 4220 2010-12-17 10:54:29Z fredm $ + $Id: simpleide.h 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxatasp.c =================================================================== --- trunk/fuse/ide/zxatasp.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/zxatasp.c 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* zxatasp.c: ZXATASP interface routines Copyright (c) 2003-2008 Garry Lancaster and Philip Kendall - $Id: zxatasp.c 4220 2010-12-17 10:54:29Z fredm $ + $Id: zxatasp.c 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxatasp.h =================================================================== --- trunk/fuse/ide/zxatasp.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/zxatasp.h 2011-04-03 11:11:05 UTC (rev 670) @@ -2,7 +2,7 @@ Copyright (c) 2003-2004 Garry Lancaster, 2004 Philip Kendall - $Id: zxatasp.h 4220 2010-12-17 10:54:29Z fredm $ + $Id: zxatasp.h 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxcf.c =================================================================== --- trunk/fuse/ide/zxcf.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/zxcf.c 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* zxcf.c: ZXCF interface routines Copyright (c) 2003-2008 Garry Lancaster and Philip Kendall - $Id: zxcf.c 4220 2010-12-17 10:54:29Z fredm $ + $Id: zxcf.c 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ide/zxcf.h =================================================================== --- trunk/fuse/ide/zxcf.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ide/zxcf.h 2011-04-03 11:11:05 UTC (rev 670) @@ -2,7 +2,7 @@ Copyright (c) 2003-2004 Garry Lancaster, 2004 Philip Kendall - $Id: zxcf.h 4220 2010-12-17 10:54:29Z fredm $ + $Id: zxcf.h 4225 2010-12-17 20:14:40Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/keysyms.pl =================================================================== --- trunk/fuse/keysyms.pl 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/keysyms.pl 2011-04-03 11:11:05 UTC (rev 670) @@ -4,7 +4,7 @@ # Copyright (c) 2000-2007 Philip Kendall, Matan Ziv-Av, Russell Marks, # Fredrick Meunier, Catalin Mihaila, Stuart Brady -# $Id: keysyms.pl 4103 2009-11-21 10:16:36Z fredm $ +# $Id: keysyms.pl 4225 2010-12-17 20:14:40Z pak21 $ # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -203,6 +203,7 @@ Down => 'CURSORBLOCKDOWN', Up => 'CURSORBLOCKUP', Right => 'CURSORBLOCKRIGHT', + KP_Enter => 'KEYPADENTER', }, function => \&svga_keysym, }, Modified: trunk/fuse/man/fuse.1 =================================================================== --- trunk/fuse/man/fuse.1 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/man/fuse.1 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ .\" -*- nroff -*- .\" .\" fuse.1: Fuse man page -.\" Copyright (c) 2001-2010 Russell Marks, Philip Kendall, Darren Salt, +.\" Copyright (c) 2001-2011 Russell Marks, Philip Kendall, Darren Salt, .\" Fredrick Meunier, Stuart Brady .\" .\" This program is free software; you can redistribute it and/or modify @@ -23,7 +23,7 @@ .\" E-mail: phi...@sh... .\" .\" -.TH fuse 1 "16th December, 2010" "Version 1.0.0" "Emulators" +.TH fuse 1 "1st April, 2011" "Version 1.0.0.1a" "Emulators" .\" .\"------------------------------------------------------------------ .\" @@ -670,7 +670,9 @@ .RI ( plusd.rom ), and the TR-DOS ROM for Beta 128 emulation with the 48K, TC2048, 128K or +2 .RI ( trdos.rom ). -The names in brackets denote the defaults. +The names in brackets denote the defaults. Note that not all these ROMs +are supplied with Fuse - you must supply your own copies of those which +are not. .RE .PP .I \-\-no\-rs232\-handshake Modified: trunk/fuse/memory.c =================================================================== --- trunk/fuse/memory.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/memory.c 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ /* memory.c: Routines for accessing memory Copyright (c) 1999-2004 Philip Kendall - $Id: memory.c 4186 2010-10-25 10:29:45Z fredm $ + $Id: memory.c 4207 2010-12-05 10:01:23Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Deleted: trunk/fuse/roms/128p-0.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/128p-1.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/256s-0.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/256s-1.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/256s-2.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/256s-3.rom =================================================================== (Binary files differ) Modified: trunk/fuse/roms/Makefile.am =================================================================== --- trunk/fuse/roms/Makefile.am 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/roms/Makefile.am 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 1999-2001 Philip Kendall -## $Id: Makefile.am 4060 2009-07-30 13:21:38Z fredm $ +## $Id: Makefile.am 4328 2011-03-27 22:19:27Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -25,18 +25,14 @@ ROMS = 128-0.rom 128-1.rom \ 48.rom \ - opus.rom \ plus2-0.rom plus2-1.rom \ plus3-0.rom plus3-1.rom plus3-2.rom plus3-3.rom \ plus3e-0.rom plus3e-1.rom plus3e-2.rom plus3e-3.rom \ tc2048.rom \ tc2068-0.rom tc2068-1.rom \ - gluck.rom 128p-0.rom 128p-1.rom trdos.rom \ - 256s-0.rom 256s-1.rom 256s-2.rom 256s-3.rom \ se-0.rom se-1.rom \ - if1-1.rom if1-2.rom \ plusd.rom pkgdata_DATA = $(ROMS) -EXTRA_DIST = $(ROMS) +EXTRA_DIST = $(ROMS) README.copyright Copied: trunk/fuse/roms/README.copyright (from rev 669, vendor/fuse-emulator/fuse-1.0.0a/fuse/roms/README.copyright) =================================================================== --- trunk/fuse/roms/README.copyright (rev 0) +++ trunk/fuse/roms/README.copyright 2011-04-03 11:11:05 UTC (rev 670) @@ -0,0 +1,47 @@ +Note that the files in this directory are _not_ covered by the GNU GPL. + +The following licenses apply: + +128-0.rom +128-1.rom +48.rom +plus2-0.rom +plus2-1.rom +plus3-0.rom +plus3-1.rom +plus3-2.rom +plus3-3.rom +tc2048.rom + +These are copyright Amstrad, who allow distribution of the ROMs but +retain the copyright. You may not sell the ROMs or embed the ROMs in +hardware, although it is allowed to sell a product which contains the +ROMs, so long as the charge is being made for the product, not for the +ROMs themselves. See +<http://groups.google.com/group/comp.sys.amstrad.8bit/msg/c092cc4d4943131e> +for more details. + +tc2068-0.rom +tc2068-1.rom + +These are derived from Amstrad code, so the above statement applies. The +modifications made by Timex are in the public domain. + +plus3e-0.rom +plus3e-1.rom +plus3e-2.rom +plus3e-3.rom + +These are derived from Amstrad code, so the above statement applies. The +modifications are copyright Garry Lancaster. + +se-0.rom +se-1.rom + +These are derived from Amstrad code, so the above statement applies. The +modifications are by Andrew Owen and are subject to the same conditions. + +plusd.rom + +This is copyright Datel Microelectronics, who allow distribution. See +<http://www.shadowmagic.org.uk/spectrum/datel.html> for details. Deleted: trunk/fuse/roms/gluck.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/if1-1.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/if1-2.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/opus.rom =================================================================== (Binary files differ) Deleted: trunk/fuse/roms/trdos.rom =================================================================== (Binary files differ) Modified: trunk/fuse/ui/fb/fbdisplay.c =================================================================== --- trunk/fuse/ui/fb/fbdisplay.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ui/fb/fbdisplay.c 2011-04-03 11:11:05 UTC (rev 670) @@ -2,7 +2,7 @@ Copyright (c) 2000-2003 Philip Kendall, Matan Ziv-Av, Darren Salt, Witold Filipczyk - $Id: fbdisplay.c 4205 2010-12-03 10:39:39Z fredm $ + $Id: fbdisplay.c 4206 2010-12-03 11:59:23Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by Modified: trunk/fuse/ui/widget/filesel.c =================================================================== --- trunk/fuse/ui/widget/filesel.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/fuse/ui/widget/filesel.c 2011-04-03 11:11:05 UTC (rev 670) @@ -2,7 +2,7 @@ Copyright (c) 2001-2005 Matan Ziv-Av, Philip Kendall, Russell Marks, Marek Januszewski - $Id: filesel.c 4103 2009-11-21 10:16:36Z fredm $ + $Id: filesel.c 4246 2011-01-09 20:47:53Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -64,6 +64,9 @@ int err = 0; + +char *amiga_asl( char *title, BOOL is_saving ); + #endif /* ifdef AMIGA */ struct widget_dirent **widget_filenames; /* Filenames in the current @@ -145,13 +148,21 @@ char * ui_get_open_filename( const char *title ) { +#if !defined AMIGA && !defined __MORPHOS__ return widget_get_filename( title, 0 ); +#else + return amiga_asl( title, FALSE ); +#endif } char * ui_get_save_filename( const char *title ) { +#if !defined AMIGA && !defined __MORPHOS__ return widget_get_filename( title, 1 ); +#else + return amiga_asl( title, TRUE ); +#endif } static int widget_add_filename( int *allocated, int *number, @@ -207,8 +218,8 @@ } #if defined AMIGA || defined __MORPHOS__ -static char * -amiga_asl( char *title ) { +char * +amiga_asl( char *title, BOOL is_saving ) { char *filename; struct FileRequester *filereq; @@ -499,8 +510,7 @@ /* Show all the filenames */ widget_print_all_filenames( widget_filenames, widget_numfiles, top_left_file, current_file, directory ); -#else /* ifndef AMIGA */ - amiga_asl(title); + #endif /* ifndef AMIGA */ return 0; Modified: trunk/libspectrum/config.h =================================================================== --- trunk/libspectrum/config.h 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/config.h 2011-04-03 11:11:05 UTC (rev 670) @@ -86,7 +86,7 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "1.0.0" +#define VERSION "1.0.0.1a" /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ Property changes on: trunk/libspectrum/libspectrum ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-662 + /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-667 /vendor/fuse-emulator/fuse-1.0.0a/libspectrum:668-669 Modified: trunk/libspectrum/libspectrum/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/ChangeLog 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/ChangeLog 2011-04-03 11:11:05 UTC (rev 670) @@ -310,5 +310,5 @@ * libspectrum separated from Fuse just before the 0.5.0 release of Fuse; see Fuse's ChangeLog for changes up to this point -$Id: ChangeLog 4220 2010-12-17 10:54:29Z fredm $ +$Id: ChangeLog 4212 2010-12-16 21:36:50Z pak21 $ Modified: trunk/libspectrum/libspectrum/Makefile.am =================================================================== --- trunk/libspectrum/libspectrum/Makefile.am 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/Makefile.am 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2001-2004 Philip Kendall -## $Id: Makefile.am 4220 2010-12-17 10:54:29Z fredm $ +## $Id: Makefile.am 4222 2010-12-17 18:56:50Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -53,6 +53,7 @@ tzx_write.c \ warajevo_read.c \ wav.c \ + windres.rc \ z80.c \ z80em.c \ zlib.c \ Modified: trunk/libspectrum/libspectrum/README =================================================================== --- trunk/libspectrum/libspectrum/README 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/README 2011-04-03 11:11:05 UTC (rev 670) @@ -69,4 +69,4 @@ Philip Kendall <phi...@sh...> 16 December 2010 -$Id: README 4220 2010-12-17 10:54:29Z fredm $ +$Id: README 4210 2010-12-16 21:34:52Z pak21 $ Modified: trunk/libspectrum/libspectrum/configure.in =================================================================== --- trunk/libspectrum/libspectrum/configure.in 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/configure.in 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ dnl Process this file with autoconf to produce a configure script. dnl Copyright (c) 1999-2008 Philip Kendall -dnl $Id: configure.in 4220 2010-12-17 10:54:29Z fredm $ +dnl $Id: configure.in 4210 2010-12-16 21:34:52Z pak21 $ dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by Modified: trunk/libspectrum/libspectrum/doc/libspectrum.txt =================================================================== --- trunk/libspectrum/libspectrum/doc/libspectrum.txt 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/doc/libspectrum.txt 2011-04-03 11:11:05 UTC (rev 670) @@ -1745,4 +1745,4 @@ Write `data' to register `reg' of the IDE channel `chn'. -$Id: libspectrum.txt 4220 2010-12-17 10:54:29Z fredm $ +$Id: libspectrum.txt 4193 2010-11-29 20:29:25Z pak21 $ Modified: trunk/libspectrum/libspectrum/hacking/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/hacking/ChangeLog 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/hacking/ChangeLog 2011-04-03 11:11:05 UTC (rev 670) @@ -794,3 +794,5 @@ for 1.0.0 release. 20101216 ChangeLog: update date here as well. 20101216 test/Makefile.am: ensure all test files are distributed. +20101217 Makefile.am: mark windres.rc as a source file so it is distributed + (thanks, Guesser). Modified: trunk/libspectrum/libspectrum/test/Makefile.am =================================================================== --- trunk/libspectrum/libspectrum/test/Makefile.am 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/test/Makefile.am 2011-04-03 11:11:05 UTC (rev 670) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2007 Philip Kendall -## $Id: Makefile.am 4220 2010-12-17 10:54:29Z fredm $ +## $Id: Makefile.am 4218 2010-12-16 21:56:33Z pak21 $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by Modified: trunk/libspectrum/libspectrum/warajevo_read.c =================================================================== --- trunk/libspectrum/libspectrum/warajevo_read.c 2011-04-02 12:26:20 UTC (rev 669) +++ trunk/libspectrum/libspectrum/warajevo_read.c 2011-04-03 11:11:05 UTC (rev 670) @@ -2,7 +2,7 @@ Copyright (c) 2001, 2002 Philip Kendall, Darren Salt Copyright (c) 2003 Fredrick Meunier - $Id: warajevo_read.c 4196 2010-11-30 18:45:18Z pak21 $ + $Id: warajevo_read.c 4197 2010-11-30 18:48:20Z pak21 $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2012-02-26 12:08:44
|
Revision: 687 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=687&view=rev Author: fredm Date: 2012-02-26 12:08:34 +0000 (Sun, 26 Feb 2012) Log Message: ----------- Merge up to vendor revision 4620. TODO: pokemem dialog. Revision Links: -------------- http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=4620&view=rev Modified Paths: -------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj trunk/FuseImporter/libspectrum.h trunk/audiofile/audiofile.xcodeproj/project.pbxproj trunk/fuse/AUTHORS trunk/fuse/ChangeLog trunk/fuse/Makefile.am trunk/fuse/README trunk/fuse/bitmap.h trunk/fuse/compat/amiga/Makefile.am trunk/fuse/compat/morphos/Makefile.am trunk/fuse/compat/unix/Makefile.am trunk/fuse/compat/unix/file.c trunk/fuse/compat/wii/Makefile.am trunk/fuse/compat/win32/Makefile.am trunk/fuse/compat/win32/timer.c trunk/fuse/compat.h trunk/fuse/configure.in trunk/fuse/debugger/breakpoint.c trunk/fuse/debugger/breakpoint.h trunk/fuse/debugger/commandl.l trunk/fuse/debugger/commandy.y trunk/fuse/debugger/debugger.c trunk/fuse/debugger/debugger_internals.h trunk/fuse/debugger/disassemble.c trunk/fuse/debugger/event.c trunk/fuse/display.c trunk/fuse/event.c trunk/fuse/fuse.c trunk/fuse/fusepb/Credits.html trunk/fuse/fusepb/English.lproj/InfoPlist.strings trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj trunk/fuse/fusepb/FuseMenus.m trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/config.h trunk/fuse/fusepb/controllers/DebuggerController.m trunk/fuse/fusepb/controllers/FuseController.h trunk/fuse/fusepb/controllers/FuseController.m trunk/fuse/fusepb/controllers/PokeFinderController.m trunk/fuse/fusepb/controllers/PreferencesController.h trunk/fuse/fusepb/controllers/PreferencesController.m trunk/fuse/fusepb/libspectrum.h trunk/fuse/fusepb/models/Emulator.h trunk/fuse/fusepb/models/Emulator.m trunk/fuse/fusepb/resources/Fuse Help/html/about.html trunk/fuse/fusepb/resources/Fuse Help/html/changelog.html trunk/fuse/fusepb/resources/Fuse Help/html/formats.html trunk/fuse/fusepb/resources/Fuse Help/html/machine.html trunk/fuse/fusepb/resources/Fuse Help/html/menus.html trunk/fuse/fusepb/resources/Fuse Help/html/monitor.html trunk/fuse/fusepb/resources/Fuse Help/html/peripherals.html trunk/fuse/fusepb/resources/Fuse Help/html/printer.html trunk/fuse/fusepb/resources/Fuse Help/html/tocstart.html trunk/fuse/fusepb/views/DisplayOpenGLView.h trunk/fuse/fusepb/views/DisplayOpenGLView.m trunk/fuse/fusepb/xibs/PokeFinder.xib trunk/fuse/fusepb/xibs/Preferences.xib trunk/fuse/hacking/ChangeLog trunk/fuse/hacking/tc2048_tech_notes.txt trunk/fuse/input.c trunk/fuse/keyboard.c trunk/fuse/keysyms.pl trunk/fuse/machine.c trunk/fuse/machine.h trunk/fuse/machines/Makefile.am trunk/fuse/machines/pentagon.c trunk/fuse/machines/pentagon.h trunk/fuse/machines/pentagon1024.c trunk/fuse/machines/pentagon512.c trunk/fuse/machines/scorpion.c trunk/fuse/machines/spec128.c trunk/fuse/machines/spec128.h trunk/fuse/machines/spec16.c trunk/fuse/machines/spec48.c trunk/fuse/machines/spec48.h trunk/fuse/machines/spec48_ntsc.c trunk/fuse/machines/spec_se.c trunk/fuse/machines/specplus2.c trunk/fuse/machines/specplus2a.c trunk/fuse/machines/specplus3.c trunk/fuse/machines/specplus3.h trunk/fuse/machines/specplus3e.c trunk/fuse/machines/tc2048.c trunk/fuse/machines/tc2068.c trunk/fuse/machines/tc2068.h trunk/fuse/machines/ts2068.c trunk/fuse/man/fuse.1 trunk/fuse/memory.c trunk/fuse/memory.h trunk/fuse/mempool.c trunk/fuse/mempool.h trunk/fuse/menu.c trunk/fuse/menu.h trunk/fuse/menu_data.dat trunk/fuse/periph.c trunk/fuse/periph.h trunk/fuse/pokefinder/Makefile.am trunk/fuse/roms/Makefile.am trunk/fuse/roms/README.copyright trunk/fuse/rzx.c trunk/fuse/screenshot.c trunk/fuse/screenshot.h trunk/fuse/settings.dat trunk/fuse/settings.pl trunk/fuse/snapshot.c trunk/fuse/sound/blipbuffer.c trunk/fuse/sound.c trunk/fuse/sound.h trunk/fuse/spectrum.c trunk/fuse/tape.c trunk/fuse/ui/cocoa/cocoaui.m trunk/fuse/ui/cocoa/options-header.pl trunk/fuse/ui/cocoa/options.pl trunk/fuse/ui/fb/fbdisplay.c trunk/fuse/ui/fb/fbjoystick.c trunk/fuse/ui/fb/fbui.c trunk/fuse/ui/gtk/Makefile.am trunk/fuse/ui/gtk/debugger.c trunk/fuse/ui/gtk/fileselector.c trunk/fuse/ui/gtk/gtkdisplay.c trunk/fuse/ui/gtk/gtkinternals.h trunk/fuse/ui/gtk/gtkjoystick.c trunk/fuse/ui/gtk/gtkui.c trunk/fuse/ui/gtk/options-header.pl trunk/fuse/ui/gtk/options.pl trunk/fuse/ui/gtk/picture.c trunk/fuse/ui/gtk/pokefinder.c trunk/fuse/ui/gtk/statusbar.c trunk/fuse/ui/options.dat trunk/fuse/ui/sdl/sdldisplay.c trunk/fuse/ui/sdl/sdljoystick.c trunk/fuse/ui/sdl/sdlui.c trunk/fuse/ui/svga/svgajoystick.c trunk/fuse/ui/svga/svgaui.c trunk/fuse/ui/ui.h trunk/fuse/ui/uijoystick.c trunk/fuse/ui/widget/Makefile.am trunk/fuse/ui/widget/debugger.c trunk/fuse/ui/widget/filesel.c trunk/fuse/ui/widget/menu.c trunk/fuse/ui/widget/options-header.pl trunk/fuse/ui/widget/options.pl trunk/fuse/ui/widget/pokefinder.c trunk/fuse/ui/widget/widget.c trunk/fuse/ui/widget/widget.h trunk/fuse/ui/widget/widget_internals.h trunk/fuse/ui/win32/Makefile.am trunk/fuse/ui/win32/debugger.c trunk/fuse/ui/win32/debugger.rc trunk/fuse/ui/win32/installer/fuse.nsi trunk/fuse/ui/win32/options-header.pl trunk/fuse/ui/win32/options-resource.pl trunk/fuse/ui/win32/options.pl trunk/fuse/ui/win32/picture.c trunk/fuse/ui/win32/pokefinder.c trunk/fuse/ui/win32/pokefinder.rc trunk/fuse/ui/win32/statusbar.c trunk/fuse/ui/win32/win32display.c trunk/fuse/ui/win32/win32internals.h trunk/fuse/ui/win32/win32joystick.c trunk/fuse/ui/win32/win32joystick.rc trunk/fuse/ui/win32/win32ui.c trunk/fuse/ui/xlib/xdisplay.c trunk/fuse/ui/xlib/xjoystick.c trunk/fuse/ui.c trunk/fuse/unittests/unittests.c trunk/fuse/unittests/unittests.h trunk/fuse/utils.c trunk/fuse/utils.h trunk/fuse/windres.rc trunk/fuse/z80/coretest.c trunk/fuse/z80/z80.c trunk/fuse/z80/z80_checks.h trunk/fuse/z80/z80_ops.c trunk/libspectrum/config.h trunk/libspectrum/libspectrum/ChangeLog trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/README trunk/libspectrum/libspectrum/accessor.pl trunk/libspectrum/libspectrum/configure.in trunk/libspectrum/libspectrum/doc/libspectrum.3 trunk/libspectrum/libspectrum/doc/libspectrum.txt trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/internals.h trunk/libspectrum/libspectrum/libspectrum.c trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/make-perl.c trunk/libspectrum/libspectrum/myglib/garray.c trunk/libspectrum/libspectrum/myglib/ghash.c trunk/libspectrum/libspectrum/rzx.c trunk/libspectrum/libspectrum/sna.c trunk/libspectrum/libspectrum/snap_accessors.txt trunk/libspectrum/libspectrum/snapshot.c trunk/libspectrum/libspectrum/szx.c trunk/libspectrum/libspectrum/tap.c trunk/libspectrum/libspectrum/tape.c trunk/libspectrum/libspectrum/tape_accessors.txt trunk/libspectrum/libspectrum/tape_block.c trunk/libspectrum/libspectrum/tape_block.h trunk/libspectrum/libspectrum/test/Makefile.am trunk/libspectrum/libspectrum/test/test.c trunk/libspectrum/libspectrum/test/test15.c trunk/libspectrum/libspectrum/tzx_read.c trunk/libspectrum/libspectrum/tzx_write.c trunk/libspectrum/libspectrum/warajevo_read.c trunk/libspectrum/libspectrum/wav.c trunk/libspectrum/libspectrum/z80.c trunk/libspectrum/libspectrum.h trunk/libspectrum/libspectrum.xcodeproj/project.pbxproj Added Paths: ----------- trunk/fuse/compat/unix/tuntap.c trunk/fuse/fusepb/resources/Fuse Help/html/discovery.html trunk/fuse/machines/machines_periph.c trunk/fuse/machines/machines_periph.h trunk/fuse/peripherals/ trunk/fuse/pokefinder/pokemem.c trunk/fuse/pokefinder/pokemem.h trunk/fuse/roms/speccyboot-1.4.rom trunk/fuse/ui/gtk/pokemem.c trunk/fuse/ui/widget/pokemem.c trunk/fuse/ui/win32/about.c trunk/fuse/ui/win32/about.h trunk/fuse/ui/win32/about.rc trunk/fuse/ui/win32/fuse.manifest.in trunk/fuse/ui/win32/hyperlinks.c trunk/fuse/ui/win32/hyperlinks.h trunk/fuse/ui/win32/pokemem.c trunk/fuse/ui/win32/pokemem.h trunk/fuse/ui/win32/pokemem.rc trunk/libspectrum/libspectrum/pzx_read.c trunk/libspectrum/libspectrum/utilities.c Removed Paths: ------------- trunk/fuse/ay.c trunk/fuse/ay.h trunk/fuse/dck.c trunk/fuse/dck.h trunk/fuse/disk/ trunk/fuse/fuller.c trunk/fuse/fuller.h trunk/fuse/ide/ trunk/fuse/if1.c trunk/fuse/if1.h trunk/fuse/if2.c trunk/fuse/if2.h trunk/fuse/joystick.c trunk/fuse/joystick.h trunk/fuse/kempmouse.c trunk/fuse/kempmouse.h trunk/fuse/melodik.c trunk/fuse/melodik.h trunk/fuse/printer.c trunk/fuse/printer.h trunk/fuse/scld.c trunk/fuse/scld.h trunk/fuse/ula.c trunk/fuse/ula.h Property Changed: ---------------- trunk/fuse/ trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2012-02-15 12:43:47 UTC (rev 686) +++ trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2012-02-26 12:08:34 UTC (rev 687) @@ -55,6 +55,8 @@ B6D30B480D16533C0036CC54 /* AttributeManager.c in Sources */ = {isa = PBXBuildFile; fileRef = B6D30B3E0D16533C0036CC54 /* AttributeManager.c */; }; B6D30B4C0D1653510036CC54 /* ColourMacros.c in Sources */ = {isa = PBXBuildFile; fileRef = B6D30B4A0D1653510036CC54 /* ColourMacros.c */; }; B6D30B510D1653730036CC54 /* JWSpectrumScreen.m in Sources */ = {isa = PBXBuildFile; fileRef = B6D30B4F0D1653730036CC54 /* JWSpectrumScreen.m */; }; + B6E1F13B14F511DA00600EB0 /* pzx_read.c in Sources */ = {isa = PBXBuildFile; fileRef = B6E1F13A14F511DA00600EB0 /* pzx_read.c */; }; + B6E1F13D14F511F000600EB0 /* utilities.c in Sources */ = {isa = PBXBuildFile; fileRef = B6E1F13C14F511F000600EB0 /* utilities.c */; }; C86B05270671AA6E00DD9006 /* CoreServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C86B05260671AA6E00DD9006 /* CoreServices.framework */; }; F28CFBFD0A3EC0AF000ABFF5 /* ApplicationServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F28CFBFC0A3EC0AF000ABFF5 /* ApplicationServices.framework */; }; F28CFC030A3EC0C6000ABFF5 /* QuickLook.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F28CFC020A3EC0C6000ABFF5 /* QuickLook.framework */; }; @@ -163,6 +165,8 @@ B6D30B4F0D1653730036CC54 /* JWSpectrumScreen.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = JWSpectrumScreen.m; path = JWSpectrumScreen/JWSpectrumScreen.m; sourceTree = "<group>"; }; B6D30B520D1653920036CC54 /* JWSpectrumScreenConstants.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = JWSpectrumScreenConstants.h; path = JWSpectrumScreen/JWSpectrumScreenConstants.h; sourceTree = "<group>"; }; B6D30B530D1653920036CC54 /* PixelData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PixelData.h; path = JWSpectrumScreen/PixelData.h; sourceTree = "<group>"; }; + B6E1F13A14F511DA00600EB0 /* pzx_read.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pzx_read.c; path = ../../libspectrum/libspectrum/pzx_read.c; sourceTree = "<group>"; }; + B6E1F13C14F511F000600EB0 /* utilities.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = utilities.c; path = ../../libspectrum/libspectrum/utilities.c; sourceTree = "<group>"; }; C86B05260671AA6E00DD9006 /* CoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreServices.framework; path = /System/Library/Frameworks/CoreServices.framework; sourceTree = "<absolute>"; }; F28CFBFC0A3EC0AF000ABFF5 /* ApplicationServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ApplicationServices.framework; path = /System/Library/Frameworks/ApplicationServices.framework; sourceTree = "<absolute>"; }; F28CFC020A3EC0C6000ABFF5 /* QuickLook.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuickLook.framework; path = /System/Library/Frameworks/QuickLook.framework; sourceTree = "<absolute>"; }; @@ -258,6 +262,7 @@ B67F1E7A0E93A3AF00246616 /* memory.c */, B6D30AF70D16288A0036CC54 /* microdrive.c */, B6D30AF90D1628A10036CC54 /* plusd.c */, + B6E1F13A14F511DA00600EB0 /* pzx_read.c */, B6D30AFB0D1628DB0036CC54 /* rzx.c */, B6D30AFC0D1628DB0036CC54 /* sna.c */, B6D30AFF0D1628F20036CC54 /* snapshot.c */, @@ -272,6 +277,7 @@ B6D30B110D16298C0036CC54 /* timings.c */, B6D30B130D1629C20036CC54 /* tzx_read.c */, B6D30B140D1629C20036CC54 /* tzx_write.c */, + B6E1F13C14F511F000600EB0 /* utilities.c */, B6D30B150D1629C20036CC54 /* warajevo_read.c */, B6D30B160D1629C20036CC54 /* wav.c */, B6D30B170D1629C20036CC54 /* z80.c */, @@ -358,7 +364,14 @@ isa = PBXProject; buildConfigurationList = 2CA326220896AD4900168862 /* Build configuration list for PBXProject "FuseGenerator" */; compatibilityVersion = "Xcode 3.1"; + developmentRegion = English; hasScannedForEncodings = 1; + knownRegions = ( + English, + Japanese, + French, + German, + ); mainGroup = 089C166AFE841209C02AAC07 /* FuseGenerator */; projectDirPath = ""; projectRoot = ""; @@ -439,6 +452,8 @@ B63944AB0D18B0430059DAA5 /* LibspectrumSCRExtractor.m in Sources */, B67F1E790E93A39800246616 /* garray.c in Sources */, B67F1E7B0E93A3AF00246616 /* memory.c in Sources */, + B6E1F13B14F511DA00600EB0 /* pzx_read.c in Sources */, + B6E1F13D14F511F000600EB0 /* utilities.c in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2012-02-15 12:43:47 UTC (rev 686) +++ trunk/FuseGenerator/libspectrum.h 2012-02-26 12:08:34 UTC (rev 687) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4148 2010-08-25 21:20:50Z pak21 $ + $Id: libspectrum.h.in 4534 2011-08-11 12:59:47Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -84,11 +84,12 @@ #define TRUE (!FALSE) #endif -typedef char gchar; +typedef char gchar; typedef int gint; typedef long glong; typedef gint gboolean; typedef unsigned int guint; +typedef unsigned long gulong; typedef const void * gconstpointer; typedef void * gpointer; @@ -106,80 +107,89 @@ gconstpointer b); -GSList WIN32_DLL *g_slist_insert_sorted (GSList *list, +WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); -GSList WIN32_DLL *g_slist_insert (GSList *list, +WIN32_DLL GSList *g_slist_insert (GSList *list, gpointer data, gint position); -GSList WIN32_DLL *g_slist_append (GSList *list, +WIN32_DLL GSList *g_slist_append (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_prepend (GSList *list, +WIN32_DLL GSList *g_slist_prepend (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_remove (GSList *list, +WIN32_DLL GSList *g_slist_remove (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_delete_link (GSList *list, +WIN32_DLL GSList *g_slist_last (GSList *list); + +WIN32_DLL GSList *g_slist_reverse (GSList *list); + +WIN32_DLL GSList *g_slist_delete_link (GSList *list, GSList *link); -guint WIN32_DLL g_slist_length (GSList *list); +WIN32_DLL guint g_slist_length (GSList *list); -void WIN32_DLL g_slist_foreach (GSList *list, +WIN32_DLL void g_slist_foreach (GSList *list, GFunc func, gpointer user_data); -void WIN32_DLL g_slist_free (GSList *list); +WIN32_DLL void g_slist_free (GSList *list); -GSList WIN32_DLL *g_slist_last (GSList *list); - -GSList WIN32_DLL *g_slist_reverse (GSList *list); - -GSList WIN32_DLL *g_slist_nth (GSList *list, +WIN32_DLL GSList *g_slist_nth (GSList *list, guint n); -GSList WIN32_DLL * g_slist_find_custom (GSList *list, +WIN32_DLL GSList *g_slist_find_custom (GSList *list, gpointer data, GCompareFunc func ); -gint WIN32_DLL g_slist_position (GSList *list, +WIN32_DLL gint g_slist_position (GSList *list, GSList *llink); typedef struct _GHashTable GHashTable; typedef guint (*GHashFunc) (gconstpointer key); +typedef void (*GHFunc) (gpointer key, + gpointer value, + gpointer user_data); + typedef gboolean (*GHRFunc) (gpointer key, gpointer value, gpointer user_data); -gint WIN32_DLL g_int_equal (gconstpointer v, +WIN32_DLL gint g_int_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_int_hash (gconstpointer v); -gint WIN32_DLL g_str_equal (gconstpointer v, +WIN32_DLL guint g_int_hash (gconstpointer v); + +WIN32_DLL gint g_str_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_str_hash (gconstpointer v); +WIN32_DLL guint g_str_hash (gconstpointer v); -GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, +WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); -void WIN32_DLL g_hash_table_destroy (GHashTable *hash_table); +WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); -void WIN32_DLL g_hash_table_insert (GHashTable *hash_table, +WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, gpointer key, gpointer value); -gpointer WIN32_DLL g_hash_table_lookup (GHashTable *hash_table, +WIN32_DLL gpointer g_hash_table_lookup (GHashTable *hash_table, gconstpointer key); -guint WIN32_DLL g_hash_table_foreach_remove (GHashTable *hash_table, +WIN32_DLL void g_hash_table_foreach (GHashTable *hash_table, + GHFunc func, + gpointer user_data); + +WIN32_DLL guint g_hash_table_foreach_remove (GHashTable *hash_table, GHRFunc func, gpointer user_data); -guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +WIN32_DLL guint g_hash_table_size (GHashTable *hash_table); typedef struct _GArray GArray; @@ -193,21 +203,24 @@ size_t allocated; }; -GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, - guint element_size ); +WIN32_DLL GArray* g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); #define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); -GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +WIN32_DLL GArray* g_array_append_vals( GArray *array, gconstpointer data, guint len ); #define g_array_index(a,t,i) (*(((t*)a->data)+i)) -GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +WIN32_DLL GArray* g_array_set_size( GArray *array, guint length ); +WIN32_DLL gchar* g_array_free( GArray *array, gboolean free_segment ); #include <TargetConditionals.h> #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#define GPOINTER_TO_UINT(p) ((guint) (gulong)(p)) #else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#define GPOINTER_TO_UINT(p) ((guint) (p)) #endif /* @@ -243,13 +256,21 @@ WIN32_DLL libspectrum_error libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, - libspectrum_byte **outptr, size_t *outlength ); + libspectrum_byte **outptr, size_t *outlength ); WIN32_DLL libspectrum_error libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, - libspectrum_byte **gzptr, size_t *gzlength ); + libspectrum_byte **gzptr, size_t *gzlength ); +/* we support files compressed with bz2 */ +#define LIBSPECTRUM_SUPPORTS_BZ2_COMPRESSION (1) + + +/* we support files wav files */ +#define LIBSPECTRUM_SUPPORTS_AUDIOFILE (1) + + /* Initialisation */ WIN32_DLL libspectrum_error libspectrum_init( void ); @@ -363,6 +384,10 @@ LIBSPECTRUM_ID_DISK_OPD, /* .opu/.opd Opus Discovery disk image */ + LIBSPECTRUM_ID_TAPE_PZX, /* PZX tape image */ + + LIBSPECTRUM_ID_AUX_POK, /* POKE file */ + LIBSPECTRUM_ID_SCREEN_SCR, /* .scr screen file */ } libspectrum_id_t; @@ -401,6 +426,8 @@ LIBSPECTRUM_CLASS_DISK_GENERIC, /* generic disk image */ + LIBSPECTRUM_CLASS_AUXILIARY, /* auxiliary supported file */ + LIBSPECTRUM_CLASS_SCREENSHOT, /* Screenshot */ } libspectrum_class_t; @@ -626,250 +653,284 @@ extern WIN32_DLL const int LIBSPECTRUM_JOYSTICK_INPUT_JOYSTICK_2; /* Accessor functions */ -libspectrum_machine WIN32_DLL libspectrum_snap_machine( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_machine( libspectrum_snap *snap, libspectrum_machine machine ); -libspectrum_byte WIN32_DLL libspectrum_snap_a( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_a( libspectrum_snap *snap, libspectrum_byte a ); -libspectrum_byte WIN32_DLL libspectrum_snap_f( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_f( libspectrum_snap *snap, libspectrum_byte f ); -libspectrum_word WIN32_DLL libspectrum_snap_bc( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_bc( libspectrum_snap *snap, libspectrum_word bc ); -libspectrum_word WIN32_DLL libspectrum_snap_de( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_de( libspectrum_snap *snap, libspectrum_word de ); -libspectrum_word WIN32_DLL libspectrum_snap_hl( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_hl( libspectrum_snap *snap, libspectrum_word hl ); -libspectrum_byte WIN32_DLL libspectrum_snap_a_( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_a_( libspectrum_snap *snap, libspectrum_byte a_ ); -libspectrum_byte WIN32_DLL libspectrum_snap_f_( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_f_( libspectrum_snap *snap, libspectrum_byte f_ ); -libspectrum_word WIN32_DLL libspectrum_snap_bc_( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_bc_( libspectrum_snap *snap, libspectrum_word bc_ ); -libspectrum_word WIN32_DLL libspectrum_snap_de_( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_de_( libspectrum_snap *snap, libspectrum_word de_ ); -libspectrum_word WIN32_DLL libspectrum_snap_hl_( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_hl_( libspectrum_snap *snap, libspectrum_word hl_ ); -libspectrum_word WIN32_DLL libspectrum_snap_ix( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_ix( libspectrum_snap *snap, libspectrum_word ix ); -libspectrum_word WIN32_DLL libspectrum_snap_iy( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_iy( libspectrum_snap *snap, libspectrum_word iy ); -libspectrum_byte WIN32_DLL libspectrum_snap_i( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_i( libspectrum_snap *snap, libspectrum_byte i ); -libspectrum_byte WIN32_DLL libspectrum_snap_r( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_r( libspectrum_snap *snap, libspectrum_byte r ); -libspectrum_word WIN32_DLL libspectrum_snap_sp( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_sp( libspectrum_snap *snap, libspectrum_word sp ); -libspectrum_word WIN32_DLL libspectrum_snap_pc( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_pc( libspectrum_snap *snap, libspectrum_word pc ); -libspectrum_byte WIN32_DLL libspectrum_snap_iff1( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_iff1( libspectrum_snap *snap, libspectrum_byte iff1 ); -libspectrum_byte WIN32_DLL libspectrum_snap_iff2( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_iff2( libspectrum_snap *snap, libspectrum_byte iff2 ); -libspectrum_byte WIN32_DLL libspectrum_snap_im( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_im( libspectrum_snap *snap, libspectrum_byte im ); -libspectrum_dword WIN32_DLL libspectrum_snap_tstates( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_tstates( libspectrum_snap *snap, libspectrum_dword tstates ); -int WIN32_DLL libspectrum_snap_halted( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_halted( libspectrum_snap *snap, int halted ); -int WIN32_DLL libspectrum_snap_last_instruction_ei( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_last_instruction_ei( libspectrum_snap *snap, int last_instruction_ei ); -libspectrum_byte WIN32_DLL libspectrum_snap_out_ula( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_out_ula( libspectrum_snap *snap, libspectrum_byte out_ula ); -libspectrum_byte WIN32_DLL libspectrum_snap_out_128_memoryport( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_out_128_memoryport( libspectrum_snap *snap, libspectrum_byte out_128_memoryport ); -libspectrum_byte WIN32_DLL libspectrum_snap_out_plus3_memoryport( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_out_plus3_memoryport( libspectrum_snap *snap, libspectrum_byte out_plus3_memoryport ); -libspectrum_byte WIN32_DLL libspectrum_snap_out_ay_registerport( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_out_ay_registerport( libspectrum_snap *snap, libspectrum_byte out_ay_registerport ); -libspectrum_byte WIN32_DLL libspectrum_snap_ay_registers( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_ay_registers( libspectrum_snap *snap, int idx, libspectrum_byte ay_registers ); -libspectrum_byte WIN32_DLL libspectrum_snap_out_scld_hsr( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_out_scld_hsr( libspectrum_snap *snap, libspectrum_byte out_scld_hsr ); -libspectrum_byte WIN32_DLL libspectrum_snap_out_scld_dec( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_out_scld_dec( libspectrum_snap *snap, libspectrum_byte out_scld_dec ); -int WIN32_DLL libspectrum_snap_interface1_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_interface1_active( libspectrum_snap *snap, int interface1_active ); -int WIN32_DLL libspectrum_snap_interface1_paged( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_interface1_paged( libspectrum_snap *snap, int interface1_paged ); -int WIN32_DLL libspectrum_snap_interface1_drive_count( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_interface1_drive_count( libspectrum_snap *snap, int interface1_drive_count ); -int WIN32_DLL libspectrum_snap_interface1_custom_rom( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_interface1_custom_rom( libspectrum_snap *snap, int interface1_custom_rom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_interface1_rom( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_interface1_rom( libspectrum_snap *snap, int idx, libspectrum_byte* interface1_rom ); -size_t WIN32_DLL libspectrum_snap_interface1_rom_length( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_interface1_rom_length( libspectrum_snap *snap, int idx, size_t interface1_rom_length ); -int WIN32_DLL libspectrum_snap_beta_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_active( libspectrum_snap *snap, int beta_active ); -int WIN32_DLL libspectrum_snap_beta_paged( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_paged( libspectrum_snap *snap, int beta_paged ); -int WIN32_DLL libspectrum_snap_beta_drive_count( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_drive_count( libspectrum_snap *snap, int beta_drive_count ); -int WIN32_DLL libspectrum_snap_beta_custom_rom( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_custom_rom( libspectrum_snap *snap, int beta_custom_rom ); -int WIN32_DLL libspectrum_snap_beta_direction( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_direction( libspectrum_snap *snap, int beta_direction ); -libspectrum_byte WIN32_DLL libspectrum_snap_beta_system( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_system( libspectrum_snap *snap, libspectrum_byte beta_system ); -libspectrum_byte WIN32_DLL libspectrum_snap_beta_track( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_track( libspectrum_snap *snap, libspectrum_byte beta_track ); -libspectrum_byte WIN32_DLL libspectrum_snap_beta_sector( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_sector( libspectrum_snap *snap, libspectrum_byte beta_sector ); -libspectrum_byte WIN32_DLL libspectrum_snap_beta_data( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_data( libspectrum_snap *snap, libspectrum_byte beta_data ); -libspectrum_byte WIN32_DLL libspectrum_snap_beta_status( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_beta_status( libspectrum_snap *snap, libspectrum_byte beta_status ); -libspectrum_byte WIN32_DLL * libspectrum_snap_beta_rom( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_beta_rom( libspectrum_snap *snap, int idx, libspectrum_byte* beta_rom ); -int WIN32_DLL libspectrum_snap_plusd_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_active( libspectrum_snap *snap, int plusd_active ); -int WIN32_DLL libspectrum_snap_plusd_paged( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_paged( libspectrum_snap *snap, int plusd_paged ); -int WIN32_DLL libspectrum_snap_plusd_drive_count( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_drive_count( libspectrum_snap *snap, int plusd_drive_count ); -int WIN32_DLL libspectrum_snap_plusd_custom_rom( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_custom_rom( libspectrum_snap *snap, int plusd_custom_rom ); -int WIN32_DLL libspectrum_snap_plusd_direction( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_direction( libspectrum_snap *snap, int plusd_direction ); -libspectrum_byte WIN32_DLL libspectrum_snap_plusd_control( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_control( libspectrum_snap *snap, libspectrum_byte plusd_control ); -libspectrum_byte WIN32_DLL libspectrum_snap_plusd_track( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_track( libspectrum_snap *snap, libspectrum_byte plusd_track ); -libspectrum_byte WIN32_DLL libspectrum_snap_plusd_sector( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_sector( libspectrum_snap *snap, libspectrum_byte plusd_sector ); -libspectrum_byte WIN32_DLL libspectrum_snap_plusd_data( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_data( libspectrum_snap *snap, libspectrum_byte plusd_data ); -libspectrum_byte WIN32_DLL libspectrum_snap_plusd_status( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_plusd_status( libspectrum_snap *snap, libspectrum_byte plusd_status ); -libspectrum_byte WIN32_DLL * libspectrum_snap_plusd_rom( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_plusd_rom( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_rom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_plusd_ram( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_plusd_ram( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_ram ); -int WIN32_DLL libspectrum_snap_opus_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_active( libspectrum_snap *snap, int opus_active ); -int WIN32_DLL libspectrum_snap_opus_paged( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_paged( libspectrum_snap *snap, int opus_paged ); -int WIN32_DLL libspectrum_snap_opus_drive_count( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_drive_count( libspectrum_snap *snap, int opus_drive_count ); -int WIN32_DLL libspectrum_snap_opus_custom_rom( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_custom_rom( libspectrum_snap *snap, int opus_custom_rom ); -int WIN32_DLL libspectrum_snap_opus_direction( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_direction( libspectrum_snap *snap, int opus_direction ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_track( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_track( libspectrum_snap *snap, libspectrum_byte opus_track ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_sector( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_sector( libspectrum_snap *snap, libspectrum_byte opus_sector ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_data( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_data( libspectrum_snap *snap, libspectrum_byte opus_data ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_status( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_status( libspectrum_snap *snap, libspectrum_byte opus_status ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_reg_a( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_data_reg_a( libspectrum_snap *snap, libspectrum_byte opus_data_reg_a ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_dir_a( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_data_dir_a( libspectrum_snap *snap, libspectrum_byte opus_data_dir_a ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_control_a( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_control_a( libspectrum_snap *snap, libspectrum_byte opus_control_a ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_reg_b( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_data_reg_b( libspectrum_snap *snap, libspectrum_byte opus_data_reg_b ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_data_dir_b( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_data_dir_b( libspectrum_snap *snap, libspectrum_byte opus_data_dir_b ); -libspectrum_byte WIN32_DLL libspectrum_snap_opus_control_b( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_opus_control_b( libspectrum_snap *snap, libspectrum_byte opus_control_b ); -libspectrum_byte WIN32_DLL * libspectrum_snap_opus_rom( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_opus_rom( libspectrum_snap *snap, int idx, libspectrum_byte* opus_rom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_opus_ram( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_opus_ram( libspectrum_snap *snap, int idx, libspectrum_byte* opus_ram ); -int WIN32_DLL libspectrum_snap_custom_rom( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_custom_rom( libspectrum_snap *snap, int custom_rom ); -size_t WIN32_DLL libspectrum_snap_custom_rom_pages( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_custom_rom_pages( libspectrum_snap *snap, size_t custom_rom_pages ); -libspectrum_byte WIN32_DLL * libspectrum_snap_roms( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_roms( libspectrum_snap *snap, int idx, libspectrum_byte* roms ); -size_t WIN32_DLL libspectrum_snap_rom_length( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_rom_length( libspectrum_snap *snap, int idx, size_t rom_length ); -libspectrum_byte WIN32_DLL * libspectrum_snap_pages( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_pages( libspectrum_snap *snap, int idx, libspectrum_byte* pages ); -libspectrum_byte WIN32_DLL * libspectrum_snap_slt( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_slt( libspectrum_snap *snap, int idx, libspectrum_byte* slt ); -size_t WIN32_DLL libspectrum_snap_slt_length( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_slt_length( libspectrum_snap *snap, int idx, size_t slt_length ); -libspectrum_byte WIN32_DLL * libspectrum_snap_slt_screen( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_slt_screen( libspectrum_snap *snap, libspectrum_byte* slt_screen ); -int WIN32_DLL libspectrum_snap_slt_screen_level( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_slt_screen_level( libspectrum_snap *snap, int slt_screen_level ); -int WIN32_DLL libspectrum_snap_zxatasp_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_active( libspectrum_snap *snap, int zxatasp_active ); -int WIN32_DLL libspectrum_snap_zxatasp_upload( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_upload( libspectrum_snap *snap, int zxatasp_upload ); -int WIN32_DLL libspectrum_snap_zxatasp_writeprotect( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_writeprotect( libspectrum_snap *snap, int zxatasp_writeprotect ); -libspectrum_byte WIN32_DLL libspectrum_snap_zxatasp_port_a( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_port_a( libspectrum_snap *snap, libspectrum_byte zxatasp_port_a ); -libspectrum_byte WIN32_DLL libspectrum_snap_zxatasp_port_b( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_port_b( libspectrum_snap *snap, libspectrum_byte zxatasp_port_b ); -libspectrum_byte WIN32_DLL libspectrum_snap_zxatasp_port_c( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_port_c( libspectrum_snap *snap, libspectrum_byte zxatasp_port_c ); -libspectrum_byte WIN32_DLL libspectrum_snap_zxatasp_control( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_control( libspectrum_snap *snap, libspectrum_byte zxatasp_control ); -size_t WIN32_DLL libspectrum_snap_zxatasp_pages( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_pages( libspectrum_snap *snap, size_t zxatasp_pages ); -size_t WIN32_DLL libspectrum_snap_zxatasp_current_page( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxatasp_current_page( libspectrum_snap *snap, size_t zxatasp_current_page ); -libspectrum_byte WIN32_DLL * libspectrum_snap_zxatasp_ram( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_zxatasp_ram( libspectrum_snap *snap, int idx, libspectrum_byte* zxatasp_ram ); -int WIN32_DLL libspectrum_snap_zxcf_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxcf_active( libspectrum_snap *snap, int zxcf_active ); -int WIN32_DLL libspectrum_snap_zxcf_upload( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxcf_upload( libspectrum_snap *snap, int zxcf_upload ); -libspectrum_byte WIN32_DLL libspectrum_snap_zxcf_memctl( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxcf_memctl( libspectrum_snap *snap, libspectrum_byte zxcf_memctl ); -size_t WIN32_DLL libspectrum_snap_zxcf_pages( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_zxcf_pages( libspectrum_snap *snap, size_t zxcf_pages ); -libspectrum_byte WIN32_DLL * libspectrum_snap_zxcf_ram( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_zxcf_ram( libspectrum_snap *snap, int idx, libspectrum_byte* zxcf_ram ); -int WIN32_DLL libspectrum_snap_interface2_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_interface2_active( libspectrum_snap *snap, int interface2_active ); -libspectrum_byte WIN32_DLL * libspectrum_snap_interface2_rom( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_interface2_rom( libspectrum_snap *snap, int idx, libspectrum_byte* interface2_rom ); -int WIN32_DLL libspectrum_snap_dock_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_dock_active( libspectrum_snap *snap, int dock_active ); -libspectrum_byte WIN32_DLL libspectrum_snap_exrom_ram( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_exrom_ram( libspectrum_snap *snap, int idx, libspectrum_byte exrom_ram ); -libspectrum_byte WIN32_DLL * libspectrum_snap_exrom_cart( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_exrom_cart( libspectrum_snap *snap, int idx, libspectrum_byte* exrom_cart ); -libspectrum_byte WIN32_DLL libspectrum_snap_dock_ram( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_dock_ram( libspectrum_snap *snap, int idx, libspectrum_byte dock_ram ); -libspectrum_byte WIN32_DLL * libspectrum_snap_dock_cart( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_dock_cart( libspectrum_snap *snap, int idx, libspectrum_byte* dock_cart ); -int WIN32_DLL libspectrum_snap_issue2( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_issue2( libspectrum_snap *snap, int issue2 ); -size_t WIN32_DLL libspectrum_snap_joystick_active_count( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_joystick_active_count( libspectrum_snap *snap, size_t joystick_active_count ); -libspectrum_joystick WIN32_DLL libspectrum_snap_joystick_list( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_joystick_list( libspectrum_snap *snap, int idx, libspectrum_joystick joystick_list ); -int WIN32_DLL libspectrum_snap_joystick_inputs( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_joystick_inputs( libspectrum_snap *snap, int idx, int joystick_inputs ); -int WIN32_DLL libspectrum_snap_kempston_mouse_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_kempston_mouse_active( libspectrum_snap *snap, int kempston_mouse_active ); -int WIN32_DLL libspectrum_snap_simpleide_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_simpleide_active( libspectrum_snap *snap, int simpleide_active ); -int WIN32_DLL libspectrum_snap_divide_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_divide_active( libspectrum_snap *snap, int divide_active ); -int WIN32_DLL libspectrum_snap_divide_eprom_writeprotect( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_divide_eprom_writeprotect( libspectrum_snap *snap, int divide_eprom_writeprotect ); -int WIN32_DLL libspectrum_snap_divide_paged( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_divide_paged( libspectrum_snap *snap, int divide_paged ); -libspectrum_byte WIN32_DLL libspectrum_snap_divide_control( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_divide_control( libspectrum_snap *snap, libspectrum_byte divide_control ); -size_t WIN32_DLL libspectrum_snap_divide_pages( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_divide_pages( libspectrum_snap *snap, size_t divide_pages ); -libspectrum_byte WIN32_DLL * libspectrum_snap_divide_eprom( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_divide_eprom( libspectrum_snap *snap, int idx, libspectrum_byte* divide_eprom ); -libspectrum_byte WIN32_DLL * libspectrum_snap_divide_ram( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_divide_ram( libspectrum_snap *snap, int idx, libspectrum_byte* divide_ram ); -int WIN32_DLL libspectrum_snap_fuller_box_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_fuller_box_active( libspectrum_snap *snap, int fuller_box_active ); -int WIN32_DLL libspectrum_snap_melodik_active( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_melodik_active( libspectrum_snap *snap, int melodik_active ); +WIN32_DLL libspectrum_machine libspectrum_snap_machine( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_machine( libspectrum_snap *snap, libspectrum_machine machine ); +WIN32_DLL libspectrum_byte libspectrum_snap_a( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_a( libspectrum_snap *snap, libspectrum_byte a ); +WIN32_DLL libspectrum_byte libspectrum_snap_f( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_f( libspectrum_snap *snap, libspectrum_byte f ); +WIN32_DLL libspectrum_word libspectrum_snap_bc( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_bc( libspectrum_snap *snap, libspectrum_word bc ); +WIN32_DLL libspectrum_word libspectrum_snap_de( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_de( libspectrum_snap *snap, libspectrum_word de ); +WIN32_DLL libspectrum_word libspectrum_snap_hl( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_hl( libspectrum_snap *snap, libspectrum_word hl ); +WIN32_DLL libspectrum_byte libspectrum_snap_a_( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_a_( libspectrum_snap *snap, libspectrum_byte a_ ); +WIN32_DLL libspectrum_byte libspectrum_snap_f_( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_f_( libspectrum_snap *snap, libspectrum_byte f_ ); +WIN32_DLL libspectrum_word libspectrum_snap_bc_( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_bc_( libspectrum_snap *snap, libspectrum_word bc_ ); +WIN32_DLL libspectrum_word libspectrum_snap_de_( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_de_( libspectrum_snap *snap, libspectrum_word de_ ); +WIN32_DLL libspectrum_word libspectrum_snap_hl_( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_hl_( libspectrum_snap *snap, libspectrum_word hl_ ); +WIN32_DLL libspectrum_word libspectrum_snap_ix( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_ix( libspectrum_snap *snap, libspectrum_word ix ); +WIN32_DLL libspectrum_word libspectrum_snap_iy( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_iy( libspectrum_snap *snap, libspectrum_word iy ); +WIN32_DLL libspectrum_byte libspectrum_snap_i( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_i( libspectrum_snap *snap, libspectrum_byte i ); +WIN32_DLL libspectrum_byte libspectrum_snap_r( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_r( libspectrum_snap *snap, libspectrum_byte r ); +WIN32_DLL libspectrum_word libspectrum_snap_sp( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_sp( libspectrum_snap *snap, libspectrum_word sp ); +WIN32_DLL libspectrum_word libspectrum_snap_pc( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_pc( libspectrum_snap *snap, libspectrum_word pc ); +WIN32_DLL libspectrum_byte libspectrum_snap_iff1( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_iff1( libspectrum_snap *snap, libspectrum_byte iff1 ); +WIN32_DLL libspectrum_byte libspectrum_snap_iff2( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_iff2( libspectrum_snap *snap, libspectrum_byte iff2 ); +WIN32_DLL libspectrum_byte libspectrum_snap_im( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_im( libspectrum_snap *snap, libspectrum_byte im ); +WIN32_DLL libspectrum_dword libspectrum_snap_tstates( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_tstates( libspectrum_snap *snap, libspectrum_dword tstates ); +WIN32_DLL int libspectrum_snap_halted( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_halted( libspectrum_snap *snap, int halted ); +WIN32_DLL int libspectrum_snap_last_instruction_ei( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_last_instruction_ei( libspectrum_snap *snap, int last_instruction_ei ); +WIN32_DLL libspectrum_byte libspectrum_snap_out_ula( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_out_ula( libspectrum_snap *snap, libspectrum_byte out_ula ); +WIN32_DLL libspectrum_byte libspectrum_snap_out_128_memoryport( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_out_128_memoryport( libspectrum_snap *snap, libspectrum_byte out_128_memoryport ); +WIN32_DLL libspectrum_byte libspectrum_snap_out_plus3_memoryport( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_out_plus3_memoryport( libspectrum_snap *snap, libspectrum_byte out_plus3_memoryport ); +WIN32_DLL libspectrum_byte libspectrum_snap_out_ay_registerport( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_out_ay_registerport( libspectrum_snap *snap, libspectrum_byte out_ay_registerport ); +WIN32_DLL libspectrum_byte libspectrum_snap_ay_registers( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_ay_registers( libspectrum_snap *snap, int idx, libspectrum_byte ay_registers ); +WIN32_DLL libspectrum_byte libspectrum_snap_out_scld_hsr( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_out_scld_hsr( libspectrum_snap *snap, libspectrum_byte out_scld_hsr ); +WIN32_DLL libspectrum_byte libspectrum_snap_out_scld_dec( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_out_scld_dec( libspectrum_snap *snap, libspectrum_byte out_scld_dec ); +WIN32_DLL int libspectrum_snap_interface1_active( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_interface1_active( libspectrum_snap *snap, int interface1_active ); +WIN32_DLL int libspectrum_snap_interface1_paged( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_interface1_paged( libspectrum_snap *snap, int interface1_paged ); +WIN32_DLL int libspectrum_snap_interface1_drive_count( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_interface1_drive_count( libspectrum_snap *snap, int interface1_drive_count ); +WIN32_DLL int libspectrum_snap_interface1_custom_rom( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_interface1_custom_rom( libspectrum_snap *snap, int interface1_custom_rom ); +WIN32_DLL libspectrum_byte * libspectrum_snap_interface1_rom( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_interface1_rom( libspectrum_snap *snap, int idx, libspectrum_byte* interface1_rom ); +WIN32_DLL size_t libspectrum_snap_interface1_rom_length( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_interface1_rom_length( libspectrum_snap *snap, int idx, size_t interface1_rom_length ); +WIN32_DLL int libspectrum_snap_beta_active( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_active( libspectrum_snap *snap, int beta_active ); +WIN32_DLL int libspectrum_snap_beta_paged( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_paged( libspectrum_snap *snap, int beta_paged ); +WIN32_DLL int libspectrum_snap_beta_autoboot( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_autoboot( libspectrum_snap *snap, int beta_autoboot ); +WIN32_DLL int libspectrum_snap_beta_drive_count( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_drive_count( libspectrum_snap *snap, int beta_drive_count ); +WIN32_DLL int libspectrum_snap_beta_custom_rom( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_custom_rom( libspectrum_snap *snap, int beta_custom_rom ); +WIN32_DLL int libspectrum_snap_beta_direction( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_direction( libspectrum_snap *snap, int beta_direction ); +WIN32_DLL libspectrum_byte libspectrum_snap_beta_system( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_system( libspectrum_snap *snap, libspectrum_byte beta_system ); +WIN32_DLL libspectrum_byte libspectrum_snap_beta_track( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_track( libspectrum_snap *snap, libspectrum_byte beta_track ); +WIN32_DLL libspectrum_byte libspectrum_snap_beta_sector( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_sector( libspectrum_snap *snap, libspectrum_byte beta_sector ); +WIN32_DLL libspectrum_byte libspectrum_snap_beta_data( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_data( libspectrum_snap *snap, libspectrum_byte beta_data ); +WIN32_DLL libspectrum_byte libspectrum_snap_beta_status( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_beta_status( libspectrum_snap *snap, libspectrum_byte beta_status ); +WIN32_DLL libspectrum_byte * libspectrum_snap_beta_rom( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_beta_rom( libspectrum_snap *snap, int idx, libspectrum_byte* beta_rom ); +WIN32_DLL int libspectrum_snap_plusd_active( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_active( libspectrum_snap *snap, int plusd_active ); +WIN32_DLL int libspectrum_snap_plusd_paged( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_paged( libspectrum_snap *snap, int plusd_paged ); +WIN32_DLL int libspectrum_snap_plusd_drive_count( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_drive_count( libspectrum_snap *snap, int plusd_drive_count ); +WIN32_DLL int libspectrum_snap_plusd_custom_rom( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_custom_rom( libspectrum_snap *snap, int plusd_custom_rom ); +WIN32_DLL int libspectrum_snap_plusd_direction( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_direction( libspectrum_snap *snap, int plusd_direction ); +WIN32_DLL libspectrum_byte libspectrum_snap_plusd_control( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_control( libspectrum_snap *snap, libspectrum_byte plusd_control ); +WIN32_DLL libspectrum_byte libspectrum_snap_plusd_track( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_track( libspectrum_snap *snap, libspectrum_byte plusd_track ); +WIN32_DLL libspectrum_byte libspectrum_snap_plusd_sector( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_sector( libspectrum_snap *snap, libspectrum_byte plusd_sector ); +WIN32_DLL libspectrum_byte libspectrum_snap_plusd_data( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_data( libspectrum_snap *snap, libspectrum_byte plusd_data ); +WIN32_DLL libspectrum_byte libspectrum_snap_plusd_status( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_plusd_status( libspectrum_snap *snap, libspectrum_byte plusd_status ); +WIN32_DLL libspectrum_byte * libspectrum_snap_plusd_rom( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_plusd_rom( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_rom ); +WIN32_DLL libspectrum_byte * libspectrum_snap_plusd_ram( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_plusd_ram( libspectrum_snap *snap, int idx, libspectrum_byte* plusd_ram ); +WIN32_DLL int libspectrum_snap_opus_active( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_active( libspectrum_snap *snap, int opus_active ); +WIN32_DLL int libspectrum_snap_opus_paged( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_paged( libspectrum_snap *snap, int opus_paged ); +WIN32_DLL int libspectrum_snap_opus_drive_count( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_drive_count( libspectrum_snap *snap, int opus_drive_count ); +WIN32_DLL int libspectrum_snap_opus_custom_rom( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_custom_rom( libspectrum_snap *snap, int opus_custom_rom ); +WIN32_DLL int libspectrum_snap_opus_direction( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_direction( libspectrum_snap *snap, int opus_direction ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_track( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_track( libspectrum_snap *snap, libspectrum_byte opus_track ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_sector( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_sector( libspectrum_snap *snap, libspectrum_byte opus_sector ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_data( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_data( libspectrum_snap *snap, libspectrum_byte opus_data ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_status( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_status( libspectrum_snap *snap, libspectrum_byte opus_status ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_data_reg_a( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_data_reg_a( libspectrum_snap *snap, libspectrum_byte opus_data_reg_a ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_data_dir_a( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_data_dir_a( libspectrum_snap *snap, libspectrum_byte opus_data_dir_a ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_control_a( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_control_a( libspectrum_snap *snap, libspectrum_byte opus_control_a ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_data_reg_b( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_data_reg_b( libspectrum_snap *snap, libspectrum_byte opus_data_reg_b ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_data_dir_b( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_data_dir_b( libspectrum_snap *snap, libspectrum_byte opus_data_dir_b ); +WIN32_DLL libspectrum_byte libspectrum_snap_opus_control_b( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_opus_control_b( libspectrum_snap *snap, libspectrum_byte opus_control_b ); +WIN32_DLL libspectrum_byte * libspectrum_snap_opus_rom( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_opus_rom( libspectrum_snap *snap, int idx, libspectrum_byte* opus_rom ); +WIN32_DLL libspectrum_byte * libspectrum_snap_opus_ram( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_opus_ram( libspectrum_snap *snap, int idx, libspectrum_byte* opus_ram ); +WIN32_DLL int libspectrum_snap_custom_rom( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_custom_rom( libspectrum_snap *snap, int custom_rom ); +WIN32_DLL size_t libspectrum_snap_custom_rom_pages( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_custom_rom_pages( libspectrum_snap *snap, size_t custom_rom_pages ); +WIN32_DLL libspectrum_byte * libspectrum_snap_roms( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_roms( libspectrum_snap *snap, int idx, libspectrum_byte* roms ); +WIN32_DLL size_t libspectrum_snap_rom_length( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_rom_length( libspectrum_snap *snap, int idx, size_t rom_length ); +WIN32_DLL libspectrum_byte * libspectrum_snap_pages( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_pages( libspectrum_snap *snap, int idx, libspectrum_byte* pages ); +WIN32_DLL libspectrum_byte * libspectrum_snap_slt( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_slt( libspectrum_snap *snap, int idx, libspectrum_byte* slt ); +WIN32_DLL size_t libspectrum_snap_slt_length( libspectrum_snap *snap, int idx ); +WIN32_DLL void libspectrum_snap_set_slt_length( libspectrum_snap *snap, int idx, size_t slt_length ); +WIN32_DLL libspectrum_byte * libspectrum_snap_slt_screen( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_slt_screen( libspectrum_snap *snap, libspectrum_byte* slt_screen ); +WIN32_DLL int libspectrum_snap_slt_screen_level( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_slt_screen_level( libspectrum_snap *snap, int slt_screen_level ); +WIN32_DLL int libspectrum_snap_zxatasp_active( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_zxatasp_active( libspectrum_snap *snap, int zxatasp_active ); +WIN32_DLL int libspectrum_snap_zxatasp_upload( libspectrum_snap *snap ); +WIN32_DLL void libspectrum_snap_set_zxatasp_upload( libspectrum_snap *snap, int zxatasp_upload ); +WIN32_DLL int libspectrum_snap_zxatasp_writeprotect(... [truncated message content] |
From: <fr...@us...> - 2012-06-19 13:23:09
|
Revision: 689 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=689&view=rev Author: fredm Date: 2012-06-19 13:23:03 +0000 (Tue, 19 Jun 2012) Log Message: ----------- Add platform references for PZX files. Modified Paths: -------------- trunk/FuseGenerator/Info.plist trunk/FuseImporter/Info.plist trunk/FuseImporter/schema.xml trunk/fuse/fusepb/Info-Fuse.plist trunk/fuse/fusepb/controllers/FuseController.m Modified: trunk/FuseGenerator/Info.plist =================================================================== --- trunk/FuseGenerator/Info.plist 2012-02-26 12:10:41 UTC (rev 688) +++ trunk/FuseGenerator/Info.plist 2012-06-19 13:23:03 UTC (rev 689) @@ -26,6 +26,7 @@ <string>net.sourceforge.projects.fuse-emulator.mgtsnp</string> <string>net.sourceforge.projects.fuse-emulator.opd</string> <string>net.sourceforge.projects.fuse-emulator.opu</string> + <string>net.sourceforge.projects.fuse-emulator.pzx</string> <string>net.sourceforge.projects.fuse-emulator.raw</string> <string>net.sourceforge.projects.fuse-emulator.rzx</string> <string>net.sourceforge.projects.fuse-emulator.scl</string> Modified: trunk/FuseImporter/Info.plist =================================================================== --- trunk/FuseImporter/Info.plist 2012-02-26 12:10:41 UTC (rev 688) +++ trunk/FuseImporter/Info.plist 2012-06-19 13:23:03 UTC (rev 689) @@ -28,6 +28,7 @@ <string>net.sourceforge.projects.fuse-emulator.mgtsnp</string> <string>net.sourceforge.projects.fuse-emulator.opd</string> <string>net.sourceforge.projects.fuse-emulator.opu</string> + <string>net.sourceforge.projects.fuse-emulator.pzx</string> <string>net.sourceforge.projects.fuse-emulator.raw</string> <string>net.sourceforge.projects.fuse-emulator.rzx</string> <string>net.sourceforge.projects.fuse-emulator.scl</string> @@ -615,6 +616,23 @@ </array> </dict> </dict> + <dict> + <key>UTTypeConformsTo</key> + <array> + <string>net.sourceforge.projects.fuse-emulator.Tape</string> + </array> + <key>UTTypeDescription</key> + <string>ZX Spectrum PZX Tape Image</string> + <key>UTTypeIdentifier</key> + <string>net.sourceforge.projects.fuse-emulator.pzx</string> + <key>UTTypeReferenceURL</key> + <string>http://zxds.raxoft.cz/pzx.html</string> + <key>UTTypeTagSpecification</key> + <dict> + <key>public.filename-extension</key> + <string>pzx</string> + </dict> + </dict> </array> </dict> </plist> Modified: trunk/FuseImporter/schema.xml =================================================================== --- trunk/FuseImporter/schema.xml 2012-02-26 12:10:41 UTC (rev 688) +++ trunk/FuseImporter/schema.xml 2012-06-19 13:23:03 UTC (rev 689) @@ -44,6 +44,32 @@ net_sourceforge_projects_fuse_emulator_Peripherals </previewattrs> </type> + <type name="net.sourceforge.projects.fuse-emulator.pzx"> + <allattrs> + net_sourceforge_projects_fuse_emulator_Category + net_sourceforge_projects_fuse_emulator_Price + net_sourceforge_projects_fuse_emulator_Loader + net_sourceforge_projects_fuse_emulator_Origin + net_sourceforge_projects_fuse_emulator_Machines + net_sourceforge_projects_fuse_emulator_Peripherals + </allattrs> + <displayattrs> + net_sourceforge_projects_fuse_emulator_Category + net_sourceforge_projects_fuse_emulator_Price + net_sourceforge_projects_fuse_emulator_Loader + net_sourceforge_projects_fuse_emulator_Origin + net_sourceforge_projects_fuse_emulator_Machines + net_sourceforge_projects_fuse_emulator_Peripherals + </displayattrs> + <previewattrs> + net_sourceforge_projects_fuse_emulator_Category + net_sourceforge_projects_fuse_emulator_Price + net_sourceforge_projects_fuse_emulator_Loader + net_sourceforge_projects_fuse_emulator_Origin + net_sourceforge_projects_fuse_emulator_Machines + net_sourceforge_projects_fuse_emulator_Peripherals + </previewattrs> + </type> <type name="net.sourceforge.projects.fuse-emulator.Snapshot"> <allattrs> net_sourceforge_projects_fuse_emulator_Machines Modified: trunk/fuse/fusepb/Info-Fuse.plist =================================================================== --- trunk/fuse/fusepb/Info-Fuse.plist 2012-02-26 12:10:41 UTC (rev 688) +++ trunk/fuse/fusepb/Info-Fuse.plist 2012-06-19 13:23:03 UTC (rev 689) @@ -289,6 +289,27 @@ <dict> <key>CFBundleTypeExtensions</key> <array> + <string>pzx</string> + <string>PZX</string> + </array> + <key>CFBundleTypeIconFile</key> + <string>blank</string> + <key>CFBundleTypeName</key> + <string>ZX Spectrum Tape Image</string> + <key>CFBundleTypeRole</key> + <string>Viewer</string> + <key>LSItemContentTypes</key> + <array> + <string>net.sourceforge.projects.fuse-emulator.pzx</string> + </array> + <key>LSTypeIsPackage</key> + <false/> + <key>NSPersistentStoreTypeKey</key> + <string>Binary</string> + </dict> + <dict> + <key>CFBundleTypeExtensions</key> + <array> <string>tzx</string> <string>TZX</string> </array> Modified: trunk/fuse/fusepb/controllers/FuseController.m =================================================================== --- trunk/fuse/fusepb/controllers/FuseController.m 2012-02-26 12:10:41 UTC (rev 688) +++ trunk/fuse/fusepb/controllers/FuseController.m 2012-06-19 13:23:03 UTC (rev 689) @@ -228,9 +228,10 @@ scrFileType = [NSMutableArray arrayWithObjects:@"scr", @"SCR", nil]; [scrFileType retain]; - tapeFileTypes = [NSMutableArray arrayWithObjects:@"csw", @"ltp", @"raw", - @"spc", @"sta", @"tap", @"tzx", @"wav", @"CSW", @"LTP", - @"RAW", @"SPC", @"STA", @"TAP", @"TZX", @"WAV", nil]; + tapeFileTypes = [NSMutableArray arrayWithObjects:@"csw", @"ltp", @"pzx", + @"raw", @"spc", @"sta", @"tap", @"tzx", @"wav", @"CSW", + @"LTP", @"PZX", @"RAW", @"SPC", @"STA", @"TAP", @"TZX", + @"WAV", nil]; [tapeFileTypes retain]; plus3FileTypes = [NSMutableArray arrayWithObjects:@"dsk", @"DSK", nil]; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2012-10-29 12:01:43
|
Revision: 691 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=691&view=rev Author: fredm Date: 2012-10-29 12:01:33 +0000 (Mon, 29 Oct 2012) Log Message: ----------- Bring the libspectrum.h generator scripts up to date. Modified Paths: -------------- trunk/FuseGenerator/generate.pl trunk/FuseImporter/generate.pl trunk/fuse/fusepb/generate.pl trunk/libspectrum/generate.pl Modified: trunk/FuseGenerator/generate.pl =================================================================== --- trunk/FuseGenerator/generate.pl 2012-10-07 11:05:44 UTC (rev 690) +++ trunk/FuseGenerator/generate.pl 2012-10-29 12:01:33 UTC (rev 691) @@ -25,11 +25,12 @@ #define TRUE (!FALSE) #endif -typedef char gchar; +typedef char gchar; typedef int gint; typedef long glong; typedef gint gboolean; typedef unsigned int guint; +typedef unsigned long gulong; typedef const void * gconstpointer; typedef void * gpointer; @@ -47,80 +48,89 @@ gconstpointer b); -GSList WIN32_DLL *g_slist_insert_sorted (GSList *list, +WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); -GSList WIN32_DLL *g_slist_insert (GSList *list, +WIN32_DLL GSList *g_slist_insert (GSList *list, gpointer data, gint position); -GSList WIN32_DLL *g_slist_append (GSList *list, +WIN32_DLL GSList *g_slist_append (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_prepend (GSList *list, +WIN32_DLL GSList *g_slist_prepend (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_remove (GSList *list, +WIN32_DLL GSList *g_slist_remove (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_delete_link (GSList *list, +WIN32_DLL GSList *g_slist_last (GSList *list); + +WIN32_DLL GSList *g_slist_reverse (GSList *list); + +WIN32_DLL GSList *g_slist_delete_link (GSList *list, GSList *link); -guint WIN32_DLL g_slist_length (GSList *list); +WIN32_DLL guint g_slist_length (GSList *list); -void WIN32_DLL g_slist_foreach (GSList *list, +WIN32_DLL void g_slist_foreach (GSList *list, GFunc func, gpointer user_data); -void WIN32_DLL g_slist_free (GSList *list); +WIN32_DLL void g_slist_free (GSList *list); -GSList WIN32_DLL *g_slist_last (GSList *list); - -GSList WIN32_DLL *g_slist_reverse (GSList *list); - -GSList WIN32_DLL *g_slist_nth (GSList *list, +WIN32_DLL GSList *g_slist_nth (GSList *list, guint n); -GSList WIN32_DLL * g_slist_find_custom (GSList *list, +WIN32_DLL GSList *g_slist_find_custom (GSList *list, gpointer data, GCompareFunc func ); -gint WIN32_DLL g_slist_position (GSList *list, +WIN32_DLL gint g_slist_position (GSList *list, GSList *llink); typedef struct _GHashTable GHashTable; typedef guint (*GHashFunc) (gconstpointer key); +typedef void (*GHFunc) (gpointer key, + gpointer value, + gpointer user_data); + typedef gboolean (*GHRFunc) (gpointer key, gpointer value, gpointer user_data); -gint WIN32_DLL g_int_equal (gconstpointer v, +WIN32_DLL gint g_int_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_int_hash (gconstpointer v); -gint WIN32_DLL g_str_equal (gconstpointer v, +WIN32_DLL guint g_int_hash (gconstpointer v); + +WIN32_DLL gint g_str_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_str_hash (gconstpointer v); +WIN32_DLL guint g_str_hash (gconstpointer v); -GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, +WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); -void WIN32_DLL g_hash_table_destroy (GHashTable *hash_table); +WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); -void WIN32_DLL g_hash_table_insert (GHashTable *hash_table, +WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, gpointer key, gpointer value); -gpointer WIN32_DLL g_hash_table_lookup (GHashTable *hash_table, +WIN32_DLL gpointer g_hash_table_lookup (GHashTable *hash_table, gconstpointer key); -guint WIN32_DLL g_hash_table_foreach_remove (GHashTable *hash_table, +WIN32_DLL void g_hash_table_foreach (GHashTable *hash_table, + GHFunc func, + gpointer user_data); + +WIN32_DLL guint g_hash_table_foreach_remove (GHashTable *hash_table, GHRFunc func, gpointer user_data); -guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +WIN32_DLL guint g_hash_table_size (GHashTable *hash_table); typedef struct _GArray GArray; @@ -134,21 +144,24 @@ size_t allocated; }; -GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, - guint element_size ); +WIN32_DLL GArray* g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); #define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); -GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +WIN32_DLL GArray* g_array_append_vals( GArray *array, gconstpointer data, guint len ); #define g_array_index(a,t,i) (*(((t*)a->data)+i)) -GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +WIN32_DLL GArray* g_array_set_size( GArray *array, guint length ); +WIN32_DLL gchar* g_array_free( GArray *array, gboolean free_segment ); #include <TargetConditionals.h> - + #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#define GPOINTER_TO_UINT(p) ((guint) (gulong)(p)) #else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#define GPOINTER_TO_UINT(p) ((guint) (p)) #endif CODE } @@ -177,18 +190,18 @@ WIN32_DLL libspectrum_error libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, - libspectrum_byte **outptr, size_t *outlength ); + libspectrum_byte **outptr, size_t *outlength ); WIN32_DLL libspectrum_error libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, - libspectrum_byte **gzptr, size_t *gzlength ); + libspectrum_byte **gzptr, size_t *gzlength ); CODE } if( /LIBSPECTRUM_SNAP_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; $_ = ''; while( <DATAFILE> ) { @@ -199,23 +212,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); CODE } else { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); CODE } @@ -224,7 +237,7 @@ if( /LIBSPECTRUM_TAPE_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/tape_accessors.txt': $!"; $_ = ''; @@ -241,23 +254,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block, size_t idx ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); CODE } else { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); CODE } Modified: trunk/FuseImporter/generate.pl =================================================================== --- trunk/FuseImporter/generate.pl 2012-10-07 11:05:44 UTC (rev 690) +++ trunk/FuseImporter/generate.pl 2012-10-29 12:01:33 UTC (rev 691) @@ -25,11 +25,12 @@ #define TRUE (!FALSE) #endif -typedef char gchar; +typedef char gchar; typedef int gint; typedef long glong; typedef gint gboolean; typedef unsigned int guint; +typedef unsigned long gulong; typedef const void * gconstpointer; typedef void * gpointer; @@ -47,80 +48,89 @@ gconstpointer b); -GSList WIN32_DLL *g_slist_insert_sorted (GSList *list, +WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); -GSList WIN32_DLL *g_slist_insert (GSList *list, +WIN32_DLL GSList *g_slist_insert (GSList *list, gpointer data, gint position); -GSList WIN32_DLL *g_slist_append (GSList *list, +WIN32_DLL GSList *g_slist_append (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_prepend (GSList *list, +WIN32_DLL GSList *g_slist_prepend (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_remove (GSList *list, +WIN32_DLL GSList *g_slist_remove (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_delete_link (GSList *list, +WIN32_DLL GSList *g_slist_last (GSList *list); + +WIN32_DLL GSList *g_slist_reverse (GSList *list); + +WIN32_DLL GSList *g_slist_delete_link (GSList *list, GSList *link); -guint WIN32_DLL g_slist_length (GSList *list); +WIN32_DLL guint g_slist_length (GSList *list); -void WIN32_DLL g_slist_foreach (GSList *list, +WIN32_DLL void g_slist_foreach (GSList *list, GFunc func, gpointer user_data); -void WIN32_DLL g_slist_free (GSList *list); +WIN32_DLL void g_slist_free (GSList *list); -GSList WIN32_DLL *g_slist_last (GSList *list); - -GSList WIN32_DLL *g_slist_reverse (GSList *list); - -GSList WIN32_DLL *g_slist_nth (GSList *list, +WIN32_DLL GSList *g_slist_nth (GSList *list, guint n); -GSList WIN32_DLL * g_slist_find_custom (GSList *list, +WIN32_DLL GSList *g_slist_find_custom (GSList *list, gpointer data, GCompareFunc func ); -gint WIN32_DLL g_slist_position (GSList *list, +WIN32_DLL gint g_slist_position (GSList *list, GSList *llink); typedef struct _GHashTable GHashTable; typedef guint (*GHashFunc) (gconstpointer key); +typedef void (*GHFunc) (gpointer key, + gpointer value, + gpointer user_data); + typedef gboolean (*GHRFunc) (gpointer key, gpointer value, gpointer user_data); -gint WIN32_DLL g_int_equal (gconstpointer v, +WIN32_DLL gint g_int_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_int_hash (gconstpointer v); -gint WIN32_DLL g_str_equal (gconstpointer v, +WIN32_DLL guint g_int_hash (gconstpointer v); + +WIN32_DLL gint g_str_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_str_hash (gconstpointer v); +WIN32_DLL guint g_str_hash (gconstpointer v); -GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, +WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); -void WIN32_DLL g_hash_table_destroy (GHashTable *hash_table); +WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); -void WIN32_DLL g_hash_table_insert (GHashTable *hash_table, +WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, gpointer key, gpointer value); -gpointer WIN32_DLL g_hash_table_lookup (GHashTable *hash_table, +WIN32_DLL gpointer g_hash_table_lookup (GHashTable *hash_table, gconstpointer key); -guint WIN32_DLL g_hash_table_foreach_remove (GHashTable *hash_table, +WIN32_DLL void g_hash_table_foreach (GHashTable *hash_table, + GHFunc func, + gpointer user_data); + +WIN32_DLL guint g_hash_table_foreach_remove (GHashTable *hash_table, GHRFunc func, gpointer user_data); -guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +WIN32_DLL guint g_hash_table_size (GHashTable *hash_table); typedef struct _GArray GArray; @@ -134,21 +144,24 @@ size_t allocated; }; -GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, - guint element_size ); +WIN32_DLL GArray* g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); #define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); -GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +WIN32_DLL GArray* g_array_append_vals( GArray *array, gconstpointer data, guint len ); #define g_array_index(a,t,i) (*(((t*)a->data)+i)) -GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +WIN32_DLL GArray* g_array_set_size( GArray *array, guint length ); +WIN32_DLL gchar* g_array_free( GArray *array, gboolean free_segment ); #include <TargetConditionals.h> - + #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#define GPOINTER_TO_UINT(p) ((guint) (gulong)(p)) #else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#define GPOINTER_TO_UINT(p) ((guint) (p)) #endif CODE } @@ -177,18 +190,18 @@ WIN32_DLL libspectrum_error libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, - libspectrum_byte **outptr, size_t *outlength ); + libspectrum_byte **outptr, size_t *outlength ); WIN32_DLL libspectrum_error libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, - libspectrum_byte **gzptr, size_t *gzlength ); + libspectrum_byte **gzptr, size_t *gzlength ); CODE } if( /LIBSPECTRUM_SNAP_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; $_ = ''; while( <DATAFILE> ) { @@ -199,23 +212,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); CODE } else { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); CODE } @@ -224,7 +237,7 @@ if( /LIBSPECTRUM_TAPE_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/tape_accessors.txt': $!"; $_ = ''; @@ -241,23 +254,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block, size_t idx ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); CODE } else { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); CODE } Modified: trunk/fuse/fusepb/generate.pl =================================================================== --- trunk/fuse/fusepb/generate.pl 2012-10-07 11:05:44 UTC (rev 690) +++ trunk/fuse/fusepb/generate.pl 2012-10-29 12:01:33 UTC (rev 691) @@ -25,11 +25,12 @@ #define TRUE (!FALSE) #endif -typedef char gchar; +typedef char gchar; typedef int gint; typedef long glong; typedef gint gboolean; typedef unsigned int guint; +typedef unsigned long gulong; typedef const void * gconstpointer; typedef void * gpointer; @@ -47,80 +48,89 @@ gconstpointer b); -GSList WIN32_DLL *g_slist_insert_sorted (GSList *list, +WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); -GSList WIN32_DLL *g_slist_insert (GSList *list, +WIN32_DLL GSList *g_slist_insert (GSList *list, gpointer data, gint position); -GSList WIN32_DLL *g_slist_append (GSList *list, +WIN32_DLL GSList *g_slist_append (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_prepend (GSList *list, +WIN32_DLL GSList *g_slist_prepend (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_remove (GSList *list, +WIN32_DLL GSList *g_slist_remove (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_delete_link (GSList *list, +WIN32_DLL GSList *g_slist_last (GSList *list); + +WIN32_DLL GSList *g_slist_reverse (GSList *list); + +WIN32_DLL GSList *g_slist_delete_link (GSList *list, GSList *link); -guint WIN32_DLL g_slist_length (GSList *list); +WIN32_DLL guint g_slist_length (GSList *list); -void WIN32_DLL g_slist_foreach (GSList *list, +WIN32_DLL void g_slist_foreach (GSList *list, GFunc func, gpointer user_data); -void WIN32_DLL g_slist_free (GSList *list); +WIN32_DLL void g_slist_free (GSList *list); -GSList WIN32_DLL *g_slist_last (GSList *list); - -GSList WIN32_DLL *g_slist_reverse (GSList *list); - -GSList WIN32_DLL *g_slist_nth (GSList *list, +WIN32_DLL GSList *g_slist_nth (GSList *list, guint n); -GSList WIN32_DLL * g_slist_find_custom (GSList *list, +WIN32_DLL GSList *g_slist_find_custom (GSList *list, gpointer data, GCompareFunc func ); -gint WIN32_DLL g_slist_position (GSList *list, +WIN32_DLL gint g_slist_position (GSList *list, GSList *llink); typedef struct _GHashTable GHashTable; typedef guint (*GHashFunc) (gconstpointer key); +typedef void (*GHFunc) (gpointer key, + gpointer value, + gpointer user_data); + typedef gboolean (*GHRFunc) (gpointer key, gpointer value, gpointer user_data); -gint WIN32_DLL g_int_equal (gconstpointer v, +WIN32_DLL gint g_int_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_int_hash (gconstpointer v); -gint WIN32_DLL g_str_equal (gconstpointer v, +WIN32_DLL guint g_int_hash (gconstpointer v); + +WIN32_DLL gint g_str_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_str_hash (gconstpointer v); +WIN32_DLL guint g_str_hash (gconstpointer v); -GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, +WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); -void WIN32_DLL g_hash_table_destroy (GHashTable *hash_table); +WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); -void WIN32_DLL g_hash_table_insert (GHashTable *hash_table, +WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, gpointer key, gpointer value); -gpointer WIN32_DLL g_hash_table_lookup (GHashTable *hash_table, +WIN32_DLL gpointer g_hash_table_lookup (GHashTable *hash_table, gconstpointer key); -guint WIN32_DLL g_hash_table_foreach_remove (GHashTable *hash_table, +WIN32_DLL void g_hash_table_foreach (GHashTable *hash_table, + GHFunc func, + gpointer user_data); + +WIN32_DLL guint g_hash_table_foreach_remove (GHashTable *hash_table, GHRFunc func, gpointer user_data); -guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +WIN32_DLL guint g_hash_table_size (GHashTable *hash_table); typedef struct _GArray GArray; @@ -134,21 +144,24 @@ size_t allocated; }; -GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, - guint element_size ); +WIN32_DLL GArray* g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); #define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); -GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +WIN32_DLL GArray* g_array_append_vals( GArray *array, gconstpointer data, guint len ); #define g_array_index(a,t,i) (*(((t*)a->data)+i)) -GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +WIN32_DLL GArray* g_array_set_size( GArray *array, guint length ); +WIN32_DLL gchar* g_array_free( GArray *array, gboolean free_segment ); #include <TargetConditionals.h> - + #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#define GPOINTER_TO_UINT(p) ((guint) (gulong)(p)) #else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#define GPOINTER_TO_UINT(p) ((guint) (p)) #endif CODE } @@ -177,18 +190,26 @@ WIN32_DLL libspectrum_error libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, - libspectrum_byte **outptr, size_t *outlength ); + libspectrum_byte **outptr, size_t *outlength ); WIN32_DLL libspectrum_error libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, - libspectrum_byte **gzptr, size_t *gzlength ); + libspectrum_byte **gzptr, size_t *gzlength ); + +/* we support files compressed with bz2 */ +#define LIBSPECTRUM_SUPPORTS_BZ2_COMPRESSION (1) + + +/* we support files wav files */ +#define LIBSPECTRUM_SUPPORTS_AUDIOFILE (1) + CODE } if( /LIBSPECTRUM_SNAP_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; $_ = ''; while( <DATAFILE> ) { @@ -199,23 +220,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); CODE } else { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); CODE } @@ -224,7 +245,7 @@ if( /LIBSPECTRUM_TAPE_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/tape_accessors.txt': $!"; $_ = ''; @@ -241,23 +262,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block, size_t idx ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); CODE } else { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); CODE } Modified: trunk/libspectrum/generate.pl =================================================================== --- trunk/libspectrum/generate.pl 2012-10-07 11:05:44 UTC (rev 690) +++ trunk/libspectrum/generate.pl 2012-10-29 12:01:33 UTC (rev 691) @@ -25,11 +25,12 @@ #define TRUE (!FALSE) #endif -typedef char gchar; +typedef char gchar; typedef int gint; typedef long glong; typedef gint gboolean; typedef unsigned int guint; +typedef unsigned long gulong; typedef const void * gconstpointer; typedef void * gpointer; @@ -47,80 +48,89 @@ gconstpointer b); -GSList WIN32_DLL *g_slist_insert_sorted (GSList *list, +WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); -GSList WIN32_DLL *g_slist_insert (GSList *list, +WIN32_DLL GSList *g_slist_insert (GSList *list, gpointer data, gint position); -GSList WIN32_DLL *g_slist_append (GSList *list, +WIN32_DLL GSList *g_slist_append (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_prepend (GSList *list, +WIN32_DLL GSList *g_slist_prepend (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_remove (GSList *list, +WIN32_DLL GSList *g_slist_remove (GSList *list, gpointer data); -GSList WIN32_DLL *g_slist_delete_link (GSList *list, +WIN32_DLL GSList *g_slist_last (GSList *list); + +WIN32_DLL GSList *g_slist_reverse (GSList *list); + +WIN32_DLL GSList *g_slist_delete_link (GSList *list, GSList *link); -guint WIN32_DLL g_slist_length (GSList *list); +WIN32_DLL guint g_slist_length (GSList *list); -void WIN32_DLL g_slist_foreach (GSList *list, +WIN32_DLL void g_slist_foreach (GSList *list, GFunc func, gpointer user_data); -void WIN32_DLL g_slist_free (GSList *list); +WIN32_DLL void g_slist_free (GSList *list); -GSList WIN32_DLL *g_slist_last (GSList *list); - -GSList WIN32_DLL *g_slist_reverse (GSList *list); - -GSList WIN32_DLL *g_slist_nth (GSList *list, +WIN32_DLL GSList *g_slist_nth (GSList *list, guint n); -GSList WIN32_DLL * g_slist_find_custom (GSList *list, +WIN32_DLL GSList *g_slist_find_custom (GSList *list, gpointer data, GCompareFunc func ); -gint WIN32_DLL g_slist_position (GSList *list, +WIN32_DLL gint g_slist_position (GSList *list, GSList *llink); typedef struct _GHashTable GHashTable; typedef guint (*GHashFunc) (gconstpointer key); +typedef void (*GHFunc) (gpointer key, + gpointer value, + gpointer user_data); + typedef gboolean (*GHRFunc) (gpointer key, gpointer value, gpointer user_data); -gint WIN32_DLL g_int_equal (gconstpointer v, +WIN32_DLL gint g_int_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_int_hash (gconstpointer v); -gint WIN32_DLL g_str_equal (gconstpointer v, +WIN32_DLL guint g_int_hash (gconstpointer v); + +WIN32_DLL gint g_str_equal (gconstpointer v, gconstpointer v2); -guint WIN32_DLL g_str_hash (gconstpointer v); +WIN32_DLL guint g_str_hash (gconstpointer v); -GHashTable WIN32_DLL *g_hash_table_new (GHashFunc hash_func, +WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); -void WIN32_DLL g_hash_table_destroy (GHashTable *hash_table); +WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); -void WIN32_DLL g_hash_table_insert (GHashTable *hash_table, +WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, gpointer key, gpointer value); -gpointer WIN32_DLL g_hash_table_lookup (GHashTable *hash_table, +WIN32_DLL gpointer g_hash_table_lookup (GHashTable *hash_table, gconstpointer key); -guint WIN32_DLL g_hash_table_foreach_remove (GHashTable *hash_table, +WIN32_DLL void g_hash_table_foreach (GHashTable *hash_table, + GHFunc func, + gpointer user_data); + +WIN32_DLL guint g_hash_table_foreach_remove (GHashTable *hash_table, GHRFunc func, gpointer user_data); -guint WIN32_DLL g_hash_table_size (GHashTable *hash_table); +WIN32_DLL guint g_hash_table_size (GHashTable *hash_table); typedef struct _GArray GArray; @@ -134,21 +144,24 @@ size_t allocated; }; -GArray* WIN32_DLL g_array_new( gboolean zero_terminated, gboolean clear, - guint element_size ); +WIN32_DLL GArray* g_array_new( gboolean zero_terminated, gboolean clear, + guint element_size ); #define g_array_append_val(a,v) g_array_append_vals( a, &(v), 1 ); -GArray* WIN32_DLL g_array_append_vals( GArray *array, gconstpointer data, guint len ); +WIN32_DLL GArray* g_array_append_vals( GArray *array, gconstpointer data, guint len ); #define g_array_index(a,t,i) (*(((t*)a->data)+i)) -GArray* WIN32_DLL g_array_set_size( GArray *array, guint length ); +WIN32_DLL GArray* g_array_set_size( GArray *array, guint length ); +WIN32_DLL gchar* g_array_free( GArray *array, gboolean free_segment ); #include <TargetConditionals.h> - + #ifdef TARGET_RT_64_BIT #define GINT_TO_POINTER(i) ((gpointer) (glong)(i)) #define GPOINTER_TO_INT(p) ((gint) (glong)(p)) +#define GPOINTER_TO_UINT(p) ((guint) (gulong)(p)) #else #define GINT_TO_POINTER(i) ((gpointer) (i)) #define GPOINTER_TO_INT(p) ((gint) (p)) +#define GPOINTER_TO_UINT(p) ((guint) (p)) #endif CODE } @@ -161,7 +174,8 @@ if( /LIBSPECTRUM_SIGNATURE_PARAMETERS/ ) { - $_ = "/* Signature parameters not stored as libgcrypt is not present */\n"; + $_ = "/* Signature parameters not stored as libgcrypt is not present */ +"; } @@ -176,18 +190,26 @@ WIN32_DLL libspectrum_error libspectrum_zlib_inflate( const libspectrum_byte *gzptr, size_t gzlength, - libspectrum_byte **outptr, size_t *outlength ); + libspectrum_byte **outptr, size_t *outlength ); WIN32_DLL libspectrum_error libspectrum_zlib_compress( const libspectrum_byte *data, size_t length, - libspectrum_byte **gzptr, size_t *gzlength ); + libspectrum_byte **gzptr, size_t *gzlength ); + +/* we support files compressed with bz2 */ +#define LIBSPECTRUM_SUPPORTS_BZ2_COMPRESSION (1) + + +/* we support files wav files */ +#define LIBSPECTRUM_SUPPORTS_AUDIOFILE (1) + CODE } if( /LIBSPECTRUM_SNAP_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/snap_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/snap_accessors.txt': $!"; $_ = ''; while( <DATAFILE> ) { @@ -198,23 +220,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap, int idx ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, int idx, $type $name ); CODE } else { print << "CODE"; $return_type libspectrum_snap_$name( libspectrum_snap *snap ); -void WIN32_DLL libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); +WIN32_DLL void libspectrum_snap_set_$name( libspectrum_snap *snap, $type $name ); CODE } @@ -223,7 +245,7 @@ if( /LIBSPECTRUM_TAPE_ACCESSORS/ ) { - open( DATAFILE, "< $ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) + open( DATAFILE, '<' . "$ENV{SRCROOT}/libspectrum/tape_accessors.txt" ) or die "Couldn't open `$ENV{SRCROOT}/libspectrum/tape_accessors.txt': $!"; $_ = ''; @@ -240,23 +262,23 @@ my $return_type; if( $type =~ /^(.*)\*/ ) { - $return_type = "$1 WIN32_DLL *"; + $return_type = "WIN32_DLL $1 *"; } else { - $return_type = "$type WIN32_DLL"; + $return_type = "WIN32_DLL $type"; } if( $indexed ) { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block, size_t idx ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type \*$name ); CODE } else { print << "CODE"; $return_type libspectrum_tape_block_$name( libspectrum_tape_block *block ); -libspectrum_error WIN32_DLL libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); +WIN32_DLL libspectrum_error libspectrum_tape_block_set_$name( libspectrum_tape_block *block, $type $name ); CODE } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2012-10-29 12:28:27
|
Revision: 699 http://fuse-for-macosx.svn.sourceforge.net/fuse-for-macosx/?rev=699&view=rev Author: fredm Date: 2012-10-29 12:28:20 +0000 (Mon, 29 Oct 2012) Log Message: ----------- Migrate to XCode 4.5.1 and 10.8 SDK for now. Modified Paths: -------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj trunk/audiofile/audiofile.xcodeproj/project.pbxproj trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj Property Changed: ---------------- trunk/FuseGenerator/FuseGenerator.xcodeproj/ trunk/FuseImporter/FuseImporter.xcodeproj/ trunk/audiofile/audiofile.xcodeproj/ trunk/fuse/fusepb/Fuse.xcodeproj/ trunk/libspectrum/libspectrum.xcodeproj/ Property changes on: trunk/FuseGenerator/FuseGenerator.xcodeproj ___________________________________________________________________ Modified: svn:ignore - *.pbxuser *.mode1v3 *.perspectivev3 + *.pbxuser *.mode1v3 *.perspectivev3 project.xcworkspace xcuserdata Modified: trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2012-10-29 12:13:52 UTC (rev 698) +++ trunk/FuseGenerator/FuseGenerator.xcodeproj/project.pbxproj 2012-10-29 12:28:20 UTC (rev 699) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 45; + objectVersion = 46; objects = { /* Begin PBXBuildFile section */ @@ -362,8 +362,11 @@ /* Begin PBXProject section */ 089C1669FE841209C02AAC07 /* Project object */ = { isa = PBXProject; + attributes = { + LastUpgradeCheck = 0450; + }; buildConfigurationList = 2CA326220896AD4900168862 /* Build configuration list for PBXProject "FuseGenerator" */; - compatibilityVersion = "Xcode 3.1"; + compatibilityVersion = "Xcode 3.2"; developmentRegion = English; hasScannedForEncodings = 1; knownRegions = ( @@ -474,9 +477,9 @@ 2CA3261F0896AD4900168862 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = NO; GCC_DYNAMIC_NO_PIC = NO; - GCC_ENABLE_FIX_AND_CONTINUE = YES; GCC_MODEL_TUNING = G5; GCC_OPTIMIZATION_LEVEL = 0; GCC_PRECOMPILE_PREFIX_HEADER = NO; @@ -496,6 +499,7 @@ 2CA326200896AD4900168862 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; GCC_MODEL_TUNING = G5; GCC_PRECOMPILE_PREFIX_HEADER = NO; @@ -531,8 +535,7 @@ GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; - PREBINDING = NO; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Debug; }; @@ -545,8 +548,7 @@ GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; - PREBINDING = NO; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Release; }; Property changes on: trunk/FuseImporter/FuseImporter.xcodeproj ___________________________________________________________________ Modified: svn:ignore - *.mode1* *.pbxuser *.perspectivev3 + *.mode1* *.pbxuser *.perspectivev3 project.xcworkspace xcuserdata Modified: trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj =================================================================== --- trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2012-10-29 12:13:52 UTC (rev 698) +++ trunk/FuseImporter/FuseImporter.xcodeproj/project.pbxproj 2012-10-29 12:28:20 UTC (rev 699) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 45; + objectVersion = 46; objects = { /* Begin PBXBuildFile section */ @@ -337,8 +337,11 @@ /* Begin PBXProject section */ 089C1669FE841209C02AAC07 /* Project object */ = { isa = PBXProject; + attributes = { + LastUpgradeCheck = 0450; + }; buildConfigurationList = B6B0E30008CC65D5001D8411 /* Build configuration list for PBXProject "FuseImporter" */; - compatibilityVersion = "Xcode 3.1"; + compatibilityVersion = "Xcode 3.2"; developmentRegion = English; hasScannedForEncodings = 1; knownRegions = ( @@ -451,11 +454,11 @@ B6B0E2FD08CC65D5001D8411 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = NO; DEBUGGING_SYMBOLS = YES; FRAMEWORK_SEARCH_PATHS = ""; GCC_DYNAMIC_NO_PIC = NO; - GCC_ENABLE_FIX_AND_CONTINUE = YES; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PRECOMPILE_PREFIX_HEADER = NO; @@ -478,7 +481,6 @@ "-lz", ); OTHER_REZFLAGS = ""; - PREBINDING = NO; PRODUCT_NAME = FuseImporter; SECTORDER_FLAGS = ""; WARNING_CFLAGS = ( @@ -494,9 +496,9 @@ B6B0E2FE08CC65D5001D8411 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = YES; FRAMEWORK_SEARCH_PATHS = ""; - GCC_ENABLE_FIX_AND_CONTINUE = NO; GCC_GENERATE_DEBUGGING_SYMBOLS = NO; GCC_PRECOMPILE_PREFIX_HEADER = NO; GCC_WARN_ABOUT_RETURN_TYPE = YES; @@ -512,7 +514,6 @@ "-lz", ); OTHER_REZFLAGS = ""; - PREBINDING = NO; PRODUCT_NAME = FuseImporter; SECTORDER_FLAGS = ""; WARNING_CFLAGS = ( @@ -528,6 +529,7 @@ B6B0E2FF08CC65D5001D8411 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; FRAMEWORK_SEARCH_PATHS = ""; GCC_GENERATE_DEBUGGING_SYMBOLS = NO; GCC_PRECOMPILE_PREFIX_HEADER = NO; @@ -544,7 +546,6 @@ "-lz", ); OTHER_REZFLAGS = ""; - PREBINDING = NO; PRODUCT_NAME = FuseImporter; SECTORDER_FLAGS = ""; WARNING_CFLAGS = ( @@ -563,7 +564,7 @@ ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Development; }; @@ -574,7 +575,7 @@ DEBUG_INFORMATION_FORMAT = dwarf; DEPLOYMENT_POSTPROCESSING = YES; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Deployment; }; @@ -584,7 +585,7 @@ ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Default; }; Property changes on: trunk/audiofile/audiofile.xcodeproj ___________________________________________________________________ Modified: svn:ignore - *.mode1 *.pbxuser *.perspectivev3 + *.mode1 *.pbxuser *.perspectivev3 project.xcworkspace xcuserdata Modified: trunk/audiofile/audiofile.xcodeproj/project.pbxproj =================================================================== --- trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2012-10-29 12:13:52 UTC (rev 698) +++ trunk/audiofile/audiofile.xcodeproj/project.pbxproj 2012-10-29 12:28:20 UTC (rev 699) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 45; + objectVersion = 46; objects = { /* Begin PBXBuildFile section */ @@ -302,8 +302,11 @@ /* Begin PBXProject section */ 000000000000000016601A90 /* Project object */ = { isa = PBXProject; + attributes = { + LastUpgradeCheck = 0450; + }; buildConfigurationList = B62395470C1CF4F8003B8E87 /* Build configuration list for PBXProject "audiofile" */; - compatibilityVersion = "Xcode 3.1"; + compatibilityVersion = "Xcode 3.2"; developmentRegion = English; hasScannedForEncodings = 1; knownRegions = ( @@ -405,7 +408,7 @@ FRAMEWORK_VERSION = 0.2.6; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; MACOSX_DEPLOYMENT_TARGET = 10.5; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Development; }; @@ -418,7 +421,7 @@ FRAMEWORK_VERSION = 0.2.6; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; MACOSX_DEPLOYMENT_TARGET = 10.5; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Deployment; }; @@ -431,19 +434,19 @@ FRAMEWORK_VERSION = 0.2.6; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; MACOSX_DEPLOYMENT_TARGET = 10.5; - SDKROOT = macosx10.5; + SDKROOT = macosx; }; name = Default; }; B62395BD0C1CF586003B8E87 /* Development */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = NO; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; FRAMEWORK_VERSION = 0.2.6; GCC_DYNAMIC_NO_PIC = NO; - GCC_ENABLE_FIX_AND_CONTINUE = YES; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREPROCESSOR_DEFINITIONS = ( @@ -465,7 +468,6 @@ ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; - PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = audiofile; SECTORDER_FLAGS = ""; @@ -478,11 +480,11 @@ B62395BE0C1CF586003B8E87 /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; FRAMEWORK_VERSION = 0.2.6; - GCC_ENABLE_FIX_AND_CONTINUE = NO; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREPROCESSOR_DEFINITIONS = ( @@ -504,7 +506,6 @@ ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; - PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = audiofile; SECTORDER_FLAGS = ""; @@ -517,6 +518,7 @@ B62395BF0C1CF586003B8E87 /* Default */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1.2; FRAMEWORK_VERSION = 0.2.6; @@ -541,7 +543,6 @@ ); OTHER_LIBTOOL_FLAGS = ""; OTHER_REZFLAGS = ""; - PREBINDING = NO; PRINCIPAL_CLASS = ""; PRODUCT_NAME = audiofile; SECTORDER_FLAGS = ""; Property changes on: trunk/fuse/fusepb/Fuse.xcodeproj ___________________________________________________________________ Modified: svn:ignore - fred.* + fred.* project.xcworkspace xcuserdata Modified: trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj =================================================================== --- trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2012-10-29 12:13:52 UTC (rev 698) +++ trunk/fuse/fusepb/Fuse.xcodeproj/project.pbxproj 2012-10-29 12:28:20 UTC (rev 699) @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 45; + objectVersion = 46; objects = { /* Begin PBXBuildFile section */ @@ -756,7 +756,7 @@ F5F291060396932B01730B00 /* Credits.html */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.html; path = Credits.html; sourceTree = "<group>"; }; F5F4333103903ED801E7A043 /* Fuse.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = Fuse.icns; sourceTree = "<group>"; }; F5F876370399540D011FA3A4 /* FuseController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = FuseController.h; path = controllers/FuseController.h; sourceTree = SOURCE_ROOT; }; - F5F876380399540D011FA3A4 /* FuseController.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; name = FuseController.m; path = controllers/FuseController.m; sourceTree = SOURCE_ROOT; }; + F5F876380399540D011FA3A4 /* FuseController.m */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 2; lastKnownFileType = sourcecode.c.objc; name = FuseController.m; path = controllers/FuseController.m; sourceTree = SOURCE_ROOT; tabWidth = 2; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -839,8 +839,10 @@ 19C28FACFE9D520D11CA2CBB /* Products */, B61F46A909121DF100C8096C /* Info-Fuse.plist */, ); + indentWidth = 2; name = Fuse; sourceTree = "<group>"; + tabWidth = 2; }; 29B97315FDCFA39411CA2CEA /* Other Sources */ = { isa = PBXGroup; @@ -1488,8 +1490,11 @@ /* Begin PBXProject section */ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; + attributes = { + LastUpgradeCheck = 0450; + }; buildConfigurationList = B63319B3086803BA00732AA3 /* Build configuration list for PBXProject "Fuse" */; - compatibilityVersion = "Xcode 3.1"; + compatibilityVersion = "Xcode 3.2"; developmentRegion = English; hasScannedForEncodings = 1; knownRegions = ( @@ -1794,6 +1799,7 @@ B61F46A609121DF100C8096C /* Development */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = NO; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; FRAMEWORK_SEARCH_PATHS = ( @@ -1802,14 +1808,15 @@ "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", ); FRAMEWORK_SEARCH_PATHS_QUOTED_1 = "\"$(SRCROOT)/../../audiofile/build/Deployment\""; - GCC_DYNAMIC_NO_PIC = YES; + GCC_C_LANGUAGE_STANDARD = gnu89; + GCC_DYNAMIC_NO_PIC = NO; GCC_ENABLE_CPP_EXCEPTIONS = NO; GCC_ENABLE_CPP_RTTI = NO; - GCC_ENABLE_FIX_AND_CONTINUE = YES; GCC_ENABLE_OBJC_EXCEPTIONS = NO; GCC_GENERATE_DEBUGGING_SYMBOLS = YES; - GCC_MODEL_CPU = G3; + GCC_MODEL_CPU = ""; GCC_OPTIMIZATION_LEVEL = 0; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; HEADER_SEARCH_PATHS = ( "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)/audiofile.framework/Headers", .., @@ -1817,7 +1824,7 @@ INFOPLIST_FILE = "Info-Fuse.plist"; INSTALL_PATH = "$(HOME)/Applications"; LIBRARY_SEARCH_PATHS = .; - OTHER_CFLAGS_ppc = "-mmultiple -mpowerpc-gfxopt -falign-loops=16"; + OTHER_CFLAGS = ""; OTHER_LDFLAGS = ( "-lbz2", "-lz", @@ -1825,7 +1832,6 @@ PRODUCT_NAME = Fuse; SCAN_ALL_SOURCE_FILES_FOR_INCLUDES = YES; SECTORDER_FLAGS = ""; - USE_ALTIVEC = 1; WARNING_CFLAGS = "-Wall"; WRAPPER_EXTENSION = app; YACC = /usr/bin/bison; @@ -1836,6 +1842,7 @@ B61F46A709121DF100C8096C /* Deployment */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = YES; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; FRAMEWORK_SEARCH_PATHS = ( @@ -1844,13 +1851,13 @@ "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", ); FRAMEWORK_SEARCH_PATHS_QUOTED_1 = "\"$(SRCROOT)/../../audiofile/build/Deployment\""; - GCC_DYNAMIC_NO_PIC = YES; + GCC_C_LANGUAGE_STANDARD = gnu89; + GCC_DYNAMIC_NO_PIC = NO; GCC_ENABLE_CPP_EXCEPTIONS = NO; GCC_ENABLE_CPP_RTTI = NO; - GCC_ENABLE_FIX_AND_CONTINUE = NO; GCC_ENABLE_OBJC_EXCEPTIONS = NO; - GCC_MODEL_CPU = G3; GCC_OPTIMIZATION_LEVEL = 2; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; HEADER_SEARCH_PATHS = ( "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)/audiofile.framework/Headers", .., @@ -1858,12 +1865,11 @@ INFOPLIST_FILE = "Info-Fuse.plist"; INSTALL_PATH = "$(HOME)/Applications"; LIBRARY_SEARCH_PATHS = .; - OTHER_CFLAGS_ppc = "-mmultiple -mpowerpc-gfxopt -falign-loops=16"; + OTHER_CFLAGS = ""; OTHER_LDFLAGS = ( "-lbz2", "-lz", ); - PREBINDING = NO; PRODUCT_NAME = Fuse; SCAN_ALL_SOURCE_FILES_FOR_INCLUDES = YES; SECTORDER_FLAGS = ""; @@ -1877,6 +1883,7 @@ B61F46A809121DF100C8096C /* Default */ = { isa = XCBuildConfiguration; buildSettings = { + COMBINE_HIDPI_IMAGES = YES; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; FRAMEWORK_SEARCH_PATHS = ( "$(HOME)/Library/Frameworks", @@ -1884,10 +1891,13 @@ "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)", ); FRAMEWORK_SEARCH_PATHS_QUOTED_1 = "\"$(SRCROOT)/../../audiofile/build/Deployment\""; + GCC_C_LANGUAGE_STANDARD = gnu89; + GCC_DYNAMIC_NO_PIC = NO; GCC_ENABLE_CPP_EXCEPTIONS = NO; GCC_ENABLE_CPP_RTTI = NO; GCC_ENABLE_OBJC_EXCEPTIONS = NO; GCC_OPTIMIZATION_LEVEL = 2; + GCC_VERSION = com.apple.compilers.llvm.clang.1_0; HEADER_SEARCH_PATHS = ( "$(FRAMEWORK_SEARCH_PATHS_QUOTED_1)/audiofile.framework/Headers", .., @@ -1895,7 +1905,7 @@ INFOPLIST_FILE = "Info-Fuse.plist"; INSTALL_PATH = "$(HOME)/Applications"; LIBRARY_SEARCH_PATHS = .; - OTHER_CFLAGS_ppc = "-mmultiple -mpowerpc-gfxopt -falign-loops=16"; + OTHER_CFLAGS = ""; OTHER_LDFLAGS = ( "-lbz2", "-lz", @@ -1914,12 +1924,13 @@ buildSettings = { ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEAD_CODE_STRIPPING = YES; - DEBUG_INFORMATION_FORMAT = dwarf; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; GCC_AUTO_VECTORIZATION = NO; + GCC_C_LANGUAGE_STANDARD = c89; GCC_DYNAMIC_NO_PIC = YES; - GCC_VERSION = com.apple.compilers.llvmgcc42; + GCC_VERSION = ""; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; - SDKROOT = macosx10.5; + SDKROOT = macosx; YACCFLAGS = "-d"; YACC_GENERATED_FILE_STEM = InputFileStem; ZERO_LINK = YES; @@ -1931,13 +1942,14 @@ buildSettings = { ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEAD_CODE_STRIPPING = YES; - DEBUG_INFORMATION_FORMAT = dwarf; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEPLOYMENT_POSTPROCESSING = YES; GCC_AUTO_VECTORIZATION = NO; + GCC_C_LANGUAGE_STANDARD = c89; GCC_DYNAMIC_NO_PIC = YES; - GCC_VERSION = com.apple.compilers.llvmgcc42; + GCC_VERSION = ""; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; - SDKROOT = macosx10.5; + SDKROOT = macosx; YACCFLAGS = "-d"; YACC_GENERATED_FILE_STEM = InputFileStem; ZERO_LINK = NO; @@ -1949,12 +1961,13 @@ buildSettings = { ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; DEAD_CODE_STRIPPING = YES; - DEBUG_INFORMATION_FORMAT = dwarf; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; GCC_AUTO_VECTORIZATION = NO; + GCC_C_LANGUAGE_STANDARD = c89; GCC_DYNAMIC_NO_PIC = YES; - GCC_VERSION = com.apple.compilers.llvmgcc42; + GCC_VERSION = ""; GCC_WARN_ABOUT_POINTER_SIGNEDNESS = NO; - SDKROOT = macosx10.5; + SDKROOT = macosx; YACCFLAGS = "-d"; YACC_GENERATED_FILE_STEM = InputFileStem; ZERO_LINK = NO; Property changes on: trunk/libspectrum/libspectrum.xcodeproj ___________________________________________________________________ Modified: svn:ignore - fred.* + fred.* project.xcworkspace xcuserdata This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fr...@us...> - 2012-12-06 11:56:03
|
Revision: 719 http://sourceforge.net/p/fuse-for-macosx/code/719 Author: fredm Date: 2012-12-06 11:55:57 +0000 (Thu, 06 Dec 2012) Log Message: ----------- Merge up to vendor revision 4779. Revision Links: -------------- http://sourceforge.net/p/fuse-for-macosx/code/4779 Modified Paths: -------------- trunk/FuseGenerator/generate.pl trunk/FuseGenerator/libspectrum.h trunk/FuseImporter/generate.pl trunk/FuseImporter/libspectrum.h trunk/fuse/fusepb/generate.pl trunk/fuse/fusepb/libspectrum.h trunk/libspectrum/generate.pl trunk/libspectrum/libspectrum/Makefile.am trunk/libspectrum/libspectrum/autogen.sh trunk/libspectrum/libspectrum/hacking/ChangeLog trunk/libspectrum/libspectrum/internals.h trunk/libspectrum/libspectrum/libspectrum.c trunk/libspectrum/libspectrum/libspectrum.h.in trunk/libspectrum/libspectrum/make-perl.c trunk/libspectrum/libspectrum/memory.c trunk/libspectrum/libspectrum/myglib/garray.c trunk/libspectrum/libspectrum/myglib/ghash.c trunk/libspectrum/libspectrum/myglib/gslist.c trunk/libspectrum/libspectrum/szx.c trunk/libspectrum/libspectrum/windres.rc trunk/libspectrum/libspectrum.h Added Paths: ----------- trunk/libspectrum/libspectrum/configure.ac trunk/libspectrum/libspectrum/m4/ Removed Paths: ------------- trunk/libspectrum/libspectrum/acinclude.m4 trunk/libspectrum/libspectrum/configure.in Property Changed: ---------------- trunk/libspectrum/libspectrum/ Modified: trunk/FuseGenerator/generate.pl =================================================================== --- trunk/FuseGenerator/generate.pl 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/FuseGenerator/generate.pl 2012-12-06 11:55:57 UTC (rev 719) @@ -47,7 +47,11 @@ typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFreeFunc) (gpointer data); + + WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); @@ -63,7 +67,7 @@ gpointer data); WIN32_DLL GSList *g_slist_remove (GSList *list, - gpointer data); + gconstpointer data); WIN32_DLL GSList *g_slist_last (GSList *list); @@ -84,7 +88,7 @@ guint n); WIN32_DLL GSList *g_slist_find_custom (GSList *list, - gpointer data, + gconstpointer data, GCompareFunc func ); WIN32_DLL gint g_slist_position (GSList *list, @@ -113,6 +117,11 @@ WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); +WIN32_DLL GHashTable *g_hash_table_new_full (GHashFunc hash_func, + GCompareFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); + WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, Modified: trunk/FuseGenerator/libspectrum.h =================================================================== --- trunk/FuseGenerator/libspectrum.h 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/FuseGenerator/libspectrum.h 2012-12-06 11:55:57 UTC (rev 719) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4534 2011-08-11 12:59:47Z fredm $ + $Id: libspectrum.h.in 4695 2012-05-07 02:03:10Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -106,7 +106,11 @@ typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFreeFunc) (gpointer data); + + WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); @@ -122,7 +126,7 @@ gpointer data); WIN32_DLL GSList *g_slist_remove (GSList *list, - gpointer data); + gconstpointer data); WIN32_DLL GSList *g_slist_last (GSList *list); @@ -143,7 +147,7 @@ guint n); WIN32_DLL GSList *g_slist_find_custom (GSList *list, - gpointer data, + gconstpointer data, GCompareFunc func ); WIN32_DLL gint g_slist_position (GSList *list, @@ -172,6 +176,11 @@ WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); +WIN32_DLL GHashTable *g_hash_table_new_full (GHashFunc hash_func, + GCompareFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); + WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, @@ -274,6 +283,7 @@ /* Initialisation */ WIN32_DLL libspectrum_error libspectrum_init( void ); +WIN32_DLL void libspectrum_end( void ); /* Version checking */ Modified: trunk/FuseImporter/generate.pl =================================================================== --- trunk/FuseImporter/generate.pl 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/FuseImporter/generate.pl 2012-12-06 11:55:57 UTC (rev 719) @@ -47,7 +47,11 @@ typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFreeFunc) (gpointer data); + + WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); @@ -63,7 +67,7 @@ gpointer data); WIN32_DLL GSList *g_slist_remove (GSList *list, - gpointer data); + gconstpointer data); WIN32_DLL GSList *g_slist_last (GSList *list); @@ -84,7 +88,7 @@ guint n); WIN32_DLL GSList *g_slist_find_custom (GSList *list, - gpointer data, + gconstpointer data, GCompareFunc func ); WIN32_DLL gint g_slist_position (GSList *list, @@ -113,6 +117,11 @@ WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); +WIN32_DLL GHashTable *g_hash_table_new_full (GHashFunc hash_func, + GCompareFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); + WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, Modified: trunk/FuseImporter/libspectrum.h =================================================================== --- trunk/FuseImporter/libspectrum.h 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/FuseImporter/libspectrum.h 2012-12-06 11:55:57 UTC (rev 719) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4534 2011-08-11 12:59:47Z fredm $ + $Id: libspectrum.h.in 4695 2012-05-07 02:03:10Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -106,7 +106,11 @@ typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFreeFunc) (gpointer data); + + WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); @@ -122,7 +126,7 @@ gpointer data); WIN32_DLL GSList *g_slist_remove (GSList *list, - gpointer data); + gconstpointer data); WIN32_DLL GSList *g_slist_last (GSList *list); @@ -143,7 +147,7 @@ guint n); WIN32_DLL GSList *g_slist_find_custom (GSList *list, - gpointer data, + gconstpointer data, GCompareFunc func ); WIN32_DLL gint g_slist_position (GSList *list, @@ -172,6 +176,11 @@ WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); +WIN32_DLL GHashTable *g_hash_table_new_full (GHashFunc hash_func, + GCompareFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); + WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, @@ -274,6 +283,7 @@ /* Initialisation */ WIN32_DLL libspectrum_error libspectrum_init( void ); +WIN32_DLL void libspectrum_end( void ); /* Version checking */ Modified: trunk/fuse/fusepb/generate.pl =================================================================== --- trunk/fuse/fusepb/generate.pl 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/fuse/fusepb/generate.pl 2012-12-06 11:55:57 UTC (rev 719) @@ -47,7 +47,11 @@ typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFreeFunc) (gpointer data); + + WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); @@ -63,7 +67,7 @@ gpointer data); WIN32_DLL GSList *g_slist_remove (GSList *list, - gpointer data); + gconstpointer data); WIN32_DLL GSList *g_slist_last (GSList *list); @@ -84,7 +88,7 @@ guint n); WIN32_DLL GSList *g_slist_find_custom (GSList *list, - gpointer data, + gconstpointer data, GCompareFunc func ); WIN32_DLL gint g_slist_position (GSList *list, @@ -113,6 +117,11 @@ WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); +WIN32_DLL GHashTable *g_hash_table_new_full (GHashFunc hash_func, + GCompareFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); + WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, Modified: trunk/fuse/fusepb/libspectrum.h =================================================================== --- trunk/fuse/fusepb/libspectrum.h 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/fuse/fusepb/libspectrum.h 2012-12-06 11:55:57 UTC (rev 719) @@ -1,7 +1,7 @@ /* libspectrum.h: the library for dealing with ZX Spectrum emulator files Copyright (c) 2001-2007 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.h.in 4534 2011-08-11 12:59:47Z fredm $ + $Id: libspectrum.h.in 4695 2012-05-07 02:03:10Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -106,7 +106,11 @@ typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFreeFunc) (gpointer data); + + WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); @@ -122,7 +126,7 @@ gpointer data); WIN32_DLL GSList *g_slist_remove (GSList *list, - gpointer data); + gconstpointer data); WIN32_DLL GSList *g_slist_last (GSList *list); @@ -143,7 +147,7 @@ guint n); WIN32_DLL GSList *g_slist_find_custom (GSList *list, - gpointer data, + gconstpointer data, GCompareFunc func ); WIN32_DLL gint g_slist_position (GSList *list, @@ -172,6 +176,11 @@ WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); +WIN32_DLL GHashTable *g_hash_table_new_full (GHashFunc hash_func, + GCompareFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); + WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, @@ -274,6 +283,7 @@ /* Initialisation */ WIN32_DLL libspectrum_error libspectrum_init( void ); +WIN32_DLL void libspectrum_end( void ); /* Version checking */ Modified: trunk/libspectrum/generate.pl =================================================================== --- trunk/libspectrum/generate.pl 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/generate.pl 2012-12-06 11:55:57 UTC (rev 719) @@ -47,7 +47,11 @@ typedef gint (*GCompareFunc) (gconstpointer a, gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFreeFunc) (gpointer data); + + WIN32_DLL GSList *g_slist_insert_sorted (GSList *list, gpointer data, GCompareFunc func); @@ -63,7 +67,7 @@ gpointer data); WIN32_DLL GSList *g_slist_remove (GSList *list, - gpointer data); + gconstpointer data); WIN32_DLL GSList *g_slist_last (GSList *list); @@ -84,7 +88,7 @@ guint n); WIN32_DLL GSList *g_slist_find_custom (GSList *list, - gpointer data, + gconstpointer data, GCompareFunc func ); WIN32_DLL gint g_slist_position (GSList *list, @@ -113,6 +117,11 @@ WIN32_DLL GHashTable *g_hash_table_new (GHashFunc hash_func, GCompareFunc key_compare_func); +WIN32_DLL GHashTable *g_hash_table_new_full (GHashFunc hash_func, + GCompareFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); + WIN32_DLL void g_hash_table_destroy (GHashTable *hash_table); WIN32_DLL void g_hash_table_insert (GHashTable *hash_table, Property changes on: trunk/libspectrum/libspectrum ___________________________________________________________________ Modified: svn:mergeinfo - /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-711 /vendor/fuse-emulator/fuse-1.0.0a/libspectrum:668-669 /vendor/fuse-emulator/fuse-r4617/libspectrum:686 + /vendor/fuse-emulator/0.10.0/libspectrum:556-557 /vendor/fuse-emulator/0.10.0-pre1/libspectrum:545-546 /vendor/fuse-emulator/current/libspectrum:530-717 /vendor/fuse-emulator/fuse-1.0.0a/libspectrum:668-669 /vendor/fuse-emulator/fuse-r4617/libspectrum:686 Modified: trunk/libspectrum/libspectrum/Makefile.am =================================================================== --- trunk/libspectrum/libspectrum/Makefile.am 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/libspectrum/Makefile.am 2012-12-06 11:55:57 UTC (rev 719) @@ -1,7 +1,7 @@ ## Process this file with automake to produce Makefile.in ## Copyright (c) 2001-2004 Philip Kendall -## $Id: Makefile.am 4388 2011-04-27 12:52:26Z fredm $ +## $Id: Makefile.am 4757 2012-11-07 11:14:48Z fredm $ ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -23,6 +23,8 @@ AUTOMAKE_OPTIONS = foreign +ACLOCAL_AMFLAGS = -I m4 + lib_LTLIBRARIES = libspectrum.la libspectrum_la_SOURCES = bzip2.c \ @@ -63,7 +65,7 @@ libspectrum_la_LDFLAGS = -version-info 8:0:0 -no-undefined @WINDRES_LDFLAGS@ -libspectrum_la_LIBADD = @AUDIOFILE_LIBS@ -lm +libspectrum_la_LIBADD = @AUDIOFILE_LIBS@ @GLIB_LIBS@ -lm libspectrum_la_DEPENDENCIES = @WINDRES_OBJ@ @@ -78,7 +80,7 @@ AM_CFLAGS = -DLIBSPECTRUM_EXPORTS make-perl$(EXEEXT): $(srcdir)/make-perl.c config.h - $(CC_FOR_BUILD) -I. -o $@ $< + $(CC_FOR_BUILD) -I. $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $< libspectrum.h: libspectrum.h.in generate.pl snap_accessors.txt tape_accessors.txt config.h @PERL@ -p generate.pl $(srcdir) $(srcdir)/libspectrum.h.in > $@.tmp && mv $@.tmp $@ @@ -97,12 +99,13 @@ @PERL@ $(srcdir)/tape_set.pl $(srcdir)/tape_accessors.txt > $@.tmp && mv $@.tmp $@ windres.o: windres.rc - @WINDRES@ $(srcdir)/windres.rc windres.o + @WINDRES@ -I. $(srcdir)/windres.rc windres.o -INCLUDES = @GLIB_CFLAGS@ @AUDIOFILE_CFLAGS@ +AM_CPPFLAGS = @GLIB_CFLAGS@ @AUDIOFILE_CFLAGS@ EXTRA_DIST = accessor.pl \ generate.pl.in \ + m4/audiofile.m4 \ make-perl.c \ tape_accessors.pl \ tape_accessors.txt \ Deleted: trunk/libspectrum/libspectrum/acinclude.m4 =================================================================== --- trunk/libspectrum/libspectrum/acinclude.m4 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/libspectrum/acinclude.m4 2012-12-06 11:55:57 UTC (rev 719) @@ -1,593 +0,0 @@ -# Configure paths for GLIB -# Owen Taylor 97-11-3 - -# Taken from Glib 1.2.10 by PAK 2004/07/06 - -dnl AM_PATH_GLIB([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]]) -dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if "gmodule" or -dnl gthread is specified in MODULES, pass to glib-config -dnl -AC_DEFUN([AM_PATH_GLIB], -[dnl -dnl Get the cflags and libraries from the glib-config script -dnl -AC_ARG_WITH(glib-prefix,[ --with-glib-prefix=PFX Prefix where GLIB is installed (optional)], - glib_config_prefix="$withval", glib_config_prefix="") -AC_ARG_WITH(glib-exec-prefix,[ --with-glib-exec-prefix=PFX Exec prefix where GLIB is installed (optional)], - glib_config_exec_prefix="$withval", glib_config_exec_prefix="") -AC_ARG_ENABLE(glibtest, [ --disable-glibtest Do not try to compile and run a test GLIB program], - , enable_glibtest=yes) - - if test x$glib_config_exec_prefix != x ; then - glib_config_args="$glib_config_args --exec-prefix=$glib_config_exec_prefix" - if test x${GLIB_CONFIG+set} != xset ; then - GLIB_CONFIG=$glib_config_exec_prefix/bin/glib-config - fi - fi - if test x$glib_config_prefix != x ; then - glib_config_args="$glib_config_args --prefix=$glib_config_prefix" - if test x${GLIB_CONFIG+set} != xset ; then - GLIB_CONFIG=$glib_config_prefix/bin/glib-config - fi - fi - - for module in . $4 - do - case "$module" in - gmodule) - glib_config_args="$glib_config_args gmodule" - ;; - gthread) - glib_config_args="$glib_config_args gthread" - ;; - esac - done - - AC_PATH_PROG(GLIB_CONFIG, glib-config, no) - min_glib_version=ifelse([$1], ,0.99.7,$1) - AC_MSG_CHECKING(for GLIB - version >= $min_glib_version) - no_glib="" - if test "$GLIB_CONFIG" = "no" ; then - no_glib=yes - else - GLIB_CFLAGS=`$GLIB_CONFIG $glib_config_args --cflags` - GLIB_LIBS=`$GLIB_CONFIG $glib_config_args --libs` - glib_config_major_version=`$GLIB_CONFIG $glib_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - glib_config_minor_version=`$GLIB_CONFIG $glib_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` - glib_config_micro_version=`$GLIB_CONFIG $glib_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` - if test "x$enable_glibtest" = "xyes" ; then - ac_save_CFLAGS="$CFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $GLIB_CFLAGS" - LIBS="$GLIB_LIBS $LIBS" -dnl -dnl Now check if the installed GLIB is sufficiently new. (Also sanity -dnl checks the results of glib-config to some extent -dnl - rm -f conf.glibtest - AC_TRY_RUN([ -#include <glib.h> -#include <stdio.h> -#include <stdlib.h> - -int -main () -{ - int major, minor, micro; - char *tmp_version; - - system ("touch conf.glibtest"); - - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = g_strdup("$min_glib_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string\n", "$min_glib_version"); - exit(1); - } - - if ((glib_major_version != $glib_config_major_version) || - (glib_minor_version != $glib_config_minor_version) || - (glib_micro_version != $glib_config_micro_version)) - { - printf("\n*** 'glib-config --version' returned %d.%d.%d, but GLIB (%d.%d.%d)\n", - $glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version, - glib_major_version, glib_minor_version, glib_micro_version); - printf ("*** was found! If glib-config was correct, then it is best\n"); - printf ("*** to remove the old version of GLIB. You may also be able to fix the error\n"); - printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n"); - printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n"); - printf("*** required on your system.\n"); - printf("*** If glib-config was wrong, set the environment variable GLIB_CONFIG\n"); - printf("*** to point to the correct copy of glib-config, and remove the file config.cache\n"); - printf("*** before re-running configure\n"); - } - else if ((glib_major_version != GLIB_MAJOR_VERSION) || - (glib_minor_version != GLIB_MINOR_VERSION) || - (glib_micro_version != GLIB_MICRO_VERSION)) - { - printf("*** GLIB header files (version %d.%d.%d) do not match\n", - GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION); - printf("*** library (version %d.%d.%d)\n", - glib_major_version, glib_minor_version, glib_micro_version); - } - else - { - if ((glib_major_version > major) || - ((glib_major_version == major) && (glib_minor_version > minor)) || - ((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n", - glib_major_version, glib_minor_version, glib_micro_version); - printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n", - major, minor, micro); - printf("*** GLIB is always available from ftp://ftp.gtk.org.\n"); - printf("***\n"); - printf("*** If you have already installed a sufficiently new version, this error\n"); - printf("*** probably means that the wrong copy of the glib-config shell script is\n"); - printf("*** being found. The easiest way to fix this is to remove the old version\n"); - printf("*** of GLIB, but you can also set the GLIB_CONFIG environment to point to the\n"); - printf("*** correct copy of glib-config. (In this case, you will have to\n"); - printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); - printf("*** so that the correct libraries are found at run-time))\n"); - } - } - return 1; -} -],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - if test "x$no_glib" = x ; then - AC_MSG_RESULT(yes) - ifelse([$2], , :, [$2]) - else - AC_MSG_RESULT(no) - if test "$GLIB_CONFIG" = "no" ; then - echo "*** The glib-config script installed by GLIB could not be found" - echo "*** If GLIB was installed in PREFIX, make sure PREFIX/bin is in" - echo "*** your path, or set the GLIB_CONFIG environment variable to the" - echo "*** full path to glib-config." - else - if test -f conf.glibtest ; then - : - else - echo "*** Could not run GLIB test program, checking why..." - CFLAGS="$CFLAGS $GLIB_CFLAGS" - LIBS="$LIBS $GLIB_LIBS" - AC_TRY_LINK([ -#include <glib.h> -#include <stdio.h> -], [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ], - [ echo "*** The test program compiled, but did not run. This usually means" - echo "*** that the run-time linker is not finding GLIB or finding the wrong" - echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your" - echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" - echo "*** to the installed location Also, make sure you have run ldconfig if that" - echo "*** is required on your system" - echo "***" - echo "*** If you have an old version installed, it is best to remove it, although" - echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" - echo "***" - echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that" - echo "*** came with the system with the command" - echo "***" - echo "*** rpm --erase --nodeps gtk gtk-devel" ], - [ echo "*** The test program failed to compile or link. See the file config.log for the" - echo "*** exact error that occured. This usually means GLIB was incorrectly installed" - echo "*** or that you have moved GLIB since it was installed. In the latter case, you" - echo "*** may want to edit the glib-config script: $GLIB_CONFIG" ]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - GLIB_CFLAGS="" - GLIB_LIBS="" - ifelse([$3], , :, [$3]) - fi - AC_SUBST(GLIB_CFLAGS) - AC_SUBST(GLIB_LIBS) - rm -f conf.glibtest -]) - -# Configure paths for GLIB -# Owen Taylor 1997-2001 - -# Taken from Glib 2.4.2 by PAK 2004/07/06 - -dnl AM_PATH_GLIB_2_0([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]]) -dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if gmodule, gobject or -dnl gthread is specified in MODULES, pass to pkg-config -dnl -AC_DEFUN([AM_PATH_GLIB_2_0], -[dnl -dnl Get the cflags and libraries from pkg-config -dnl -AC_ARG_ENABLE(glibtest, [ --disable-glibtest do not try to compile and run a test GLIB program], - , enable_glibtest=yes) - - pkg_config_args=glib-2.0 - for module in . $4 - do - case "$module" in - gmodule) - pkg_config_args="$pkg_config_args gmodule-2.0" - ;; - gobject) - pkg_config_args="$pkg_config_args gobject-2.0" - ;; - gthread) - pkg_config_args="$pkg_config_args gthread-2.0" - ;; - esac - done - - AC_PATH_PROG(PKG_CONFIG, pkg-config, no) - - no_glib="" - - if test x$PKG_CONFIG != xno ; then - if $PKG_CONFIG --atleast-pkgconfig-version 0.7 ; then - : - else - echo *** pkg-config too old; version 0.7 or better required. - no_glib=yes - PKG_CONFIG=no - fi - else - no_glib=yes - fi - - min_glib_version=ifelse([$1], ,2.0.0,$1) - AC_MSG_CHECKING(for GLIB - version >= $min_glib_version) - - if test x$PKG_CONFIG != xno ; then - ## don't try to run the test against uninstalled libtool libs - if $PKG_CONFIG --uninstalled $pkg_config_args; then - echo "Will use uninstalled version of GLib found in PKG_CONFIG_PATH" - enable_glibtest=no - fi - - if $PKG_CONFIG --atleast-version $min_glib_version $pkg_config_args; then - : - else - no_glib=yes - fi - fi - - if test x"$no_glib" = x ; then - GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0` - GOBJECT_QUERY=`$PKG_CONFIG --variable=gobject_query glib-2.0` - GLIB_MKENUMS=`$PKG_CONFIG --variable=glib_mkenums glib-2.0` - - GLIB_CFLAGS=`$PKG_CONFIG --cflags $pkg_config_args` - GLIB_LIBS=`$PKG_CONFIG --libs $pkg_config_args` - glib_config_major_version=`$PKG_CONFIG --modversion glib-2.0 | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - glib_config_minor_version=`$PKG_CONFIG --modversion glib-2.0 | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` - glib_config_micro_version=`$PKG_CONFIG --modversion glib-2.0 | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` - if test "x$enable_glibtest" = "xyes" ; then - ac_save_CFLAGS="$CFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $GLIB_CFLAGS" - LIBS="$GLIB_LIBS $LIBS" -dnl -dnl Now check if the installed GLIB is sufficiently new. (Also sanity -dnl checks the results of pkg-config to some extent) -dnl - rm -f conf.glibtest - AC_TRY_RUN([ -#include <glib.h> -#include <stdio.h> -#include <stdlib.h> - -int -main () -{ - int major, minor, micro; - char *tmp_version; - - system ("touch conf.glibtest"); - - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = g_strdup("$min_glib_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string\n", "$min_glib_version"); - exit(1); - } - - if ((glib_major_version != $glib_config_major_version) || - (glib_minor_version != $glib_config_minor_version) || - (glib_micro_version != $glib_config_micro_version)) - { - printf("\n*** 'pkg-config --modversion glib-2.0' returned %d.%d.%d, but GLIB (%d.%d.%d)\n", - $glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version, - glib_major_version, glib_minor_version, glib_micro_version); - printf ("*** was found! If pkg-config was correct, then it is best\n"); - printf ("*** to remove the old version of GLib. You may also be able to fix the error\n"); - printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n"); - printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n"); - printf("*** required on your system.\n"); - printf("*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH\n"); - printf("*** to point to the correct configuration files\n"); - } - else if ((glib_major_version != GLIB_MAJOR_VERSION) || - (glib_minor_version != GLIB_MINOR_VERSION) || - (glib_micro_version != GLIB_MICRO_VERSION)) - { - printf("*** GLIB header files (version %d.%d.%d) do not match\n", - GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION); - printf("*** library (version %d.%d.%d)\n", - glib_major_version, glib_minor_version, glib_micro_version); - } - else - { - if ((glib_major_version > major) || - ((glib_major_version == major) && (glib_minor_version > minor)) || - ((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n", - glib_major_version, glib_minor_version, glib_micro_version); - printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n", - major, minor, micro); - printf("*** GLIB is always available from ftp://ftp.gtk.org.\n"); - printf("***\n"); - printf("*** If you have already installed a sufficiently new version, this error\n"); - printf("*** probably means that the wrong copy of the pkg-config shell script is\n"); - printf("*** being found. The easiest way to fix this is to remove the old version\n"); - printf("*** of GLIB, but you can also set the PKG_CONFIG environment to point to the\n"); - printf("*** correct copy of pkg-config. (In this case, you will have to\n"); - printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); - printf("*** so that the correct libraries are found at run-time))\n"); - } - } - return 1; -} -],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - if test "x$no_glib" = x ; then - AC_MSG_RESULT(yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version)) - ifelse([$2], , :, [$2]) - else - AC_MSG_RESULT(no) - if test "$PKG_CONFIG" = "no" ; then - echo "*** A new enough version of pkg-config was not found." - echo "*** See http://www.freedesktop.org/software/pkgconfig/" - else - if test -f conf.glibtest ; then - : - else - echo "*** Could not run GLIB test program, checking why..." - ac_save_CFLAGS="$CFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $GLIB_CFLAGS" - LIBS="$LIBS $GLIB_LIBS" - AC_TRY_LINK([ -#include <glib.h> -#include <stdio.h> -], [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ], - [ echo "*** The test program compiled, but did not run. This usually means" - echo "*** that the run-time linker is not finding GLIB or finding the wrong" - echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your" - echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" - echo "*** to the installed location Also, make sure you have run ldconfig if that" - echo "*** is required on your system" - echo "***" - echo "*** If you have an old version installed, it is best to remove it, although" - echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], - [ echo "*** The test program failed to compile or link. See the file config.log for the" - echo "*** exact error that occured. This usually means GLIB is incorrectly installed."]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - GLIB_CFLAGS="" - GLIB_LIBS="" - GLIB_GENMARSHAL="" - GOBJECT_QUERY="" - GLIB_MKENUMS="" - ifelse([$3], , :, [$3]) - fi - AC_SUBST(GLIB_CFLAGS) - AC_SUBST(GLIB_LIBS) - AC_SUBST(GLIB_GENMARSHAL) - AC_SUBST(GOBJECT_QUERY) - AC_SUBST(GLIB_MKENUMS) - rm -f conf.glibtest -]) - -# Configure paths for the Audio File Library -# Bertrand Guiheneuf 98-10-21 -# stolen from esd.m4 in esound : -# Manish Singh 98-9-30 -# stolen back from Frank Belew -# stolen from Manish Singh -# Shamelessly stolen from Owen Taylor - -dnl AM_PATH_AUDIOFILE([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) -dnl Test for Audio File Library, and define AUDIOFILE_CFLAGS and AUDIOFILE_LIBS. -dnl -AC_DEFUN([AM_PATH_AUDIOFILE], -[dnl -dnl Get compiler flags and libraries from the audiofile-config script. -dnl -AC_ARG_WITH(audiofile-prefix,[ --with-audiofile-prefix=PFX Prefix where Audio File Library is installed (optional)], - audiofile_prefix="$withval", audiofile_prefix="") -AC_ARG_WITH(audiofile-exec-prefix,[ --with-audiofile-exec-prefix=PFX Exec prefix where Audio File Library is installed (optional)], - audiofile_exec_prefix="$withval", audiofile_exec_prefix="") -AC_ARG_ENABLE(audiofiletest, [ --disable-audiofiletest Do not try to compile and run a test Audio File Library program], , enable_audiofiletest=yes) - - if test x$audiofile_exec_prefix != x ; then - audiofile_args="$audiofile_args --exec-prefix=$audiofile_exec_prefix" - if test x${AUDIOFILE_CONFIG+set} != xset ; then - AUDIOFILE_CONFIG=$audiofile_exec_prefix/bin/audiofile-config - fi - fi - if test x$audiofile_prefix != x ; then - audiofile_args="$audiofile_args --prefix=$audiofile_prefix" - if test x${AUDIOFILE_CONFIG+set} != xset ; then - AUDIOFILE_CONFIG=$audiofile_prefix/bin/audiofile-config - fi - fi - - AC_PATH_PROG(AUDIOFILE_CONFIG, audiofile-config, no) - min_audiofile_version=ifelse([$1], ,0.2.5,$1) - AC_MSG_CHECKING(for Audio File Library - version >= $min_audiofile_version) - no_audiofile="" - if test "$AUDIOFILE_CONFIG" = "no" ; then - no_audiofile=yes - else - AUDIOFILE_LIBS=`$AUDIOFILE_CONFIG $audiofileconf_args --libs` - AUDIOFILE_CFLAGS=`$AUDIOFILE_CONFIG $audiofileconf_args --cflags` - audiofile_major_version=`$AUDIOFILE_CONFIG $audiofile_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - audiofile_minor_version=`$AUDIOFILE_CONFIG $audiofile_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` - audiofile_micro_version=`$AUDIOFILE_CONFIG $audiofile_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` - if test "x$enable_audiofiletest" = "xyes" ; then - AC_LANG_SAVE - AC_LANG_C - ac_save_CFLAGS="$CFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $AUDIOFILE_CFLAGS" - LIBS="$LIBS $AUDIOFILE_LIBS" -dnl -dnl Now check if the installed Audio File Library is sufficiently new. -dnl (Also checks the sanity of the results of audiofile-config to some extent.) -dnl - rm -f conf.audiofiletest - AC_TRY_RUN([ -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <audiofile.h> - -char* -my_strdup (char *str) -{ - char *new_str; - - if (str) - { - new_str = malloc ((strlen (str) + 1) * sizeof(char)); - strcpy (new_str, str); - } - else - new_str = NULL; - - return new_str; -} - -int main () -{ - int major, minor, micro; - char *tmp_version; - - system ("touch conf.audiofiletest"); - - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = my_strdup("$min_audiofile_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string\n", "$min_audiofile_version"); - exit(1); - } - - if (($audiofile_major_version > major) || - (($audiofile_major_version == major) && ($audiofile_minor_version > minor)) || - (($audiofile_major_version == major) && ($audiofile_minor_version == minor) && ($audiofile_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** 'audiofile-config --version' returned %d.%d.%d, but the minimum version\n", $audiofile_major_version, $audiofile_minor_version, $audiofile_micro_version); - printf("*** of the Audio File Library required is %d.%d.%d. If audiofile-config is correct, then it is\n", major, minor, micro); - printf("*** best to upgrade to the required version.\n"); - printf("*** If audiofile-config was wrong, set the environment variable AUDIOFILE_CONFIG\n"); - printf("*** to point to the correct copy of audiofile-config, and remove the file\n"); - printf("*** config.cache before re-running configure\n"); - return 1; - } -} - -],, no_audiofile=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - AC_LANG_RESTORE - fi - fi - if test "x$no_audiofile" = x ; then - AC_MSG_RESULT(yes) - ifelse([$2], , :, [$2]) - else - AC_MSG_RESULT(no) - if test "$AUDIOFILE_CONFIG" = "no" ; then - cat <<END -*** The audiofile-config script installed by the Audio File Library could -*** not be found. If the Audio File Library was installed in PREFIX, make -*** sure PREFIX/bin is in your path, or set the AUDIOFILE_CONFIG -*** environment variable to the full path to audiofile-config. -END - else - if test -f conf.audiofiletest ; then - : - else - echo "*** Could not run Audio File Library test program; checking why..." - AC_LANG_SAVE - AC_LANG_C - CFLAGS="$CFLAGS $AUDIOFILE_CFLAGS" - LIBS="$LIBS $AUDIOFILE_LIBS" - AC_TRY_LINK([ -#include <stdio.h> -#include <audiofile.h> -], [ return 0; ], - [ cat <<END -*** The test program compiled, but did not run. This usually means that -*** the run-time linker is not finding Audio File Library or finding the -*** wrong version of Audio File Library. -*** -*** If it is not finding Audio File Library, you'll need to set your -*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point -*** to the installed location. Also, make sure you have run ldconfig if -*** that is required on your system. -*** -*** If you have an old version installed, it is best to remove it, although -*** you may also be able to get things to work by modifying -*** LD_LIBRARY_PATH. -END - ], - [ echo "*** The test program failed to compile or link. See the file config.log" - echo "*** for the exact error that occured. This usually means the Audio File" - echo "*** Library was incorrectly installed or that you have moved the Audio" - echo "*** File Library since it was installed. In the latter case, you may want" - echo "*** to edit the audiofile-config script: $AUDIOFILE_CONFIG" ]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - AC_LANG_RESTORE - fi - fi - AUDIOFILE_CFLAGS="" - AUDIOFILE_LIBS="" - ifelse([$3], , :, [$3]) - fi - AC_SUBST(AUDIOFILE_CFLAGS) - AC_SUBST(AUDIOFILE_LIBS) - rm -f conf.audiofiletest -]) Modified: trunk/libspectrum/libspectrum/autogen.sh =================================================================== --- trunk/libspectrum/libspectrum/autogen.sh 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/libspectrum/autogen.sh 2012-12-06 11:55:57 UTC (rev 719) @@ -3,7 +3,7 @@ # autogen.sh: autotools invocation # Copyright (c) 2004 Philip Kendall -# $Id: autogen.sh 2890 2007-05-26 19:31:43Z zubzero $ +# $Id: autogen.sh 4751 2012-10-21 05:03:37Z fredm $ # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -26,7 +26,7 @@ # Exit on errors set -e -aclocal +aclocal -I m4 autoheader glibtoolize --automake automake --add-missing Copied: trunk/libspectrum/libspectrum/configure.ac (from rev 717, vendor/fuse-emulator/current/libspectrum/configure.ac) =================================================================== --- trunk/libspectrum/libspectrum/configure.ac (rev 0) +++ trunk/libspectrum/libspectrum/configure.ac 2012-12-06 11:55:57 UTC (rev 719) @@ -0,0 +1,224 @@ +dnl Process this file with autoconf to produce a configure script. +dnl Copyright (c) 1999-2008 Philip Kendall + +dnl $Id: configure.ac 4778 2012-11-28 23:21:34Z sbaldovi $ + +dnl This program is free software; you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 2 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License along +dnl with this program; if not, write to the Free Software Foundation, Inc., +dnl 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +dnl +dnl Author contact information: +dnl +dnl E-mail: phi...@sh... + +dnl Package version +m4_define([libspectrum_version], [1.0.0]) + +dnl Product full version +m4_define([libspectrum_major_version], [1]) +m4_define([libspectrum_minor_version], [0]) +m4_define([libspectrum_micro_version], [0]) +m4_define([libspectrum_nano_version], [0]) +m4_define([libspectrum_full_version], + [libspectrum_major_version.libspectrum_minor_version.libspectrum_micro_version.libspectrum_nano_version]) +m4_define([libspectrum_rc_version], + [libspectrum_major_version,libspectrum_minor_version,libspectrum_micro_version,libspectrum_nano_version]) + +dnl Package info +m4_define([libspectrum_copyright], ["(c) 1999-2012 Philip Kendall and others"]) +m4_define([libspectrum_url], + [http://fuse-emulator.sourceforge.net/libspectrum.php]) +m4_define([libspectrum_bugreport], + [http://sourceforge.net/tracker/?group_id=91293&atid=596648]) + +AC_INIT([libspectrum],[libspectrum_version],[libspectrum_bugreport], + [libspectrum],[libspectrum_url]) +AC_CONFIG_SRCDIR([libspectrum.c]) +AC_CONFIG_MACRO_DIR([m4]) +AC_CONFIG_HEADERS([config.h]) +AC_CANONICAL_HOST + +dnl Use automake to produce `Makefile.in' +AM_INIT_AUTOMAKE + +dnl Substitutions for .in files +LIBSPECTRUM_FULL_VERSION=libspectrum_full_version +LIBSPECTRUM_COPYRIGHT=libspectrum_copyright +LIBSPECTRUM_URL=libspectrum_url +AC_SUBST(LIBSPECTRUM_FULL_VERSION) +AC_SUBST(LIBSPECTRUM_COPYRIGHT) +AC_SUBST(LIBSPECTRUM_URL) + +dnl Definitions for config.h +AC_DEFINE([LIBSPECTRUM_RC_VERSION], [libspectrum_rc_version], + [Define version information for win32 dll library]) +AC_DEFINE([LIBSPECTRUM_COPYRIGHT], [libspectrum_copyright], + [Define copyright of libspectrum]) + +dnl Checks for programs. +AC_PROG_CC + +dnl Setup for compiling build tools (make-perl) +if test $cross_compiling = yes; then + AC_CHECK_PROGS(CC_FOR_BUILD, gcc cc) +else + CC_FOR_BUILD=$CC +fi +AC_MSG_CHECKING([for a C compiler for build tools]) +AC_MSG_RESULT([$CC_FOR_BUILD]) +AC_SUBST(CC_FOR_BUILD) + +LT_INIT +AC_PATH_PROG(PERL, perl) +AC_SUBST(PERL) + +dnl Checks for header files. +AC_HEADER_STDC +AC_CHECK_HEADERS(stdint.h strings.h unistd.h) + +dnl Checks for typedefs, structures, and compiler characteristics. +AC_C_CONST + +dnl Check for host specific programs +WINDRES_OBJ= +WINDRES_LDFLAGS= +case "$host_os" in + mingw32*) + AC_CHECK_TOOL([WINDRES], [windres], [no]) + if test "$WINDRES" != no; then + WINDRES_OBJ="windres.o" + WINDRES_LDFLAGS="-Xlinker windres.o" + fi + ;; +esac +AC_SUBST(WINDRES_OBJ) +AC_SUBST(WINDRES_LDFLAGS) + +dnl Check for big endianness +AC_C_BIGENDIAN + +dnl Check for functions +AC_CHECK_FUNCS(_snprintf _stricmp _strnicmp snprintf strcasecmp strncasecmp) + +dnl Allow the user to say that various libraries are in one place +AC_ARG_WITH(local-prefix, +[ --with-local-prefix=PFX local libraries installed in PFX (optional)], +CPPFLAGS="$CPPFLAGS -I$withval/include"; LDFLAGS="$LDFLAGS -L$withval/lib", +if test "$prefix" != "NONE"; then + CPPFLAGS="$CPPFLAGS -I$prefix/include"; LDFLAGS="$LDFLAGS -L$prefix/lib" +fi) + +dnl Check whether to use zlib (the UNIX version is called z, Win32 zdll) +AC_MSG_CHECKING(whether to use zlib) +AC_ARG_WITH(zlib, +[ --without-zlib don't use zlib], +if test "$withval" = no; then zlib=no; else zlib=yes; fi, +zlib=yes) +AC_MSG_RESULT($zlib) +if test "$zlib" = yes; then + AC_CHECK_HEADERS( + zlib.h, + AC_SEARCH_LIBS(compress2, z zdll) + ) +fi + +dnl Check whether to use libgcrypt +AC_MSG_CHECKING(whether to use libgcrypt) +AC_ARG_WITH(libgcrypt, +[ --without-libgcrypt don't use libgcrypt], +if test "$withval" = no; then libgcrypt=no; else libgcrypt=yes; fi, +libgcrypt=yes) +AC_MSG_RESULT($libgcrypt) +if test "$libgcrypt" = yes; then + AC_CHECK_HEADERS(gcrypt.h,LIBS="$LIBS -lgcrypt") +fi + +dnl Check whether to use libbz2 (1.0 or greater) +AC_MSG_CHECKING(whether to use libbz2) +AC_ARG_WITH(bzip2, +[ --without-bzip2 don't use libbz2], +if test "$withval" = no; then bzip2=no; else bzip2=yes; fi, +bzip2=yes) +AC_MSG_RESULT($bzip2) +if test "$bzip2" = yes; then + AC_CHECK_HEADER( + bzlib.h, + AC_CHECK_LIB(bz2,BZ2_bzDecompressInit) + ) +fi + +dnl Either find glib or use the replacement +AC_MSG_CHECKING(whether to use glib) +AC_ARG_WITH(glib, +[ --without-glib don't use glib], +if test "$withval" = no; then glib=no; else glib=yes; fi, +glib=yes) +AC_MSG_RESULT($glib) +if test "$glib" = yes; then + PKG_CHECK_MODULES( + GLIB, + glib-2.0, + AC_DEFINE([HAVE_LIB_GLIB], 1, [Defined if we've got glib]), + glib="no" + ) +fi + +AM_CONDITIONAL(USE_MYGLIB, test "$glib" = no) + +dnl If it appears we're using gcc as our compiler, turn on warnings +if test "$ac_cv_prog_gcc" = yes; then + CFLAGS="$CFLAGS -Wall" + dnl And possibly lots of warnings + AC_MSG_CHECKING(whether lots of warnings requested) + AC_ARG_ENABLE(warnings, + [ --enable-warnings give lots of warnings if using gcc], + if test "$enableval" = yes; then + warnings=yes; + else + warnings=no; + fi, + warnings=no) + AC_MSG_RESULT($warnings) + if test "$warnings" = yes; then + CFLAGS="$CFLAGS -Wstrict-prototypes -Wmissing-prototypes -Winline -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Waggregate-return -W -Wsign-compare" + fi +fi + +dnl Check whether to use libaudiofile +AC_MSG_CHECKING(whether to use libaudiofile) +AC_ARG_WITH(libaudiofile, +[ --without-libaudiofile don't use libaudiofile], +if test "$withval" = no; then libaudiofile=no; else libaudiofile=yes; fi, +libaudiofile=yes) +AC_MSG_RESULT($libaudiofile) +if test "$libaudiofile" = yes; then + PKG_CHECK_MODULES( + AUDIOFILE, + audiofile, + AC_DEFINE([HAVE_LIB_AUDIOFILE], 1, [Defined if we've got audiofile]), + [true] + ) + if test -z "$AUDIOFILE_LIBS"; then + AM_PATH_AUDIOFILE( + 0.2.3, + AC_DEFINE([HAVE_LIB_AUDIOFILE], 1, [Defined if we've got audiofile]) + ) + fi +fi + +AC_CONFIG_FILES([ + Makefile + libspectrum.qpg +]) + +AC_OUTPUT Deleted: trunk/libspectrum/libspectrum/configure.in =================================================================== --- trunk/libspectrum/libspectrum/configure.in 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/libspectrum/configure.in 2012-12-06 11:55:57 UTC (rev 719) @@ -1,196 +0,0 @@ -dnl Process this file with autoconf to produce a configure script. -dnl Copyright (c) 1999-2008 Philip Kendall - -dnl $Id: configure.in 4416 2011-05-02 12:59:42Z fredm $ - -dnl This program is free software; you can redistribute it and/or modify -dnl it under the terms of the GNU General Public License as published by -dnl the Free Software Foundation; either version 2 of the License, or -dnl (at your option) any later version. -dnl -dnl This program is distributed in the hope that it will be useful, -dnl but WITHOUT ANY WARRANTY; without even the implied warranty of -dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -dnl GNU General Public License for more details. -dnl -dnl You should have received a copy of the GNU General Public License along -dnl with this program; if not, write to the Free Software Foundation, Inc., -dnl 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -dnl -dnl Author contact information: -dnl -dnl E-mail: phi...@sh... - -AC_INIT(libspectrum.c) -AM_CONFIG_HEADER(config.h) - -define(LIBSPECTRUM_VERSION, [1.0.0]) - -dnl Use automake to produce `Makefile.in' -AM_INIT_AUTOMAKE(libspectrum, LIBSPECTRUM_VERSION) - -dnl Checks for programs. -AC_PROG_CC - -dnl Setup for compiling build tools (make-perl) -AC_MSG_CHECKING([for a C compiler for build tools]) -if test $cross_compiling = yes; then - AC_CHECK_PROGS(CC_FOR_BUILD, gcc cc) -else - CC_FOR_BUILD=$CC -fi -AC_MSG_RESULT([$CC_FOR_BUILD]) -AC_SUBST(CC_FOR_BUILD) - -AM_PROG_LIBTOOL -AC_PATH_PROG(PERL, perl) -AC_SUBST(PERL) - -dnl Checks for header files. -AC_HEADER_STDC -AC_CHECK_HEADERS(stdint.h strings.h unistd.h) - -dnl Checks for typedefs, structures, and compiler characteristics. -AC_C_CONST - -dnl Check whether to use Windows resource file utility -AC_MSG_CHECKING(whether to use windres) -AC_ARG_WITH(windres, -[ --without-windres don't use windres], -if test "$withval" = no; then windres=no; else windres=yes; fi, -windres=yes) -AC_MSG_RESULT($windres) -if test "$windres" = yes; then - AC_CHECK_TOOL(WINDRES, windres, no) - AC_SUBST(WINDRES) - if test "$WINDRES" != no; then - WINDRES_OBJ="windres.o" - WINDRES_LDFLAGS="-Xlinker windres.o" - define(LIBSPECTRUM_FULL_VERSION, - [ifelse(translit(LIBSPECTRUM_VERSION, [0-9]), [.], [LIBSPECTRUM_VERSION[.0.0]], - translit(LIBSPECTRUM_VERSION, [0-9]), [..], [LIBSPECTRUM_VERSION[.0]], - [LIBSPECTRUM_VERSION])])dnl - AC_DEFINE([VERSION_WIN32], [translit(LIBSPECTRUM_FULL_VERSION, [.], [,])], [Define version information for win32 dll library]) - fi -fi -AC_SUBST(WINDRES_OBJ) -AC_SUBST(WINDRES_LDFLAGS) - -dnl Check for big endianness -AC_C_BIGENDIAN - -dnl Check for functions -AC_CHECK_FUNCS(_snprintf _stricmp _strnicmp snprintf strcasecmp strncasecmp) - -dnl Allow the user to say that various libraries are in one place -AC_ARG_WITH(local-prefix, -[ --with-local-prefix=PFX local libraries installed in PFX (optional)], -CPPFLAGS="$CPPFLAGS -I$withval/include"; LDFLAGS="$LDFLAGS -L$withval/lib", -if test "$prefix" != "NONE"; then - CPPFLAGS="$CPPFLAGS -I$prefix/include"; LDFLAGS="$LDFLAGS -L$prefix/lib" -fi) - -dnl Check whether to use zlib (the UNIX version is called z, Win32 zdll) -AC_MSG_CHECKING(whether to use zlib) -AC_ARG_WITH(zlib, -[ --without-zlib don't use zlib], -if test "$withval" = no; then zlib=no; else zlib=yes; fi, -zlib=yes) -AC_MSG_RESULT($zlib) -if test "$zlib" = yes; then - AC_CHECK_HEADERS( - zlib.h, - AC_SEARCH_LIBS(compress2, z zdll) - ) -fi - -dnl Check whether to use libgcrypt -AC_MSG_CHECKING(whether to use libgcrypt) -AC_ARG_WITH(libgcrypt, -[ --without-libgcrypt don't use libgcrypt], -if test "$withval" = no; then libgcrypt=no; else libgcrypt=yes; fi, -libgcrypt=yes) -AC_MSG_RESULT($libgcrypt) -if test "$libgcrypt" = yes; then - AC_CHECK_HEADERS(gcrypt.h,LIBS="$LIBS -lgcrypt") -fi - -dnl Check whether to use libbz2 (1.0 or greater) -AC_MSG_CHECKING(whether to use libbz2) -AC_ARG_WITH(bzip2, -[ --without-bzip2 don't use libbz2], -if test "$withval" = no; then bzip2=no; else bzip2=yes; fi, -bzip2=yes) -AC_MSG_RESULT($bzip2) -if test "$bzip2" = yes; then - AC_CHECK_HEADER( - bzlib.h, - AC_CHECK_LIB(bz2,BZ2_bzDecompressInit) - ) -fi - -dnl Either find glib or use the replacement -AC_MSG_CHECKING(whether to use glib) -AC_ARG_WITH(glib, -[ --without-glib don't use glib], -if test "$withval" = no; then glib=no; else glib=yes; fi, -glib=yes) -AC_MSG_RESULT($glib) -if test "$glib" = yes; then - glib2=no - AM_PATH_GLIB_2_0( - 2.0.0, - glib2=yes - AC_DEFINE([HAVE_LIB_GLIB], 1, [Defined if we've got glib]) - LIBS="$LIBS `pkg-config --libs glib-2.0`", - ) - if test "$glib2" = no; then - AM_PATH_GLIB( - 1.2.0, - AC_DEFINE([HAVE_LIB_GLIB], 1, [Defined if we've got glib]) - LIBS="$LIBS `glib-config --libs`", - glib=no - AC_MSG_WARN(glib not found - using internal replacement) - ) - fi -fi - -AM_CONDITIONAL(USE_MYGLIB, test "$glib" = no) - -dnl If it appears we're using gcc as our compiler, turn on warnings -if test "$ac_cv_prog_gcc" = yes; then - CFLAGS="$CFLAGS -Wall" - dnl And possibly lots of warnings - AC_MSG_CHECKING(whether lots of warnings requested) - AC_ARG_ENABLE(warnings, - [ --enable-warnings give lots of warnings if using gcc], - if test "$enableval" = yes; then - warnings=yes; - else - warnings=no; - fi, - warnings=no) - AC_MSG_RESULT($warnings) - if test "$warnings" = yes; then - CFLAGS="$CFLAGS -Wstrict-prototypes -Wmissing-prototypes -Winline -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Waggregate-return -W -Wsign-compare" - fi -fi - -dnl Check whether to use libaudiofile -AC_MSG_CHECKING(whether to use libaudiofile) -AC_ARG_WITH(libaudiofile, -[ --without-libaudiofile don't use libaudiofile], -if test "$withval" = no; then libaudiofile=no; else libaudiofile=yes; fi, -libaudiofile=yes) -AC_MSG_RESULT($libaudiofile) -if test "$libaudiofile" = yes; then - AM_PATH_AUDIOFILE( - 0.2.3, - AC_DEFINE([HAVE_LIB_AUDIOFILE], 1, [Defined if we've got audiofile]) - ) -fi - -AC_OUTPUT( - Makefile - libspectrum.qpg -) Modified: trunk/libspectrum/libspectrum/hacking/ChangeLog =================================================================== --- trunk/libspectrum/libspectrum/hacking/ChangeLog 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/libspectrum/hacking/ChangeLog 2012-12-06 11:55:57 UTC (rev 719) @@ -875,3 +875,33 @@ (thanks, clang 2.1) (Fred). 20120220 make-perl.c: advertise that we support bzip2 compressed and wav files (part of patch #3413549) (Sergio Baldoví). +20120327 configure.in,Makefile.am,acinclude.m4: simplify detection of GLib + and drop support for version 1.x (patch #3508792) (Alberto Garcia) +20120327 configure.in: add support for audiofile 0.3.x (patch #3508658) (Alberto + Garcia). +20120506 make-perl.c,myglib/gslist.c: fix some const qualifiers for the data + argument to g_slist_remove and g_slist_find_custom (part of bug + #3514721) (Sergio Baldoví). +20120507 internals.h,libspectrum.c,libspectrum.h.in,make-perl.c,myglib/{ghash.c, + gslist.c}: add g_hash_table_new_full() and libspectrum_end() for memory + releasing (part of bug #3515269) (Sergio Baldoví). +20120916 Makefile.am: allow custom build flags for make-perl to address warning + from the debian build system (bug #3567469) (Sergio Baldoví). +20120928 szx.c: read all possible RAM pages from the snap (thanks, ketmar) + (Fred). +20121021 Makefile.am,acinclude.m4,autogen.sh,configure.ac,configure.in, + m4/audiofile.m4,windres.rc: modernise autoconf support (more from patch + #3575831) (Sergio). +20121026 configure.ac: fix the build when libaudiofile is not found and we are + using an old pkg-config/autoconf (bug #3579244) (Sergio). +20121107 Makefile.am: fix the build when source and build trees are different + (VPATH) (bug #3584527) (Sergio). +20121107 szx.c: fix potential calls to memcpy with a null pointer argument + (thanks, clang 4.1) (Fred). +20121107 libspectrum.c: fix potential leak of memory pointed to by + 'new_filename' (thanks, clang 4.1) (Fred). +20121126 memory.c,myglib/garray.c,windres.rc: fix hard-coded Id tags and add + missing properties (Sergio). +20121129 configure.ac: don't check for windres when not building for Windows + hosts. Remove --without-windres option, previously used as a workaround + (Sergio). Modified: trunk/libspectrum/libspectrum/internals.h =================================================================== --- trunk/libspectrum/libspectrum/internals.h 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/libspectrum/internals.h 2012-12-06 11:55:57 UTC (rev 719) @@ -2,7 +2,7 @@ routines, but not by user code Copyright (c) 2001-2008 Philip Kendall, Darren Salt - $Id: internals.h 4388 2011-04-27 12:52:26Z fredm $ + $Id: internals.h 4695 2012-05-07 02:03:10Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -258,4 +258,14 @@ extern const int LIBSPECTRUM_BITS_IN_BYTE; +/* glib replacement functions */ + +#ifndef HAVE_LIB_GLIB /* Only if we are using glib replacement */ +void +libspectrum_slist_cleanup( void ); + +void +libspectrum_hashtable_cleanup( void ); +#endif /* #ifndef HAVE_LIB_GLIB */ + #endif /* #ifndef LIBSPECTRUM_INTERNALS_H */ Modified: trunk/libspectrum/libspectrum/libspectrum.c =================================================================== --- trunk/libspectrum/libspectrum/libspectrum.c 2012-12-06 10:27:01 UTC (rev 718) +++ trunk/libspectrum/libspectrum/libspectrum.c 2012-12-06 11:55:57 UTC (rev 719) @@ -1,7 +1,7 @@ /* libspectrum.c: Some general routines Copyright (c) 2001-2009 Philip Kendall, Darren Salt, Fredrick Meunier - $Id: libspectrum.c 4539 2011-09-05 12:17:34Z fredm $ + $Id: libspectrum.c 4759 2012-11-07 12:01:50Z fredm $ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -121,6 +121,15 @@ return LIBSPECTRUM_ERROR_NONE; } +void +libspectrum_end( void ) +{ +#ifndef HAVE_LIB_GLIB + libspectrum_slist_cleanup(); + libspectrum_hashtable_cleanup(); +#endif /* #ifndef HAVE_LIB_GLIB */ +} + #ifdef HAVE_GCRYPT_H static void gcrypt_log_handler( void *opaque, int level, const char *format, va_list ap ) @@ -463,10 +472,12 @@ error = libspectrum_iden... [truncated message content] |