vice-emu-commit Mailing List for VICE (Page 3)
Versatile Commodore Emulator
Brought to you by:
blackystardust,
gpz
You can subscribe to this list here.
| 2008 |
Jan
|
Feb
|
Mar
|
Apr
(38) |
May
(60) |
Jun
(122) |
Jul
(148) |
Aug
(178) |
Sep
(151) |
Oct
(131) |
Nov
(208) |
Dec
(129) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2009 |
Jan
(193) |
Feb
(209) |
Mar
(221) |
Apr
(243) |
May
(165) |
Jun
(168) |
Jul
(198) |
Aug
(161) |
Sep
(103) |
Oct
(98) |
Nov
(168) |
Dec
(99) |
| 2010 |
Jan
(263) |
Feb
(156) |
Mar
(57) |
Apr
(93) |
May
(85) |
Jun
(124) |
Jul
(57) |
Aug
(58) |
Sep
(113) |
Oct
(148) |
Nov
(114) |
Dec
(193) |
| 2011 |
Jan
(200) |
Feb
(207) |
Mar
(91) |
Apr
(91) |
May
(142) |
Jun
(104) |
Jul
(115) |
Aug
(137) |
Sep
(266) |
Oct
(91) |
Nov
(85) |
Dec
(186) |
| 2012 |
Jan
(98) |
Feb
(146) |
Mar
(160) |
Apr
(99) |
May
(59) |
Jun
(257) |
Jul
(84) |
Aug
(103) |
Sep
(169) |
Oct
(206) |
Nov
(90) |
Dec
(296) |
| 2013 |
Jan
(294) |
Feb
(130) |
Mar
(36) |
Apr
(14) |
May
(51) |
Jun
(74) |
Jul
(180) |
Aug
(85) |
Sep
(26) |
Oct
(45) |
Nov
(29) |
Dec
(21) |
| 2014 |
Jan
(56) |
Feb
(40) |
Mar
(57) |
Apr
(30) |
May
(31) |
Jun
(11) |
Jul
(107) |
Aug
(135) |
Sep
(142) |
Oct
(195) |
Nov
(139) |
Dec
(133) |
| 2015 |
Jan
(293) |
Feb
(161) |
Mar
(146) |
Apr
(85) |
May
(139) |
Jun
(51) |
Jul
(21) |
Aug
(24) |
Sep
(29) |
Oct
(136) |
Nov
(212) |
Dec
(118) |
| 2016 |
Jan
(119) |
Feb
(165) |
Mar
(229) |
Apr
(219) |
May
(134) |
Jun
(119) |
Jul
(134) |
Aug
(236) |
Sep
(203) |
Oct
(215) |
Nov
(300) |
Dec
(140) |
| 2017 |
Jan
(188) |
Feb
(20) |
Mar
(147) |
Apr
(198) |
May
(26) |
Jun
(21) |
Jul
(67) |
Aug
(219) |
Sep
(209) |
Oct
(194) |
Nov
(144) |
Dec
(99) |
| 2018 |
Jan
(139) |
Feb
(122) |
Mar
(116) |
Apr
(85) |
May
(232) |
Jun
(181) |
Jul
(190) |
Aug
(105) |
Sep
(92) |
Oct
(178) |
Nov
(105) |
Dec
(86) |
| 2019 |
Jan
(119) |
Feb
(79) |
Mar
(74) |
Apr
(117) |
May
(115) |
Jun
(307) |
Jul
(107) |
Aug
(131) |
Sep
(103) |
Oct
(60) |
Nov
(118) |
Dec
(70) |
| 2020 |
Jan
(114) |
Feb
(103) |
Mar
(77) |
Apr
(121) |
May
(193) |
Jun
(110) |
Jul
(214) |
Aug
(210) |
Sep
(179) |
Oct
(260) |
Nov
(237) |
Dec
(334) |
| 2021 |
Jan
(163) |
Feb
(186) |
Mar
(58) |
Apr
(81) |
May
(108) |
Jun
(175) |
Jul
(154) |
Aug
(180) |
Sep
(217) |
Oct
(204) |
Nov
(232) |
Dec
(190) |
| 2022 |
Jan
(253) |
Feb
(134) |
Mar
(229) |
Apr
(190) |
May
(125) |
Jun
(70) |
Jul
(8) |
Aug
(22) |
Sep
(19) |
Oct
(33) |
Nov
(94) |
Dec
(164) |
| 2023 |
Jan
(158) |
Feb
(366) |
Mar
(272) |
Apr
(109) |
May
(198) |
Jun
(226) |
Jul
(200) |
Aug
(94) |
Sep
(108) |
Oct
(62) |
Nov
(175) |
Dec
(116) |
| 2024 |
Jan
(35) |
Feb
(40) |
Mar
(51) |
Apr
(89) |
May
(24) |
Jun
(26) |
Jul
(53) |
Aug
(71) |
Sep
(23) |
Oct
(11) |
Nov
(22) |
Dec
(58) |
| 2025 |
Jan
(26) |
Feb
(40) |
Mar
(107) |
Apr
(39) |
May
(35) |
Jun
(20) |
Jul
(11) |
Aug
(24) |
Sep
(35) |
Oct
(28) |
Nov
(12) |
Dec
|
|
From: <gp...@us...> - 2025-09-16 20:40:21
|
Revision: 45770
http://sourceforge.net/p/vice-emu/code/45770
Author: gpz
Date: 2025-09-16 20:40:19 +0000 (Tue, 16 Sep 2025)
Log Message:
-----------
missing ifdef
Modified Paths:
--------------
trunk/vice/src/c64/vsid-stubs.c
trunk/vice/src/joyport/joyport.c
Modified: trunk/vice/src/c64/vsid-stubs.c
===================================================================
--- trunk/vice/src/c64/vsid-stubs.c 2025-09-16 20:19:50 UTC (rev 45769)
+++ trunk/vice/src/c64/vsid-stubs.c 2025-09-16 20:40:19 UTC (rev 45770)
@@ -1286,6 +1286,7 @@
DIAG harness
*******************************************************************************/
+#ifdef HAVE_EXPERIMENTAL_DEVICES
void c64_diag_586220_store_joyport_dig(uint8_t port, uint8_t val)
{
}
@@ -1299,8 +1300,8 @@
{
return 0;
}
+#endif
-
/*******************************************************************************
UI
*******************************************************************************/
Modified: trunk/vice/src/joyport/joyport.c
===================================================================
--- trunk/vice/src/joyport/joyport.c 2025-09-16 20:19:50 UTC (rev 45769)
+++ trunk/vice/src/joyport/joyport.c 2025-09-16 20:40:19 UTC (rev 45770)
@@ -1421,6 +1421,7 @@
NULL, /* resources shutdown function */
NULL /* cmdline options init function */
},
+#ifdef JOYPORT_EXPERIMENTAL_DEVICES
{ JOYPORT_ID_DIAG_586220_HARNESS, /* device id */
VICE_MACHINE_C64_COMPATIBLE, /* emulators this device works on */
joyport_diag_586220_harness_resources_init, /* resources init function */
@@ -1427,6 +1428,7 @@
NULL, /* resources shutdown function */
NULL /* cmdline options init function */
},
+#endif
{ JOYPORT_ID_NONE, VICE_MACHINE_NONE, NULL, NULL, NULL }, /* end of the devices list */
};
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-16 20:19:52
|
Revision: 45769
http://sourceforge.net/p/vice-emu/code/45769
Author: gpz
Date: 2025-09-16 20:19:50 +0000 (Tue, 16 Sep 2025)
Log Message:
-----------
added joyport side of the 586220 diag harness, fixed some other details. iec port and keyboard port dongles are still missing
Modified Paths:
--------------
trunk/vice/src/c64/Makefile.am
trunk/vice/src/c64/vsid-stubs.c
trunk/vice/src/diag/Makefile.am
trunk/vice/src/diag/c64_diag_586220_harness.c
trunk/vice/src/joyport/Makefile.am
trunk/vice/src/joyport/joyport.c
trunk/vice/src/joyport/joyport.h
trunk/vice/src/tapeport/tape_diag_586220_harness.c
trunk/vice/src/userport/userport_diag_586220_harness.c
Added Paths:
-----------
trunk/vice/src/joyport/joyport_diag_586220_harness.c
trunk/vice/src/joyport/joyport_diag_586220_harness.h
Modified: trunk/vice/src/c64/Makefile.am
===================================================================
--- trunk/vice/src/c64/Makefile.am 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/c64/Makefile.am 2025-09-16 20:19:50 UTC (rev 45769)
@@ -26,6 +26,7 @@
-I$(top_srcdir)/src/hvsc \
-I$(top_srcdir)/src/vdrive \
-I$(top_srcdir)/src/fsdevice \
+ -I$(top_srcdir)/src/diag \
-I$(top_srcdir)/src/imagecontents
AM_CFLAGS = @VICE_CFLAGS@
Modified: trunk/vice/src/c64/vsid-stubs.c
===================================================================
--- trunk/vice/src/c64/vsid-stubs.c 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/c64/vsid-stubs.c 2025-09-16 20:19:50 UTC (rev 45769)
@@ -1282,7 +1282,25 @@
return false;
}
+/*******************************************************************************
+ DIAG harness
+*******************************************************************************/
+void c64_diag_586220_store_joyport_dig(uint8_t port, uint8_t val)
+{
+}
+
+uint8_t c64_diag_586220_read_joyport_dig(uint8_t port)
+{
+ return 0;
+}
+
+uint8_t c64_diag_586220_read_joyport_pot(void)
+{
+ return 0;
+}
+
+
/*******************************************************************************
UI
*******************************************************************************/
Modified: trunk/vice/src/diag/Makefile.am
===================================================================
--- trunk/vice/src/diag/Makefile.am 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/diag/Makefile.am 2025-09-16 20:19:50 UTC (rev 45769)
@@ -3,6 +3,8 @@
@ARCH_INCLUDES@ \
-I$(top_builddir)/src \
-I$(top_srcdir)/src \
+ -I$(top_srcdir)/src/c64 \
+ -I$(top_srcdir)/src/joyport \
-I$(top_srcdir)/src/datasette \
-I$(top_srcdir)/src/tapeport
Modified: trunk/vice/src/diag/c64_diag_586220_harness.c
===================================================================
--- trunk/vice/src/diag/c64_diag_586220_harness.c 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/diag/c64_diag_586220_harness.c 2025-09-16 20:19:50 UTC (rev 45769)
@@ -30,21 +30,38 @@
#include <string.h>
#include "c64_diag_586220_harness.h"
+#include "c64.h"
+#include "cia.h"
#include "datasette.h"
+#include "machine.h"
#include "tapeport.h"
#include "types.h"
+#include "log.h"
+/*#define DEBUG_DIAG_586220*/
+
+#ifdef DEBUG_DIAG_586220
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
static uint8_t c64_diag_userport_pax = 0;
static uint8_t c64_diag_userport_pbx = 0;
static uint8_t c64_diag_userport_sp1 = 0;
static uint8_t c64_diag_userport_sp2 = 0;
+
static uint8_t c64_diag_tapeport = 0;
+static uint8_t c64_diag_switches = 0;
+
static uint8_t c64_diag_joyport0 = 0;
static uint8_t c64_diag_joyport1 = 0;
+static uint8_t c64_diag_joyvalue = 0;
+
static uint8_t c64_diag_keyboard_pax = 0;
static uint8_t c64_diag_keyboard_pbx = 0;
+
static uint8_t c64_diag_serial = 0;
-static uint8_t c64_diag_switches = 0;
void c64_diag_586220_init(void)
{
@@ -61,25 +78,96 @@
c64_diag_switches = 0;
}
+
+/* USERPORT connector
+
+PIN | PIN | NOTES
+-----------------
+ 4 | 6 | CNT1 <-> CNT2
+ 5 | 7 | SP1 <-> SP2
+ 9 | M | PA3 <-> PA2
+ B | 8 | FLAG2 <- PC2
+
+ C | H | PB0 <-> PB4
+ D | J | PB1 <-> PB5
+ E | K | PB2 <-> PB6
+ F | L | PB3 <-> PB7
+
+no data lines go to other ports
+
+*/
+
+/* called by userport_diag_586220_harness_store_paX() */
void c64_diag_586220_store_userport_pax(uint8_t val)
{
c64_diag_userport_pax = val;
+ DBG(("c64_diag_586220_store_userport_pax %02x", val));
}
-
+/* called by userport_diag_586220_harness_store_pbx() */
void c64_diag_586220_store_userport_pbx(uint8_t val)
{
c64_diag_userport_pbx = val;
}
-
+/* called by userport_diag_586220_harness_store_spX */
void c64_diag_586220_store_userport_sp(uint8_t port, uint8_t val)
{
+ DBG(("c64_diag_586220_store_userport_sp port:%d val:%02x", port, val));
if (!port) {
+ ciacore_set_sdr(machine_context.cia2, val);
+ c64_diag_userport_sp2 = val;
+ } else {
+ ciacore_set_sdr(machine_context.cia1, val);
c64_diag_userport_sp1 = val;
- } else {
- c64_diag_userport_sp2 = val;
}
}
+/* called from userport_diag_586220_harness_read_paX */
+uint8_t c64_diag_586220_read_userport_pax(void)
+{
+ uint8_t retval;
+
+ retval = (c64_diag_userport_pax & 4) << 1; /* bit2 -> bit3 */
+ retval |= (c64_diag_userport_pax & 8) >> 1; /* bit3 -> bit2 */
+
+ retval ^= 0x0c;
+
+ DBG(("c64_diag_586220_read_userport_pax %02x", retval));
+ return retval;
+}
+/* called from userport_diag_586220_harness_read_pbx */
+uint8_t c64_diag_586220_read_userport_pbx(void)
+{
+ uint8_t retval;
+
+ retval = (c64_diag_userport_pbx >> 4) & 0x0f; /* bit4-7 -> bit0-3 */
+ retval |= (c64_diag_userport_pbx & 0x0f) << 4; /* bit0-3 -> bit4-7 */
+
+ return retval;
+}
+/* called from userport_diag_586220_harness_read_spX */
+uint8_t c64_diag_586220_read_userport_sp(uint8_t port)
+{
+ DBG(("c64_diag_586220_read_userport_sp port:%d val:%02x",
+ port, port ? c64_diag_userport_sp2 : c64_diag_userport_sp1));
+ if (!port) {
+ return c64_diag_userport_sp1;
+ }
+ return c64_diag_userport_sp2;
+}
+
+
+/* TAPE connector
+
+PIN | CABLE | NOTES
+-------------------
+C-3 | 7 | Motor | Joyport Switches control (MOTOR) can ground the line
+D-4 | 6 | Read | loops to 4 (READ <-> SENSE)
+E-5 | 5 | Write | Joyport Switches control (WRITE) can ground the line
+F-6 | 4 | Sense | loops to 6 (SENSE <-> READ)
+
+*/
+
+/* called from tape_diag_586220_harness... */
void c64_diag_586220_store_tapeport(uint8_t pin, uint8_t val)
{
c64_diag_tapeport &= ~(1 << pin);
@@ -86,17 +174,23 @@
c64_diag_tapeport |= (val << pin);
switch (pin) {
+ /* motor <-> write */
case C64_DIAG_TAPEPORT_MOTOR:
+ DBG(("c64_diag_586220_store_tapeport motor:%d",val));
machine_set_tape_write_in(TAPEPORT_PORT_1, val);
break;
+ case C64_DIAG_TAPEPORT_WRITE:
+ DBG(("c64_diag_586220_store_tapeport write:%d",val));
+ machine_set_tape_motor_in(TAPEPORT_PORT_1, val);
+ break;
+ /* read <-> sense */
case C64_DIAG_TAPEPORT_READ:
+ DBG(("c64_diag_586220_store_tapeport read:%d\n",val));
machine_set_tape_sense(TAPEPORT_PORT_1, val);
break;
- case C64_DIAG_TAPEPORT_WRITE:
- machine_set_tape_motor_in(TAPEPORT_PORT_1, val);
- break;
case C64_DIAG_TAPEPORT_SENSE:
- machine_trigger_flux_change(TAPEPORT_PORT_1, val);
+ DBG(("c64_diag_586220_store_tapeport sense:%d\n",val));
+ machine_set_tape_read_in(TAPEPORT_PORT_1, val);
break;
}
@@ -107,85 +201,78 @@
}
}
-void c64_diag_586220_store_joyport_dig(uint8_t port, uint8_t val)
+#if 0
+/* TODO: unused */
+uint8_t c64_diag_586220_read_tapeport(uint8_t pin)
{
- if (!port) {
- c64_diag_joyport0 = val;
- } else {
- c64_diag_joyport1 = val;
- }
-}
-
-void c64_diag_586220_store_keyboard(uint8_t port, uint8_t val)
-{
- if (!port) {
- c64_diag_keyboard_pax = val;
- } else {
- c64_diag_keyboard_pbx = val;
- }
-}
-
-void c64_diag_586220_store_serial(uint8_t val)
-{
- c64_diag_serial = val;
-}
-
-uint8_t c64_diag_586220_read_userport_pax(void)
-{
uint8_t retval;
- retval = (c64_diag_userport_pax & 4) << 1;
- retval |= (c64_diag_userport_pax & 2) >> 1;
+ retval = c64_diag_tapeport & 0xf5;
+ retval |= (c64_diag_tapeport & 8) >> 2;
+ retval |= (c64_diag_tapeport & 2) << 2;
+ retval &= (1 << pin);
return retval;
}
+#endif
-uint8_t c64_diag_586220_read_userport_pbx(void)
-{
- uint8_t retval;
+/* JOYSTICK connector
- retval = c64_diag_userport_pbx >> 4;
- retval |= (c64_diag_userport_pbx & 0xf) << 4;
+when enabled, via the analog switch connected to the tape port, bits0-4 of the
+two joystick ports are connected 1:1
- return retval;
-}
+*/
-uint8_t c64_diag_586220_read_userport_sp(uint8_t port)
+/* called by harness_store_dig */
+void c64_diag_586220_store_joyport_dig(uint8_t port, uint8_t val)
{
+ /*DBG(("c64_diag_586220_store_joyport_dig port:%d val:%02x", port, val));*/
if (!port) {
- return c64_diag_userport_sp2;
+ c64_diag_joyport0 = val;
+ } else {
+ c64_diag_joyport1 = val;
}
- return c64_diag_userport_sp1;
+ c64_diag_joyvalue = val;
}
-uint8_t c64_diag_586220_read_tapeport(uint8_t pin)
-{
- uint8_t retval;
-
- retval = c64_diag_tapeport & 0xf5;
- retval |= (c64_diag_tapeport & 8) >> 2;
- retval |= (c64_diag_tapeport & 2) << 2;
- retval &= (1 << pin);
-
- return retval;
-}
-
+/* called by harness_read_dig */
uint8_t c64_diag_586220_read_joyport_dig(uint8_t port)
{
+ /*DBG(("c64_diag_586220_read_joyport_dig port:%d",port));*/
if (c64_diag_switches) {
+#if 0
if (!port) {
return c64_diag_joyport1;
}
return c64_diag_joyport0;
+#endif
+ return c64_diag_joyvalue;
}
- return 0;
+ return 0xff;
}
+/* called by harness_read_potX */
uint8_t c64_diag_586220_read_joyport_pot(void)
{
- return 0xff;
+ /* resistor value for all resistors is 120Ohm */
+ /* diag expects 0x58...0x78 */
+ return 0x60;
}
+
+/* KEYBOARD connector */
+
+/* TODO: unused */
+void c64_diag_586220_store_keyboard(uint8_t port, uint8_t val)
+{
+ if (!port) {
+ c64_diag_keyboard_pax = val;
+ } else {
+ c64_diag_keyboard_pbx = val;
+ }
+}
+
+/* TODO: unused */
uint8_t c64_diag_586220_read_keyboard(uint8_t port)
{
if (!port) {
@@ -194,14 +281,41 @@
return c64_diag_keyboard_pax;
}
+
+/* IEC connector
+
+PIN | CABLE | NOTES
+--------------------------------------------------------------------------------
+1-5 | SRQIN - DATA | SRQIN->CIA1 FLAG DATA->CIA2 PA5/PA7
+3-4 | ATN - CLOCK |
+
+*/
+
+/* TODO: unused */
+void c64_diag_586220_store_serial(uint8_t val)
+{
+ /* Bit 7 Serial Bus Data Input
+ Bit 6 Serial Bus Clock Pulse Input
+ Bit 5 Serial Bus Data Output
+ Bit 4 Serial Bus Clock Pulse Output
+ Bit 3 Serial Bus ATN Signal Output */
+ DBG(("c64_diag_586220_store_serial %02x", val));
+ c64_diag_serial = val;
+}
+
+/* TODO: unused */
uint8_t c64_diag_586220_read_serial(void)
{
uint8_t retval;
- retval = (c64_diag_serial & 8) >> 3;
- retval |= (c64_diag_serial & 4) >> 1;
- retval |= (c64_diag_serial & 2) << 1;
- retval |= (c64_diag_serial & 1) << 3;
-
+ retval = ((c64_diag_serial >> 3) & 1) << 6; /* ATN Output -> Clock Input */
+ retval |= ((c64_diag_serial >> 5) & 1) << 7; /* Data Output -> SRQIN */
+ /* Bit 7 Serial Bus Data Input
+ Bit 6 Serial Bus Clock Pulse Input
+ Bit 5 Serial Bus Data Output
+ Bit 4 Serial Bus Clock Pulse Output
+ Bit 3 Serial Bus ATN Signal Output */
+ DBG(("c64_diag_586220_read_serial %02x (%02x)", c64_diag_serial, retval));
return retval;
}
+
Modified: trunk/vice/src/joyport/Makefile.am
===================================================================
--- trunk/vice/src/joyport/Makefile.am 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/joyport/Makefile.am 2025-09-16 20:19:50 UTC (rev 45769)
@@ -8,7 +8,8 @@
-I$(top_srcdir)/src \
-I$(top_srcdir)/src/samplerdrv \
-I$(top_srcdir)/src/core/rtc \
- -I$(top_srcdir)/src/userport
+ -I$(top_srcdir)/src/userport \
+ -I$(top_srcdir)/src/diag
AM_CFLAGS = @VICE_CFLAGS@
@@ -34,6 +35,8 @@
inception.h \
joyport.c \
joyport.h \
+ joyport_diag_586220_harness.c \
+ joyport_diag_586220_harness.h \
joyport_io_sim.c \
joyport_io_sim.h \
joystick.c \
Modified: trunk/vice/src/joyport/joyport.c
===================================================================
--- trunk/vice/src/joyport/joyport.c 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/joyport/joyport.c 2025-09-16 20:19:50 UTC (rev 45769)
@@ -39,6 +39,7 @@
#include "cx85.h"
#include "inception.h"
#include "joyport.h"
+#include "joyport_diag_586220_harness.h"
#include "joyport_io_sim.h"
#include "joystick.h"
#include "lib.h"
@@ -132,6 +133,7 @@
return pot_port_mask_clk;
}
+/* FIXME: isn't this info in the registered device struct? */
static int joyport_device_is_single_port(int id)
{
switch (id) {
@@ -149,6 +151,7 @@
case JOYPORT_ID_PROTOPAD:
case JOYPORT_ID_PADDLES:
case JOYPORT_ID_IO_SIMULATION:
+ case JOYPORT_ID_DIAG_586220_HARNESS:
return 0;
}
return 1;
@@ -1418,6 +1421,12 @@
NULL, /* resources shutdown function */
NULL /* cmdline options init function */
},
+ { JOYPORT_ID_DIAG_586220_HARNESS, /* device id */
+ VICE_MACHINE_C64_COMPATIBLE, /* emulators this device works on */
+ joyport_diag_586220_harness_resources_init, /* resources init function */
+ NULL, /* resources shutdown function */
+ NULL /* cmdline options init function */
+ },
{ JOYPORT_ID_NONE, VICE_MACHINE_NONE, NULL, NULL, NULL }, /* end of the devices list */
};
Modified: trunk/vice/src/joyport/joyport.h
===================================================================
--- trunk/vice/src/joyport/joyport.h 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/joyport/joyport.h 2025-09-16 20:19:50 UTC (rev 45769)
@@ -85,6 +85,7 @@
JOYPORT_ID_PAPERCLIP64SC,
JOYPORT_ID_PAPERCLIP2,
JOYPORT_ID_POWERPAD,
+ JOYPORT_ID_DIAG_586220_HARNESS,
/* This item always needs to be at the end */
JOYPORT_MAX_DEVICES
@@ -150,7 +151,8 @@
JOYPORT_DEVICE_SAMPLER,
JOYPORT_DEVICE_RTC,
JOYPORT_DEVICE_C64_DONGLE,
- JOYPORT_DEVICE_IO_SIMULATION
+ JOYPORT_DEVICE_IO_SIMULATION,
+ JOYPORT_DEVICE_DIAG_HARNESS,
};
/* joystick bits */
Added: trunk/vice/src/joyport/joyport_diag_586220_harness.c
===================================================================
--- trunk/vice/src/joyport/joyport_diag_586220_harness.c (rev 0)
+++ trunk/vice/src/joyport/joyport_diag_586220_harness.c 2025-09-16 20:19:50 UTC (rev 45769)
@@ -0,0 +1,113 @@
+/*
+ * joyport_diag_586220_harness.c - Joyport part of the DIAG 586220 harness
+ *
+ * Written by
+ * groepaz <gr...@gm...>
+ *
+ * This file is part of VICE, the Versatile Commodore Emulator.
+ * See README for copyright notice.
+ *
+ * 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., 59 Temple Place, Suite 330, Boston, MA
+ * 02111-1307 USA.
+ *
+ */
+
+#include "vice.h"
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#include "c64_diag_586220_harness.h"
+#include "joyport_diag_586220_harness.h"
+#include "joyport.h"
+#include "joystick.h"
+#include "machine.h"
+#include "resources.h"
+#include "snapshot.h"
+#include "log.h"
+
+/*#define DEBUG_DIAG_586220*/
+
+#ifdef DEBUG_DIAG_586220
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
+#ifdef JOYPORT_EXPERIMENTAL_DEVICES
+
+static uint8_t harness_read_dig(int joyport)
+{
+ uint8_t retval = c64_diag_586220_read_joyport_dig(joyport);
+ /*DBG(("harness_read_dig port:%d retval:%02x", joyport, retval));*/
+ return retval;
+}
+
+static void harness_store_dig(int joyport, uint8_t val)
+{
+ /*DBG(("harness_store_dig port:%d val:%02x", joyport, val));*/
+ c64_diag_586220_store_joyport_dig(joyport, val);
+}
+
+static uint8_t harness_read_potx(int joyport)
+{
+ return c64_diag_586220_read_joyport_pot();
+}
+
+static uint8_t harness_read_poty(int joyport)
+{
+ return c64_diag_586220_read_joyport_pot();
+}
+
+
+static int joyport_harness_enabled[JOYPORT_MAX_PORTS] = {0};
+
+static int joyport_harness_set_enabled(int port, int enabled)
+{
+ int new_state = enabled ? 1 : 0;
+
+ joyport_harness_enabled[port] = new_state;
+
+ return 0;
+}
+
+static joyport_t joyport_harness_device = {
+ "586220 DIAG Harness", /* name of the device */
+ JOYPORT_RES_ID_NONE, /* device can be used in multiple ports at the same time */
+ JOYPORT_IS_NOT_LIGHTPEN, /* device is NOT a lightpen */
+ JOYPORT_POT_REQUIRED, /* device uses the potentiometer lines */
+ JOYPORT_5VDC_NOT_NEEDED, /* device does NOT need +5VDC to work */
+ JOYSTICK_ADAPTER_ID_NONE, /* device is NOT a joystick adapter */
+ JOYPORT_DEVICE_DIAG_HARNESS, /* device is a diag harness */
+ 0, /* output bits are programmable */
+ joyport_harness_set_enabled, /* device enable/disable function */
+ harness_read_dig, /* digital line read function */
+ harness_store_dig, /* digital line store function */
+ harness_read_potx, /* pot-x read function */
+ harness_read_poty, /* pot-y read function */
+ NULL, /* NO powerup function */
+ NULL, /* NO device write snapshot function */
+ NULL, /* NO device read snapshot function */
+ NULL, /* NO device hook function */
+ 0 /* NO device hook function mask */
+};
+
+int joyport_diag_586220_harness_resources_init(void)
+{
+ return joyport_device_register(JOYPORT_ID_DIAG_586220_HARNESS, &joyport_harness_device);
+}
+
+#endif
Added: trunk/vice/src/joyport/joyport_diag_586220_harness.h
===================================================================
--- trunk/vice/src/joyport/joyport_diag_586220_harness.h (rev 0)
+++ trunk/vice/src/joyport/joyport_diag_586220_harness.h 2025-09-16 20:19:50 UTC (rev 45769)
@@ -0,0 +1,34 @@
+/*
+ * joyport_diag_586220_harness.h
+ *
+ * Written by
+ * groepaz <gr...@gm...>
+ *
+ * This file is part of VICE, the Versatile Commodore Emulator.
+ * See README for copyright notice.
+ *
+ * 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., 59 Temple Place, Suite 330, Boston, MA
+ * 02111-1307 USA.
+ *
+ */
+
+#ifndef VICE_JOYPORT_DIAG_586220_HARNESS_H
+#define VICE_JOYPORT_DIAG_586220_HARNESS_H
+
+#include "types.h"
+
+int joyport_diag_586220_harness_resources_init(void);
+
+#endif
Modified: trunk/vice/src/tapeport/tape_diag_586220_harness.c
===================================================================
--- trunk/vice/src/tapeport/tape_diag_586220_harness.c 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/tapeport/tape_diag_586220_harness.c 2025-09-16 20:19:50 UTC (rev 45769)
@@ -31,11 +31,11 @@
PIN | CABLE | NOTES
-------------------
-A-1 | 8 | SWa, SWb, SWc, SWd, SWa2 control (+5V)
-C-3 | 7 | SWa, SWb, SWc, SWd, SWa2 control (MOTOR) can ground the line
-D-4 | 6 | loops to 4 (READ <-> SENSE)
-E-5 | 5 | SWa, SWb, SWc, SWd, SWa2 control (WRITE) can ground the line
-F-6 | 4 | loops to 6 (SENSE <-> READ)
+C-3 | 7 | Motor | Joyport Switches control (MOTOR) can ground the line
+D-4 | 6 | Read | loops to 4 (READ <-> SENSE)
+E-5 | 5 | Write | Joyport Switches control (WRITE) can ground the line
+F-6 | 4 | Sense | loops to 6 (SENSE <-> READ)
+
*/
#include "vice.h"
@@ -55,6 +55,14 @@
#include "tapeport.h"
#include "util.h"
+/*#define DEBUG_DIAG_586220*/
+
+#ifdef DEBUG_DIAG_586220
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
#ifdef TAPEPORT_EXPERIMENTAL_DEVICES
/* Device enabled */
@@ -96,7 +104,7 @@
static void tape_diag_586220_harness_toggle_write_bit(int port, int write_bit)
{
- c64_diag_586220_store_tapeport(C64_DIAG_TAPEPORT_WRITE, (uint8_t)write_bit);
+ c64_diag_586220_store_tapeport(C64_DIAG_TAPEPORT_WRITE, (uint8_t)write_bit ? 1 : 0);
}
static void tape_diag_586220_harness_set_sense_out(int port, int sense)
Modified: trunk/vice/src/userport/userport_diag_586220_harness.c
===================================================================
--- trunk/vice/src/userport/userport_diag_586220_harness.c 2025-09-14 16:30:53 UTC (rev 45768)
+++ trunk/vice/src/userport/userport_diag_586220_harness.c 2025-09-16 20:19:50 UTC (rev 45769)
@@ -28,22 +28,18 @@
PIN | PIN | NOTES
-----------------
- 4 | 6 | CNT1 <-> CNT2
- 5 | 7 | SP1 <-> SP2
- 6 | 4 | CNT2 <-> CNT1
- 7 | 5 | SP2 <-> SP1
- 8 | B | PC2 -> FLAG2
- 9 | M | PA3 <-> PA2
- B | 8 | FLAG2 <- PC2
- C | H | PB0 <-> PB4
- D | J | PB1 <-> PB5
- E | K | PB2 <-> PB6
- F | L | PB3 <-> PB7
- H | C | PB4 <-> PB0
- J | D | PB5 <-> PB1
- K | E | PB6 <-> PB2
- L | F | PB7 <-> PB3
- M | 9 | PA2 <-> PA3
+ 4 | 6 | CNT1 <-> CNT2
+ 5 | 7 | SP1 <-> SP2
+ 9 | M | PA3 <-> PA2
+ B | 8 | FLAG2 <- PC2
+
+ C | H | PB0 <-> PB4
+ D | J | PB1 <-> PB5
+ E | K | PB2 <-> PB6
+ F | L | PB3 <-> PB7
+
+no data lines go to other ports
+
*/
#include "vice.h"
@@ -58,7 +54,16 @@
#include "joyport.h"
#include "userport.h"
#include "userport_diag_586220_harness.h"
+#include "log.h"
+/*#define DEBUG_DIAG_586220*/
+
+#ifdef DEBUG_DIAG_586220
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
#ifdef USERPORT_EXPERIMENTAL_DEVICES
int userport_diag_586220_harness_enabled = 0;
@@ -138,10 +143,11 @@
static void userport_diag_586220_harness_store_pa2(uint8_t value)
{
- pax &= 0xfb;
- pax |= ((value & 1) << 2);
+ pax &= 0xfb;
+ pax |= ((value & 1) << 2);
- c64_diag_586220_store_userport_pax(pax);
+ DBG(("userport_diag_586220_harness_store_pa2 %02x (%02x)", value, pax));
+ c64_diag_586220_store_userport_pax(pax);
}
static uint8_t userport_diag_586220_harness_read_pa3(uint8_t orig)
@@ -151,10 +157,10 @@
static void userport_diag_586220_harness_store_pa3(uint8_t value)
{
- pax &= 0xf7;
- pax |= ((value & 1) << 3);
-
- c64_diag_586220_store_userport_pax(pax);
+ pax &= 0xf7;
+ pax |= ((value & 1) << 3);
+ DBG(("userport_diag_586220_harness_store_pa3 %02x (%02x)", value, pax));
+ c64_diag_586220_store_userport_pax(pax);
}
static uint8_t userport_diag_586220_harness_read_sp1(uint8_t orig)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 16:30:55
|
Revision: 45768
http://sourceforge.net/p/vice-emu/code/45768
Author: gpz
Date: 2025-09-14 16:30:53 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
add build_mac to publish_release and build_error_notify. macos builds should be ok now :)
Modified Paths:
--------------
trunk/.github/workflows/build-main-on-push.yml
Modified: trunk/.github/workflows/build-main-on-push.yml
===================================================================
--- trunk/.github/workflows/build-main-on-push.yml 2025-09-14 16:08:24 UTC (rev 45767)
+++ trunk/.github/workflows/build-main-on-push.yml 2025-09-14 16:30:53 UTC (rev 45768)
@@ -622,7 +622,7 @@
publish_release:
name: Publish Release
- needs: [create_release, build, build_deb]
+ needs: [create_release, build, build_deb, build_mac]
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v7
@@ -640,7 +640,7 @@
build_error_notify:
name: IRC Notification of Build Errors
- needs: [cleanup_previous_builds, create_release, build_doc, build, build_deb, publish_release]
+ needs: [cleanup_previous_builds, create_release, build_doc, build, build_deb, build_mac, publish_release]
runs-on: ubuntu-latest
if: ${{ failure() }}
steps:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 16:08:26
|
Revision: 45767
http://sourceforge.net/p/vice-emu/code/45767
Author: gpz
Date: 2025-09-14 16:08:24 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
set env var(s)
Modified Paths:
--------------
trunk/.github/workflows/build-main-on-push.yml
Modified: trunk/.github/workflows/build-main-on-push.yml
===================================================================
--- trunk/.github/workflows/build-main-on-push.yml 2025-09-14 15:44:35 UTC (rev 45766)
+++ trunk/.github/workflows/build-main-on-push.yml 2025-09-14 16:08:24 UTC (rev 45767)
@@ -1,4 +1,6 @@
name: Snapshot Build
+env:
+ PATH_ARTIFACTS: dist
on:
push:
tags:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 15:44:37
|
Revision: 45766
http://sourceforge.net/p/vice-emu/code/45766
Author: gpz
Date: 2025-09-14 15:44:35 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
don't use non existing configure option :)
Modified Paths:
--------------
trunk/.github/workflows/build-main-on-push.yml
Modified: trunk/.github/workflows/build-main-on-push.yml
===================================================================
--- trunk/.github/workflows/build-main-on-push.yml 2025-09-14 15:33:37 UTC (rev 45765)
+++ trunk/.github/workflows/build-main-on-push.yml 2025-09-14 15:44:35 UTC (rev 45766)
@@ -578,7 +578,6 @@
./configure --enable-option-checking=fatal \
--prefix=/usr \
--disable-arch \
- --enable-usbsid \
--enable-cpuhistory \
--enable-parsid \
--with-pulse \
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 15:33:39
|
Revision: 45765
http://sourceforge.net/p/vice-emu/code/45765
Author: gpz
Date: 2025-09-14 15:33:37 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
ehrm invalid file?
Modified Paths:
--------------
trunk/.github/workflows/build-main-on-push.yml
Modified: trunk/.github/workflows/build-main-on-push.yml
===================================================================
--- trunk/.github/workflows/build-main-on-push.yml 2025-09-14 15:29:27 UTC (rev 45764)
+++ trunk/.github/workflows/build-main-on-push.yml 2025-09-14 15:33:37 UTC (rev 45765)
@@ -521,7 +521,7 @@
data: fs.readFileSync(ASSET_PATH)
});
- build_mac:
+ build_mac:
name: Build MacOs Package
needs: [create_release, build_doc]
runs-on: macos-latest
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 15:29:29
|
Revision: 45764
http://sourceforge.net/p/vice-emu/code/45764
Author: gpz
Date: 2025-09-14 15:29:27 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
lets try building a macos version too
Modified Paths:
--------------
trunk/.github/workflows/build-main-on-push.yml
Modified: trunk/.github/workflows/build-main-on-push.yml
===================================================================
--- trunk/.github/workflows/build-main-on-push.yml 2025-09-14 14:48:18 UTC (rev 45763)
+++ trunk/.github/workflows/build-main-on-push.yml 2025-09-14 15:29:27 UTC (rev 45764)
@@ -521,6 +521,104 @@
data: fs.readFileSync(ASSET_PATH)
});
+ build_mac:
+ name: Build MacOs Package
+ needs: [create_release, build_doc]
+ runs-on: macos-latest
+ strategy:
+ fail-fast: false
+ matrix:
+ ui: [ { name: 'GTK3',
+ conf: '--enable-gtk3ui',
+ deps: 'gtk+3' },
+ { name: 'SDL2',
+ conf: '--enable-sdl2ui --with-sdlsound --without-pulse',
+ deps: 'sdl2 sdl2_image' },
+ # { name: 'SDL1',
+ # conf: '--enable-sdl1ui --with-sdlsound --without-pulse',
+ # deps: 'sdl sdl12-compat sdl2_image' },
+ { name: 'Headless',
+ conf: '--enable-headlessui --with-pulse',
+ deps: '' }
+ ]
+ steps:
+ - name: Checkout Source
+ uses: actions/checkout@v4
+
+ - name: deps [macOS]
+ if: runner.os == 'macOS'
+ run: |
+ export HOMEBREW_NO_INSTALL_CLEANUP=1
+ brew update
+ brew upgrade || true
+ brew uninstall --ignore-dependencies --force pkg-config@0.29.2
+ brew install \
+ dos2unix \
+ autoconf \
+ automake \
+ libtool \
+ pkgconf \
+ coreutils \
+ gnu-sed \
+ libgcrypt \
+ xa \
+ librsvg \
+ adwaita-icon-theme \
+ glew \
+ libusb \
+ libusb-compat \
+ ${{ matrix.ui.deps }}
+ - name: Build
+ run: |
+ mkdir -p build/usr
+ cd vice
+ ./src/buildtools/genvicedate_h.sh
+ ./autogen.sh
+ # ALSA is required for SDL2 as well for midi support
+ ./configure --enable-option-checking=fatal \
+ --prefix=/usr \
+ --disable-arch \
+ --enable-usbsid \
+ --enable-cpuhistory \
+ --enable-parsid \
+ --with-pulse \
+ --with-alsa \
+ --with-fastsid \
+ --with-resid \
+ ${{ matrix.ui.conf }}
+ make -j $(sysctl -n hw.ncpu) -s
+ make DESTDIR=$HOME/build install
+ cd ..
+ mkdir $PATH_ARTIFACTS
+ cd $PATH_ARTIFACTS
+ tar cvzf vice-macos-${{ matrix.ui.name }}.tgz -C $HOME/build .
+ pwd
+ ls -l
+
+ - name: Upload zip
+ id: upload_macoszip
+ uses: actions/github-script@v7
+ env:
+ UPLOAD_URL: ${{ needs.create_release.outputs.upload_url }}
+ ASSET_PATH: ${{ env.PATH_ARTIFACTS}}/vice-macos-${{ matrix.ui.name }}.tgz
+ ASSET_NAME: vice-macos-${{ matrix.ui.name }}.tgz
+ ASSET_CONTENT_TYPE: application/vnd.debian.binary-package
+ with:
+ github-token: ${{ secrets.GITHUB_TOKEN }}
+ retries: 3
+ script: |
+ const fs = require('fs');
+ const { UPLOAD_URL, ASSET_PATH, ASSET_NAME, ASSET_CONTENT_TYPE } = process.env;
+ const uploadAssetResponse = await github.rest.repos.uploadReleaseAsset({
+ url: UPLOAD_URL,
+ headers: {
+ 'content-type': ASSET_CONTENT_TYPE,
+ 'content-length': fs.statSync(ASSET_PATH).size
+ },
+ name: ASSET_NAME,
+ data: fs.readFileSync(ASSET_PATH)
+ });
+
publish_release:
name: Publish Release
needs: [create_release, build, build_deb]
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 14:48:21
|
Revision: 45763
http://sourceforge.net/p/vice-emu/code/45763
Author: gpz
Date: 2025-09-14 14:48:18 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
fix readmode switch bug, patch by LouD
Modified Paths:
--------------
trunk/vice/src/lib/libusbsiddrv/USBSID.cpp
Modified: trunk/vice/src/lib/libusbsiddrv/USBSID.cpp
===================================================================
--- trunk/vice/src/lib/libusbsiddrv/USBSID.cpp 2025-09-14 14:47:38 UTC (rev 45762)
+++ trunk/vice/src/lib/libusbsiddrv/USBSID.cpp 2025-09-14 14:48:18 UTC (rev 45763)
@@ -654,6 +654,7 @@
/* Init ringbuffer */
flush_buffer = 0;
run_thread = buffer_pos = 1;
+ threaded = withcycles = true;
pthread_mutex_lock(&us_mutex);
USBSID_InitRingBuffer(ring_size, diff_size);
us_thread++;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 14:47:40
|
Revision: 45762
http://sourceforge.net/p/vice-emu/code/45762
Author: gpz
Date: 2025-09-14 14:47:38 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
silence log, patch by LouD
Modified Paths:
--------------
trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c
trunk/vice/src/lib/libusbsiddrv/USBSID.cpp
Property Changed:
----------------
trunk/vice/src/lib/libusbsiddrv/
Modified: trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c
===================================================================
--- trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c 2025-09-14 14:44:33 UTC (rev 45761)
+++ trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c 2025-09-14 14:47:38 UTC (rev 45762)
@@ -105,7 +105,7 @@
sids_found = 0;
- log_message(usbsid_log, "Detecting boards");
+ log_debug(usbsid_log, "Detecting boards");
if (usbsid == NULL) {
usbsid = create_USBSID();
Index: trunk/vice/src/lib/libusbsiddrv
===================================================================
--- trunk/vice/src/lib/libusbsiddrv 2025-09-14 14:44:33 UTC (rev 45761)
+++ trunk/vice/src/lib/libusbsiddrv 2025-09-14 14:47:38 UTC (rev 45762)
Property changes on: trunk/vice/src/lib/libusbsiddrv
___________________________________________________________________
Modified: svn:ignore
## -1 +1,3 ##
.deps
+Makefile
+Makefile.in
Modified: trunk/vice/src/lib/libusbsiddrv/USBSID.cpp
===================================================================
--- trunk/vice/src/lib/libusbsiddrv/USBSID.cpp 2025-09-14 14:44:33 UTC (rev 45761)
+++ trunk/vice/src/lib/libusbsiddrv/USBSID.cpp 2025-09-14 14:47:38 UTC (rev 45762)
@@ -1239,7 +1239,7 @@
/* Check for an available USBSID-Pico */
if (LIBUSB_Available(ctx, VENDOR_ID, PRODUCT_ID) <= 0) {
- USBERR(stderr, "[USBSID] USBSID-Pico not connected\n");
+ USBDBG(stderr, "[USBSID] USBSID-Pico not connected\n");
goto out;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 14:44:35
|
Revision: 45761
http://sourceforge.net/p/vice-emu/code/45761
Author: gpz
Date: 2025-09-14 14:44:33 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
remove generated Makefile(s)
Removed Paths:
-------------
trunk/vice/src/lib/libusbsiddrv/Makefile
trunk/vice/src/lib/libusbsiddrv/Makefile.in
Property Changed:
----------------
trunk/vice/src/lib/libusbsiddrv/
Index: trunk/vice/src/lib/libusbsiddrv
===================================================================
--- trunk/vice/src/lib/libusbsiddrv 2025-09-14 14:25:26 UTC (rev 45760)
+++ trunk/vice/src/lib/libusbsiddrv 2025-09-14 14:44:33 UTC (rev 45761)
Property changes on: trunk/vice/src/lib/libusbsiddrv
___________________________________________________________________
Added: svn:ignore
## -0,0 +1 ##
+.deps
Deleted: trunk/vice/src/lib/libusbsiddrv/Makefile
===================================================================
--- trunk/vice/src/lib/libusbsiddrv/Makefile 2025-09-14 14:25:26 UTC (rev 45760)
+++ trunk/vice/src/lib/libusbsiddrv/Makefile 2025-09-14 14:44:33 UTC (rev 45761)
@@ -1,739 +0,0 @@
-# Makefile.in generated by automake 1.17 from Makefile.am.
-# src/lib/libusbsiddrv/Makefile. Generated from Makefile.in by configure.
-
-# Copyright (C) 1994-2024 Free Software Foundation, Inc.
-
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-
-
-
-
-am__is_gnu_make = { \
- if test -z '$(MAKELEVEL)'; then \
- false; \
- elif test -n '$(MAKE_HOST)'; then \
- true; \
- elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
- true; \
- else \
- false; \
- fi; \
-}
-am__make_running_with_option = \
- case $${target_option-} in \
- ?) ;; \
- *) echo "am__make_running_with_option: internal error: invalid" \
- "target option '$${target_option-}' specified" >&2; \
- exit 1;; \
- esac; \
- has_opt=no; \
- sane_makeflags=$$MAKEFLAGS; \
- if $(am__is_gnu_make); then \
- sane_makeflags=$$MFLAGS; \
- else \
- case $$MAKEFLAGS in \
- *\\[\ \ ]*) \
- bs=\\; \
- sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
- | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
- esac; \
- fi; \
- skip_next=no; \
- strip_trailopt () \
- { \
- flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
- }; \
- for flg in $$sane_makeflags; do \
- test $$skip_next = yes && { skip_next=no; continue; }; \
- case $$flg in \
- *=*|--*) continue;; \
- -*I) strip_trailopt 'I'; skip_next=yes;; \
- -*I?*) strip_trailopt 'I';; \
- -*O) strip_trailopt 'O'; skip_next=yes;; \
- -*O?*) strip_trailopt 'O';; \
- -*l) strip_trailopt 'l'; skip_next=yes;; \
- -*l?*) strip_trailopt 'l';; \
- -[dEDm]) skip_next=yes;; \
- -[JT]) skip_next=yes;; \
- esac; \
- case $$flg in \
- *$$target_option*) has_opt=yes; break;; \
- esac; \
- done; \
- test $$has_opt = yes
-am__make_dryrun = (target_option=n; $(am__make_running_with_option))
-am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
-am__rm_f = rm -f $(am__rm_f_notfound)
-am__rm_rf = rm -rf $(am__rm_f_notfound)
-pkgdatadir = $(datadir)/vice
-pkgincludedir = $(includedir)/vice
-pkglibdir = $(libdir)/vice
-pkglibexecdir = $(libexecdir)/vice
-am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
-install_sh_DATA = $(install_sh) -c -m 644
-install_sh_PROGRAM = $(install_sh) -c
-install_sh_SCRIPT = $(install_sh) -c
-INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-build_triplet = x86_64-pc-linux-gnu
-host_triplet = x86_64-pc-linux-gnu
-subdir = src/lib/libusbsiddrv
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
- $(top_srcdir)/m4/lib-ld.m4 \
- $(top_srcdir)/m4/m4_ax_subdirs_configure.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/vice_args.m4 \
- $(top_srcdir)/m4/vice_compiler_checks.m4 \
- $(top_srcdir)/configure.ac
-am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
- $(ACLOCAL_M4)
-DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \
- $(am__DIST_COMMON)
-mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
-CONFIG_HEADER = $(top_builddir)/src/config.h
-CONFIG_CLEAN_FILES =
-CONFIG_CLEAN_VPATH_FILES =
-LIBRARIES = $(noinst_LIBRARIES)
-AM_V_AR = $(am__v_AR_$(V))
-am__v_AR_ = $(am__v_AR_$(AM_DEFAULT_VERBOSITY))
-am__v_AR_0 = @echo " AR " $@;
-am__v_AR_1 =
-libusbsiddrv_a_AR = $(AR) $(ARFLAGS)
-libusbsiddrv_a_RANLIB = $(RANLIB)
-libusbsiddrv_a_DEPENDENCIES = $(USBSIDDRIVER)
-am_libusbsiddrv_a_OBJECTS =
-libusbsiddrv_a_OBJECTS = $(am_libusbsiddrv_a_OBJECTS)
-AM_V_P = $(am__v_P_$(V))
-am__v_P_ = $(am__v_P_$(AM_DEFAULT_VERBOSITY))
-am__v_P_0 = false
-am__v_P_1 = :
-AM_V_GEN = $(am__v_GEN_$(V))
-am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
-am__v_GEN_0 = @echo " GEN " $@;
-am__v_GEN_1 =
-AM_V_at = $(am__v_at_$(V))
-am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
-am__v_at_0 = @
-am__v_at_1 =
-DEFAULT_INCLUDES = -I. -I$(top_builddir)/src
-depcomp = $(SHELL) $(top_srcdir)/depcomp
-am__maybe_remake_depfiles = depfiles
-am__depfiles_remade = ./$(DEPDIR)/USBSID.Po \
- ./$(DEPDIR)/USBSIDInterface.Po
-am__mv = mv -f
-CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
-AM_V_CXX = $(am__v_CXX_$(V))
-am__v_CXX_ = $(am__v_CXX_$(AM_DEFAULT_VERBOSITY))
-am__v_CXX_0 = @echo " CXX " $@;
-am__v_CXX_1 =
-CXXLD = $(CXX)
-CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
- -o $@
-AM_V_CXXLD = $(am__v_CXXLD_$(V))
-am__v_CXXLD_ = $(am__v_CXXLD_$(AM_DEFAULT_VERBOSITY))
-am__v_CXXLD_0 = @echo " CXXLD " $@;
-am__v_CXXLD_1 =
-SOURCES = $(libusbsiddrv_a_SOURCES) $(EXTRA_libusbsiddrv_a_SOURCES)
-DIST_SOURCES = $(libusbsiddrv_a_SOURCES) \
- $(EXTRA_libusbsiddrv_a_SOURCES)
-am__can_run_installinfo = \
- case $$AM_UPDATE_INFO_DIR in \
- n|no|NO) false;; \
- *) (install-info --version) >/dev/null 2>&1;; \
- esac
-HEADERS = $(noinst_HEADERS)
-am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
-# Read a list of newline-separated strings from the standard input,
-# and print each of them once, without duplicates. Input order is
-# *not* preserved.
-am__uniquify_input = $(AWK) '\
- BEGIN { nonempty = 0; } \
- { items[$$0] = 1; nonempty = 1; } \
- END { if (nonempty) { for (i in items) print i; }; } \
-'
-# Make sure the list of sources is unique. This is necessary because,
-# e.g., the same source file might be shared among _SOURCES variables
-# for different programs/libraries.
-am__define_uniq_tagged_files = \
- list='$(am__tagged_files)'; \
- unique=`for i in $$list; do \
- if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
- done | $(am__uniquify_input)`
-am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \
- $(top_srcdir)/mkinstalldirs README.md
-DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
-ACLOCAL = ${SHELL} '/home/groepaz/Desktop/vice/vice-emu/trunk/vice/missing' aclocal-1.17
-AMTAR = $${TAR-tar}
-AM_DEFAULT_VERBOSITY = 1
-AR = ar
-ARCH_DIR = $(top_builddir)/src/arch/sdl
-ARCH_EXTRA_SUBDIR =
-ARCH_INCLUDES = -I$(top_srcdir)/src/arch/sdl -I$(top_srcdir)/src/arch/shared
-ARCH_LIBS = $(top_builddir)/src/arch/sdl/libarch.a
-ARCH_MAKE_BINDIST_DIR =
-ARCH_SRC_DIR = $(top_srcdir)/src/arch/sdl
-ARFLAGS = cr
-AR_FLAGS = cr
-AUTOCONF = ${SHELL} '/home/groepaz/Desktop/vice/vice-emu/trunk/vice/missing' autoconf
-AUTOHEADER = ${SHELL} '/home/groepaz/Desktop/vice/vice-emu/trunk/vice/missing' autoheader
-AUTOMAKE = ${SHELL} '/home/groepaz/Desktop/vice/vice-emu/trunk/vice/missing' automake-1.17
-AWK = gawk
-CC = cc
-CCAS = cc
-CCASDEPMODE = depmode=gcc3
-CCASFLAGS =
-CCDEPMODE = depmode=gcc3
-CFLAGS = -D_DEFAULT_SOURCE -D_DEFAULT_SOURCE -DHAVE_NET_ETHERNET_H
-CPP = cc -E
-CPPFLAGS =
-CROSS = false
-CSCOPE = cscope
-CTAGS = ctags
-CXX = c++ -std=c++11
-CXXCPP = c++ -std=c++11 -E
-CXXDEPMODE = depmode=gcc3
-CXXFLAGS = -fno-exceptions
-CYGPATH_W = echo
-DEBUGBUILD = 0
-DEFS = -DHAVE_CONFIG_H
-DEPDIR = .deps
-DESKTOP_FILE_INSTALL =
-DOS2UNIX = dos2unix
-DYNLIB_LIBS =
-ECHO_C =
-ECHO_N = -n
-ECHO_T =
-ENABLE_ARCH = yes
-ETAGS = etags
-EXEEXT =
-FCCACHE = /usr/bin/fc-cache
-FONTCONFIG_CFLAGS =
-FONTCONFIG_LIBS =
-FW_DIR =
-GFXOUTPUT_DRIVERS = pngdrv.o
-GFXOUTPUT_LIBS = -lpng
-GLEW_CFLAGS =
-GLEW_LIBS =
-GLIB_CFLAGS =
-GLIB_COMPILE_RESOURCES =
-GLIB_GENMARSHAL =
-GLIB_LIBS =
-GTK_CFLAGS =
-GTK_LIBS =
-HAVE_CXX11 = 1
-ICONV = iconv
-ICOTOOL = no
-INLINE_UNIT_GROWTH = --param inline-unit-growth=60
-INSTALL = /usr/bin/install -c
-INSTALL_DATA = ${INSTALL} -m 644
-INSTALL_PROGRAM = ${INSTALL}
-INSTALL_SCRIPT = ${INSTALL}
-INSTALL_STRIP_PROGRAM = $(install_sh) -c -s
-JOYSTICK_DRIVERS =
-JOY_LIBS =
-LDFLAGS =
-LEX = flex
-LEXLIB = -lfl
-LEX_OUTPUT_ROOT = lex.yy
-LIBOBJS =
-LIBS = -lbsd -lusb-1.0 -lpci -lnsl -lm -lSDL2 -lSDL2_image -lSDL2 -lcap -lcurl
-LIBUSB_CFLAGS = -I/usr/include/libusb-1.0
-LIBUSB_LIBS = -lusb-1.0
-LINKCC = $(CXX)
-LN_S = ln -s
-LTLIBOBJS =
-MAKEINFO = ${SHELL} '/home/groepaz/Desktop/vice/vice-emu/trunk/vice/missing' makeinfo
-MAX_INLINE_INSN_SINGLE = --param max-inline-insns-single=600
-MKDIR_P = /bin/mkdir -p
-MONITOR_CFLAGS = -Wno-unused-label -Wno-unreachable-code -Wno-misleading-indentation
-NETPLAY_LIBS = -lnet -lbsd -lnsl
-OBJC = cc
-OBJCDEPMODE = depmode=gcc3
-OBJCFLAGS =
-OBJCPP =
-OBJEXT = o
-PACKAGE = vice
-PACKAGE_BUGREPORT =
-PACKAGE_NAME = vice
-PACKAGE_STRING = vice 3.9
-PACKAGE_TARNAME = vice
-PACKAGE_URL =
-PACKAGE_VERSION = 3.9
-PATH_SEPARATOR = :
-PDFTEX = pdftex
-PERL = perl
-PKG_CONFIG = /usr/bin/pkg-config
-PLATFORM_DOX_FLAGS = platformall
-PNG_CFLAGS =
-PNG_LIBS =
-PROGRAM_PREFIX = sdl2-
-PROGRAM_SUFFIX =
-RANLIB = ranlib
-RESIDDTVSUB = resid-dtv
-RESIDSUB = resid
-RESID_DEP = libresid
-RESID_DIR = resid
-RESID_DTV_DEP = libresiddtv
-RESID_DTV_DIR = resid-dtv
-RESID_DTV_INCLUDES = -I$(top_builddir)/src/resid-dtv
-RESID_DTV_LIBS = $(top_builddir)/src/resid-dtv/libresiddtv.a
-RESID_INCLUDES = -I$(top_builddir)/src/resid
-RESID_LIBS = $(top_builddir)/src/resid/libresid.a
-SDL2_CFLAGS = -I/usr/include/SDL2 -D_REENTRANT
-SDL2_IMAGE_CFLAGS = -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/libpng16
-SDL2_IMAGE_LIBS = -lSDL2_image -lSDL2
-SDL2_LIBS = -lSDL2
-SDLCONFIG =
-SDL_EXTRA_LIBS =
-SDL_IMAGE_CFLAGS =
-SDL_IMAGE_LIBS =
-SET_MAKE =
-SHELL = /bin/sh
-SOUND_DRIVERS = soundsdl.o soundpulse.o soundalsa.o
-SOUND_LIBS = -lpulse-simple -lpulse -lasound
-SOUND_MIDAS_OBJ =
-SOUND_SDL_OBJ =
-STRIP = strip
-SVN = svn
-SVNVERSION = svnversion
-SVN_REVISION_OVERRIDE =
-TAR = tar
-TEXI2DVI = texi2dvi
-TFE_LIBS = -lpcap -L/usr/lib64 -lnet
-UI_LIBS =
-UNZIPBIN = no
-UPDATE_DESKTOP_DATABASE =
-VERSION = 3.9
-VERSION_COMBINED = 198912
-VERSION_RC = 3,9,0,0
-VICE_CFLAGS = -g -O3 -W -Wall -Wextra -Wformat -Wformat-signedness -Wformat-security -Wshadow -Wpointer-arith -Wmissing-prototypes -Wstrict-prototypes -Wuninitialized -Wmissing-field-initializers -Wunreachable-code -Werror=implicit-function-declaration -Wfatal-errors -Wdiscarded-qualifiers -Wno-unknown-pragmas -Wunused-but-set-variable -Wno-sign-compare -Wno-ignored-qualifiers -Wno-unused-parameter -fopenmp -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/libpng16 -I/usr/include/libusb-1.0
-VICE_CPPFLAGS = -I$(top_srcdir)/src/arch/systemheaderoverride -DNDEBUG -I/usr/include/libusb-1.0
-VICE_CXXFLAGS = -g -O3 -Wall -Wformat -Wshadow -Wpointer-arith -Wuninitialized -Wunreachable-code -Wno-unused-parameter -Wfatal-errors -fopenmp -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/libpng16
-VICE_DATADIR = ${datarootdir}/vice
-VICE_DOCDIR = ${datarootdir}/doc/${PACKAGE_TARNAME}
-VICE_LDFLAGS = -fopenmp
-VICE_OBJCFLAGS = -g -O3
-VICE_PDF_FILE_NAME = vice.pdf
-VICE_VERSION = 3.9
-VICE_VERSION_BUILD = 0
-VICE_VERSION_MAJOR = 3
-VICE_VERSION_MINOR = 9
-VTE_CXXFLAGS = -Wno-address-of-packed-member -Wno-char-subscripts -Wno-format-signedness -Wno-c99-designator -Wno-shorten-64-to-32 -Wno-nonnull-compare
-WINDRES =
-WINDRES_LIB = $(top_builddir)/src/arch/sdl/icon.res
-XA = xa
-XDG_ICON_RESOURCE =
-YACC = byacc
-ZLIB_LIBS = -lz
-abs_builddir = /home/groepaz/Desktop/vice/vice-emu/trunk/vice/src/lib/libusbsiddrv
-abs_srcdir = /home/groepaz/Desktop/vice/vice-emu/trunk/vice/src/lib/libusbsiddrv
-abs_top_builddir = /home/groepaz/Desktop/vice/vice-emu/trunk/vice
-abs_top_srcdir = /home/groepaz/Desktop/vice/vice-emu/trunk/vice
-ac_ct_CC = cc
-ac_ct_CXX = c++
-ac_ct_OBJC = cc
-am__include = include
-am__leading_dot = .
-am__quote =
-am__rm_f_notfound =
-am__tar = $${TAR-tar} chof - "$$tardir"
-am__untar = $${TAR-tar} xf -
-am__xargs_n = xargs -n
-bindir = ${exec_prefix}/bin
-build = x86_64-pc-linux-gnu
-build_alias =
-build_cpu = x86_64
-build_os = linux-gnu
-build_vendor = pc
-builddir = .
-datadir = ${datarootdir}
-datarootdir = ${prefix}/share
-docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
-dvidir = ${docdir}
-exec_prefix = ${prefix}
-host = x86_64-pc-linux-gnu
-host_alias =
-host_cpu = x86_64
-host_os = linux-gnu
-host_vendor = pc
-htmldir = ${docdir}
-includedir = ${prefix}/include
-infodir = ${datarootdir}/info
-install_sh = ${SHELL} /home/groepaz/Desktop/vice/vice-emu/trunk/vice/install-sh
-libcurl_CFLAGS =
-libcurl_LIBS = -lcurl
-libdir = ${exec_prefix}/lib
-libevdev_CFLAGS =
-libevdev_LIBS =
-libexecdir = ${exec_prefix}/libexec
-localedir = ${datarootdir}/locale
-localstatedir = ${prefix}/var
-mandir = ${datarootdir}/man
-mkdir_p = $(MKDIR_P)
-objdump = objdump
-oldincludedir = /usr/include
-pdfdir = ${docdir}
-prefix = /usr/games
-program_transform_name = s&^&sdl2-&
-psdir = ${docdir}
-runstatedir = ${localstatedir}/run
-sbindir = ${exec_prefix}/sbin
-sdl_config = sdl-config
-sharedstatedir = ${prefix}/com
-srcdir = .
-subdirs_extra = src/resid src/resid-dtv
-sysconfdir = ${prefix}/etc
-target_alias =
-top_build_prefix = ../../../
-top_builddir = ../../..
-top_srcdir = ../../..
-vsid_LDFLAGS =
-x128_LDFLAGS =
-x64_LDFLAGS =
-xcbm2_LDFLAGS =
-xpet_LDFLAGS =
-xplus4_LDFLAGS =
-xscpu64_LDFLAGS =
-xvic_LDFLAGS =
-
-# Makefile.am for `libusbsiddrv.a'.
-# if HAVE_USBSID
-AM_CPPFLAGS = \
- -I$(top_srcdir)/src/arch/systemheaderoverride -DNDEBUG -I/usr/include/libusb-1.0 \
- -I$(top_srcdir)/src/arch/sdl -I$(top_srcdir)/src/arch/shared \
- -I$(top_builddir)/src \
- -I$(top_srcdir)/src \
- -I$(top_srcdir)/src/lib/libusbsiddrv
-
-AM_CFLAGS = -g -O3 -W -Wall -Wextra -Wformat -Wformat-signedness -Wformat-security -Wshadow -Wpointer-arith -Wmissing-prototypes -Wstrict-prototypes -Wuninitialized -Wmissing-field-initializers -Wunreachable-code -Werror=implicit-function-declaration -Wfatal-errors -Wdiscarded-qualifiers -Wno-unknown-pragmas -Wunused-but-set-variable -Wno-sign-compare -Wno-ignored-qualifiers -Wno-unused-parameter -fopenmp -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/libpng16 -I/usr/include/libusb-1.0
-AM_CXXFLAGS = \
- -g -O3 -Wall -Wformat -Wshadow -Wpointer-arith -Wuninitialized -Wunreachable-code -Wno-unused-parameter -Wfatal-errors -fopenmp -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/SDL2 -D_REENTRANT -I/usr/include/libpng16 \
- -Wno-unused-variable \
- -I$(top_srcdir)/src/lib/libusbsiddrv
-
-AM_LDFLAGS = -fopenmp
-noinst_LIBRARIES = libusbsiddrv.a
-USBSIDDRIVER = USBSID.o USBSIDInterface.o
-
-# Built depending on configure options:
-EXTRA_libusbsiddrv_a_SOURCES = \
- USBSIDInterface.cpp \
- USBSID.cpp
-
-EXTRA_DIST = \
- USBSID.h \
- USBSIDInterface.h
-
-
-# Always built:
-# (needs to be declared empty to avoid `make` to try to build libusbsiddrv.o
-# from libusbsiddrv.c)
-libusbsiddrv_a_SOURCES =
-noinst_HEADERS = USBSID.h USBSIDInterface.h
-
-# Make sure we actually link the generated object files into the library:
-libusbsiddrv_a_LIBADD = $(USBSIDDRIVER)
-all: all-am
-
-.SUFFIXES:
-.SUFFIXES: .cpp .o .obj
-$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
- @for dep in $?; do \
- case '$(am__configure_deps)' in \
- *$$dep*) \
- ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
- && { if test -f $@; then exit 0; else break; fi; }; \
- exit 1;; \
- esac; \
- done; \
- echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/lib/libusbsiddrv/Makefile'; \
- $(am__cd) $(top_srcdir) && \
- $(AUTOMAKE) --foreign src/lib/libusbsiddrv/Makefile
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- @case '$?' in \
- *config.status*) \
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
- *) \
- echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
- cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
- esac;
-
-$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-
-$(top_srcdir)/configure: $(am__configure_deps)
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-$(ACLOCAL_M4): $(am__aclocal_m4_deps)
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-$(am__aclocal_m4_deps):
-
-clean-noinstLIBRARIES:
- -$(am__rm_f) $(noinst_LIBRARIES)
-
-libusbsiddrv.a: $(libusbsiddrv_a_OBJECTS) $(libusbsiddrv_a_DEPENDENCIES) $(EXTRA_libusbsiddrv_a_DEPENDENCIES)
- $(AM_V_at)-rm -f libusbsiddrv.a
- $(AM_V_AR)$(libusbsiddrv_a_AR) libusbsiddrv.a $(libusbsiddrv_a_OBJECTS) $(libusbsiddrv_a_LIBADD)
- $(AM_V_at)$(libusbsiddrv_a_RANLIB) libusbsiddrv.a
-
-mostlyclean-compile:
- -rm -f *.$(OBJEXT)
-
-distclean-compile:
- -rm -f *.tab.c
-
-include ./$(DEPDIR)/USBSID.Po # am--include-marker
-include ./$(DEPDIR)/USBSIDInterface.Po # am--include-marker
-
-$(am__depfiles_remade):
- @$(MKDIR_P) $(@D)
- @: >>$@
-
-am--depfiles: $(am__depfiles_remade)
-
-.cpp.o:
- $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-# $(AM_V_CXX)source='$<' object='$@' libtool=no \
-# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
-# $(AM_V_CXX_no)$(CXXCOMPILE) -c -o $@ $<
-
-.cpp.obj:
- $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-# $(AM_V_CXX)source='$<' object='$@' libtool=no \
-# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
-# $(AM_V_CXX_no)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
-
-ID: $(am__tagged_files)
- $(am__define_uniq_tagged_files); mkid -fID $$unique
-tags: tags-am
-TAGS: tags
-
-tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- set x; \
- here=`pwd`; \
- $(am__define_uniq_tagged_files); \
- shift; \
- if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
- test -n "$$unique" || unique=$$empty_fix; \
- if test $$# -gt 0; then \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- "$$@" $$unique; \
- else \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- $$unique; \
- fi; \
- fi
-ctags: ctags-am
-
-CTAGS: ctags
-ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- $(am__define_uniq_tagged_files); \
- test -z "$(CTAGS_ARGS)$$unique" \
- || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
- $$unique
-
-GTAGS:
- here=`$(am__cd) $(top_builddir) && pwd` \
- && $(am__cd) $(top_srcdir) \
- && gtags -i $(GTAGS_ARGS) "$$here"
-cscopelist: cscopelist-am
-
-cscopelist-am: $(am__tagged_files)
- list='$(am__tagged_files)'; \
- case "$(srcdir)" in \
- [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
- *) sdir=$(subdir)/$(srcdir) ;; \
- esac; \
- for i in $$list; do \
- if test -f "$$i"; then \
- echo "$(subdir)/$$i"; \
- else \
- echo "$$sdir/$$i"; \
- fi; \
- done >> $(top_builddir)/cscope.files
-
-distclean-tags:
- -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-distdir: $(BUILT_SOURCES)
- $(MAKE) $(AM_MAKEFLAGS) distdir-am
-
-distdir-am: $(DISTFILES)
- @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
- topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
- list='$(DISTFILES)'; \
- dist_files=`for file in $$list; do echo $$file; done | \
- sed -e "s|^$$srcdirstrip/||;t" \
- -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
- case $$dist_files in \
- */*) $(MKDIR_P) `echo "$$dist_files" | \
- sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
- sort -u` ;; \
- esac; \
- for file in $$dist_files; do \
- if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
- if test -d $$d/$$file; then \
- dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
- if test -d "$(distdir)/$$file"; then \
- find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
- fi; \
- if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
- find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
- fi; \
- cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
- else \
- test -f "$(distdir)/$$file" \
- || cp -p $$d/$$file "$(distdir)/$$file" \
- || exit 1; \
- fi; \
- done
-check-am: all-am
-check: check-am
-all-am: Makefile $(LIBRARIES) $(HEADERS)
-installdirs:
-install: install-am
-install-exec: install-exec-am
-install-data: install-data-am
-uninstall: uninstall-am
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-
-installcheck: installcheck-am
-install-strip:
- if test -z '$(STRIP)'; then \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- install; \
- else \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
- fi
-mostlyclean-generic:
-
-clean-generic:
-
-distclean-generic:
- -$(am__rm_f) $(CONFIG_CLEAN_FILES)
- -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
-
-maintainer-clean-generic:
- @echo "This command is intended for maintainers to use"
- @echo "it deletes files that may require special tools to rebuild."
-clean: clean-am
-
-clean-am: clean-generic clean-noinstLIBRARIES mostlyclean-am
-
-distclean: distclean-am
- -rm -f ./$(DEPDIR)/USBSID.Po
- -rm -f ./$(DEPDIR)/USBSIDInterface.Po
- -rm -f Makefile
-distclean-am: clean-am distclean-compile distclean-generic \
- distclean-tags
-
-dvi: dvi-am
-
-dvi-am:
-
-html: html-am
-
-html-am:
-
-info: info-am
-
-info-am:
-
-install-data-am:
-
-install-dvi: install-dvi-am
-
-install-dvi-am:
-
-install-exec-am:
-
-install-html: install-html-am
-
-install-html-am:
-
-install-info: install-info-am
-
-install-info-am:
-
-install-man:
-
-install-pdf: install-pdf-am
-
-install-pdf-am:
-
-install-ps: install-ps-am
-
-install-ps-am:
-
-installcheck-am:
-
-maintainer-clean: maintainer-clean-am
- -rm -f ./$(DEPDIR)/USBSID.Po
- -rm -f ./$(DEPDIR)/USBSIDInterface.Po
- -rm -f Makefile
-maintainer-clean-am: distclean-am maintainer-clean-generic
-
-mostlyclean: mostlyclean-am
-
-mostlyclean-am: mostlyclean-compile mostlyclean-generic
-
-pdf: pdf-am
-
-pdf-am:
-
-ps: ps-am
-
-ps-am:
-
-uninstall-am:
-
-.MAKE: install-am install-strip
-
-.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
- clean-generic clean-noinstLIBRARIES cscopelist-am ctags \
- ctags-am distclean distclean-compile distclean-generic \
- distclean-tags distdir dvi dvi-am html html-am info info-am \
- install install-am install-data install-data-am install-dvi \
- install-dvi-am install-exec install-exec-am install-html \
- install-html-am install-info install-info-am install-man \
- install-pdf install-pdf-am install-ps install-ps-am \
- install-strip installcheck installcheck-am installdirs \
- maintainer-clean maintainer-clean-generic mostlyclean \
- mostlyclean-compile mostlyclean-generic pdf pdf-am ps ps-am \
- tags tags-am uninstall uninstall-am
-
-.PRECIOUS: Makefile
-
-# endif HAVE_USBSID
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
-
-# Tell GNU make to disable its built-in pattern rules.
-%:: %,v
-%:: RCS/%,v
-%:: RCS/%
-%:: s.%
-%:: SCCS/s.%
Deleted: trunk/vice/src/lib/libusbsiddrv/Makefile.in
===================================================================
--- trunk/vice/src/lib/libusbsiddrv/Makefile.in 2025-09-14 14:25:26 UTC (rev 45760)
+++ trunk/vice/src/lib/libusbsiddrv/Makefile.in 2025-09-14 14:44:33 UTC (rev 45761)
@@ -1,739 +0,0 @@
-# Makefile.in generated by automake 1.17 from Makefile.am.
-# @configure_input@
-
-# Copyright (C) 1994-2024 Free Software Foundation, Inc.
-
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-@SET_MAKE@
-
-
-VPATH = @srcdir@
-am__is_gnu_make = { \
- if test -z '$(MAKELEVEL)'; then \
- false; \
- elif test -n '$(MAKE_HOST)'; then \
- true; \
- elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
- true; \
- else \
- false; \
- fi; \
-}
-am__make_running_with_option = \
- case $${target_option-} in \
- ?) ;; \
- *) echo "am__make_running_with_option: internal error: invalid" \
- "target option '$${target_option-}' specified" >&2; \
- exit 1;; \
- esac; \
- has_opt=no; \
- sane_makeflags=$$MAKEFLAGS; \
- if $(am__is_gnu_make); then \
- sane_makeflags=$$MFLAGS; \
- else \
- case $$MAKEFLAGS in \
- *\\[\ \ ]*) \
- bs=\\; \
- sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
- | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
- esac; \
- fi; \
- skip_next=no; \
- strip_trailopt () \
- { \
- flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
- }; \
- for flg in $$sane_makeflags; do \
- test $$skip_next = yes && { skip_next=no; continue; }; \
- case $$flg in \
- *=*|--*) continue;; \
- -*I) strip_trailopt 'I'; skip_next=yes;; \
- -*I?*) strip_trailopt 'I';; \
- -*O) strip_trailopt 'O'; skip_next=yes;; \
- -*O?*) strip_trailopt 'O';; \
- -*l) strip_trailopt 'l'; skip_next=yes;; \
- -*l?*) strip_trailopt 'l';; \
- -[dEDm]) skip_next=yes;; \
- -[JT]) skip_next=yes;; \
- esac; \
- case $$flg in \
- *$$target_option*) has_opt=yes; break;; \
- esac; \
- done; \
- test $$has_opt = yes
-am__make_dryrun = (target_option=n; $(am__make_running_with_option))
-am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
-am__rm_f = rm -f $(am__rm_f_notfound)
-am__rm_rf = rm -rf $(am__rm_f_notfound)
-pkgdatadir = $(datadir)/@PACKAGE@
-pkgincludedir = $(includedir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
-pkglibexecdir = $(libexecdir)/@PACKAGE@
-am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
-install_sh_DATA = $(install_sh) -c -m 644
-install_sh_PROGRAM = $(install_sh) -c
-install_sh_SCRIPT = $(install_sh) -c
-INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-build_triplet = @build@
-host_triplet = @host@
-subdir = src/lib/libusbsiddrv
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \
- $(top_srcdir)/m4/lib-ld.m4 \
- $(top_srcdir)/m4/m4_ax_subdirs_configure.m4 \
- $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/vice_args.m4 \
- $(top_srcdir)/m4/vice_compiler_checks.m4 \
- $(top_srcdir)/configure.ac
-am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
- $(ACLOCAL_M4)
-DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \
- $(am__DIST_COMMON)
-mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
-CONFIG_HEADER = $(top_builddir)/src/config.h
-CONFIG_CLEAN_FILES =
-CONFIG_CLEAN_VPATH_FILES =
-LIBRARIES = $(noinst_LIBRARIES)
-AM_V_AR = $(am__v_AR_@AM_V@)
-am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
-am__v_AR_0 = @echo " AR " $@;
-am__v_AR_1 =
-libusbsiddrv_a_AR = $(AR) $(ARFLAGS)
-libusbsiddrv_a_RANLIB = $(RANLIB)
-libusbsiddrv_a_DEPENDENCIES = $(USBSIDDRIVER)
-am_libusbsiddrv_a_OBJECTS =
-libusbsiddrv_a_OBJECTS = $(am_libusbsiddrv_a_OBJECTS)
-AM_V_P = $(am__v_P_@AM_V@)
-am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
-am__v_P_0 = false
-am__v_P_1 = :
-AM_V_GEN = $(am__v_GEN_@AM_V@)
-am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
-am__v_GEN_1 =
-AM_V_at = $(am__v_at_@AM_V@)
-am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
-am__v_at_0 = @
-am__v_at_1 =
-DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src
-depcomp = $(SHELL) $(top_srcdir)/depcomp
-am__maybe_remake_depfiles = depfiles
-am__depfiles_remade = ./$(DEPDIR)/USBSID.Po \
- ./$(DEPDIR)/USBSIDInterface.Po
-am__mv = mv -f
-CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
-AM_V_CXX = $(am__v_CXX_@AM_V@)
-am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@)
-am__v_CXX_0 = @echo " CXX " $@;
-am__v_CXX_1 =
-CXXLD = $(CXX)
-CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
- -o $@
-AM_V_CXXLD = $(am__v_CXXLD_@AM_V@)
-am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@)
-am__v_CXXLD_0 = @echo " CXXLD " $@;
-am__v_CXXLD_1 =
-SOURCES = $(libusbsiddrv_a_SOURCES) $(EXTRA_libusbsiddrv_a_SOURCES)
-DIST_SOURCES = $(libusbsiddrv_a_SOURCES) \
- $(EXTRA_libusbsiddrv_a_SOURCES)
-am__can_run_installinfo = \
- case $$AM_UPDATE_INFO_DIR in \
- n|no|NO) false;; \
- *) (install-info --version) >/dev/null 2>&1;; \
- esac
-HEADERS = $(noinst_HEADERS)
-am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
-# Read a list of newline-separated strings from the standard input,
-# and print each of them once, without duplicates. Input order is
-# *not* preserved.
-am__uniquify_input = $(AWK) '\
- BEGIN { nonempty = 0; } \
- { items[$$0] = 1; nonempty = 1; } \
- END { if (nonempty) { for (i in items) print i; }; } \
-'
-# Make sure the list of sources is unique. This is necessary because,
-# e.g., the same source file might be shared among _SOURCES variables
-# for different programs/libraries.
-am__define_uniq_tagged_files = \
- list='$(am__tagged_files)'; \
- unique=`for i in $$list; do \
- if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
- done | $(am__uniquify_input)`
-am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \
- $(top_srcdir)/mkinstalldirs README.md
-DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
-ACLOCAL = @ACLOCAL@
-AMTAR = @AMTAR@
-AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
-AR = @AR@
-ARCH_DIR = @ARCH_DIR@
-ARCH_EXTRA_SUBDIR = @ARCH_EXTRA_SUBDIR@
-ARCH_INCLUDES = @ARCH_INCLUDES@
-ARCH_LIBS = @ARCH_LIBS@
-ARCH_MAKE_BINDIST_DIR = @ARCH_MAKE_BINDIST_DIR@
-ARCH_SRC_DIR = @ARCH_SRC_DIR@
-ARFLAGS = @ARFLAGS@
-AR_FLAGS = @AR_FLAGS@
-AUTOCONF = @AUTOCONF@
-AUTOHEADER = @AUTOHEADER@
-AUTOMAKE = @AUTOMAKE@
-AWK = @AWK@
-CC = @CC@
-CCAS = @CCAS@
-CCASDEPMODE = @CCASDEPMODE@
-CCASFLAGS = @CCASFLAGS@
-CCDEPMODE = @CCDEPMODE@
-CFLAGS = @CFLAGS@
-CPP = @CPP@
-CPPFLAGS = @CPPFLAGS@
-CROSS = @CROSS@
-CSCOPE = @CSCOPE@
-CTAGS = @CTAGS@
-CXX = @CXX@
-CXXCPP = @CXXCPP@
-CXXDEPMODE = @CXXDEPMODE@
-CXXFLAGS = @CXXFLAGS@
-CYGPATH_W = @CYGPATH_W@
-DEBUGBUILD = @DEBUGBUILD@
-DEFS = @DEFS@
-DEPDIR = @DEPDIR@
-DESKTOP_FILE_INSTALL = @DESKTOP_FILE_INSTALL@
-DOS2UNIX = @DOS2UNIX@
-DYNLIB_LIBS = @DYNLIB_LIBS@
-ECHO_C = @ECHO_C@
-ECHO_N = @ECHO_N@
-ECHO_T = @ECHO_T@
-ENABLE_ARCH = @ENABLE_ARCH@
-ETAGS = @ETAGS@
-EXEEXT = @EXEEXT@
-FCCACHE = @FCCACHE@
-FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@
-FONTCONFIG_LIBS = @FONTCONFIG_LIBS@
-FW_DIR = @FW_DIR@
-GFXOUTPUT_DRIVERS = @GFXOUTPUT_DRIVERS@
-GFXOUTPUT_LIBS = @GFXOUTPUT_LIBS@
-GLEW_CFLAGS = @GLEW_CFLAGS@
-GLEW_LIBS = @GLEW_LIBS@
-GLIB_CFLAGS = @GLIB_CFLAGS@
-GLIB_COMPILE_RESOURCES = @GLIB_COMPILE_RESOURCES@
-GLIB_GENMARSHAL = @GLIB_GENMARSHAL@
-GLIB_LIBS = @GLIB_LIBS@
-GTK_CFLAGS = @GTK_CFLAGS@
-GTK_LIBS = @GTK_LIBS@
-HAVE_CXX11 = @HAVE_CXX11@
-ICONV = @ICONV@
-ICOTOOL = @ICOTOOL@
-INLINE_UNIT_GROWTH = @INLINE_UNIT_GROWTH@
-INSTALL = @INSTALL@
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
-JOYSTICK_DRIVERS = @JOYSTICK_DRIVERS@
-JOY_LIBS = @JOY_LIBS@
-LDFLAGS = @LDFLAGS@
-LEX = @LEX@
-LEXLIB = @LEXLIB@
-LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
-LIBOBJS = @LIBOBJS@
-LIBS = @LIBS@
-LIBUSB_CFLAGS = @LIBUSB_CFLAGS@
-LIBUSB_LIBS = @LIBUSB_LIBS@
-LINKCC = @LINKCC@
-LN_S = @LN_S@
-LTLIBOBJS = @LTLIBOBJS@
-MAKEINFO = @MAKEINFO@
-MAX_INLINE_INSN_SINGLE = @MAX_INLINE_INSN_SINGLE@
-MKDIR_P = @MKDIR_P@
-MONITOR_CFLAGS = @MONITOR_CFLAGS@
-NETPLAY_LIBS = @NETPLAY_LIBS@
-OBJC = @OBJC@
-OBJCDEPMODE = @OBJCDEPMODE@
-OBJCFLAGS = @OBJCFLAGS@
-OBJCPP = @OBJCPP@
-OBJEXT = @OBJEXT@
-PACKAGE = @PACKAGE@
-PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
-PACKAGE_NAME = @PACKAGE_NAME@
-PACKAGE_STRING = @PACKAGE_STRING@
-PACKAGE_TARNAME = @PACKAGE_TARNAME@
-PACKAGE_URL = @PACKAGE_URL@
-PACKAGE_VERSION = @PACKAGE_VERSION@
-PATH_SEPARATOR = @PATH_SEPARATOR@
-PDFTEX = @PDFTEX@
-PERL = @PERL@
-PKG_CONFIG = @PKG_CONFIG@
-PLATFORM_DOX_FLAGS = @PLATFORM_DOX_FLAGS@
-PNG_CFLAGS = @PNG_CFLAGS@
-PNG_LIBS = @PNG_LIBS@
-PROGRAM_PREFIX = @PROGRAM_PREFIX@
-PROGRAM_SUFFIX = @PROGRAM_SUFFIX@
-RANLIB = @RANLIB@
-RESIDDTVSUB = @RESIDDTVSUB@
-RESIDSUB = @RESIDSUB@
-RESID_DEP = @RESID_DEP@
-RESID_DIR = @RESID_DIR@
-RESID_DTV_DEP = @RESID_DTV_DEP@
-RESID_DTV_DIR = @RESID_DTV_DIR@
-RESID_DTV_INCLUDES = @RESID_DTV_INCLUDES@
-RESID_DTV_LIBS = @RESID_DTV_LIBS@
-RESID_INCLUDES = @RESID_INCLUDES@
-RESID_LIBS = @RESID_LIBS@
-SDL2_CFLAGS = @SDL2_CFLAGS@
-SDL2_IMAGE_CFLAGS = @SDL2_IMAGE_CFLAGS@
-SDL2_IMAGE_LIBS = @SDL2_IMAGE_LIBS@
-SDL2_LIBS = @SDL2_LIBS@
-SDLCONFIG = @SDLCONFIG@
-SDL_EXTRA_LIBS = @SDL_EXTRA_LIBS@
-SDL_IMAGE_CFLAGS = @SDL_IMAGE_CFLAGS@
-SDL_IMAGE_LIBS = @SDL_IMAGE_LIBS@
-SET_MAKE = @SET_MAKE@
-SHELL = @SHELL@
-SOUND_DRIVERS = @SOUND_DRIVERS@
-SOUND_LIBS = @SOUND_LIBS@
-SOUND_MIDAS_OBJ = @SOUND_MIDAS_OBJ@
-SOUND_SDL_OBJ = @SOUND_SDL_OBJ@
-STRIP = @STRIP@
-SVN = @SVN@
-SVNVERSION = @SVNVERSION@
-SVN_REVISION_OVERRIDE = @SVN_REVISION_OVERRIDE@
-TAR = @TAR@
-TEXI2DVI = @TEXI2DVI@
-TFE_LIBS = @TFE_LIBS@
-UI_LIBS = @UI_LIBS@
-UNZIPBIN = @UNZIPBIN@
-UPDATE_DESKTOP_DATABASE = @UPDATE_DESKTOP_DATABASE@
-VERSION = @VERSION@
-VERSION_COMBINED = @VERSION_COMBINED@
-VERSION_RC = @VERSION_RC@
-VICE_CFLAGS = @VICE_CFLAGS@
-VICE_CPPFLAGS = @VICE_CPPFLAGS@
-VICE_CXXFLAGS = @VICE_CXXFLAGS@
-VICE_DATADIR = @VICE_DATADIR@
-VICE_DOCDIR = @VICE_DOCDIR@
-VICE_LDFLAGS = @VICE_LDFLAGS@
-VICE_OBJCFLAGS = @VICE_OBJCFLAGS@
-VICE_PDF_FILE_NAME = @VICE_PDF_FILE_NAME@
-VICE_VERSION = @VICE_VERSION@
-VICE_VERSION_BUILD = @VICE_VERSION_BUILD@
-VICE_VERSION_MAJOR = @VICE_VERSION_MAJOR@
-VICE_VERSION_MINOR = @VICE_VERSION_MINOR@
-VTE_CXXFLAGS = @VTE_CXXFLAGS@
-WINDRES = @WINDRES@
-WINDRES_LIB = @WINDRES_LIB@
-XA = @XA@
-XDG_ICON_RESOURCE = @XDG_ICON_RESOURCE@
-YACC = @YACC@
-ZLIB_LIBS = @ZLIB_LIBS@
-abs_builddir = @abs_builddir@
-abs_srcdir = @abs_srcdir@
-abs_top_builddir = @abs_top_builddir@
-abs_top_srcdir = @abs_top_srcdir@
-ac_ct_CC = @ac_ct_CC@
-ac_ct_CXX = @ac_ct_CXX@
-ac_ct_OBJC = @ac_ct_OBJC@
-am__include = @am__include@
-am__leading_dot = @am__leading_dot@
-am__quote = @am__quote@
-am__rm_f_notfound = @am__rm_f_notfound@
-am__tar = @am__tar@
-am__untar = @am__untar@
-am__xargs_n = @am__xargs_n@
-bindir = @bindir@
-build = @build@
-build_alias = @build_alias@
-build_cpu = @build_cpu@
-build_os = @build_os@
-build_vendor = @build_vendor@
-builddir = @builddir@
-datadir = @datadir@
-datarootdir = @datarootdir@
-docdir = @docdir@
-dvidir = @dvidir@
-exec_prefix = @exec_prefix@
-host = @host@
-host_alias = @host_alias@
-host_cpu = @host_cpu@
-host_os = @host_os@
-host_vendor = @host_vendor@
-htmldir = @htmldir@
-includedir = @includedir@
-infodir = @infodir@
-install_sh = @install_sh@
-libcurl_CFLAGS = @libcurl_CFLAGS@
-libcurl_LIBS = @libcurl_LIBS@
-libdir = @libdir@
-libevdev_CFLAGS = @libevdev_CFLAGS@
-libevdev_LIBS = @libevdev_LIBS@
-libexecdir = @libexecdir@
-localedir = @localedir@
-localstatedir = @localstatedir@
-mandir = @mandir@
-mkdir_p = @mkdir_p@
-objdump = @objdump@
-oldincludedir = @oldincludedir@
-pdfdir = @pdfdir@
-prefix = @prefix@
-program_transform_name = @program_transform_name@
-psdir = @psdir@
-runstatedir = @runstatedir@
-sbindir = @sbindir@
-sdl_config = @sdl_config@
-sharedstatedir = @sharedstatedir@
-srcdir = @srcdir@
-subdirs_extra = @subdirs_extra@
-sysconfdir = @sysconfdir@
-target_alias = @target_alias@
-top_build_prefix = @top_build_prefix@
-top_builddir = @top_builddir@
-top_srcdir = @top_srcdir@
-vsid_LDFLAGS = @vsid_LDFLAGS@
-x128_LDFLAGS = @x128_LDFLAGS@
-x64_LDFLAGS = @x64_LDFLAGS@
-xcbm2_LDFLAGS = @xcbm2_LDFLAGS@
-xpet_LDFLAGS = @xpet_LDFLAGS@
-xplus4_LDFLAGS = @xplus4_LDFLAGS@
-xscpu64_LDFLAGS = @xscpu64_LDFLAGS@
-xvic_LDFLAGS = @xvic_LDFLAGS@
-
-# Makefile.am for `libusbsiddrv.a'.
-# if HAVE_USBSID
-AM_CPPFLAGS = \
- @VICE_CPPFLAGS@ \
- @ARCH_INCLUDES@ \
- -I$(top_builddir)/src \
- -I$(top_srcdir)/src \
- -I$(top_srcdir)/src/lib/libusbsiddrv
-
-AM_CFLAGS = @VICE_CFLAGS@
-AM_CXXFLAGS = \
- @VICE_CXXFLAGS@ \
- -Wno-unused-variable \
- -I$(top_srcdir)/src/lib/libusbsiddrv
-
-AM_LDFLAGS = @VICE_LDFLAGS@
-noinst_LIBRARIES = libusbsiddrv.a
-USBSIDDRIVER = USBSID.o USBSIDInterface.o
-
-# Built depending on configure options:
-EXTRA_libusbsiddrv_a_SOURCES = \
- USBSIDInterface.cpp \
- USBSID.cpp
-
-EXTRA_DIST = \
- USBSID.h \
- USBSIDInterface.h
-
-
-# Always built:
-# (needs to be declared empty to avoid `make` to try to build libusbsiddrv.o
-# from libusbsiddrv.c)
-libusbsiddrv_a_SOURCES =
-noinst_HEADERS = USBSID.h USBSIDInterface.h
-
-# Make sure we actually link the generated object files into the library:
-libusbsiddrv_a_LIBADD = $(USBSIDDRIVER)
-all: all-am
-
-.SUFFIXES:
-.SUFFIXES: .cpp .o .obj
-$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
- @for dep in $?; do \
- case '$(am__configure_deps)' in \
- *$$dep*) \
- ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
- && { if test -f $@; then exit 0; else break; fi; }; \
- exit 1;; \
- esac; \
- done; \
- echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/lib/libusbsiddrv/Makefile'; \
- $(am__cd) $(top_srcdir) && \
- $(AUTOMAKE) --foreign src/lib/libusbsiddrv/Makefile
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- @case '$?' in \
- *config.status*) \
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
- *) \
- echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
- cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
- esac;
-
-$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-
-$(top_srcdir)/configure: $(am__configure_deps)
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-$(ACLOCAL_M4): $(am__aclocal_m4_deps)
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-$(am__aclocal_m4_deps):
-
-clean-noinstLIBRARIES:
- -$(am__rm_f) $(noinst_LIBRARIES)
-
-libusbsiddrv.a: $(libusbsiddrv_a_OBJECTS) $(libusbsiddrv_a_DEPENDENCIES) $(EXTRA_libusbsiddrv_a_DEPENDENCIES)
- $(AM_V_at)-rm -f libusbsiddrv.a
- $(AM_V_AR)$(libusbsiddrv_a_AR) libusbsiddrv.a $(libusbsiddrv_a_OBJECTS) $(libusbsiddrv_a_LIBADD)
- $(AM_V_at)$(libusbsiddrv_a_RANLIB) libusbsiddrv.a
-
-mostlyclean-compile:
- -rm -f *.$(OBJEXT)
-
-distclean-compile:
- -rm -f *.tab.c
-
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/USBSID.Po@am__quote@ # am--include-marker
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/USBSIDInterface.Po@am__quote@ # am--include-marker
-
-$(am__depfiles_remade):
- @$(MKDIR_P) $(@D)
- @: >>$@
-
-am--depfiles: $(am__depfiles_remade)
-
-.cpp.o:
-@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
-@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $<
-
-.cpp.obj:
-@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
-@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
-
-ID: $(am__tagged_files)
- $(am__define_uniq_tagged_files); mkid -fID $$unique
-tags: tags-am
-TAGS: tags
-
-tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- set x; \
- here=`pwd`; \
- $(am__define_uniq_tagged_files); \
- shift; \
- if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
- test -n "$$unique" || unique=$$empty_fix; \
- if test $$# -gt 0; then \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- "$$@" $$unique; \
- else \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- $$unique; \
- fi; \
- fi
-ctags: ctags-am
-
-CTAGS: ctags
-ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- $(am__define_uniq_tagged_files); \
- test -z "$(CTAGS_ARGS)$$unique" \
- || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
- $$unique
-
-GTAGS:
- here=`$(am__cd) $(top_builddir) && pwd` \
- && $(am__cd) $(top_srcdir) \
- && gtags -i $(GTAGS_ARGS) "$$here"
-cscopelist: cscopelist-am
-
-cscopelist-am: $(am__tagged_files)
- list='$(am__tagged_files)'; \
- case "$(srcdir)" in \
- [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
- *) sdir=$(subdir)/$(srcdir) ;; \
- esac; \
- for i in $$list; do \
- if test -f "$$i"; then \
- echo "$(subdir)/$$i"; \
- else \
- echo "$$sdir/$$i"; \
- fi; \
- done >> $(top_builddir)/cscope.files
-
-distclean-tags:
- -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-distdir: $(BUILT_SOURCES)
- $(MAKE) $(AM_MAKEFLAGS) distdir-am
-
-distdir-am: $(DISTFILES)
- @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
- topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
- list='$(DISTFILES)'; \
- dist_files=`for file in $$list; do echo $$file; done | \
- sed -e "s|^$$srcdirstrip/||;t" \
- -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
- case $$dist_files in \
- */*) $(MKDIR_P) `echo "$$dist_files" | \
- sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
- sort -u` ;; \
- esac; \
- for file in $$dist_files; do \
- if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
- if test -d $$d/$$file; then \
- dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
- if test -d "$(distdir)/$$file"; then \
- find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
- fi; \
- if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
- find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
- fi; \
- cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
- else \
- test -f "$(distdir)/$$file" \
- || cp -p $$d/$$file "$(distdir)/$$file" \
- || exit 1; \
- fi; \
- done
-check-am: all-am
-check: check-am
-all-am: Makefile $(LIBRARIES) $(HEADERS)
-installdirs:
-install: install-am
-install-exec: install-exec-am
-install-data: install-data-am
-uninstall: uninstall-am
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-
-installcheck: installcheck-am
-install-strip:
- if test -z '$(STRIP)'; then \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- install; \
- else \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
- fi
-mostlyclean-generic:
-
-clean-generic:
-
-distclean-generic:
- -$(am__rm_f) $(CONFIG_CLEAN_FILES)
- -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
-
-maintainer-clean-generic:
- @echo "This command is intended for maintainers to use"
- @echo "it deletes files that may require special tools to rebuild."
-clean: clean-am
-
-clean-am: clean-generic clean-noinstLIBRARIES mostlyclean-am
-
-distclean: distclean-am
- -rm -f ./$(DEPDIR)/USBSID.Po
- -rm -f ./$(DEPDIR)/USBSIDInterface.Po
- -rm -f Makefile
-distclean-am: clean-am distclean-compile distclean-generic \
- distclean-tags
-
-dvi: dvi-am
-
-dvi-am:
-
-html: html-am
-
-html-am:
-
-info: info-am
-
-info-am:
-
-install-data-am:
-
-install-dvi: install-dvi-am
-
-install-dvi-am:
-
-install-exec-am:
-
-install-html: install-html-am
-
-install-html-am:
-
-install-info: install-info-am
-
-install-info-am:
-
-install-man:
-
-install-pdf: install-pdf-am
-
-install-pdf-am:
-
-install-ps: install-ps-am
-
-install-ps-am:
-
-installcheck-am:
-
-maintainer-clean: maintainer-clean-am
- -rm -f ./$(DEPDIR)/USBSID.Po
- -rm -f ./$(DEPDIR)/USBSIDInterface.Po
- -rm -f Makefile
-maintainer-clean-am: distclean-am maintainer-clean-generic
-
-mostlyclean: mostlyclean-am
-
-mostlyclean-am: mostlyclean-compile mostlyclean-generic
-
-pdf: pdf-am
-
-pdf-am:
-
-ps: ps-am
-
-ps-am:
-
-uninstall-am:
-
-.MAKE: install-am install-strip
-
-.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
- clean-generic clean-noinstLIBRARIES cscopelist-am ctags \
- ctags-am distclean distclean-compile distclean-generic \
- distclean-tags distdir dvi dvi-am html html-am info info-am \
- install install-am install-data install-data-am install-dvi \
- install-dvi-am install-exec install-exec-am install-html \
- install-html-am install-info install-info-am install-man \
- install-pdf install-pdf-am install-ps install-ps-am \
- install-strip installcheck installcheck-am installdirs \
- maintainer-clean maintainer-clean-generic mostlyclean \
- mostlyclean-compile mostlyclean-generic pdf pdf-am ps ps-am \
- tags tags-am uninstall uninstall-am
-
-.PRECIOUS: Makefile
-
-# endif HAVE_USBSID
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
-
-# Tell GNU make to disable its built-in pattern rules.
-%:: %,v
-%:: RCS/%,v
-%:: RCS/%
-%:: s.%
-%:: SCCS/s.%
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 14:25:27
|
Revision: 45760
http://sourceforge.net/p/vice-emu/code/45760
Author: gpz
Date: 2025-09-14 14:25:26 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
debian needs another libusb dev package apparently
Modified Paths:
--------------
trunk/.github/workflows/build-main-on-push.yml
trunk/.github/workflows/make-release.yml
Modified: trunk/.github/workflows/build-main-on-push.yml
===================================================================
--- trunk/.github/workflows/build-main-on-push.yml 2025-09-14 14:09:02 UTC (rev 45759)
+++ trunk/.github/workflows/build-main-on-push.yml 2025-09-14 14:25:26 UTC (rev 45760)
@@ -446,6 +446,8 @@
libmpg123-dev \
libpcap-dev \
libpng-dev \
+ libusb-1.0-0 \
+ libusb-1.0-0-dev \
libusb-dev \
libvorbis-dev \
portaudio19-dev \
Modified: trunk/.github/workflows/make-release.yml
===================================================================
--- trunk/.github/workflows/make-release.yml 2025-09-14 14:09:02 UTC (rev 45759)
+++ trunk/.github/workflows/make-release.yml 2025-09-14 14:25:26 UTC (rev 45760)
@@ -408,6 +408,8 @@
libmpg123-dev \
libpcap-dev \
libpng-dev \
+ libusb-1.0-0 \
+ libusb-1.0-0-dev \
libusb-dev \
libvorbis-dev \
portaudio19-dev \
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-14 14:09:03
|
Revision: 45759
http://sourceforge.net/p/vice-emu/code/45759
Author: gpz
Date: 2025-09-14 14:09:02 +0000 (Sun, 14 Sep 2025)
Log Message:
-----------
install libusb on the build vm, should enable usbsid-pico support
Modified Paths:
--------------
trunk/.github/workflows/build-main-on-push.yml
trunk/.github/workflows/make-release.yml
Modified: trunk/.github/workflows/build-main-on-push.yml
===================================================================
--- trunk/.github/workflows/build-main-on-push.yml 2025-09-13 23:30:47 UTC (rev 45758)
+++ trunk/.github/workflows/build-main-on-push.yml 2025-09-14 14:09:02 UTC (rev 45759)
@@ -231,6 +231,7 @@
mingw-w64-${{ matrix.arch.arch }}-icoutils
mingw-w64-${{ matrix.arch.arch }}-lame
mingw-w64-${{ matrix.arch.arch }}-libpcap
+ mingw-w64-${{ matrix.arch.arch }}-libusb
mingw-w64-${{ matrix.arch.arch }}-libvorbis
mingw-w64-${{ matrix.arch.arch }}-mpg123
mingw-w64-${{ matrix.arch.arch }}-ntldd
@@ -266,6 +267,7 @@
mingw-w64-${{ matrix.arch.arch }}-icoutils
mingw-w64-${{ matrix.arch.arch }}-lame
mingw-w64-${{ matrix.arch.arch }}-libpcap
+ mingw-w64-${{ matrix.arch.arch }}-libusb
mingw-w64-${{ matrix.arch.arch }}-libvorbis
mingw-w64-${{ matrix.arch.arch }}-mpg123
mingw-w64-${{ matrix.arch.arch }}-ntldd
@@ -300,6 +302,7 @@
mingw-w64-${{ matrix.arch.arch }}-icoutils
mingw-w64-${{ matrix.arch.arch }}-lame
mingw-w64-${{ matrix.arch.arch }}-libpcap
+ mingw-w64-${{ matrix.arch.arch }}-libusb
mingw-w64-${{ matrix.arch.arch }}-libvorbis
mingw-w64-${{ matrix.arch.arch }}-mpg123
mingw-w64-${{ matrix.arch.arch }}-ntldd
@@ -443,6 +446,7 @@
libmpg123-dev \
libpcap-dev \
libpng-dev \
+ libusb-dev \
libvorbis-dev \
portaudio19-dev \
texinfo \
Modified: trunk/.github/workflows/make-release.yml
===================================================================
--- trunk/.github/workflows/make-release.yml 2025-09-13 23:30:47 UTC (rev 45758)
+++ trunk/.github/workflows/make-release.yml 2025-09-14 14:09:02 UTC (rev 45759)
@@ -228,6 +228,7 @@
mingw-w64-${{ matrix.arch.arch }}-icoutils
mingw-w64-${{ matrix.arch.arch }}-lame
mingw-w64-${{ matrix.arch.arch }}-libpcap
+ mingw-w64-${{ matrix.arch.arch }}-libusb
mingw-w64-${{ matrix.arch.arch }}-libvorbis
mingw-w64-${{ matrix.arch.arch }}-mpg123
mingw-w64-${{ matrix.arch.arch }}-ntldd
@@ -263,6 +264,7 @@
mingw-w64-${{ matrix.arch.arch }}-icoutils
mingw-w64-${{ matrix.arch.arch }}-lame
mingw-w64-${{ matrix.arch.arch }}-libpcap
+ mingw-w64-${{ matrix.arch.arch }}-libusb
mingw-w64-${{ matrix.arch.arch }}-libvorbis
mingw-w64-${{ matrix.arch.arch }}-mpg123
mingw-w64-${{ matrix.arch.arch }}-ntldd
@@ -406,6 +408,7 @@
libmpg123-dev \
libpcap-dev \
libpng-dev \
+ libusb-dev \
libvorbis-dev \
portaudio19-dev \
texinfo \
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-13 23:30:51
|
Revision: 45758
http://sourceforge.net/p/vice-emu/code/45758
Author: gpz
Date: 2025-09-13 23:30:47 +0000 (Sat, 13 Sep 2025)
Log Message:
-----------
added support for USBSID-Pico, based on patch(es) by LouD
Modified Paths:
--------------
trunk/vice/configure.ac
trunk/vice/doc/vice.texi
trunk/vice/src/Makefile.am
trunk/vice/src/arch/gtk3/widgets/sidenginemodelwidget.c
trunk/vice/src/arch/gtk3/widgets/sidsoundwidget.c
trunk/vice/src/arch/sdl/menu_sid.c
trunk/vice/src/arch/shared/hwsiddrv/Makefile.am
trunk/vice/src/lib/Makefile.am
trunk/vice/src/sid/Makefile.am
trunk/vice/src/sid/parsid.c
trunk/vice/src/sid/sid-cmdline-options.c
trunk/vice/src/sid/sid-cmdline-options.h
trunk/vice/src/sid/sid-resources.c
trunk/vice/src/sid/sid-snapshot.c
trunk/vice/src/sid/sid-snapshot.h
trunk/vice/src/sid/sid.c
trunk/vice/src/sid/sid.h
trunk/vice/src/vicefeatures.c
Added Paths:
-----------
trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c
trunk/vice/src/arch/shared/hwsiddrv/us-unixwin.h
trunk/vice/src/arch/shared/hwsiddrv/usbsid-unixwin-drv.c
trunk/vice/src/lib/libusbsiddrv/
trunk/vice/src/lib/libusbsiddrv/LICENSE
trunk/vice/src/lib/libusbsiddrv/Makefile
trunk/vice/src/lib/libusbsiddrv/Makefile.am
trunk/vice/src/lib/libusbsiddrv/Makefile.in
trunk/vice/src/lib/libusbsiddrv/README.md
trunk/vice/src/lib/libusbsiddrv/USBSID.cpp
trunk/vice/src/lib/libusbsiddrv/USBSID.h
trunk/vice/src/lib/libusbsiddrv/USBSIDInterface.cpp
trunk/vice/src/lib/libusbsiddrv/USBSIDInterface.h
trunk/vice/src/sid/usbsid.c
trunk/vice/src/usbsid.h
Modified: trunk/vice/configure.ac
===================================================================
--- trunk/vice/configure.ac 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/configure.ac 2025-09-13 23:30:47 UTC (rev 45758)
@@ -445,6 +445,7 @@
HAVE_FASTSID_SUPPORT="no "
HAVE_FONTCONFIG_SUPPORT="no "
HAVE_GIF_SUPPORT="no "
+HAVE_USBSID_SUPPORT="no "
HAVE_HARDSID_SUPPORT="no "
HAVE_HWSCALE_SUPPORT="no "
HAVE_IOSID_SUPPORT="no "
@@ -789,6 +790,44 @@
AM_CONDITIONAL(HAVE_CATWEASELMKIII, true)
HAVE_CATWEASELMKIII_SUPPORT="yes"
fi
+
+ dnl check for usbsid required libraries and headers
+ if test x"$enable_usbsid" != "xno" ; then
+ PKG_PROG_PKG_CONFIG
+ WIN32_USBSID_HEADER_PRESENT=yes
+ AC_CHECK_HEADERS(libusb-1.0/libusb.h,,[WIN32_USBSID_HEADER_PRESENT=no],)
+ if test x"$WIN32_USBSID_HEADER_PRESENT" = "xyes"; then
+ AC_CHECK_LIB(usb-1.0, libusb_init,[LIBS="-lusb-1.0 $LIBS"; USBSID_LIB_PRESENT=yes],,)
+ if test x"$PKG_CONFIG" != "x" -a x"$USBSID_LIB_PRESENT" = "xyes"; then
+ PKG_CHECK_MODULES(LIBUSB, [libusb-1.0], HAVE_LIBUSB_SUPPORT="yes")
+ AC_MSG_CHECKING([for pkgconfig libusb-1.0])
+ if test x"$HAVE_LIBUSB_SUPPORT" = "xyes"; then
+ VICE_CFLAGS="$VICE_CFLAGS $LIBUSB_CFLAGS";
+ VICE_CPPFLAGS="$VICE_CPPFLAGS $LIBUSB_CFLAGS";
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ fi
+ fi
+ fi
+ fi
+
+ dnl usbsid support
+ AM_CONDITIONAL(HAVE_USBSID, false)
+ AC_MSG_CHECKING([for USBSID-Pico support])
+ if test x"$enable_usbsid" != "xno" ; then
+ if test x"$HAVE_LIBUSB_SUPPORT" = "xyes"; then
+ AC_DEFINE([HAVE_USBSID],,[Support for USBSID])
+ HAVE_USBSID_SUPPORT="yes"
+ AM_CONDITIONAL(HAVE_USBSID, true)
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no (LIBUSB not found)])
+ fi
+ else
+ AC_MSG_RESULT([no (USBSID-Pico disabled)])
+ fi
+
if test x"$enable_hardsid" != "xno"; then
AC_DEFINE(HAVE_HARDSID,,[Support for HardSID.])
HAVE_HARDSID_SUPPORT="yes"
@@ -2761,7 +2800,7 @@
AC_SUBST(SOUND_DRIVERS)
AC_SUBST(SOUND_LIBS)
-dnl Check for ParSID/HardSID/CW support
+dnl Check for ParSID/USBSID/HardSID/CW support
if test x"$is_unix" = "xyes"; then
dnl Check cpu first
@@ -2914,6 +2953,44 @@
fi
fi
+
+ dnl usbsid required libraries and headers
+ if test x"$enable_usbsid" != "xno" ; then
+ PKG_PROG_PKG_CONFIG
+ UNIX_USBSID_HEADER_PRESENT=yes
+ AC_CHECK_HEADERS(libusb-1.0/libusb.h,,[UNIX_USBSID_HEADER_PRESENT=no],)
+ if test x"$UNIX_USBSID_HEADER_PRESENT" = "xyes"; then
+ AC_CHECK_LIB(usb-1.0, libusb_init,[LIBS="-lusb-1.0 $LIBS"; USBSID_LIB_PRESENT=yes],,)
+ if test x"$PKG_CONFIG" != "x" -a x"$USBSID_LIB_PRESENT" = "xyes"; then
+ PKG_CHECK_MODULES(LIBUSB, [libusb-1.0], HAVE_LIBUSB_SUPPORT="yes")
+ AC_MSG_CHECKING([for pkgconfig libusb-1.0])
+ if test x"$HAVE_LIBUSB_SUPPORT" = "xyes"; then
+ VICE_CFLAGS="$VICE_CFLAGS $LIBUSB_CFLAGS";
+ VICE_CPPFLAGS="$VICE_CPPFLAGS $LIBUSB_CFLAGS";
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ fi
+ fi
+ fi
+ fi
+
+ dnl usbsid support
+ AM_CONDITIONAL(HAVE_USBSID, false)
+ AC_MSG_CHECKING([for USBSID-Pico support])
+ if test x"$enable_usbsid" != "xno" ; then
+ if test x"$HAVE_LIBUSB_SUPPORT" = "xyes"; then
+ AC_DEFINE([HAVE_USBSID],,[Support for USBSID])
+ HAVE_USBSID_SUPPORT="yes"
+ AM_CONDITIONAL(HAVE_USBSID, true)
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no (LIBUSB not found!!)])
+ fi
+ else
+ AC_MSG_RESULT([no (USBSID-Pico disabled)])
+ fi
+
fi
AC_TYPE_SIGNAL
@@ -3455,6 +3532,7 @@
src/lib/Makefile
src/lib/p64/Makefile
src/lib/linenoise-ng/Makefile
+ src/lib/libusbsiddrv/Makefile
src/lib/libzmbv/Makefile
src/lib/md5/Makefile
src/monitor/Makefile
@@ -3613,6 +3691,7 @@
if test x"$real_arch" = "xUnix" -o x"$real_arch" = "xOSX" -o x"$real_arch" = "xWin32"; then
echo "MIDI support : $HAVE_MIDI_SUPPORT (--enable/disable-midi)"
+ echo "USBSID-Pico support : $HAVE_USBSID_SUPPORT"
fi
if test x"$real_arch" != "xOSX" -a x"$real_arch" != "xBeOS"; then
Modified: trunk/vice/doc/vice.texi
===================================================================
--- trunk/vice/doc/vice.texi 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/doc/vice.texi 2025-09-13 23:30:47 UTC (rev 45758)
@@ -12311,7 +12311,7 @@
@vindex SidEngine
@item SidEngine
Integer specifying what SID engine will be used.
-(0: FastSID, 1: ReSID, 2: Catweasel MKIII, 3: HardSID, 4: ParSID Port 1, 5: ParSID Port 2, 6: ParSID Port 3)
+(0: FastSID, 1: ReSID, 2: Catweasel MKIII, 3: HardSID, 4: ParSID Port 1, 5: ParSID Port 2, 6: ParSID Port 3, 7: USBSID-Pico)
@vindex SidResidSampling
@item SidResidSampling
@@ -12352,6 +12352,37 @@
not downsampled - audio data is written to a file called resid.raw in the current
working directory.
+@vindex SidUSBSIDReadMode
+@item SidUSBSIDReadMode
+Boolean specifying whether to enable USBSID-Pico read mode. When enabled, this
+mode allows for reading from SID registers that provides a means to configure an
+FPGASID that is seated on USBSID-Pico. This mode is not suited for regular audio
+use as it disables cycle exact writing & digiplay.
+Default is (@code{SidUSBSIDReadMode=0}) for off, (@code{SidUSBSIDReadMode=1}) for on.
+
+@vindex SidUSBSIDAudioMode
+@item SidUSBSIDAudioMode
+Boolean to enable USBSID-Pico PCB (v1.3) stereo audio mode. When enabled the audio of SID socket 1
+will be output over the left audio channel and the audio of SID socket 2 over the right channel
+of USBSID-Pico's audio out.
+Default is (@code{SidUSBSIDAudioMode=0}) for Mono, (@code{SidUSBSIDAudioMode=1}) for Stereo.
+
+@vindex SidUSBSIDDiffSize
+@item SidUSBSIDDiffSize
+Integer specifying the minimal difference (must be a number divisable by 8) in bytes to
+use between the head and tail of the drivers ringbuffer, this allows for some audio
+quality tuning on slower systems.
+In most cases the default value of 64 bytes (also the size of a USB packet) is the
+right setting for best audio quality. (@code{SidUSBSIDDiffSize=32-256}).
+
+@vindex SidUSBSIDBufferSize
+@item SidUSBSIDBufferSize
+Integer specifying the size in bytes to use as ringbuffer to store temporary data when sending
+SID writes to USBSID-Pico (must be a number divisable by 8), this allows for some audio quality
+tuning on slower systems.
+In most cases the default value of 8192 bytes is the right setting for best audio quality.
+(@code{SidUSBSIDBufferSize=512-16384}).
+
@end table
@@ -12498,14 +12529,15 @@
Catweasel MKIII: 512/catweaselmkiii/catweasel3/catweasel/cwmkiii/cw3/cw,
HardSID: 768/hardsid/hard/hs,
ParSID Port 1: 1024/parsid/parsid1/par1/lpt1,
-ParSID Port 2: 1280/parsid2/par2/lpt2
-ParSID Port 3: 1536/parsid3/par3/lpt3)
+ParSID Port 2: 1280/parsid2/par2/lpt2,
+ParSID Port 3: 1536/parsid3/par3/lpt3,
+USBSID-Pico: 1792/usbsid/usbs/us)
@findex -sidengine
@item -sidengine <engine>
Specify engine for the emulated SID chip
(@code{SidEngine}).
-(FastSID: 0, ReSID: 1, DTVSID: 2, HardSID: 3, ParSID Port 1: 4, ParSID Port 2: 5, ParSID Port 3: 6)
+(FastSID: 0, ReSID: 1, DTVSID: 2, HardSID: 3, ParSID Port 1: 4, ParSID Port 2: 5, ParSID Port 3: 6, USBSID-Pico: 7)
@findex -sidmodel
@item -sidmodel <model>
@@ -12558,6 +12590,35 @@
not downsampled - audio data is written to a file called resid.raw in the current
working directory.
+@findex -usreadmode
+@item -usreadmode <0 or 1>
+Enable USBSID-Pico read mode. When enabled, this mode allows for reading from SID
+ registers that provides a means to configure an FPGASID that is seated on USBSID-Pico.
+ This mode is not suited for regular audio use as it disables cycle exact writing & digiplay.
+ Default is (@code{SidUSBSIDReadMode=0}) for off, (@code{SidUSBSIDReadMode=1}) for on.
+
+@findex -usaudiomode
+@item -usaudiomode <0 or 1>
+Set USBSID-Pico PCB (v1.3) audio mode to Stereo or Mono. When enabled the audio of SID socket 1
+ will be output over the left audio channel and the audio of SID socket 2 over the right channel
+ of USBSID-Pico's audio out.
+ Default is (@code{SidUSBSIDAudioMode=0}) for Mono, (@code{SidUSBSIDAudioMode=1}) for Stereo.
+
+@findex -usdiffsize
+@item -usdiffsize <number divisable by 8>
+Specifies the minimal difference in bytes to use between the head and tail of the
+ drivers ringbuffer, this allows for some audio quality tuning on slower systems.
+ In most cases the default value of 64 bytes (also the size of a USB packet) is the
+ right setting for best audio quality.
+ (@code{SidUSBSIDDiffSize=32-256}).
+
+@findex -usbuffsize
+@item -usbuffsize <number divisable by 8>
+Specifies the size in bytes to use as ringbuffer to store temporary data when sending
+ SID writes to USBSID-Pico, this allows for some audio quality tuning on slower systems.
+ In most cases the default value of 8192 bytes is the right setting for best audio quality.
+ (@code{SidUSBSIDBufferSize=512-16384}).
+
@end table
@@ -37493,6 +37554,10 @@
@b{Bjoern Odendahl}
Created the new VICE logo and volunteered to create new icons.
+@item
+@b{LouD}
+Added USBSID-Pico hardware SID support.
+
@end itemize
(We hope we have not forgotten anybody; if you think we have,
Modified: trunk/vice/src/Makefile.am
===================================================================
--- trunk/vice/src/Makefile.am 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/src/Makefile.am 2025-09-13 23:30:47 UTC (rev 45758)
@@ -268,6 +268,7 @@
uicmdline.h \
uicolor.h \
uimon.h \
+ usbsid.h \
util.h \
version.h.in \
version.h \
@@ -569,6 +570,9 @@
if !USE_HEADLESSUI
hotkeys_lib = $(top_builddir)/src/arch/shared/hotkeys/libhotkeys.a
endif
+if HAVE_USBSID
+usbsiddrv_lib = $(top_builddir)/src/lib/libusbsiddrv/libusbsiddrv.a
+endif
hwsiddrv_lib = $(top_builddir)/src/arch/shared/hwsiddrv/libhwsiddrv.a
hvsc_lib = $(top_builddir)/src/hvsc/libhvsc.a
iecbus_lib = $(top_builddir)/src/iecbus/libiecbus.a
@@ -630,6 +634,10 @@
driver_libs = $(joyport_lib) $(samplerdrv_lib) $(sounddrv_lib) $(mididrv_lib) $(socketdrv_lib) $(hwsiddrv_lib) $(gfxoutputdrv_lib) $(printerdrv_lib) $(diskimage_lib) $(fsdevice_lib) $(tape_lib) $(fileio_lib) $(serial_lib) $(core_lib)
+if HAVE_USBSID
+driver_libs += $(usbsiddrv_lib)
+endif
+
if SUPPORT_X64
x64_bin = x64
else
@@ -669,6 +677,10 @@
$(vsidstubs_lib) \
$(md5_lib)
+if HAVE_USBSID
+vsid_libs += $(usbsiddrv_lib)
+endif
+
vsid_SOURCES = $(base_sources) $(midi_sources)
vsid_LDADD = $(vsid_libs) $(emu_extlibs) @TFE_LIBS@ @NETPLAY_LIBS@ $(VSID_RES)
@@ -1503,6 +1515,11 @@
$(hvsc_lib):
@echo "making all in hvsc"
@(cd hvsc && $(MAKE))
+if HAVE_USBSID
+$(usbsiddrv_lib):
+ @echo "making all in lib/libusbsiddrv"
+ @(cd lib/libusbsiddrv && $(MAKE))
+endif
$(hwsiddrv_lib):
@echo "making all in arch/shared/hwsiddrv"
@(cd arch/shared/hwsiddrv && $(MAKE))
Modified: trunk/vice/src/arch/gtk3/widgets/sidenginemodelwidget.c
===================================================================
--- trunk/vice/src/arch/gtk3/widgets/sidenginemodelwidget.c 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/src/arch/gtk3/widgets/sidenginemodelwidget.c 2025-09-13 23:30:47 UTC (rev 45758)
@@ -122,7 +122,6 @@
list = sid_get_engine_model_list();
for (i = 0; list[i] != NULL; i++) {
GtkWidget *radio;
-
radio = gtk_radio_button_new_with_label(group, list[i]->name);
gtk_radio_button_join_group(GTK_RADIO_BUTTON(radio),
GTK_RADIO_BUTTON(last));
Modified: trunk/vice/src/arch/gtk3/widgets/sidsoundwidget.c
===================================================================
--- trunk/vice/src/arch/gtk3/widgets/sidsoundwidget.c 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/src/arch/gtk3/widgets/sidsoundwidget.c 2025-09-13 23:30:47 UTC (rev 45758)
@@ -39,6 +39,12 @@
* $VICERES Sid2AddressStart all
* $VICERES Sid3AddressStart all
*
+ * These are related to USBSID
+ * $VICERES SidUSBSIDReadMode all
+ * $VICERES SidUSBSIDAudioMode all
+ * $VICERES SidUSBSIDDiffSize all
+ * $VICERES SidUSBSIDBufferSize all
+ *
* Until PSID files support more than three SIDs, these will be -vsid:
* $VICERES Sid4AddressStart -vsid
* $VICERES Sid5AddressStart -vsid
@@ -133,6 +139,30 @@
};
#endif
+#ifdef HAVE_USBSID
+/** \brief Values for the "SidUSBSIDDiffSize" resource
+ */
+static const vice_gtk3_radiogroup_entry_t us_diffsizes_radio[] = {
+ { "32", 32 },
+ { "64", 64 },
+ { "128", 128 },
+ { "256", 256 },
+ { NULL, -1 }
+};
+
+/** \brief Values for the "SidUSBSIDBufferSize" resource
+ */
+static const vice_gtk3_radiogroup_entry_t us_buffsizes_radio[] = {
+ { "512", 512 },
+ { "1024", 1024 },
+ { "2048", 2048 },
+ { "4092", 4092 },
+ { "8192", 8192 },
+ { "16384", 16384 },
+ { NULL, -1 }
+};
+#endif
+
/** \brief I/O addresses for extra SID's for the C64 */
static int sid_addr_list_c64[] = {
/*N/A*/ 0xd420, 0xd440, 0xd460, 0xd480, 0xd4a0, 0xd4c0, 0xd4e0,
@@ -168,6 +198,15 @@
static GtkWidget *resid_8580_grid;
#endif
+#ifdef HAVE_USBSID
+/** \brief USBSID read mode / audio mode checkbox */
+static GtkWidget *us_switches;
+/** \brief USBSID diffsizes radio buttons */
+static GtkWidget *us_diffsizes;
+/** \brief USBSID buffsizes radio buttons */
+static GtkWidget *us_buffsizes;
+#endif
+
/** \brief Number of extra SIDs widget */
static GtkWidget *num_sids_widget;
@@ -274,6 +313,83 @@
}
#endif
+#ifdef HAVE_USBSID
+/** \brief Create widget to control USBSID switches
+ *
+ * \return GtkGrid
+ */
+static GtkWidget *create_us_switches_widget(void)
+{
+ GtkWidget *grid;
+ GtkWidget *label;
+ GtkWidget *us_readmode;
+ GtkWidget *us_audiomode;
+
+ grid = gtk_grid_new();
+ gtk_grid_set_row_spacing(GTK_GRID(grid), 8);
+
+ label = label_helper("<b>USBSID options</b>");
+ us_readmode = vice_gtk3_resource_check_button_new("SidUSBSIDReadMode",
+ "Enable read mode");
+ us_audiomode = vice_gtk3_resource_check_button_new("SidUSBSIDAudioMode",
+ "Enable stereo mode");
+
+ gtk_grid_attach(GTK_GRID(grid), label, 0, 0, 1, 1);
+ gtk_grid_attach(GTK_GRID(grid), us_readmode, 0, 1, 1, 1);
+ gtk_grid_attach(GTK_GRID(grid), us_audiomode, 0, 2, 1, 1);
+ gtk_widget_show_all(grid);
+ return grid;
+}
+
+/** \brief Create widget to control USBSID buffer diff
+ *
+ * \return GtkGrid
+ */
+static GtkWidget *create_us_diffsizes_widget(void)
+{
+ GtkWidget *grid;
+ GtkWidget *label;
+ GtkWidget *group;
+
+ grid = gtk_grid_new();
+ gtk_grid_set_row_spacing(GTK_GRID(grid), 8);
+
+ label = label_helper("<b>USBSID buffer diff</b>");
+ group = vice_gtk3_resource_radiogroup_new("SidUSBSIDDiffSize",
+ us_diffsizes_radio,
+ GTK_ORIENTATION_VERTICAL);
+
+ gtk_grid_attach(GTK_GRID(grid), label, 0, 0, 1, 1);
+ gtk_grid_attach(GTK_GRID(grid), group, 0, 1, 1, 1);
+ gtk_widget_show_all(grid);
+ return grid;
+}
+
+/** \brief Create widget to control USBSID buffer size
+ *
+ * \return GtkGrid
+ */
+static GtkWidget *create_us_buffsizes_widget(void)
+{
+ GtkWidget *grid;
+ GtkWidget *label;
+ GtkWidget *group;
+
+ grid = gtk_grid_new();
+ gtk_grid_set_row_spacing(GTK_GRID(grid), 8);
+
+ label = label_helper("<b>USBSID buffer size</b>");
+ group = vice_gtk3_resource_radiogroup_new("SidUSBSIDBufferSize",
+ us_buffsizes_radio,
+ GTK_ORIENTATION_VERTICAL);
+
+ gtk_grid_attach(GTK_GRID(grid), label, 0, 0, 1, 1);
+ gtk_grid_attach(GTK_GRID(grid), group, 0, 1, 1, 1);
+ gtk_widget_show_all(grid);
+ return grid;
+}
+#endif
+
/** \brief Create widget to set the number of emulated SID's
*
* \return GtkGrid
@@ -551,6 +667,22 @@
}
#endif
+/* FIXME: HardSID options are missing */
+
+#ifdef HAVE_USBSID
+ us_switches = create_us_switches_widget();
+ us_diffsizes = create_us_diffsizes_widget();
+ us_buffsizes = create_us_buffsizes_widget();
+
+ gtk_grid_attach(GTK_GRID(grid), us_switches, 0, row + 3, 1, 1);
+ gtk_grid_attach(GTK_GRID(grid), us_diffsizes, 1, row + 3, 1, 1);
+ gtk_grid_attach(GTK_GRID(grid), us_buffsizes, 2, row + 3, 1, 1);
+
+ gtk_widget_set_sensitive(us_switches, current_engine == SID_ENGINE_USBSID);
+ gtk_widget_set_sensitive(us_diffsizes, current_engine == SID_ENGINE_USBSID);
+ gtk_widget_set_sensitive(us_buffsizes, current_engine == SID_ENGINE_USBSID);
+#endif
+
if (machine_class != VICE_MACHINE_PLUS4 &&
machine_class != VICE_MACHINE_CBM5x0 &&
machine_class != VICE_MACHINE_CBM6x0) {
Modified: trunk/vice/src/arch/sdl/menu_sid.c
===================================================================
--- trunk/vice/src/arch/sdl/menu_sid.c 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/src/arch/sdl/menu_sid.c 2025-09-13 23:30:47 UTC (rev 45758)
@@ -169,6 +169,94 @@
#endif /* HAVE_RESID */
+#ifdef HAVE_USBSID
+UI_MENU_DEFINE_TOGGLE(SidUSBSIDReadMode)
+UI_MENU_DEFINE_TOGGLE(SidUSBSIDAudioMode)
+UI_MENU_DEFINE_RADIO(SidUSBSIDDiffSize)
+UI_MENU_DEFINE_RADIO(SidUSBSIDBufferSize)
+
+static const ui_menu_entry_t us_diffsize_menu[] = {
+ { .string = "32",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDDiffSize_callback,
+ .data = (ui_callback_data_t)32
+ },
+ { .string = "64",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDDiffSize_callback,
+ .data = (ui_callback_data_t)64
+ },
+ { .string = "128",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDDiffSize_callback,
+ .data = (ui_callback_data_t)128
+ },
+ { .string = "256",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDDiffSize_callback,
+ .data = (ui_callback_data_t)256
+ },
+ SDL_MENU_LIST_END
+};
+
+static const ui_menu_entry_t us_buffsize_menu[] = {
+ { .string = "512",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDBufferSize_callback,
+ .data = (ui_callback_data_t)512
+ },
+ { .string = "1024",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDBufferSize_callback,
+ .data = (ui_callback_data_t)1024
+ },
+ { .string = "2048",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDBufferSize_callback,
+ .data = (ui_callback_data_t)2048
+ },
+ { .string = "4096",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDBufferSize_callback,
+ .data = (ui_callback_data_t)4096
+ },
+ { .string = "8192",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDBufferSize_callback,
+ .data = (ui_callback_data_t)8192
+ },
+ { .string = "16384",
+ .type = MENU_ENTRY_RESOURCE_RADIO,
+ .callback = radio_SidUSBSIDBufferSize_callback,
+ .data = (ui_callback_data_t)16384
+ },
+ SDL_MENU_LIST_END
+};
+
+# define VICE_SDL_USBSID_OPTIONS \
+ { .string = "USBSID enable stereo audio mode", \
+ .type = MENU_ENTRY_RESOURCE_TOGGLE, \
+ .callback = toggle_SidUSBSIDAudioMode_callback \
+ }, \
+ { .string = "USBSID enable read mode", \
+ .type = MENU_ENTRY_RESOURCE_TOGGLE, \
+ .callback = toggle_SidUSBSIDReadMode_callback \
+ }, \
+ { .string = "USBSID buffer size", \
+ .type = MENU_ENTRY_SUBMENU, \
+ .callback = submenu_radio_callback, \
+ .data = (ui_callback_data_t)us_buffsize_menu \
+ }, \
+ { .string = "USBSID diff size", \
+ .type = MENU_ENTRY_SUBMENU, \
+ .callback = submenu_radio_callback, \
+ .data = (ui_callback_data_t)us_diffsize_menu \
+ }, \
+
+
+#endif /* HAVE_USBSID */
+
+
UI_MENU_DEFINE_TOGGLE(SidFilters)
UI_MENU_DEFINE_RADIO(SidStereo)
UI_MENU_DEFINE_RADIO(Sid2AddressStart)
@@ -681,6 +769,9 @@
#ifdef HAVE_RESID
VICE_SDL_RESID_OPTIONS
#endif
+#ifdef HAVE_USBSID
+ VICE_SDL_USBSID_OPTIONS
+#endif
SDL_MENU_LIST_END
};
@@ -736,6 +827,9 @@
#ifdef HAVE_RESID
VICE_SDL_RESID_OPTIONS
#endif
+#ifdef HAVE_USBSID
+ VICE_SDL_USBSID_OPTIONS
+#endif
SDL_MENU_LIST_END
};
@@ -751,6 +845,9 @@
#ifdef HAVE_RESID
VICE_SDL_RESID_OPTIONS
#endif
+#ifdef HAVE_USBSID
+ VICE_SDL_USBSID_OPTIONS
+#endif
SDL_MENU_LIST_END
};
@@ -766,6 +863,9 @@
#ifdef HAVE_RESID
VICE_SDL_RESID_OPTIONS
#endif
+#ifdef HAVE_USBSID
+ VICE_SDL_USBSID_OPTIONS
+#endif
SDL_MENU_LIST_END
};
@@ -789,6 +889,9 @@
#ifdef HAVE_RESID
VICE_SDL_RESID_OPTIONS
#endif
+#ifdef HAVE_USBSID
+ VICE_SDL_USBSID_OPTIONS
+#endif
SDL_MENU_ITEM_SEPARATOR,
SDL_MENU_ITEM_TITLE("SID address"),
{ .string = "$9800",
@@ -833,6 +936,9 @@
#ifdef HAVE_RESID
VICE_SDL_RESID_OPTIONS
#endif
+#ifdef HAVE_USBSID
+ VICE_SDL_USBSID_OPTIONS
+#endif
SDL_MENU_ITEM_SEPARATOR,
SDL_MENU_ITEM_TITLE("SID address"),
{ .string = "$8F00",
@@ -879,6 +985,9 @@
#ifdef HAVE_RESID
VICE_SDL_RESID_OPTIONS
#endif
+#ifdef HAVE_USBSID
+ VICE_SDL_USBSID_OPTIONS
+#endif
SDL_MENU_ITEM_SEPARATOR,
SDL_MENU_ITEM_TITLE("SID address"),
Modified: trunk/vice/src/arch/shared/hwsiddrv/Makefile.am
===================================================================
--- trunk/vice/src/arch/shared/hwsiddrv/Makefile.am 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/src/arch/shared/hwsiddrv/Makefile.am 2025-09-13 23:30:47 UTC (rev 45758)
@@ -16,6 +16,12 @@
AM_LDFLAGS = @VICE_LDFLAGS@
+# TESTING
+if HAVE_USBSID
+AM_CPPFLAGS += -I$(top_srcdir)/src/lib/libusbsiddrv
+AM_CXXFLAGS += -I$(top_srcdir)/src/lib/libusbsiddrv
+AM_LDFLAGS += -I$(top_srcdir)/src/lib/libusbsiddrv
+endif
noinst_LIBRARIES = libhwsiddrv.a
@@ -38,6 +44,11 @@
parsid-win32-drv.o \
ps-ieee1284.o
endif HAVE_PARSID
+if HAVE_USBSID
+HWSIDDRIVERS += \
+ usbsid-unixwin-drv.o \
+ us-unixwin-device.o
+endif HAVE_USBSID
endif WINDOWS_COMPILE
if BEOS_COMPILE
@@ -64,6 +75,11 @@
ps-ieee1284.o \
ps-unix-file.o
endif HAVE_PARSID
+if HAVE_USBSID
+HWSIDDRIVERS += \
+ usbsid-unixwin-drv.o \
+ us-unixwin-device.o
+endif HAVE_USBSID
endif UNIX_COMPILE
@@ -80,7 +96,9 @@
parsid-unix-drv.c \
parsid-win32-drv.c \
ps-ieee1284.c \
- ps-unix-file.c
+ ps-unix-file.c \
+ usbsid-unixwin-drv.c \
+ us-unixwin-device.c
EXTRA_DIST = \
cw-unix.h \
@@ -88,7 +106,8 @@
hs-unix.h \
hs-win32.h \
ps-unix.h \
- ps-win32.h
+ ps-win32.h \
+ us-unixwin.h
# Always built:
# (needs to be declared empty to avoid `make` to try to build libhwsiddrv.o
Added: trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c
===================================================================
--- trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c (rev 0)
+++ trunk/vice/src/arch/shared/hwsiddrv/us-unixwin-device.c 2025-09-13 23:30:47 UTC (rev 45758)
@@ -0,0 +1,330 @@
+/*
+ * us-unixwin-device.c
+ *
+ * Written by
+ * LouDnl <vi...@ma...>
+ *
+ * Based on vice code written by
+ * Simon White <sid...@ya...>
+ * Marco van den Heuvel <bla...@ya...>
+ *
+ * This file is part of VICE, modified from the other hardware sid sources.
+ *
+ * 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., 59 Temple Place, Suite 330, Boston, MA
+ * 02111-1307 USA.
+ *
+ */
+
+#include "vice.h"
+
+#if defined(HAVE_USBSID)
+
+#include <fcntl.h>
+#include <unistd.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <errno.h>
+#include <stdlib.h>
+#include <string.h>
+#include <sys/time.h> /* TIMESPEC */
+#include <time.h> /* TIMESPEC */
+
+#include "alarm.h"
+#include "us-unixwin.h"
+#include "usbsid.h"
+#include "log.h"
+#include "maincpu.h"
+#include "machine.h"
+#include "resources.h"
+#include "sid-resources.h"
+#include "types.h"
+
+#include "USBSIDInterface.h"
+
+static int rc = -1, sids_found = -1, no_sids = -1;
+static int r_audiomode = -1, audiomode = -1;
+static int r_readmode = -1, readmode = -1;
+static int buffsize = -1, diffsize = -1;
+static int r_buffsize = -1, r_diffsize = -1;
+const int d_buffsize = 8192, d_diffsize = 64;
+static uint8_t sid_registers[0x20 * US_MAXSID];
+static int usid_chipno = -1;
+
+static CLOCK usid_main_clk;
+static CLOCK usid_alarm_clk;
+static alarm_t *usid_alarm = NULL;
+static long raster_rate;
+
+static log_t usbsid_log = LOG_DEFAULT;
+
+/* pre declarations */
+static void usbsid_alarm_handler(CLOCK offset, void *data);
+
+USBSIDitf usbsid;
+
+void us_device_reset(bool us_reset)
+{
+ if (sids_found > 0) {
+ raster_rate = getrasterrate_USBSID(usbsid);
+ usid_main_clk = maincpu_clk;
+ usid_alarm_clk = raster_rate;
+ alarm_set(usid_alarm, (usid_main_clk + raster_rate));
+ if (us_reset) {
+ reset_USBSID(usbsid);
+ log_message(usbsid_log, "Reset sent");
+ }
+ no_sids = -1;
+ log_message(usbsid_log, "Clocks reset");
+ }
+ return;
+}
+
+int us_device_open(void)
+{
+ usbsid_log = log_open("USBSID");
+
+ if (!sids_found) {
+ return -1;
+ }
+
+ if (sids_found > 0) {
+ return sids_found;
+ }
+
+ sids_found = 0;
+
+ log_message(usbsid_log, "Detecting boards");
+
+ if (usbsid == NULL) {
+ usbsid = create_USBSID();
+ if (usbsid) {
+ /* Gather settings from resources */
+ resources_get_int("SidUSBSIDReadMode", &r_readmode);
+ resources_get_int("SidUSBSIDAudioMode", &r_audiomode);
+ resources_get_int("SidUSBSIDDiffSize", &r_readmode);
+ resources_get_int("SidUSBSIDBufferSize", &r_diffsize);
+ /* Apply settings to local variables */
+ readmode = r_readmode;
+ audiomode = r_audiomode;
+ diffsize = r_diffsize;
+ buffsize = r_buffsize;
+ /* Update diff and buff size if needed */
+ if (diffsize >= 16) {
+ setdiffsize_USBSID(usbsid, diffsize);
+ }
+ if (buffsize >= 256) {
+ setbuffsize_USBSID(usbsid, buffsize);
+ }
+ }
+
+ if (readmode == 1) {
+ rc = init_USBSID(usbsid, false, false); /* threading and cycles disabled */
+ if (rc >= 0) {
+ log_message(usbsid_log, "Starting in read mode");
+ }
+ } else { /* (readmode == 0 || readmode == -1) */
+ /* NOTICE: Digitunes only play with threaded cycles */
+ rc = init_USBSID(usbsid, true, true); /* threading and cycles enabled */
+ if (rc >= 0) {
+ log_message(usbsid_log, "Starting in normal mode");
+ }
+ }
+ if (rc < 0) {
+ return rc;
+ }
+ }
+
+ log_message(usbsid_log, "Set audio mode to %s", (audiomode == 1 ? "Stereo" : "Mono"));
+ setstereo_USBSID(usbsid, (audiomode == 1 ? audiomode : 0));
+
+ usid_alarm = alarm_new(maincpu_alarm_context, "usbsid", usbsid_alarm_handler, NULL);
+ sids_found = getnumsids_USBSID(usbsid);
+ no_sids = 0;
+ log_message(usbsid_log, "Alarm set, reset sids");
+ us_device_reset(false); /* No reset on init! */
+ log_message(usbsid_log, "Opened");
+
+ return rc;
+}
+
+int us_device_close(void)
+{
+ log_message(usbsid_log, "Start device closing");
+ if (usbsid) {
+ mute_USBSID(usbsid);
+ close_USBSID(usbsid);
+ }
+
+ /* Clean up vars */
+ alarm_destroy(usid_alarm);
+ usid_alarm = 0;
+ sids_found = -1;
+ no_sids = -1;
+ rc = -1;
+ usbsid = NULL;
+ log_message(usbsid_log, "Closed");
+ return 0;
+}
+
+int us_device_read(uint16_t addr, int chipno)
+{ /* NOTICE: Disabled, unneeded */
+ if (chipno < US_MAXSID) {
+ addr = ((addr & 0x1F) + (chipno * 0x20));
+ if (readmode == 1) {
+ sid_registers[addr] = read_USBSID(usbsid, addr);
+ }
+ usid_chipno = chipno;
+ return sid_registers[addr];
+ }
+ usid_chipno = -1;
+ return 0x0;
+}
+
+CLOCK us_delay(void)
+{ /* ISSUE: This should return an unsigned 64 bit integer but that makes vice stall indefinately on negative integers */
+ if (maincpu_clk < usid_main_clk) { /* Sync reset */
+ usid_main_clk = maincpu_clk;
+ return 0;
+ }
+ /* Without substracting 1 cycle this
+ * can cause a clicking noise in cycle exact tunes
+ * create audible skips in digitunes like Sky Buster */
+ CLOCK cycles = maincpu_clk - usid_main_clk - 1;
+ while (cycles > 0xffff) {
+ cycles -= 0xffff;
+ }
+ usid_main_clk = maincpu_clk;
+ return cycles;
+}
+
+void us_device_store(uint16_t addr, uint8_t val, int chipno) /* max chipno = 1 */
+{
+ if (chipno < US_MAXSID) { /* remove 0x20 address limitation */
+ addr = ((addr & 0x1F) + (chipno * 0x20));
+ if (readmode == 0) {
+ CLOCK cycles = us_delay();
+ writeringcycled_USBSID(usbsid, addr, val, (uint16_t)cycles);
+ } else if (readmode == 1) {
+ write_USBSID(usbsid, addr, val);
+ }
+ usid_chipno = chipno;
+ sid_registers[addr] = val;
+ return;
+ }
+ usid_chipno = -1;
+ return;
+}
+
+void us_set_machine_parameter(long cycles_per_sec)
+{
+ setclockrate_USBSID(usbsid, cycles_per_sec, true);
+ raster_rate = getrasterrate_USBSID(usbsid);
+ log_message(usbsid_log, "Clockspeed set to: %ld and rasterrate set to: %ld", cycles_per_sec, raster_rate);
+ return;
+}
+
+unsigned int us_device_available(void)
+{
+ log_message(usbsid_log, "%d SIDs available", sids_found);
+ return sids_found;
+}
+
+void us_set_readmode(int val)
+{
+ resources_get_int("SidUSBSIDReadMode", &r_readmode);
+ if (readmode != val) {
+ log_message(usbsid_log, "Set read mode from %d to %d (resource: %d)", readmode, val, r_readmode);
+ readmode = val;
+ if (val == 0) {
+ enablethread_USBSID(usbsid);
+ }
+ if (val == 1) {
+ disablethread_USBSID(usbsid);
+ }
+ }
+ return;
+}
+
+void us_set_audiomode(int val)
+{ /* Gets set by x64sc from SID settings and by VSID at SID file change */
+ resources_get_int("SidUSBSIDAudioMode", &r_audiomode);
+ log_message(usbsid_log, "Audio mode is '%s' (resource:%d val:%d)", (r_audiomode == 1 ? "Stereo" : "Mono"), r_audiomode, val);
+ audiomode = r_audiomode;
+
+ setstereo_USBSID(usbsid, audiomode);
+}
+
+void us_restart_ringbuffer(void)
+{ /* Restarts the ringbuffer with a new value */
+ if (buffsize != d_buffsize) {
+ log_message(usbsid_log, "Restarting ringbuffer with buffer size:%d & diff size:%d", buffsize, diffsize);
+ restartringbuffer_USBSID(usbsid);
+ }
+}
+
+void us_set_buffsize(int val)
+{ /* Set the ringbuffer size */
+ resources_get_int("SidUSBSIDBufferSize", &r_buffsize);
+ buffsize = r_buffsize;
+ if (r_buffsize != d_buffsize) {
+ log_message(usbsid_log, "Setting ringbuffer size to: %d (val:%d default:%d)", buffsize, val, d_buffsize);
+ setbuffsize_USBSID(usbsid, buffsize);
+ us_restart_ringbuffer();
+ }
+}
+
+void us_set_diffsize(int val)
+{ /* Set the ringbuffer head to tail difference size */
+ resources_get_int("SidUSBSIDDiffSize", &r_diffsize);
+ diffsize = r_diffsize;
+ if (r_diffsize != d_diffsize) {
+ log_message(usbsid_log, "Setting ringbuffer diff size to: %d (val:%d default:%d)", diffsize, val, d_diffsize);
+ setdiffsize_USBSID(usbsid, diffsize);
+ }
+
+}
+
+static void usbsid_alarm_handler(CLOCK offset, void *data)
+{
+ CLOCK cycles = (usid_alarm_clk + offset) - usid_main_clk;
+
+ if (cycles < raster_rate) {
+ usid_alarm_clk = usid_main_clk + raster_rate;
+ } else {
+ setflush_USBSID(usbsid);
+ usid_main_clk = maincpu_clk - offset;
+ usid_alarm_clk = usid_main_clk + raster_rate;
+ }
+ alarm_set(usid_alarm, usid_alarm_clk);
+ return;
+}
+
+/* ---------------------------------------------------------------------*/
+
+void us_device_state_read(int chipno, struct sid_us_snapshot_state_s *sid_state)
+{
+ sid_state->usid_main_clk = usid_main_clk;
+ sid_state->usid_alarm_clk = usid_alarm_clk;
+ sid_state->lastaccess_chipno = usid_chipno;
+}
+
+void us_device_state_write(int chipno, struct sid_us_snapshot_state_s *sid_state)
+{
+ usid_main_clk = sid_state->usid_main_clk;
+ usid_alarm_clk = sid_state->usid_alarm_clk;
+ usid_chipno = sid_state->lastaccess_chipno;
+}
+
+#endif /* HAVE_USBSID */
Added: trunk/vice/src/arch/shared/hwsiddrv/us-unixwin.h
===================================================================
--- trunk/vice/src/arch/shared/hwsiddrv/us-unixwin.h (rev 0)
+++ trunk/vice/src/arch/shared/hwsiddrv/us-unixwin.h 2025-09-13 23:30:47 UTC (rev 45758)
@@ -0,0 +1,68 @@
+/*
+ * us-unixwin.h - Linux USBSID specific prototypes.
+ *
+ * Written by
+ * LouDnl <vi...@ma...>
+ *
+ * Based on hs-unix.h written by
+ * Marco van den Heuvel <bla...@ya...>
+ *
+ * This file is part of VICE, the Versatile Commodore Emulator.
+ * See README for copyright notice.
+ *
+ * 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., 59 Temple Place, Suite 330, Boston, MA
+ * 02111-1307 USA.
+ *
+ */
+
+#ifndef VICE_US_UNIXWIN_H
+#define VICE_US_UNIXWIN_H
+
+#include "sid-snapshot.h"
+#include "types.h"
+
+#define US_MAXSID 4
+
+int us_device_open(void);
+
+int us_device_close(void);
+
+void us_device_reset(bool us_reset);
+
+int us_device_read(uint16_t addr, int chipno);
+
+CLOCK us_delay(void);
+
+void us_device_store(uint16_t addr, uint8_t val, int chipno);
+
+void us_set_machine_parameter(long cycles_per_sec);
+
+unsigned int us_device_available(void);
+
+void us_set_readmode(int val);
+
+void us_set_audiomode(int val);
+
+void us_restart_ringbuffer(void);
+
+void us_set_buffsize(int val);
+
+void us_set_diffsize(int val);
+
+void us_device_state_read(int chipno, struct sid_us_snapshot_state_s *sid_state);
+
+void us_device_state_write(int chipno, struct sid_us_snapshot_state_s *sid_state);
+
+#endif /* VICE_US_UNIXWIN_H */
Added: trunk/vice/src/arch/shared/hwsiddrv/usbsid-unixwin-drv.c
===================================================================
--- trunk/vice/src/arch/shared/hwsiddrv/usbsid-unixwin-drv.c (rev 0)
+++ trunk/vice/src/arch/shared/hwsiddrv/usbsid-unixwin-drv.c 2025-09-13 23:30:47 UTC (rev 45758)
@@ -0,0 +1,151 @@
+/*
+ * usbsid-unixwin-drv.c
+ *
+ * Written by
+ * LouDnl <vi...@ma...>
+ *
+ * Based on hs-unix-linux.c written by
+ * Marco van den Heuvel <bla...@ya...>
+ *
+ * This file is part of VICE, the Versatile Commodore Emulator.
+ * See README for copyright notice.
+ *
+ * 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., 59 Temple Place, Suite 330, Boston, MA
+ * 02111-1307 USA.
+ *
+ */
+
+#include "vice.h"
+
+#ifdef HAVE_USBSID
+
+#include "usbsid.h"
+#include "us-unixwin.h"
+#include "types.h"
+
+static int use_us_device = 0;
+
+int usbsid_drv_open(void)
+{
+ int rc = 0;
+ if (!(rc = us_device_open())) {
+ use_us_device = 1;
+ return 0;
+ }
+
+ return rc;
+}
+
+int usbsid_drv_close(void)
+{
+
+ if (use_us_device) {
+ use_us_device = 0;
+ us_device_close();
+ }
+
+ return 0;
+}
+
+void usbsid_drv_reset(bool us_reset)
+{
+ if (use_us_device) {
+ us_device_reset(us_reset);
+ }
+}
+
+int usbsid_drv_read(uint16_t addr, int chipno)
+{
+ if (use_us_device) {
+ return us_device_read(addr, chipno);
+ }
+
+ return 0;
+}
+
+void usbsid_drv_store(uint16_t addr, uint8_t val, int chipno)
+{
+ if (use_us_device) {
+ us_device_store(addr, val, chipno);
+ }
+}
+
+void usbsid_drv_set_machine_parameter(long cycles_per_sec)
+{
+ if (use_us_device) {
+ us_set_machine_parameter(cycles_per_sec);
+ }
+}
+
+int usbsid_drv_available(void)
+{
+
+ if (use_us_device) {
+ return us_device_available();
+ }
+
+ return 0;
+}
+
+void usbsid_drv_set_readmode(int val)
+{
+ if (use_us_device) {
+ us_set_readmode(val);
+ }
+}
+
+void usbsid_drv_set_audiomode(int val)
+{
+ if (use_us_device) {
+ us_set_audiomode(val);
+ }
+}
+
+void usbsid_drv_restart_ringbuffer(void)
+{
+ if (use_us_device) {
+ us_restart_ringbuffer();
+ }
+}
+
+void usbsid_drv_set_buffsize(int val)
+{
+ if (use_us_device) {
+ us_set_buffsize(val);
+ }
+}
+
+void usbsid_drv_set_diffsize(int val)
+{
+ if (use_us_device) {
+ us_set_diffsize(val);
+ }
+}
+
+void usbsid_drv_state_read(int chipno, struct sid_us_snapshot_state_s *sid_state)
+{
+ if (use_us_device) {
+ us_device_state_read(chipno, sid_state);
+ }
+}
+
+void usbsid_drv_state_write(int chipno, struct sid_us_snapshot_state_s *sid_state)
+{
+ if (use_us_device) {
+ us_device_state_write(chipno, sid_state);
+ }
+}
+
+#endif /* HAVE_USBSID */
Modified: trunk/vice/src/lib/Makefile.am
===================================================================
--- trunk/vice/src/lib/Makefile.am 2025-09-13 11:58:55 UTC (rev 45757)
+++ trunk/vice/src/lib/Makefile.am 2025-09-13 23:30:47 UTC (rev 45758)
@@ -1,5 +1,9 @@
SUBDIRS = p64 linenoise-ng libzmbv md5
+if HAVE_USBSID
+SUBDIRS += libusbsiddrv
+endif
+
AM_CFLAGS = @VICE_CFLAGS@
AM_CXXFLAGS = @VICE_CXXFLAGS@
@@ -16,3 +20,9 @@
libzmbv:
(cd libzmbv; $(MAKE))
+
+.PHONY: libusbsiddrv
+if HAVE_USBSID
+libusbsiddrv:
+ (cd libusbsiddrv; $(MAKE))
+endif
Added: trunk/vice/src/lib/libusbsiddrv/LICENSE
===================================================================
--- trunk/vice/src/lib/libusbsiddrv/LICENSE (rev 0)
+++ trunk/vice/src/lib/libusbsiddrv/LICENSE 2025-09-13 23:30:47 UTC (rev 45758)
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ 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.
+
+Also add informati...
[truncated message content] |
|
From: <gp...@us...> - 2025-09-13 11:58:57
|
Revision: 45757
http://sourceforge.net/p/vice-emu/code/45757
Author: gpz
Date: 2025-09-13 11:58:55 +0000 (Sat, 13 Sep 2025)
Log Message:
-----------
fix typo, patch by Dan Fandrich
Modified Paths:
--------------
trunk/vice/src/tools/petcat/petcat.c
Modified: trunk/vice/src/tools/petcat/petcat.c
===================================================================
--- trunk/vice/src/tools/petcat/petcat.c 2025-09-05 16:01:31 UTC (rev 45756)
+++ trunk/vice/src/tools/petcat/petcat.c 2025-09-13 11:58:55 UTC (rev 45757)
@@ -566,7 +566,7 @@
{ B_DRAGO, 13, 0xD8, 0x0801, 0, 0xCC, dragobasickwcc, "drago", 0, 0, 0, "Basic v2.0 with Drago Basic v2.2 (C64)" },
{ B_REU, 15, 0xDA, 0x0801, 0, 0xCC, reubasickwcc, "reu", 0, 0, 0, "Basic v2.0 with REU-Basic (C64)" },
{ B_BASL, 51, 0xFE, 0x0801, 0, 0xCC, baslkwcc, "lightning", 0, 0, 0, "Basic v2.0 with Basic Lightning (C64)" },
- { B_71, 56, 0x39, 0x1c01, 2, 0, NULL, /* fix */ "71", 0, 1, 1, "Basic v7.0 with Basic v7.1 externsion (C128)" },
+ { B_71, 56, 0x39, 0x1c01, 2, 0, NULL, /* fix */ "71", 0, 1, 1, "Basic v7.0 with Basic v7.1 extension (C128)" },
{ B_MAGIC, 50, 0xFD, 0x0801, 0, 0xCC, magickwcc, "magic", 0, 0, 0, "Basic v2.0 with Magic Basic (C64)" },
{ B_EASY, 51, 0xFE, 0x3001, 0, 0xCC, easykwcc, "easy", 0, 0, 0, "Basic v2.0 with Easy Basic (VIC20)" },
{ B_BLARG, 11, 0xEA, 0x0801, 0, 0xE0, blargkwe0, "blarg", 0, 0, 0, "Basic v2.0 with Blarg (C64)" },
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 16:01:37
|
Revision: 45756
http://sourceforge.net/p/vice-emu/code/45756
Author: gpz
Date: 2025-09-05 16:01:31 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
some log stuff
Modified Paths:
--------------
trunk/vice/src/c128/c128rom.c
trunk/vice/src/c64/cart/c64carthooks.c
trunk/vice/src/c64/cart/sfx_soundexpander.c
Modified: trunk/vice/src/c128/c128rom.c
===================================================================
--- trunk/vice/src/c128/c128rom.c 2025-09-05 16:00:22 UTC (rev 45755)
+++ trunk/vice/src/c128/c128rom.c 2025-09-05 16:01:31 UTC (rev 45756)
@@ -752,8 +752,6 @@
int mem_load(void)
{
- const char *rom_name = NULL;
-
if (c128rom_log == LOG_DEFAULT) {
c128rom_log = log_open("C128MEM");
}
Modified: trunk/vice/src/c64/cart/c64carthooks.c
===================================================================
--- trunk/vice/src/c64/cart/c64carthooks.c 2025-09-05 16:00:22 UTC (rev 45755)
+++ trunk/vice/src/c64/cart/c64carthooks.c 2025-09-05 16:01:31 UTC (rev 45756)
@@ -166,7 +166,7 @@
/* #define DEBUGCART */
#ifdef DEBUGCART
-#define DBG(x) printf x
+#define DBG(x) log_printf x
#else
#define DBG(x)
#endif
@@ -1409,7 +1409,7 @@
zippcode48_config_setup(rawcart);
break;
default:
- DBG(("CART: no attach hook %d\n", type));
+ DBG(("CART: no attach hook %d", type));
break;
}
}
@@ -1444,7 +1444,7 @@
while (*list != 0) {
if (*list != type) {
if (cartridge_type_enabled(*list)) {
- DBG(("CART: detach conflicting cart: %d (only one Slot 0 cart can be active)\n", *list));
+ DBG(("CART: detach conflicting cart: %d (only one Slot 0 cart can be active)", *list));
cartridge_detach_image(*list);
}
}
@@ -1458,7 +1458,7 @@
void cart_detach_conflicting(int type)
{
- DBG(("CART: detach conflicting for type: %d ...\n", type));
+ DBG(("CART: detach conflicting for type: %d ...", type));
cart_detach_conflicts0(slot0conflicts, type);
cart_detach_conflicts0(slot1conflicts, type);
}
@@ -1468,7 +1468,7 @@
*/
int cartridge_enable(int type)
{
- DBG(("CART: enable type: %d\n", type));
+ DBG(("CART: enable type: %d", type));
switch (type) {
/* "Slot 0" */
case CARTRIDGE_IEEE488:
@@ -1542,7 +1542,7 @@
#endif
/* "Main Slot" */
default:
- DBG(("CART: no enable hook %d\n", type));
+ DBG(("CART: no enable hook %d", type));
break;
}
cart_detach_conflicting(type);
@@ -1569,7 +1569,7 @@
fprintf(stderr, "%s:%d: %s() isn't implemented yet, continuing\n",
__FILE__, __LINE__, __func__);
*/
- DBG(("CART: enable type: %d\n", type));
+ DBG(("CART: enable type: %d", type));
switch (type) {
/* "Slot 0" */
case CARTRIDGE_IEEE488:
@@ -1643,7 +1643,7 @@
#endif
/* "Main Slot" */
default:
- DBG(("CART: no disable hook %d\n", type));
+ DBG(("CART: no disable hook %d", type));
break;
}
#if 0
@@ -1666,7 +1666,7 @@
*/
void cart_detach_all(void)
{
- DBG(("CART: detach all\n"));
+ DBG(("CART: detach all"));
debugcart_detach();
/* "slot 0" */
tpi_detach();
@@ -1709,7 +1709,7 @@
*/
void cart_detach(int type)
{
- DBG(("CART: cart_detach ID: %d\n", type));
+ DBG(("CART: cart_detach ID: %d", type));
switch (type) {
/* "Slot 0" */
@@ -2027,7 +2027,7 @@
zippcode48_detach();
break;
default:
- DBG(("CART: no detach hook ID: %d\n", type));
+ DBG(("CART: no detach hook ID: %d", type));
break;
}
}
@@ -2035,7 +2035,7 @@
/* called once by cartridge_init at machine init */
void cart_init(void)
{
- DBG(("CART: cart_init\n"));
+ DBG(("CART: cart_init"));
/* "Slot 0" */
mmc64_init();
@@ -2344,7 +2344,7 @@
case CARTRIDGE_NONE:
break;
default:
- DBG(("CART: no init hook ID: %d\n", mem_cartridge_type));
+ DBG(("CART: no init hook ID: %d", mem_cartridge_type));
cart_config_changed_slotmain(CMODE_RAM, CMODE_RAM, CMODE_READ);
break;
}
@@ -2650,7 +2650,7 @@
/* called by cart_nmi_alarm_triggered, after an alarm occured */
static void cart_freeze(int type)
{
- DBG(("CART: freeze (type:%d)\n", type));
+ DBG(("CART: freeze (type:%d)", type));
switch (type) {
/* "Slot 0" (no freezer carts) */
/* "Slot 1" */
@@ -3112,6 +3112,7 @@
void cartridge_sound_chip_init(void)
{
+ DBG(("cartridge_sound_chip_init"));
digimax_sound_chip_init();
sfx_soundsampler_sound_chip_init();
sfx_soundexpander_sound_chip_init();
@@ -3156,7 +3157,7 @@
*/
void cartridge_mmu_translate(unsigned int addr, uint8_t **base, int *start, int *limit)
{
- /* DBG(("CARTHOOKS: cartridge_mmu_translate(%x)\n",addr)); */
+ /* DBG(("CARTHOOKS: cartridge_mmu_translate(%x)",addr)); */
int res = CART_READ_THROUGH;
#if 0
/* disable all the mmu translation stuff for testing */
@@ -3298,7 +3299,7 @@
while (e != NULL) {
if (number_of_carts == C64CART_DUMP_MAX_CARTS) {
- DBG(("CART snapshot save: active carts > max (%i)\n", number_of_carts));
+ DBG(("CART snapshot save: active carts > max (%i)", number_of_carts));
return -1;
}
if (last_cart != (int)e->device->cartid) {
@@ -3894,7 +3895,7 @@
default:
/* If the cart cannot be saved, we obviously can't load it either.
Returning an error at this point is better than failing at later. */
- DBG(("CART snapshot save: cart %i handler missing\n", cart_ids[i]));
+ DBG(("CART snapshot save: cart %i handler missing", cart_ids[i]));
return -1;
}
}
@@ -3946,7 +3947,7 @@
}
if (number_of_carts > C64CART_DUMP_MAX_CARTS) {
- DBG(("CART snapshot read: carts %i > max %i\n", number_of_carts, C64CART_DUMP_MAX_CARTS));
+ DBG(("CART snapshot read: carts %i > max %i", number_of_carts, C64CART_DUMP_MAX_CARTS));
goto fail;
}
@@ -4517,7 +4518,7 @@
#endif
default:
- DBG(("CART snapshot read: cart %i handler missing\n", cart_ids[i]));
+ DBG(("CART snapshot read: cart %i handler missing", cart_ids[i]));
goto fail2;
}
}
Modified: trunk/vice/src/c64/cart/sfx_soundexpander.c
===================================================================
--- trunk/vice/src/c64/cart/sfx_soundexpander.c 2025-09-05 16:00:22 UTC (rev 45755)
+++ trunk/vice/src/c64/cart/sfx_soundexpander.c 2025-09-05 16:01:31 UTC (rev 45756)
@@ -45,6 +45,14 @@
#include "sound.h"
#include "uiapi.h"
+/* #define DEBUG_SFX_SOUNDEXPANDER */
+
+#ifdef DEBUG_SFX_SOUNDEXPANDER
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
/*
Note: this cartridge has a passthrough port, which for some odd reason does
connect all lines 1:1 straight through, EXCEPT for these:
@@ -179,6 +187,7 @@
void sfx_soundexpander_sound_chip_init(void)
{
+ DBG(("sfx_soundexpander_sound_chip_init"));
sfx_soundexpander_sound_chip_offset = sound_chip_register(&sfx_soundexpander_sound_chip);
}
@@ -194,7 +203,8 @@
static int set_sfx_soundexpander_enabled(int value, void *param)
{
int val = value ? 1 : 0;
-
+ DBG(("set_sfx_soundexpander_enabled chip_enabled:%d value:%d",
+ sfx_soundexpander_sound_chip.chip_enabled, value));
if (sfx_soundexpander_sound_chip.chip_enabled != val) {
if (val) {
if (export_add(&export_res_sound) < 0) {
@@ -428,12 +438,13 @@
static int sfx_soundexpander_sound_machine_init(sound_t *psid, int speed, int cycles_per_sec)
{
+ DBG(("sfx_soundexpander_sound_machine_init sfx_soundexpander_chip:%d", sfx_soundexpander_chip));
if (sfx_soundexpander_chip == 3812) {
if (YM3812_chip != NULL) {
ym3812_shutdown(YM3812_chip);
}
YM3812_chip = ym3812_init((UINT32)3579545, (UINT32)speed);
- } else {
+ } else if (sfx_soundexpander_chip == 3526) {
if (YM3526_chip != NULL) {
ym3526_shutdown(YM3526_chip);
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 16:00:25
|
Revision: 45755
http://sourceforge.net/p/vice-emu/code/45755
Author: gpz
Date: 2025-09-05 16:00:22 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
allocate buffer on first use
Modified Paths:
--------------
trunk/vice/src/arch/gtk3/widgets/settings_ramreset.c
Modified: trunk/vice/src/arch/gtk3/widgets/settings_ramreset.c
===================================================================
--- trunk/vice/src/arch/gtk3/widgets/settings_ramreset.c 2025-09-05 15:54:41 UTC (rev 45754)
+++ trunk/vice/src/arch/gtk3/widgets/settings_ramreset.c 2025-09-05 16:00:22 UTC (rev 45755)
@@ -47,6 +47,7 @@
#include "vice_gtk3.h"
#include "ram.h"
#include "resources.h"
+#include "lib.h"
#include "settings_ramreset.h"
@@ -100,7 +101,7 @@
/** \brief Buffer used to print the raw text of the hexdump
*/
-static char printbuffer[PREVIEWTEXTBYTES];
+static char *printbuffer = NULL;
/** \brief Handler for the 'value-changed' event of the widgets in this dialog
@@ -116,6 +117,11 @@
GtkTextIter start;
GtkTextIter end;
+ /* FIXME: right now we allocate the buffer once on first use and never
+ free/release it */
+ if (printbuffer == NULL) {
+ printbuffer = lib_malloc(PREVIEWTEXTBYTES);
+ }
ram_init_print_pattern(printbuffer, PREVIEWPATTERNBYTES, "\n");
buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(data));
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 15:54:44
|
Revision: 45754
http://sourceforge.net/p/vice-emu/code/45754
Author: gpz
Date: 2025-09-05 15:54:41 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
allocate some tables dynamically. there is (much) more room for stuff like this in this file
Modified Paths:
--------------
trunk/vice/src/core/fmopl.c
Modified: trunk/vice/src/core/fmopl.c
===================================================================
--- trunk/vice/src/core/fmopl.c 2025-09-05 15:52:49 UTC (rev 45753)
+++ trunk/vice/src/core/fmopl.c 2025-09-05 15:54:41 UTC (rev 45754)
@@ -325,13 +325,13 @@
* TL_RES_LEN - sinus resolution (X axis)
*/
#define TL_TAB_LEN (12 * 2 * TL_RES_LEN)
-static signed int tl_tab[TL_TAB_LEN];
+static signed int *tl_tab = NULL;
#define ENV_QUIET (TL_TAB_LEN >> 4)
/* sin waveform table in 'decibel' scale */
/* four waveforms on OPL2 type chips */
-static unsigned int sin_tab[SIN_LEN * 4];
+static unsigned int *sin_tab = NULL;
/* LFO Amplitude Modulation table (verified on real YM3812)
27 output levels (triangle waveform); 1 level takes one of: 192, 256 or 448 samples
@@ -950,6 +950,15 @@
signed int n;
double o, m;
+ if (tl_tab == NULL) {
+ tl_tab = lib_malloc(TL_TAB_LEN * sizeof(signed int));
+ }
+
+ if (sin_tab == NULL) {
+ sin_tab = lib_malloc(SIN_LEN * 4 * sizeof(unsigned int));
+ }
+
+
for (x = 0; x < TL_RES_LEN; x++) {
m = (1 << 16) / pow(2, (x + 1) * (ENV_STEP / 4.0) / 8.0);
m = floor(m);
@@ -1031,6 +1040,15 @@
static void OPLCloseTable( void )
{
+ if (tl_tab) {
+ lib_free(tl_tab);
+ tl_tab = NULL;
+ }
+
+ if (sin_tab) {
+ lib_free(sin_tab);
+ sin_tab = NULL;
+ }
}
static void OPL_initalize(FM_OPL *OPL)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 15:52:51
|
Revision: 45753
http://sourceforge.net/p/vice-emu/code/45753
Author: gpz
Date: 2025-09-05 15:52:49 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
allocate commandbuffer dynamically
Modified Paths:
--------------
trunk/vice/src/userport/userport_wic64.c
Modified: trunk/vice/src/userport/userport_wic64.c
===================================================================
--- trunk/vice/src/userport/userport_wic64.c 2025-09-05 11:48:16 UTC (rev 45752)
+++ trunk/vice/src/userport/userport_wic64.c 2025-09-05 15:52:49 UTC (rev 45753)
@@ -512,6 +512,7 @@
static size_t httpbufferptr = 0;
static uint8_t *httpbuffer = NULL;
static char *replybuffer = NULL;
+static uint8_t *commandbuffer = NULL;
#define COMMANDBUFFER_MAXLEN 0x100010
#define URL_MAXLEN 8192
@@ -560,6 +561,10 @@
debug_log(CONS_COL_NO, 2, "%s: encoded_helper allocated 0x%xkB", __FUNCTION__,
COMMANDBUFFER_MAXLEN / 1024);
+ commandbuffer = lib_malloc(COMMANDBUFFER_MAXLEN);
+ debug_log(CONS_COL_NO, 2, "%s: commandbuffer allocated 0x%xkB", __FUNCTION__,
+ COMMANDBUFFER_MAXLEN / 1024);
+
curl_send_buf = lib_malloc(COMMANDBUFFER_MAXLEN);
debug_log(CONS_COL_NO, 2, "%s: curl_send_buf allocated 0x%xkB", __FUNCTION__,
COMMANDBUFFER_MAXLEN / 1014);
@@ -582,6 +587,10 @@
lib_free(encoded_helper);
encoded_helper = NULL;
}
+ if (commandbuffer) {
+ lib_free(commandbuffer);
+ commandbuffer = NULL;
+ }
if (curl_send_buf) {
lib_free(curl_send_buf);
curl_send_buf = NULL;
@@ -1168,7 +1177,6 @@
static uint8_t input_state = 0, input_command = WIC64_CMD_NONE;
static uint8_t wic64_inputmode = 1;
static uint32_t input_length = 0, commandptr = 0;
-static uint8_t commandbuffer[COMMANDBUFFER_MAXLEN];
static uint32_t replyptr = 0, reply_length = 0;
static uint8_t reply_port_value = 0;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 11:48:17
|
Revision: 45752
http://sourceforge.net/p/vice-emu/code/45752
Author: gpz
Date: 2025-09-05 11:48:16 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
allocate buffer for tap file(s) dynamically
Modified Paths:
--------------
trunk/vice/src/datasette/datasette.c
Modified: trunk/vice/src/datasette/datasette.c
===================================================================
--- trunk/vice/src/datasette/datasette.c 2025-09-05 11:46:19 UTC (rev 45751)
+++ trunk/vice/src/datasette/datasette.c 2025-09-05 11:48:16 UTC (rev 45752)
@@ -71,7 +71,7 @@
static tap_t *current_image[TAPEPORT_MAX_PORTS];
/* Buffer for the TAP */
-static uint8_t tap_buffer[TAPEPORT_MAX_PORTS][TAP_BUFFER_LENGTH];
+static uint8_t *tap_buffer[TAPEPORT_MAX_PORTS];
/* Pointer and length of the tap-buffer */
static long next_tap[TAPEPORT_MAX_PORTS], last_tap[TAPEPORT_MAX_PORTS];
@@ -887,6 +887,10 @@
datasette_internal_reset(port);
if (image != NULL) {
+ /* allocate buffer for the image */
+ if (tap_buffer[port] == NULL) {
+ tap_buffer[port] = lib_malloc(TAP_BUFFER_LENGTH);
+ }
/* We need the length of tape for realistic counter. */
current_image[port]->cycle_counter_total = 0;
do {
@@ -904,6 +908,13 @@
fullwave[port] = 0;
ui_set_tape_status(port, current_image[port] ? 1 : 0);
+
+ /* if image was removed, get rid of the buffer */
+ if (image == NULL) {
+ if (tap_buffer[port] != NULL) {
+ lib_free(tap_buffer[port]);
+ }
+ }
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 11:46:21
|
Revision: 45751
http://sourceforge.net/p/vice-emu/code/45751
Author: gpz
Date: 2025-09-05 11:46:19 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
allocate ROM buffer dynamically
Modified Paths:
--------------
trunk/vice/src/c64/cart/magicvoice.c
Modified: trunk/vice/src/c64/cart/magicvoice.c
===================================================================
--- trunk/vice/src/c64/cart/magicvoice.c 2025-09-05 11:32:40 UTC (rev 45750)
+++ trunk/vice/src/c64/cart/magicvoice.c 2025-09-05 11:46:19 UTC (rev 45751)
@@ -129,7 +129,7 @@
static tpi_context_t *tpi_context = NULL; /* context for the TPI chip */
#define MV_ROM_SIZE 0x4000
-static uint8_t mv_rom[MV_ROM_SIZE];
+static uint8_t *mv_rom = NULL;
static int mv_extgame = 0, mv_extexrom = 0;
static int mv_game = 1, mv_exrom = 1;
@@ -1109,8 +1109,15 @@
io_source_unregister(magicvoice_io2_list_item);
magicvoice_io2_list_item = NULL;
magicvoice_sound_chip.chip_enabled = 0;
+ if (mv_rom) {
+ lib_free(mv_rom);
+ mv_rom = NULL;
+ }
DBG(("MV: set_enabled unregistered\n"));
} else if (!magicvoice_sound_chip.chip_enabled && val) {
+ if (mv_rom == NULL) {
+ mv_rom = lib_malloc(MV_ROM_SIZE);
+ }
if (param) {
/* if the param is != NULL, then we should load the default image file */
if ((magicvoice_filename != NULL) && (*magicvoice_filename != 0)) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 11:32:42
|
Revision: 45750
http://sourceforge.net/p/vice-emu/code/45750
Author: gpz
Date: 2025-09-05 11:32:40 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
call missing shutdown function, some log cosmetics
Modified Paths:
--------------
trunk/vice/src/arch/sdl/archdep.c
trunk/vice/src/arch/shared/sounddrv/soundsdl.c
Modified: trunk/vice/src/arch/sdl/archdep.c
===================================================================
--- trunk/vice/src/arch/sdl/archdep.c 2025-09-05 11:19:27 UTC (rev 45749)
+++ trunk/vice/src/arch/sdl/archdep.c 2025-09-05 11:32:40 UTC (rev 45750)
@@ -121,7 +121,6 @@
return archdep_init_extra(argc, argv);
}
-
void archdep_shutdown(void)
{
/* free memory used by the exec path */
@@ -136,6 +135,8 @@
archdep_user_cache_path_free();
/* free memory used by the config files path */
archdep_user_config_path_free();
+ /* free memory used by the state files path */
+ archdep_user_state_path_free();
/* free memory used by the sysfile pathlist */
archdep_default_sysfile_pathlist_free();
Modified: trunk/vice/src/arch/shared/sounddrv/soundsdl.c
===================================================================
--- trunk/vice/src/arch/shared/sounddrv/soundsdl.c 2025-09-05 11:19:27 UTC (rev 45749)
+++ trunk/vice/src/arch/shared/sounddrv/soundsdl.c 2025-09-05 11:32:40 UTC (rev 45750)
@@ -41,6 +41,8 @@
#include "log.h"
#include "sound.h"
+static log_t sdlaudio_log = LOG_DEFAULT;
+
static int16_t *sdl_buf = NULL;
static SDL_AudioSpec sdl_spec;
static volatile int sdl_inptr = 0;
@@ -80,6 +82,19 @@
}
}
+#ifdef USE_SDL2UI
+static void printdrivers(void)
+{
+ int i;
+ char names[256] = { 0 };
+ for (i = 0; i < SDL_GetNumAudioDrivers(); i++) {
+ strcat(names, SDL_GetAudioDriver(i));
+ strcat(names, " ");
+ }
+ log_message(sdlaudio_log, "Available drivers: %s", names);
+}
+#endif
+
static int sdl_init(const char *param, int *speed,
int *fragsize, int *fragnr, int *channels)
{
@@ -86,13 +101,10 @@
SDL_AudioSpec spec;
int nr;
+ sdlaudio_log = log_open("SDLAudio");
+
#ifdef USE_SDL2UI
- int i;
-
- log_message(LOG_DEFAULT, "SDLAudio: list of drivers:");
- for (i = 0; i < SDL_GetNumAudioDrivers(); i++) {
- log_message(LOG_DEFAULT, "SDLAudio: %d: %s", i, SDL_GetAudioDriver(i));
- }
+ printdrivers();
#endif
memset(&spec, 0, sizeof(spec));
@@ -118,7 +130,7 @@
* to get an idea of the whole mess
*/
if (SDL_OpenAudio(&spec, NULL)) {
- log_message(LOG_DEFAULT, "SDLAudio: SDL_OpenAudio() failed: %s",
+ log_message(sdlaudio_log, "SDLAudio: SDL_OpenAudio() failed: %s",
SDL_GetError());
return 1;
}
@@ -131,7 +143,7 @@
* $ SDL_AUDIODRIVER="directsound" x64sc.exe
*/
#ifdef USE_SDL2UI
- log_message(LOG_DEFAULT, "SDLAudio: current driver: %s",
+ log_message(sdlaudio_log, "SDLAudio: current driver: %s",
SDL_GetCurrentAudioDriver());
#endif
@@ -138,10 +150,10 @@
if ((sdl_spec.format != AUDIO_S16 && sdl_spec.format != AUDIO_S16MSB)
|| sdl_spec.channels != *channels) {
SDL_CloseAudio();
- log_message(LOG_DEFAULT, "SDLAudio: got invalid audio spec.");
+ log_warning(sdlaudio_log, "SDLAudio: got invalid audio spec.");
return 1;
}
- log_message(LOG_DEFAULT, "SDLAudio: got proper audio spec.");
+ log_verbose(sdlaudio_log, "SDLAudio: got proper audio spec.");
/* recalculate the number of fragments since the frag size might
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 11:19:28
|
Revision: 45749
http://sourceforge.net/p/vice-emu/code/45749
Author: gpz
Date: 2025-09-05 11:19:27 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
use log system instead of printf, some log cosmetics, add missing SaveResourcesOnExit
Modified Paths:
--------------
trunk/vice/src/arch/headless/ui.c
Modified: trunk/vice/src/arch/headless/ui.c
===================================================================
--- trunk/vice/src/arch/headless/ui.c 2025-09-05 11:17:14 UTC (rev 45748)
+++ trunk/vice/src/arch/headless/ui.c 2025-09-05 11:19:27 UTC (rev 45749)
@@ -139,7 +139,7 @@
*/
void ui_init_with_args(int *argc, char **argv)
{
- printf("Initialising headless ui with args\n");
+ log_verbose(LOG_DEFAULT, "Initialising headless ui with args");
}
@@ -149,7 +149,7 @@
*/
int ui_init(void)
{
- printf("Initialising headless ui\n");
+ log_verbose(LOG_DEFAULT, "Initialising headless ui");
return 0;
}
@@ -165,7 +165,7 @@
*/
int ui_init_finalize(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
return 0;
}
@@ -179,7 +179,7 @@
*/
ui_jam_action_t ui_jam_dialog(const char *format, ...)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
va_list args;
char *buffer;
@@ -190,7 +190,7 @@
buffer = lib_mvsprintf(format, args);
va_end(args);
- printf("%s\n", buffer);
+ log_warning(LOG_DEFAULT, "%s", buffer);
lib_free(buffer);
@@ -198,7 +198,21 @@
return MACHINE_JAM_ACTION_QUIT; /* quit emulator */
}
+static int save_resources_on_exit;
+static int set_save_resources_on_exit(int val, void *param)
+{
+ save_resources_on_exit = val ? 1 : 0;
+
+ return 0;
+}
+
+static resource_int_t resources_int[] = {
+ { "SaveResourcesOnExit", 0, RES_EVENT_NO, NULL,
+ &save_resources_on_exit, set_save_resources_on_exit, NULL },
+ RESOURCE_INT_LIST_END
+};
+
/** \brief Initialize resources related to the UI in general
*
* \return 0 on success, -1 on failure
@@ -205,7 +219,10 @@
*/
int ui_resources_init(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
+ if (resources_register_int(resources_int) < 0) {
+ return -1;
+ }
return 0;
}
@@ -215,7 +232,7 @@
*/
void ui_resources_shutdown(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
}
/** \brief Clean up memory used by the UI system itself
@@ -222,7 +239,7 @@
*/
void ui_shutdown(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
}
@@ -230,7 +247,7 @@
*/
void ui_dispatch_events(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
}
/** \brief Display the "Do you want to extend the disk image to
@@ -243,7 +260,7 @@
*/
int ui_extend_image_dialog(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
/* FIXME: this dialog needs to be implemented. */
NOT_IMPLEMENTED();
@@ -257,7 +274,7 @@
*/
void ui_error(const char *format, ...)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
char *buffer;
va_list ap;
@@ -266,7 +283,7 @@
buffer = lib_mvsprintf(format, ap);
va_end(ap);
- printf("VICE Error: %s\n", buffer);
+ log_error(LOG_DEFAULT, "VICE Error: %s", buffer);
lib_free(buffer);
}
@@ -277,7 +294,7 @@
*/
void ui_message(const char *format, ...)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
char *buffer;
va_list ap;
@@ -286,7 +303,7 @@
buffer = lib_mvsprintf(format, ap);
va_end(ap);
- printf("VICE Message: %s", buffer);
+ log_message(LOG_DEFAULT, "VICE Message: %s", buffer);
lib_free(buffer);
}
@@ -293,7 +310,7 @@
bool ui_pause_loop_iteration(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
/*
ui_dispatch_next_event();
g_usleep(10000);
@@ -309,7 +326,7 @@
*/
static void pause_trap(uint16_t addr, void *data)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
/*
vsync_suspend_speed_eval();
sound_suspend();
@@ -325,7 +342,7 @@
*/
int ui_pause_active(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
return is_paused;
}
@@ -335,7 +352,7 @@
*/
void ui_pause_enable(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
if (!ui_pause_active()) {
is_paused = 1;
@@ -348,7 +365,7 @@
*/
void ui_pause_disable(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
if (ui_pause_active()) {
is_paused = 0;
@@ -360,7 +377,7 @@
*/
void ui_update_lightpen(void)
{
- /* printf("%s\n", __func__); */
+ /* log_verbose(LOG_DEFAULT, "%s", __func__); */
}
void arch_ui_activate(void)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-05 11:17:16
|
Revision: 45748
http://sourceforge.net/p/vice-emu/code/45748
Author: gpz
Date: 2025-09-05 11:17:14 +0000 (Fri, 05 Sep 2025)
Log Message:
-----------
skip some keymap related init when using headless ui, removes a bunch of (pointless) error messages from the log
Modified Paths:
--------------
trunk/vice/src/keymap.c
Modified: trunk/vice/src/keymap.c
===================================================================
--- trunk/vice/src/keymap.c 2025-09-01 19:17:11 UTC (rev 45747)
+++ trunk/vice/src/keymap.c 2025-09-05 11:17:14 UTC (rev 45748)
@@ -31,7 +31,6 @@
*/
/* #define DBGKBD */
-/* #define DBGKBD_MODIFIERS */
#include "vice.h"
@@ -65,17 +64,11 @@
#include "vice-event.h"
#ifdef DBGKBD
-#define DBG(x) printf x
+#define DBG(x) log_printf x
#else
#define DBG(x)
#endif
-#ifdef DBGKBD_MODIFIERS
-#define DBGMOD(x) printf x
-#else
-#define DBGMOD(x)
-#endif
-
static log_t keyboard_log = LOG_DEFAULT;
keyboard_conv_t *keyconvmap = NULL; /* FIXME: getter */
@@ -705,7 +698,7 @@
char buffer[1024];
int line = 0;
- DBG((">keyboard_parse_keymap(%s)\n", filename));
+ DBG((">keyboard_parse_keymap(%s)", filename));
/* open in binary mode so the newline system doesn't matter */
fp = sysfile_open(filename, machine_name, &complete_path, "rb");
@@ -712,7 +705,7 @@
if (fp == NULL) {
log_message(keyboard_log, "Error loading keymap `%s'->`%s'.", filename, complete_path ? complete_path : "<empty/null>");
- DBG(("<keyboard_parse_keymap(%s) ERROR\n", filename));
+ DBG(("<keyboard_parse_keymap(%s) ERROR", filename));
return -1;
}
@@ -761,15 +754,15 @@
check_modifiers(filename);
- DBG(("<keyboard_parse_keymap OK\n"));
+ DBG(("<keyboard_parse_keymap OK"));
return 0;
}
static int keyboard_keymap_load(const char *filename)
{
- DBG((">keyboard_keymap_load(%s)\n", filename));
+ DBG((">keyboard_keymap_load(%s)", filename));
if (filename == NULL) {
- DBG(("<keyboard_keymap_load ERROR\n"));
+ DBG(("<keyboard_keymap_load ERROR"));
return -1;
}
@@ -779,7 +772,7 @@
keyboard_keyconvmap_alloc();
- DBG(("<keyboard_keymap_load -> keyboard_parse_keymap\n"));
+ DBG(("<keyboard_keymap_load -> keyboard_parse_keymap"));
return keyboard_parse_keymap(filename, 0);
}
@@ -1063,7 +1056,7 @@
return -1;
}
- DBG(("load_keymap_file(%d) calls keyboard_keymap_load(%s)\n", val, name));
+ DBG(("load_keymap_file(%d) calls keyboard_keymap_load(%s)", val, name));
if (keyboard_keymap_load(name) >= 0) {
} else {
@@ -1083,7 +1076,7 @@
newindex = vice_ptr_to_int(param);
- DBG(("keyboard_set_keymap_file '%s' newidx:%d\n", val, newindex));
+ DBG(("keyboard_set_keymap_file '%s' newidx:%d", val, newindex));
/* FIXME: remove */
if (newindex >= machine_num_keyboard_mappings()) {
@@ -1113,7 +1106,7 @@
int mapping;
int type;
- DBG(("*keyboard_set_keymap_index(%d)\n", val));
+ DBG(("*keyboard_set_keymap_index(%d)", val));
if ((val < 0) || (val > KBD_INDEX_LAST)) {
return -1;
@@ -1122,11 +1115,11 @@
mapping = machine_keyboard_mapping;
type = machine_keyboard_type;
- DBG((">keyboard_set_keymap_index(idx:%d mapping:%d type:%d)\n", val, mapping, type));
+ DBG((">keyboard_set_keymap_index(idx:%d mapping:%d type:%d)", val, mapping, type));
if (val < 2) {
if (switch_keymap_file(KBD_SWITCH_INDEX, &val, &mapping, &type) < 0) {
- DBG(("<keyboard_set_keymap_index switch_keymap_file ERROR\n"));
+ DBG(("<keyboard_set_keymap_index switch_keymap_file ERROR"));
log_error(keyboard_log, "Default keymap not found, this should be fixed. Going on anyway...");
/* return -1; */
return 0; /* HACK: allow to start up when default keymap is missing */
@@ -1136,15 +1129,16 @@
}
if (load_keymap_file(val) < 0) {
- DBG(("<keyboard_set_keymap_index load_keymap_file ERROR\n"));
+ DBG(("<keyboard_set_keymap_index load_keymap_file ERROR"));
return -1;
}
- DBG(("<keyboard_set_keymap_index OK (idx:%d mapping:%d type:%d)\n", val, mapping, type));
+ DBG(("<keyboard_set_keymap_index OK (idx:%d mapping:%d type:%d)", val, mapping, type));
machine_keymap_index = val;
return 0;
}
+#ifndef USE_HEADLESSUI
/* handle change of "KeyboardType" */
static int keyboard_set_keyboard_type(int val, void *param)
{
@@ -1153,7 +1147,7 @@
mapping = machine_keyboard_mapping;
idx = machine_keymap_index;
- DBG((">keyboard_set_keyboard_type(idx:%d mapping:%d type:%d)\n", idx, mapping, val));
+ DBG((">keyboard_set_keyboard_type(idx:%d mapping:%d type:%d)", idx, mapping, val));
if (idx < 2) {
if (switch_keymap_file(KBD_SWITCH_TYPE, &idx, &mapping, &val) < 0) {
log_error(keyboard_log, "Default keymap not found, this should be fixed. Going on anyway...");
@@ -1165,15 +1159,17 @@
}
if (load_keymap_file(idx) < 0) {
- DBG(("<keyboard_set_keyboard_type load_keymap_file ERROR\n"));
+ DBG(("<keyboard_set_keyboard_type load_keymap_file ERROR"));
return -1;
}
machine_keyboard_type = val;
- DBG(("<keyboard_set_keyboard_type(%d)\n", val));
+ DBG(("<keyboard_set_keyboard_type(%d)", val));
return 0;
}
+#endif
+#ifndef USE_HEADLESSUI
/* handle change if "KeyboardMapping" */
static int keyboard_set_keyboard_mapping(int val, void *param)
{
@@ -1183,7 +1179,7 @@
type = machine_keyboard_type;
idx = machine_keymap_index;
- DBG((">keyboard_set_keyboard_mapping(%d,%d,%d)\n", idx, type, val));
+ DBG((">keyboard_set_keyboard_mapping(%d,%d,%d)", idx, type, val));
if (idx < 2) {
if (switch_keymap_file(KBD_SWITCH_MAPPING, &idx, &val, &type) < 0) {
@@ -1196,15 +1192,16 @@
}
if (load_keymap_file(idx) < 0) {
- DBG(("<keyboard_set_keyboard_mapping load_keymap_file ERROR\n"));
+ DBG(("<keyboard_set_keyboard_mapping load_keymap_file ERROR"));
return -1;
}
machine_keyboard_mapping = val;
- DBG(("<keyboard_set_keyboard_mapping(%d,%d,%d)\n", idx, type, val));
+ DBG(("<keyboard_set_keyboard_mapping(%d,%d,%d)", idx, type, val));
return 0;
}
+#endif
/* return number of available keyboard maps for gives "type" and "index" (sym/pos) */
int keyboard_get_num_mappings(void)
@@ -1255,7 +1252,7 @@
const char *mapname;
char *name = NULL, *tstr = NULL;
- DBG((">keyboard_get_keymap_name idx %d mapping %d type %d\n", idx, mapping, type));
+ DBG((">keyboard_get_keymap_name idx %d mapping %d type %d", idx, mapping, type));
if (type >= 0) {
tstr = machine_get_keyboard_type_name(type);
}
@@ -1272,7 +1269,7 @@
name = util_concat(KBD_PORT_PREFIX, "_", tstr, "_", sympos[idx], "_", mapname, ".vkm", NULL);
}
- DBG(("keyboard_get_keymap_name: (port:%s type:%s idx:%d mapping:%d) '%s' = '%s'\n",
+ DBG(("keyboard_get_keymap_name: (port:%s type:%s idx:%d mapping:%d) '%s' = '%s'",
KBD_PORT_PREFIX, tstr ? tstr : "-", idx, mapping,
idx ? "KeymapPosFile" : "KeymapSymFile", name));
@@ -1335,9 +1332,9 @@
name = keyboard_get_keymap_name(idx, mapping, type);
util_string_set(&machine_keymap_file_list[atidx], name);
- DBG(("try_set_keymap_file calls sysfile_locate(%s)\n", name));
+ DBG(("try_set_keymap_file calls sysfile_locate(%s)", name));
if (sysfile_locate(name, machine_name, &complete_path) != 0) {
- DBG(("<try_set_keymap_file ERROR locating keymap `%s'.\n", name ? name : "(null)"));
+ DBG(("<try_set_keymap_file ERROR locating keymap `%s'.", name ? name : "(null)"));
lib_free(name);
lib_free(complete_path);
return -1;
@@ -1344,7 +1341,7 @@
}
lib_free(name);
lib_free(complete_path);
- DBG(("<try_set_keymap_file OK\n"));
+ DBG(("<try_set_keymap_file OK"));
return 0;
}
@@ -1355,7 +1352,8 @@
int idx = *idxp;
int atidx = *idxp;
- DBG((">switch_keymap_file idx %d mapping %d type %d\n", *idxp, *mapp, *typep));
+ DBG((">switch_keymap_file idx %d mapping %d type %d", *idxp, *mapp, *typep));
+
if(try_set_keymap_file(atidx, idx, mapping, type) >= 0) {
goto ok;
}
@@ -1394,11 +1392,11 @@
type = 0; /* FIXME */
goto ok;
}
- DBG(("<switch_keymap_file ERROR idx %d mapping %d type %d\n", idx, mapping, type));
+ DBG(("<switch_keymap_file ERROR idx %d mapping %d type %d", idx, mapping, type));
return -1;
ok:
- DBG(("<switch_keymap_file OK idx %d mapping %d type %d\n", idx, mapping, type));
+ DBG(("<switch_keymap_file OK idx %d mapping %d type %d", idx, mapping, type));
*idxp = idx;
*mapp = mapping;
*typep = type;
@@ -1405,6 +1403,7 @@
return 0;
}
+#ifndef USE_HEADLESSUI
/* called by keyboard_resources_init to create the default keymap(s)
idx is the index to the resource for the setting ("KeymapIndex")
*/
@@ -1413,7 +1412,7 @@
int mapping = 0;
int type = 0;
- DBG((">keyboard_set_default_keymap_file(%d)\n", idx));
+ DBG((">keyboard_set_default_keymap_file(%d)", idx));
if ((idx != KBD_INDEX_SYM) && (idx != KBD_INDEX_POS)) {
/* it's a user keymap, do not set a default */
@@ -1430,7 +1429,7 @@
if(switch_keymap_file(KBD_SWITCH_DEFAULT, &idx, &mapping, &type) < 0) {
/* return -1; */
- DBG(("<keyboard_set_default_keymap_file(FAILURE: idx: %d type: %d mapping: %d)\n", idx, type, mapping));
+ DBG(("<keyboard_set_default_keymap_file(FAILURE: idx: %d type: %d mapping: %d)", idx, type, mapping));
return 0; /* always return success to allow starting up without valid keymap */
}
@@ -1438,9 +1437,10 @@
machine_keyboard_type = type;
machine_keyboard_mapping = mapping;
- DBG(("<keyboard_set_default_keymap_file(OK: idx: %d type: %d mapping: %d)\n", idx, type, mapping));
+ DBG(("<keyboard_set_default_keymap_file(OK: idx: %d type: %d mapping: %d)", idx, type, mapping));
return 0; /* success */
}
+#endif
/*--------------------------------------------------------------------------*/
@@ -1449,6 +1449,7 @@
static char *resources_string_d2 = NULL;
static char *resources_string_d3 = NULL;
+#ifndef USE_HEADLESSUI
static const resource_string_t resources_string[] = {
{ "KeymapSymFile", "", RES_EVENT_NO, NULL,
&machine_keymap_file_list[KBD_INDEX_SYM],
@@ -1476,11 +1477,16 @@
&machine_keyboard_type, keyboard_set_keyboard_type, NULL },
RESOURCE_INT_LIST_END
};
+#endif
/*--------------------------------------------------------------------------*/
int keymap_resources_init(void)
{
+#ifdef USE_HEADLESSUI
+ /* headless has no keyboard, no point in further initializing anything */
+ return 0;
+#else
int nsym, npos, mapping, idx, type;
const char *name;
@@ -1502,7 +1508,7 @@
npos = (machine_keymap_file_list[KBD_INDEX_POS] == NULL) || (machine_keymap_file_list[KBD_INDEX_POS][0] == 0);
nsym = (machine_keymap_file_list[KBD_INDEX_SYM] == NULL) || (machine_keymap_file_list[KBD_INDEX_SYM][0] == 0);
- DBG((">>keyboard_resources_init(first start:%s)\n", (npos && nsym) ? "yes" : "no"));
+ DBG((">>keyboard_resources_init(first start:%s)", (npos && nsym) ? "yes" : "no"));
if (npos && nsym) {
mapping = archdep_kbd_get_host_mapping();
@@ -1518,7 +1524,7 @@
keyboard_set_default_keymap_file(KBD_INDEX_POS);
if (resources_get_string("KeymapPosFile", &name) < 0) {
- DBG(("<<keyboard_resources_init(error)\n"));
+ DBG(("<<keyboard_resources_init(error)"));
return -1;
}
util_string_set(&resources_string_d1, name);
@@ -1527,7 +1533,7 @@
log_verbose(keyboard_log, "Default positional map is: %s", name);
keyboard_set_default_keymap_file(KBD_INDEX_SYM);
if (resources_get_string("KeymapSymFile", &name) < 0) {
- DBG(("<<keyboard_resources_init(error)\n"));
+ DBG(("<<keyboard_resources_init(error)"));
return -1;
}
log_verbose(keyboard_log, "Default symbolic map is: %s", name);
@@ -1543,15 +1549,15 @@
idx = type = mapping = 0;
if (resources_get_int("KeymapIndex", &idx) < 0) {
- DBG(("<<keyboard_resources_init(error)\n"));
+ DBG(("<<keyboard_resources_init(error)"));
return -1;
}
if (resources_get_int("KeyboardType", &type) < 0) {
- DBG(("<<keyboard_resources_init(error)\n"));
+ DBG(("<<keyboard_resources_init(error)"));
return -1;
}
if (resources_get_int("KeyboardMapping", &mapping) < 0) {
- DBG(("<<keyboard_resources_init(error)\n"));
+ DBG(("<<keyboard_resources_init(error)"));
return -1;
}
resources_set_default_int("KeymapIndex", idx);
@@ -1558,8 +1564,9 @@
resources_set_default_int("KeyboardType", type);
resources_set_default_int("KeyboardMapping", mapping);
}
- DBG(("<<keyboard_resources_init(ok)\n"));
+ DBG(("<<keyboard_resources_init(ok)"));
return 0;
+#endif
}
static void keyboard_resources_shutdown(void)
@@ -1580,6 +1587,7 @@
/*--------------------------------------------------------------------------*/
+#ifndef USE_HEADLESSUI
static cmdline_option_t const cmdline_options[] =
{
{ "-keymap", SET_RESOURCE, CMDLINE_ATTRIB_NEED_ARGS,
@@ -1601,12 +1609,15 @@
"<Name>", "Specify name of positional keymap file" },
CMDLINE_LIST_END
};
+#endif
int keymap_cmdline_options_init(void)
{
+#ifndef USE_HEADLESSUI
if (machine_class != VICE_MACHINE_VSID) {
return cmdline_register_options(cmdline_options);
}
+#endif
return 0;
}
@@ -1614,10 +1625,12 @@
void keymap_init(void)
{
+#ifndef USE_HEADLESSUI
if (machine_class != VICE_MACHINE_VSID) {
load_keymap_ok = 1;
keyboard_set_keymap_index(machine_keymap_index, NULL);
}
+#endif
}
void keymap_shutdown(void)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-01 19:17:16
|
Revision: 45747
http://sourceforge.net/p/vice-emu/code/45747
Author: gpz
Date: 2025-09-01 19:17:11 +0000 (Mon, 01 Sep 2025)
Log Message:
-----------
Some log cosmetics, make things a bit less verbose by default
Modified Paths:
--------------
trunk/vice/src/arch/gtk3/directx_renderer_impl.cc
trunk/vice/src/arch/gtk3/joystickdrv/joystick_linux_evdev.c
trunk/vice/src/arch/gtk3/opengl_renderer.c
trunk/vice/src/arch/gtk3/opengl_renderer_unix.c
trunk/vice/src/arch/gtk3/render_thread.c
trunk/vice/src/arch/gtk3/uimachinewindow.c
trunk/vice/src/arch/shared/archdep_cbmfont.c
trunk/vice/src/arch/shared/hotkeys/uihotkeys.c
trunk/vice/src/arch/shared/hwsiddrv/ps-ieee1284.c
trunk/vice/src/arch/shared/hwsiddrv/ps-unix-file.c
trunk/vice/src/arch/shared/mididrv/midi-unix-drv.c
trunk/vice/src/c64/c64.c
trunk/vice/src/drive/drive.c
trunk/vice/src/log.c
trunk/vice/src/log.h
trunk/vice/src/machine.c
trunk/vice/src/main.c
trunk/vice/src/mainlock.c
trunk/vice/src/resources.c
trunk/vice/src/sound.c
trunk/vice/src/sysfile.c
trunk/vice/src/viciisc/vicii-resources.c
Modified: trunk/vice/src/arch/gtk3/directx_renderer_impl.cc
===================================================================
--- trunk/vice/src/arch/gtk3/directx_renderer_impl.cc 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/gtk3/directx_renderer_impl.cc 2025-09-01 19:17:11 UTC (rev 45747)
@@ -514,13 +514,13 @@
/* Make sure the render thread wakes up and does its thing asap. */
SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_TIME_CRITICAL);
- log_message(LOG_DEFAULT, "Render thread initialised");
+ log_verbose(LOG_DEFAULT, "Render thread initialised");
return;
}
if (job == render_thread_shutdown) {
archdep_thread_shutdown();
- log_message(LOG_DEFAULT, "Render thread shutdown");
+ log_verbose(LOG_DEFAULT, "Render thread shutdown");
return;
}
Modified: trunk/vice/src/arch/gtk3/joystickdrv/joystick_linux_evdev.c
===================================================================
--- trunk/vice/src/arch/gtk3/joystickdrv/joystick_linux_evdev.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/gtk3/joystickdrv/joystick_linux_evdev.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -448,5 +448,5 @@
*/
void joystick_arch_shutdown(void)
{
- printf("%s(): called\n", __func__);
+ /* printf("%s(): called\n", __func__); */
}
Modified: trunk/vice/src/arch/gtk3/opengl_renderer.c
===================================================================
--- trunk/vice/src/arch/gtk3/opengl_renderer.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/gtk3/opengl_renderer.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -709,13 +709,13 @@
/* TODO: BSD thread prio stuff */
#endif
- log_message(opengl_log, "Render thread initialised");
+ log_verbose(opengl_log, "Render thread initialised");
return;
}
if (job == render_thread_shutdown) {
archdep_thread_shutdown();
- log_message(opengl_log, "Render thread shutdown");
+ log_verbose(opengl_log, "Render thread shutdown");
return;
}
Modified: trunk/vice/src/arch/gtk3/opengl_renderer_unix.c
===================================================================
--- trunk/vice/src/arch/gtk3/opengl_renderer_unix.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/gtk3/opengl_renderer_unix.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -115,7 +115,7 @@
archdep_vice_exit(1);
}
- log_message(opengl_log, "GLX version: %d.%d", glx_major, glx_minor);
+ log_verbose(opengl_log, "GLX version: %d.%d", glx_major, glx_minor);
/* FBConfigs were added in GLX version 1.3. */
if (glx_major < 1 || (glx_major == 1 && glx_minor < 3)) {
@@ -123,7 +123,7 @@
archdep_vice_exit(1);
}
- log_message(opengl_log, "Getting matching framebuffer configs" );
+ log_verbose(opengl_log, "Getting matching framebuffer configs" );
PFNGLXCHOOSEFBCONFIGPROC vice_glXChooseFBConfig = (PFNGLXCHOOSEFBCONFIGPROC)glXGetProcAddressARB((const GLubyte *)"glXChooseFBConfig");
GLXFBConfig *framebuffer_configs = vice_glXChooseFBConfig(context->x_display, DefaultScreen(context->x_display), visual_attribs, &fbcount);
@@ -131,7 +131,7 @@
log_error(opengl_log, "Failed to retrieve a framebuffer config\n");
archdep_vice_exit(1);
}
- log_message(opengl_log, "Found %d matching FB configs.", fbcount);
+ log_verbose(opengl_log, "Found %d matching FB configs.", fbcount);
/* Just pick the first one I guess. */
GLXFBConfig framebuffer_config = framebuffer_configs[0];
@@ -230,7 +230,16 @@
/* Anything less than OpenGL 3.2 will use the legacy renderer */
context->gl_context_is_legacy = major < 3 || (major == 3 && minor < 2);
- log_message(opengl_log, "Obtained OpenGL %d.%d context\n Vendor: %s\n Renderer: %s\n Version: %s\n Legacy: %s",
+ if (log_get_limit() <= LOG_LIMIT_STANDARD) {
+ log_message(opengl_log, "Obtained OpenGL %d.%d context %s %s",
+ major,
+ minor,
+ context->gl_context_is_legacy ? "Legacy" : "",
+ glXIsDirect(context->x_display, context->gl_context) ? "" : "GLX indirect"
+ );
+ }
+
+ log_verbose(opengl_log, "Obtained OpenGL %d.%d context\n Vendor: %s\n Renderer: %s\n Version: %s\n Legacy: %s",
major,
minor,
glGetString(GL_VENDOR),
@@ -240,12 +249,12 @@
/* Not sure if an indirect context will work but lets leave some useful output for bug reports */
if (!glXIsDirect(context->x_display, context->gl_context)) {
- log_message(opengl_log, "Indirect GLX rendering context obtained - please let us know if this works!");
+ log_warning(opengl_log, "Indirect GLX rendering context obtained - please let us know if this works!");
} else {
- log_message(opengl_log, "Direct GLX rendering context obtained");
+ log_verbose(opengl_log, "Direct GLX rendering context obtained");
}
- log_message(opengl_log, "Swap control support. glXSwapIntervalMESA: %d glXSwapIntervalEXT: %d glXSwapIntervalSGI: %d", !!glXSwapIntervalMESA, !!glXSwapIntervalEXT, !!glXSwapIntervalSGI);
+ log_verbose(opengl_log, "Swap control support. glXSwapIntervalMESA: %d glXSwapIntervalEXT: %d glXSwapIntervalSGI: %d", !!glXSwapIntervalMESA, !!glXSwapIntervalEXT, !!glXSwapIntervalSGI);
vice_opengl_renderer_clear_current(context);
}
Modified: trunk/vice/src/arch/gtk3/render_thread.c
===================================================================
--- trunk/vice/src/arch/gtk3/render_thread.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/gtk3/render_thread.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -81,7 +81,7 @@
UNLOCK();
- log_message(render_log, "Created render thread %d", thread->index);
+ log_verbose(render_log, "Created render thread %d", thread->index);
return thread;
}
@@ -95,7 +95,7 @@
return;
}
- log_message(render_log, "Initiating render thread %d shutdown", thread->index);
+ log_verbose(render_log, "Initiating render thread %d shutdown", thread->index);
thread->is_shutdown_initiated = true;
/* Schedule the shutdown job */
@@ -106,7 +106,7 @@
void render_thread_join(render_thread_t thread)
{
- log_message(render_log, "Joining render thread %d ...", thread->index);
+ log_verbose(render_log, "Joining render thread %d ...", thread->index);
/* TODO: We should block until all jobs are done - but there's a race condition deadlock outcome here. Fix needed */
g_thread_pool_free(thread->executor, TRUE, TRUE);
@@ -115,7 +115,7 @@
thread->is_shut_down = true;
UNLOCK();
- log_message(render_log, "Joined render thread %d.", thread->index);
+ log_verbose(render_log, "Joined render thread %d.", thread->index);
}
void render_thread_shutdown_and_join_all(void)
Modified: trunk/vice/src/arch/gtk3/uimachinewindow.c
===================================================================
--- trunk/vice/src/arch/gtk3/uimachinewindow.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/gtk3/uimachinewindow.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -686,7 +686,8 @@
backend_label = "OpenGL";
#endif
- log_message(machine_window_log, "using GTK3 backend: %s", backend_label);
+ log_message(machine_window_log, "Chip '%s' using GTK3 backend '%s'.",
+ canvas->videoconfig->chip_name , backend_label);
new_event_box = gtk_event_box_new();
@@ -734,20 +735,20 @@
tricks and assumptions. the following also shows shortcomings / problems in other parts of the code.
*/
#if 1
- log_message(machine_window_log, "chip_name: %s", canvas->videoconfig->chip_name);
- log_message(machine_window_log, " screen_size: %u x %u", canvas->geometry->screen_size.width, canvas->geometry->screen_size.height);
- /*log_message(machine_window_log, " first/lastline: %u x %u", canvas->viewport->first_line, canvas->viewport->last_line);*/
- log_message(machine_window_log, " gfx_size: %u x %u", canvas->geometry->gfx_size.width, canvas->geometry->gfx_size.height);
- log_message(machine_window_log, " gfx_position: %u x %u", canvas->geometry->gfx_position.x, canvas->geometry->gfx_position.y);
- log_message(machine_window_log, " first/last displayed line: %u x %u", canvas->geometry->first_displayed_line, canvas->geometry->last_displayed_line);
- log_message(machine_window_log, " extra offscreen border left/right: %u x %u", canvas->geometry->extra_offscreen_border_left, canvas->geometry->extra_offscreen_border_right);
- /*log_message(machine_window_log, " screen_display_wh: %f x %f", (float)canvas->screen_display_w, (float)canvas->screen_display_h);*/
- /*log_message(machine_window_log, " canvas_physical_wh: %u x %u", canvas->draw_buffer->canvas_physical_width, canvas->draw_buffer->canvas_physical_width);*/
- log_message(machine_window_log, " scalexy: %d x %d sizexy: %u x %u",
+ /*log_verbose(machine_window_log, "chip_name: %s", canvas->videoconfig->chip_name);*/
+ log_verbose(machine_window_log, " screen_size: %u x %u", canvas->geometry->screen_size.width, canvas->geometry->screen_size.height);
+ /*log_verbose(machine_window_log, " first/lastline: %u x %u", canvas->viewport->first_line, canvas->viewport->last_line);*/
+ log_verbose(machine_window_log, " gfx_size: %u x %u", canvas->geometry->gfx_size.width, canvas->geometry->gfx_size.height);
+ log_verbose(machine_window_log, " gfx_position: %u x %u", canvas->geometry->gfx_position.x, canvas->geometry->gfx_position.y);
+ log_verbose(machine_window_log, " first/last displayed line: %u x %u", canvas->geometry->first_displayed_line, canvas->geometry->last_displayed_line);
+ log_verbose(machine_window_log, " extra offscreen border left/right: %u x %u", canvas->geometry->extra_offscreen_border_left, canvas->geometry->extra_offscreen_border_right);
+ /*log_verbose(machine_window_log, " screen_display_wh: %f x %f", (float)canvas->screen_display_w, (float)canvas->screen_display_h);*/
+ /*log_verbose(machine_window_log, " canvas_physical_wh: %u x %u", canvas->draw_buffer->canvas_physical_width, canvas->draw_buffer->canvas_physical_width);*/
+ log_verbose(machine_window_log, " scalexy: %d x %d sizexy: %u x %u",
canvas->videoconfig->scalex, canvas->videoconfig->scaley,
canvas->videoconfig->cap->single_mode.sizex, canvas->videoconfig->cap->single_mode.sizey);
- log_message(machine_window_log, " rmode: %u", canvas->videoconfig->cap->single_mode.rmode);
- log_message(machine_window_log, " aspect ratio: %f", (float)canvas->geometry->pixel_aspect_ratio);
+ log_verbose(machine_window_log, " rmode: %u", canvas->videoconfig->cap->single_mode.rmode);
+ log_verbose(machine_window_log, " aspect ratio: %f", (float)canvas->geometry->pixel_aspect_ratio);
#endif
/* find out if we have a videochip that uses vertical stretching. since the resources are not
initialized, assume it always is stretched (this is the default) */
@@ -762,7 +763,7 @@
/* vstretch = 1; */ /* HACK: for some reason that doesn't give the wanted result */
}
#if 1
- log_message(machine_window_log, " hstretch: %u vstretch: %u", hstretch, vstretch);
+ log_verbose(machine_window_log, " hstretch: %u vstretch: %u", hstretch, vstretch);
#endif
/* calculate the initial size from the values we have
WARNING: terrible hacks coming up
@@ -780,7 +781,7 @@
h = (unsigned)(((double)h) * canvas->geometry->pixel_aspect_ratio);
}
#if 1
- log_message(machine_window_log, " initializing with width, height: %u x %u", w, h);
+ log_verbose(machine_window_log, " initializing with width, height: %u x %u", w, h);
#endif
/* finally set the size. use -1 for width and height to compensate for single pixel errors. this
will be corrected by the resize that will happen at the end of initialization */
Modified: trunk/vice/src/arch/shared/archdep_cbmfont.c
===================================================================
--- trunk/vice/src/arch/shared/archdep_cbmfont.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/shared/archdep_cbmfont.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -39,6 +39,8 @@
#ifdef USE_GTK3UI
+static log_t archdep_font_log = LOG_DEFAULT;
+
/** \brief Filename of the TrueType CBM font used for directory display
*/
/* #define VICE_CBM_FONT_TTF "C64_Pro_Mono-STYLE.ttf" */
@@ -79,7 +81,7 @@
for (i = 0; i < sizeof font_files / sizeof font_files[0]; i++) {
if (sysfile_locate(font_files[i], "common", &fontPath) < 0) {
- log_error(LOG_DEFAULT, "failed to find resource data '%s'.",
+ log_error(archdep_font_log, "failed to find resource data '%s'.",
font_files[i]);
return 0;
}
@@ -92,7 +94,7 @@
if(!CTFontManagerRegisterFontsForURLs(fontUrls, kCTFontManagerScopeProcess, &errors))
{
- log_error(LOG_DEFAULT, "Failed to register font for file: %s", fontPath);
+ log_error(archdep_font_log, "Failed to register font for file: %s", fontPath);
CFRelease(fontUrls);
CFRelease(fontUrl);
lib_free(fontPath);
@@ -123,11 +125,15 @@
return 0;
}
+ if (archdep_font_log == LOG_DEFAULT) {
+ archdep_font_log = log_open("Font");
+ }
+
fc_config = FcConfigGetCurrent();
for (i = 0; i < sizeof font_files / sizeof font_files[0]; i++) {
if (sysfile_locate(font_files[i], "common", &path) < 0) {
- log_error(LOG_DEFAULT,
+ log_error(archdep_font_log,
"failed to find resource data '%s'.",
font_files[i]);
return 0;
@@ -136,7 +142,7 @@
lib_free(path);
return 0;
} else {
- log_message(LOG_DEFAULT, "registered font '%s'.", path);
+ log_message(archdep_font_log, "registered '%s'.", path);
lib_free(path);
}
}
@@ -148,7 +154,7 @@
int archdep_register_cbmfont(void)
{
- log_error(LOG_DEFAULT, "no fontconfig support, sorry.");
+ log_error(archdep_font_log, "no fontconfig support, sorry.");
return 0;
}
@@ -186,7 +192,7 @@
size_t i;
int nfonts = 0;
- log_message(LOG_DEFAULT,
+ log_message(archdep_font_log,
"%s(): Registering CBM fonts using Pango %s",
__func__, pango_version_string());
@@ -194,7 +200,7 @@
char *path = NULL;
if (sysfile_locate(font_files[i], "common", &path) < 0) {
- log_warning(LOG_DEFAULT,
+ log_warning(archdep_font_log,
"failed to find resource data '%s', continuing...",
font_files[i]);
} else {
@@ -202,18 +208,18 @@
if (result > 0) {
font_registered = true;
- log_message(LOG_DEFAULT,
+ log_message(archdep_font_log,
"succesfully registered %d font(s) from %s.",
result, path);
lib_free(path);
nfonts += result;
} else {
- log_warning(LOG_DEFAULT, "no fonts found in %s.", path);
+ log_warning(archdep_font_log, "no fonts found in %s.", path);
}
}
}
- log_message(LOG_DEFAULT, "registered %d font(s) total.", nfonts);
+ log_message(archdep_font_log, "registered %d font(s) total.", nfonts);
#if 0
/* Work around the fact that Pango, starting with 1.50.12, has switched to
(only) using DirectWrite for enumarating fonts, and DirectWrite doesn't
@@ -224,7 +230,7 @@
enumeration (with AddFontResource[A|W]) will be added back in 1.50.13.
*/
if (pango_version() < PANGO_VERSION_ENCODE(1, 50, 12)) {
- log_message(LOG_DEFAULT,
+ log_message(archdep_font_log,
"%s(): Using AddFontResourceEx()",
__func__);
result = AddFontResourceEx(path, FR_PRIVATE, 0);
@@ -231,7 +237,7 @@
} else {
/* non-private version, if VICE crashes the font will remain on the
host system until the system is rebooted */
- log_message(LOG_DEFAULT,
+ log_message(archdep_font_log,
"%s(): Using AddFontResourceA()",
__func__);
result = AddFontResourceA(path);
@@ -239,13 +245,13 @@
lib_free(path);
if (result > 0) {
font_registered = true;
- log_message(LOG_DEFAULT,
+ log_message(archdep_font_log,
"%s(): According to Windows, the CBM font was succesfully"
" registered.",
__func__);
return 1;
}
- log_warning(LOG_DEFAULT,
+ log_warning(archdep_font_log,
"%s(): According to Windows, registering the font failed",
__func__);
#endif
@@ -276,13 +282,13 @@
char *path;
if (sysfile_locate(VICE_CBM_FONT_TTF, "common", &path) < 0) {
- log_error(LOG_DEFAULT, "failed to find resource data '%s'.",
+ log_error(archdep_font_log, "failed to find resource data '%s'.",
VICE_CBM_FONT_TTF);
return;
}
if (pango_version() < PANGO_VERSION_ENCODE(1, 50, 12)) {
- log_message(LOG_DEFAULT,
+ log_message(archdep_font_log,
"%s(): Unregistering CBM font with RemoveFontResourceExA()",
__func__);
RemoveFontResourceExA(path, FR_PRIVATE, 0);
@@ -299,7 +305,7 @@
* So we leave the font around for the session, after a reboot (heh)
* the font will be gone again and VICE will register it again.
*/
- log_warning(LOG_DEFAULT,
+ log_warning(archdep_font_log,
"%s(): Pango version >= 1.5.12: skipping unregistering"
" font with RemoveFontResourceA()",
__func__);
Modified: trunk/vice/src/arch/shared/hotkeys/uihotkeys.c
===================================================================
--- trunk/vice/src/arch/shared/hotkeys/uihotkeys.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/shared/hotkeys/uihotkeys.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -234,7 +234,7 @@
void ui_hotkeys_init(const char *prefix)
{
vhk_log = log_open("Hotkeys");
- log_message(vhk_log, "Initializing hotkeys.");
+ log_verbose(vhk_log, "Initializing hotkeys.");
if (prefix == NULL || *prefix == '\0') {
log_error(vhk_log,
"%s(): `prefix` cannot be empty or NULL.",
@@ -283,7 +283,7 @@
*/
void ui_hotkeys_shutdown(void)
{
- log_message(vhk_log, "shutting down.");
+ log_verbose(vhk_log, "shutting down.");
/* call virtual method before tearing down the generic hotkeys data */
ui_hotkeys_arch_shutdown();
vhk_parser_shutdown();
@@ -312,12 +312,12 @@
lib_free(fullpath);
if (ui_hotkeys_load(filename)) {
- log_message(vhk_log, "OK.");
+ log_verbose(vhk_log, "OK.");
/* clear the custom hotkeys file resource */
resources_set_string("HotkeyFile", "");
vhk_source = VHK_SOURCE_VICE;
} else {
- log_message(vhk_log, "failed, continuing anyway.");
+ log_error(vhk_log, "failed, continuing anyway.");
}
}
@@ -338,10 +338,10 @@
"parsing user-defined hotkeys in '%s'",
path);
if (ui_hotkeys_load(path)) {
- log_message(vhk_log, "OK.");
+ log_verbose(vhk_log, "OK.");
vhk_source = VHK_SOURCE_USER;
} else {
- log_message(vhk_log, "failed, continuing anyway.");
+ log_error(vhk_log, "failed, continuing anyway.");
}
lib_free(path);
return true;
Modified: trunk/vice/src/arch/shared/hwsiddrv/ps-ieee1284.c
===================================================================
--- trunk/vice/src/arch/shared/hwsiddrv/ps-ieee1284.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/shared/hwsiddrv/ps-ieee1284.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -186,7 +186,7 @@
sids_found = 0;
- log_message(sid_log, "Detecting libieee1284 ParSIDs.");
+ log_verbose(sid_log, "Detecting libieee1284 ParSIDs.");
if (ieee1284_find_ports(&parlist, 0) != E1284_OK) {
return -1;
@@ -210,7 +210,7 @@
}
if (!sids_found) {
- log_message(sid_log, "No libieee1284 ParSIDs found.");
+ log_verbose(sid_log, "No libieee1284 ParSIDs found.");
return -1;
}
Modified: trunk/vice/src/arch/shared/hwsiddrv/ps-unix-file.c
===================================================================
--- trunk/vice/src/arch/shared/hwsiddrv/ps-unix-file.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/shared/hwsiddrv/ps-unix-file.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -163,7 +163,7 @@
sids_found = 0;
- log_message(sid_log, "Detecting Linux ParSIDs.");
+ log_verbose(sid_log, "Detecting Linux ParSIDs.");
for (i = 0; i < MAXSID; ++i) {
pssids[sids_found] = open(parport_name[i], O_RDWR);
@@ -189,12 +189,12 @@
pssids[sids_found] = -1;
}
} else {
- log_message(sid_log, "Could not open %s.", parport_name[i]);
+ log_verbose(sid_log, "Could not open %s.", parport_name[i]);
}
}
if (!sids_found) {
- log_message(sid_log, "No Linux ParSIDs found.");
+ log_verbose(sid_log, "No Linux ParSIDs found.");
return -1;
}
Modified: trunk/vice/src/arch/shared/mididrv/midi-unix-drv.c
===================================================================
--- trunk/vice/src/arch/shared/mididrv/midi-unix-drv.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/arch/shared/mididrv/midi-unix-drv.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -444,13 +444,9 @@
if (mididrv_log == LOG_DEFAULT) {
mididrv_log = log_open("ALSA MIDI");
}
-#if 0
-#ifdef DEBUG_MIDI
- log_message(mididrv_log, "alsa_shutdown");
-#endif
-#endif
- log_message(mididrv_log, "closed ALSA MIDI sequencer port '%s'", midi_name);
+ log_verbose(mididrv_log, "closed ALSA MIDI sequencer port '%s'", midi_name);
+
if (fd_in >= 0) {
mididrv_alsa_in_close();
}
@@ -509,7 +505,7 @@
log_error(mididrv_log, "could not create ALSA sequencer port");
return;
}
- log_message(mididrv_log, "opened ALSA MIDI sequencer port '%s'", midi_name);
+ log_verbose(mididrv_log, "opened ALSA MIDI sequencer port '%s'", midi_name);
/* create event parser */
if ((alsa_err = snd_midi_event_new(RINGBUFFER_SIZE, &midi_event_parser)) < 0) {
Modified: trunk/vice/src/c64/c64.c
===================================================================
--- trunk/vice/src/c64/c64.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/c64/c64.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -158,6 +158,16 @@
#include "mouse.h"
#endif
+
+/* #define DEBUG_C64 */
+
+#ifdef DEBUG_C64
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
+
/** \brief Delay in seconds before pasting -keybuf argument into the buffer
*/
#define KBDBUF_ALARM_DELAY 1
@@ -1018,6 +1028,8 @@
{
c64_log = log_open("C64");
+ DBG(("machine_specific_init"));
+
if (mem_load() < 0) {
return -1;
}
@@ -1153,6 +1165,8 @@
machine_drive_stub();
+ DBG(("machine_specific_init (done)"));
+
return 0;
}
Modified: trunk/vice/src/drive/drive.c
===================================================================
--- trunk/vice/src/drive/drive.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/drive/drive.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -224,7 +224,7 @@
machine_drive_rom_setup_image(unit);
}
- log_message(drive_log, "Finished loading ROM images.");
+ log_verbose(drive_log, "Finished loading ROM images.");
for (unit = 0; unit < NUM_DISK_UNITS; unit++) {
diskunit_context_t *diskunit = diskunit_context[unit];
Modified: trunk/vice/src/log.c
===================================================================
--- trunk/vice/src/log.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/log.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -193,6 +193,11 @@
UNLOCK_AND_RETURN_INT(0);
}
+int log_get_limit(void)
+{
+ return log_limit;
+}
+
/* called by code that is executed *before* the resources are registered */
int log_set_limit_early(int n)
{
Modified: trunk/vice/src/log.h
===================================================================
--- trunk/vice/src/log.h 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/log.h 2025-09-01 19:17:11 UTC (rev 45747)
@@ -55,6 +55,7 @@
int log_early_init(int argc, char **argv);
int log_set_limit(int n);
+int log_get_limit(void);
int log_resources_init(void);
void log_resources_shutdown(void);
Modified: trunk/vice/src/machine.c
===================================================================
--- trunk/vice/src/machine.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/machine.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -297,6 +297,8 @@
{
machine_init_was_called = 1;
+ DBG(("machine_init"));
+
fsdevice_init();
file_system_init();
mem_initialize_memory();
Modified: trunk/vice/src/main.c
===================================================================
--- trunk/vice/src/main.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/main.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -144,47 +144,53 @@
log_message(LOG_DEFAULT, LOG_COL_LWHITE "*** VICE Version %s ***" LOG_COL_OFF, VERSION);
#endif
log_message(LOG_DEFAULT, " ");
- if (machine_class == VICE_MACHINE_VSID) {
- log_message(LOG_DEFAULT, "Welcome to %s, the free portable SID Player.",
- program_name);
+
+ if (log_get_limit() <= LOG_LIMIT_STANDARD) {
+ log_message(LOG_DEFAULT, "This is the condensed log, for the full log use " LOG_COL_LWHITE "--verbose" LOG_COL_OFF " or " LOG_COL_LWHITE "--debug" LOG_COL_OFF ".");
+ log_message(LOG_DEFAULT, " ");
} else {
- log_message(LOG_DEFAULT, "Welcome to %s, the free portable %s Emulator.",
- program_name, machine_name);
- }
- log_message(LOG_DEFAULT, " ");
+ if (machine_class == VICE_MACHINE_VSID) {
+ log_message(LOG_DEFAULT, "Welcome to %s, the free portable SID Player.",
+ program_name);
+ } else {
+ log_message(LOG_DEFAULT, "Welcome to %s, the free portable %s Emulator.",
+ program_name, machine_name);
+ }
+ log_message(LOG_DEFAULT, " ");
- log_message(LOG_DEFAULT, "Current VICE team members:");
- n = 0; *term_tmp = 0;
- for (i = 0; core_team[i].name != NULL; i++) {
- name_len = strlen(core_team[i].name);
- /* XXX: reject names that will never fit, for now */
- if ((int)name_len + 3 > TERM_TMP_SIZE) {
- log_warning(LOG_DEFAULT, "%s:%d: name '%s' too large for buffer",
- __FILE__, __LINE__, core_team[i].name);
- break; /* this will still write out whatever was in the buffer */
+ log_message(LOG_DEFAULT, "Current VICE team members:");
+ n = 0; *term_tmp = 0;
+ for (i = 0; core_team[i].name != NULL; i++) {
+ name_len = strlen(core_team[i].name);
+ /* XXX: reject names that will never fit, for now */
+ if ((int)name_len + 3 > TERM_TMP_SIZE) {
+ log_warning(LOG_DEFAULT, "%s:%d: name '%s' too large for buffer",
+ __FILE__, __LINE__, core_team[i].name);
+ break; /* this will still write out whatever was in the buffer */
+ }
+
+ if (n + (int)name_len + 3 > TERM_TMP_SIZE) { /* +3 for ", \0" */
+ log_message(LOG_DEFAULT, "%s", term_tmp);
+ strcpy(term_tmp, core_team[i].name);
+ n = (int)name_len;
+ } else {
+ strcat(term_tmp, core_team[i].name);
+ n += (int)name_len;
+ }
+ if (core_team[i + 1].name == NULL) {
+ strcat(term_tmp, ".");
+ } else {
+ strcat(term_tmp, ", ");
+ n += 2;
+ }
}
+ log_message(LOG_DEFAULT, "%s", term_tmp);
- if (n + (int)name_len + 3 > TERM_TMP_SIZE) { /* +3 for ", \0" */
- log_message(LOG_DEFAULT, "%s", term_tmp);
- strcpy(term_tmp, core_team[i].name);
- n = (int)name_len;
- } else {
- strcat(term_tmp, core_team[i].name);
- n += (int)name_len;
- }
- if (core_team[i + 1].name == NULL) {
- strcat(term_tmp, ".");
- } else {
- strcat(term_tmp, ", ");
- n += 2;
- }
+ log_message(LOG_DEFAULT, " ");
+ log_message(LOG_DEFAULT, LOG_COL_LWHITE "This is free software with ABSOLUTELY NO WARRANTY." LOG_COL_OFF);
+ log_message(LOG_DEFAULT, LOG_COL_LWHITE "See the \"About VICE\" command for more info." LOG_COL_OFF);
+ log_message(LOG_DEFAULT, " ");
}
- log_message(LOG_DEFAULT, "%s", term_tmp);
-
- log_message(LOG_DEFAULT, " ");
- log_message(LOG_DEFAULT, LOG_COL_LWHITE "This is free software with ABSOLUTELY NO WARRANTY." LOG_COL_OFF);
- log_message(LOG_DEFAULT, LOG_COL_LWHITE "See the \"About VICE\" command for more info." LOG_COL_OFF);
- log_message(LOG_DEFAULT, " ");
}
/* This is the main program entry point. Call this from `main()'. */
@@ -242,6 +248,11 @@
/* printf("%s(): disabling stream redirection\n", __func__); */
}
#endif
+
+ /* set log level to "normal" here, any log output before would use "debug",
+ and anything after here can use the option(s) on the cmdline */
+ log_set_limit_early(LOG_LIMIT_STANDARD);
+
/* Check for some options at the beginning of the commandline before
initializing the user interface or loading the config file.
-default => use default config, do not load any config
@@ -500,7 +511,7 @@
pthread_join(vice_thread, NULL);
- log_message(main_log, "VICE thread has been joined.");
+ log_verbose(main_log, "VICE thread has been joined.");
}
void *vice_thread_main(void *unused)
Modified: trunk/vice/src/mainlock.c
===================================================================
--- trunk/vice/src/mainlock.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/mainlock.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -109,7 +109,7 @@
pthread_mutex_unlock(&internal_lock);
pthread_mutex_unlock(&main_lock);
- log_message(mainlock_log, "VICE thread is exiting");
+ log_verbose(mainlock_log, "VICE thread is exiting");
archdep_thread_shutdown();
@@ -138,7 +138,7 @@
vice_thread_keepalive = false;
pthread_mutex_unlock(&internal_lock);
- log_message(mainlock_log, "VICE thread initiating shutdown");
+ log_verbose(mainlock_log, "VICE thread initiating shutdown");
/* If called on the vice thread itself, run the exit code immediately */
if (pthread_equal(pthread_self(), vice_thread)) {
Modified: trunk/vice/src/resources.c
===================================================================
--- trunk/vice/src/resources.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/resources.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -951,8 +951,8 @@
{
unsigned int i;
- log_message(LOG_DEFAULT, "%s", ""); /* ugly hack to produce a blank log line, but not trigger a warning */
- log_message(LOG_DEFAULT, "Setting resources to default...");
+ log_verbose(LOG_DEFAULT, "%s", ""); /* ugly hack to produce a blank log line, but not trigger a warning */
+ log_verbose(LOG_DEFAULT, "Setting resources to default...");
/* the cartridge system uses internal state variables so the default cartridge
can be unset without changing the attached cartridge and/or attach another
Modified: trunk/vice/src/sound.c
===================================================================
--- trunk/vice/src/sound.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/sound.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -1325,7 +1325,7 @@
static void sounddev_close(const sound_device_t **dev)
{
if (*dev) {
- log_message(sound_log, "Closing device `%s'", (*dev)->name);
+ log_verbose(sound_log, "Closing device `%s'", (*dev)->name);
if ((*dev)->close) {
(*dev)->close();
}
Modified: trunk/vice/src/sysfile.c
===================================================================
--- trunk/vice/src/sysfile.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/sysfile.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -47,6 +47,8 @@
#define DBG(x)
#endif
+static log_t sysfile_log = LOG_DEFAULT;
+
/* Resources. */
static char *default_path = NULL;
@@ -138,6 +140,9 @@
int sysfile_init(const char *emu_id)
{
+ if (sysfile_log == LOG_DEFAULT) {
+ sysfile_log = log_open("Sysfile");
+ }
default_path = archdep_default_sysfile_pathlist(emu_id);
DBG(("sysfile_init(%s) -> default_path:'%s'", emu_id, default_path));
/* HACK: set the default value early, so the systemfile locater also works
@@ -179,7 +184,7 @@
FILE *f;
if (name == NULL || *name == '\0') {
- log_error(LOG_DEFAULT, "Missing name for system file.");
+ log_error(sysfile_log, "Missing name for system file.");
return NULL;
}
@@ -201,7 +206,7 @@
/* make sure we're not opening a directory */
archdep_stat(p, NULL, &isdir);
if (isdir) {
- log_error(LOG_DEFAULT, "'%s' is a directory, not a file.", p);
+ log_error(sysfile_log, "'%s' is a directory, not a file.", p);
if (complete_path_return != NULL) {
*complete_path_return = NULL;
}
@@ -269,11 +274,11 @@
}
}
- log_message(LOG_DEFAULT, "Loading system file `%s'.", complete_path);
+ log_message(sysfile_log, "Loading `%s'.", complete_path);
tmpsize = archdep_file_size(fp);
if (tmpsize < 0) {
- log_message(LOG_DEFAULT, "Failed to determine size of '%s'.", complete_path);
+ log_message(sysfile_log, "Failed to determine size of '%s'.", complete_path);
goto fail;
}
rsize = (size_t)tmpsize;
@@ -285,11 +290,11 @@
}
if (rsize < ((size_t)minsize)) {
- log_error(LOG_DEFAULT, "ROM %s: short file.", complete_path);
+ log_error(sysfile_log, "ROM %s: short file.", complete_path);
goto fail;
}
if (rsize == ((size_t)maxsize + 2)) {
- log_warning(LOG_DEFAULT,
+ log_warning(sysfile_log,
"ROM `%s': two bytes too large - removing assumed "
"start address.", complete_path);
if (fread((char *)dest, 1, 2, fp) < 2) {
@@ -300,7 +305,7 @@
if (load_at_end && rsize < ((size_t)maxsize)) {
dest += maxsize - rsize;
} else if (rsize > ((size_t)maxsize)) {
- log_warning(LOG_DEFAULT,
+ log_warning(sysfile_log,
"ROM `%s': long file (%"PRI_SIZE_T"), discarding end (%"PRI_SIZE_T" bytes).",
complete_path, rsize, rsize - maxsize);
rsize = maxsize;
Modified: trunk/vice/src/viciisc/vicii-resources.c
===================================================================
--- trunk/vice/src/viciisc/vicii-resources.c 2025-09-01 19:07:14 UTC (rev 45746)
+++ trunk/vice/src/viciisc/vicii-resources.c 2025-09-01 19:17:11 UTC (rev 45747)
@@ -87,8 +87,11 @@
static int set_vsp_bug_enabled(int val, void *param)
{
+ int old = vicii_resources.vsp_bug_enabled;
vicii_resources.vsp_bug_enabled = val;
- vicii_init_vsp_bug();
+ if (val != old) {
+ vicii_init_vsp_bug();
+ }
return 0;
}
@@ -196,7 +199,7 @@
if ((machine_class == VICE_MACHINE_C64SC) ||
(machine_class == VICE_MACHINE_SCPU64)){
- resources_int2[0].factory_value = VICII_MODEL_8565;
+ resources_int2[0].factory_value = vicii_resources.model = VICII_MODEL_8565;
}
if (raster_resources_chip_init("VICII", &vicii.raster, &video_chip_cap) < 0) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <gp...@us...> - 2025-09-01 19:07:17
|
Revision: 45746
http://sourceforge.net/p/vice-emu/code/45746
Author: gpz
Date: 2025-09-01 19:07:14 +0000 (Mon, 01 Sep 2025)
Log Message:
-----------
get rid of static buffers for kernal/basic/chargen
Modified Paths:
--------------
trunk/vice/src/c128/c128-resources.c
trunk/vice/src/c128/c128rom.c
trunk/vice/src/c128/c128rom.h
trunk/vice/src/c64/c64rom.c
trunk/vice/src/c64/c64rom.h
trunk/vice/src/c64dtv/c64dtvflash.c
trunk/vice/src/c64dtv/c64dtvflash.h
Modified: trunk/vice/src/c128/c128-resources.c
===================================================================
--- trunk/vice/src/c128/c128-resources.c 2025-08-31 13:34:57 UTC (rev 45745)
+++ trunk/vice/src/c128/c128-resources.c 2025-09-01 19:07:14 UTC (rev 45746)
@@ -466,7 +466,15 @@
return 0;
}
- return c128rom_load_basiclo(basiclo_rom_name);
+ if (c128rom_load_basiclo(basiclo_rom_name) < 0) {
+ return -1;
+ }
+
+ if (c128rom_basic_setup() < 0) {
+ return -1;
+ }
+
+ return 0;
}
static int set_basichi_rom_name(const char *val, void *param)
@@ -475,7 +483,15 @@
return 0;
}
- return c128rom_load_basichi(basichi_rom_name);
+ if (c128rom_load_basichi(basichi_rom_name) < 0) {
+ return -1;
+ }
+
+ if (c128rom_basic_setup() < 0) {
+ return -1;
+ }
+
+ return 0;
}
static int set_kernal64_rom_name(const char *val, void *param)
@@ -484,7 +500,15 @@
return 0;
}
- return c128rom_load_kernal64(kernal64_rom_name, NULL);
+ if (c128rom_load_kernal64(kernal64_rom_name) < 0) {
+ return -1;
+ }
+
+ if (c128rom_kernal64_setup() < 0) {
+ return -1;
+ }
+
+ return 0;
}
static int set_basic64_rom_name(const char *val, void *param)
@@ -493,7 +517,15 @@
return 0;
}
- return c128rom_load_basic64(basic64_rom_name);
+ if (c128rom_load_basic64(basic64_rom_name) < 0) {
+ return -1;
+ }
+
+ if (c128rom_basic64_setup() < 0) {
+ return -1;
+ }
+
+ return 0;
}
static int set_cia1_model(int val, void *param)
Modified: trunk/vice/src/c128/c128rom.c
===================================================================
--- trunk/vice/src/c128/c128rom.c 2025-08-31 13:34:57 UTC (rev 45745)
+++ trunk/vice/src/c128/c128rom.c 2025-09-01 19:07:14 UTC (rev 45746)
@@ -37,6 +37,7 @@
#include "c64rom.h"
#include "machine.h"
#include "mem.h"
+#include "lib.h"
#include "log.h"
#include "resources.h"
#include "sysfile.h"
@@ -44,31 +45,21 @@
#include "util.h"
#include "z80mem.h"
+/* #define DEBUG_C128ROM */
+
+#ifdef DEBUG_C128ROM
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
static log_t c128rom_log = LOG_DEFAULT;
-/* Flag: nonzero if the Kernal and BASIC ROMs have been loaded. */
+/* Flag: nonzero if the Kernal and BASIC ROMs are available. */
static int rom_loaded = 0;
-/* National Kernal ROM images. */
-static uint8_t kernal_int[C128_KERNAL_ROM_IMAGE_SIZE];
-static uint8_t kernal_ch[C128_KERNAL_ROM_IMAGE_SIZE];
-static uint8_t kernal_de[C128_KERNAL_ROM_IMAGE_SIZE];
-static uint8_t kernal_fi[C128_KERNAL_ROM_IMAGE_SIZE];
-static uint8_t kernal_fr[C128_KERNAL_ROM_IMAGE_SIZE];
-static uint8_t kernal_it[C128_KERNAL_ROM_IMAGE_SIZE];
-static uint8_t kernal_no[C128_KERNAL_ROM_IMAGE_SIZE];
-static uint8_t kernal_se[C128_KERNAL_ROM_IMAGE_SIZE];
+/******************************************************************************/
-/* National Chargen ROM images. */
-static uint8_t chargen_int[C128_CHARGEN_ROM_SIZE];
-static uint8_t chargen_ch[C128_CHARGEN_ROM_SIZE];
-static uint8_t chargen_de[C128_CHARGEN_ROM_SIZE];
-static uint8_t chargen_fi[C128_CHARGEN_ROM_SIZE];
-static uint8_t chargen_fr[C128_CHARGEN_ROM_SIZE];
-static uint8_t chargen_it[C128_CHARGEN_ROM_SIZE];
-static uint8_t chargen_no[C128_CHARGEN_ROM_SIZE];
-static uint8_t chargen_se[C128_CHARGEN_ROM_SIZE];
-
typedef struct
{
char *name;
@@ -119,6 +110,9 @@
return 0;
}
+/******************************************************************************/
+
+/* Check if international Kernal ROM is available. */
int c128rom_load_kernal_int(const char *rom_name)
{
if (!rom_loaded) {
@@ -126,9 +120,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load international Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_int, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -135,6 +127,7 @@
return 0;
}
+/* Check if German Kernal ROM is available. */
int c128rom_load_kernal_de(const char *rom_name)
{
if (!rom_loaded) {
@@ -142,9 +135,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load German Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_de, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -151,6 +142,7 @@
return 0;
}
+/* Check if Finnish Kernal ROM is available. */
int c128rom_load_kernal_fi(const char *rom_name)
{
if (!rom_loaded) {
@@ -158,9 +150,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load Finnish Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_fi, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -167,6 +157,7 @@
return 0;
}
+/* Check if French Kernal ROM is available. */
int c128rom_load_kernal_fr(const char *rom_name)
{
if (!rom_loaded) {
@@ -174,9 +165,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load French Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_fr, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -183,6 +172,7 @@
return 0;
}
+/* Check if Italian Kernal ROM is available. */
int c128rom_load_kernal_it(const char *rom_name)
{
if (!rom_loaded) {
@@ -190,9 +180,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load Italian Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_it, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -199,6 +187,7 @@
return 0;
}
+/* Check if Norwegian Kernal ROM is available. */
int c128rom_load_kernal_no(const char *rom_name)
{
if (!rom_loaded) {
@@ -206,9 +195,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load Norwegian Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_no, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -215,6 +202,7 @@
return 0;
}
+/* Check if Swedish Kernal ROM is available. */
int c128rom_load_kernal_se(const char *rom_name)
{
if (!rom_loaded) {
@@ -222,9 +210,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load Swedish Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_se, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -231,6 +217,7 @@
return 0;
}
+/* Check if Swiss Kernal ROM is available. */
int c128rom_load_kernal_ch(const char *rom_name)
{
if (!rom_loaded) {
@@ -238,9 +225,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load Swiss Kernal ROM. */
- if (sysfile_load(rom_name, machine_name, kernal_ch, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -290,6 +275,8 @@
int c128rom_kernal_setup(void)
{
int machine_type;
+ const char *resname = NULL;
+ const char *rom_name = NULL;
uint8_t *kernal = NULL;
static const char *last_kernal64 = NULL;
char *name;
@@ -303,30 +290,30 @@
switch (machine_type) {
case C128_MACHINE_INT:
- kernal = kernal_int;
+ resname = "KernalIntName";
break;
case C128_MACHINE_FINNISH:
- kernal = kernal_fi;
+ resname = "KernalFIName";
break;
case C128_MACHINE_FRENCH:
- kernal = kernal_fr;
+ resname = "KernalFRName";
break;
case C128_MACHINE_GERMAN:
- kernal = kernal_de;
+ resname = "KernalDEName";
break;
case C128_MACHINE_ITALIAN:
- kernal = kernal_it;
+ resname = "KernalITName";
break;
case C128_MACHINE_NORWEGIAN:
- kernal = kernal_no;
kernal64 = C128_KERNAL64_NO_NAME;
+ resname = "KernalNOName";
break;
case C128_MACHINE_SWEDISH:
- kernal = kernal_se;
kernal64 = C128_KERNAL64_SE_NAME;
+ resname = "KernalSEName";
break;
case C128_MACHINE_SWISS:
- kernal = kernal_ch;
+ resname = "KernalCHName";
break;
default:
log_error(c128rom_log, "Unknown machine type %i.", machine_type);
@@ -344,6 +331,20 @@
get_trapflags();
clear_trapflags();
+ kernal = lib_malloc(C128_KERNAL_ROM_IMAGE_SIZE);
+ if (kernal == NULL) {
+ goto exiterror;
+ }
+
+ if (resources_get_string(resname, &rom_name) < 0) {
+ goto exiterror;
+ }
+
+ if (sysfile_load(rom_name, machine_name, kernal, C128_KERNAL_ROM_IMAGE_SIZE, C128_KERNAL_ROM_IMAGE_SIZE) < 0) {
+ log_error(c128rom_log, "Couldn't load kernal ROM `%s'.", rom_name);
+ goto exiterror;
+ }
+
memcpy(&c128memrom_basic_rom[C128_BASIC_ROM_SIZE], kernal, C128_EDITOR_ROM_SIZE);
memcpy(z80bios_rom, &kernal[C128_EDITOR_ROM_SIZE], C128_Z80BIOS_ROM_SIZE);
memcpy(c128memrom_kernal_rom, &kernal[C128_EDITOR_ROM_SIZE + C128_Z80BIOS_ROM_SIZE], C128_KERNAL_ROM_SIZE);
@@ -357,9 +358,18 @@
restore_trapflags();
+ lib_free(kernal);
return 0;
+
+exiterror:
+ if (kernal) {
+ lib_free(kernal);
+ }
+ return -1;
}
+/******************************************************************************/
+
static ROMINFO basicinfo[] = {
{ "85", C128_BASIC_85_CHECKSUM, 0 },
{ "86", C128_BASIC_86_CHECKSUM, 0 },
@@ -406,6 +416,38 @@
return 0;
}
+/******************************************************************************/
+
+int c128rom_basic_setup(void)
+{
+ const char *rom_name = NULL;
+
+ if (!rom_loaded) {
+ return 0;
+ }
+
+ if (resources_get_string("BasicLoName", &rom_name) < 0) {
+ return -1;
+ }
+
+ /* Load Basic ROM. */
+ if (sysfile_load(rom_name, machine_name, c128memrom_basic_rom, C128_BASIC_ROM_IMAGELO_SIZE, C128_BASIC_ROM_IMAGELO_SIZE) < 0) {
+ log_error(c128rom_log, "Couldn't load basic ROM `%s'.", rom_name);
+ return -1;
+ }
+
+ if (resources_get_string("BasicHiName", &rom_name) < 0) {
+ return -1;
+ }
+
+ if (sysfile_load(rom_name, machine_name, &c128memrom_basic_rom[C128_BASIC_ROM_IMAGELO_SIZE], C128_BASIC_ROM_IMAGEHI_SIZE, C128_BASIC_ROM_IMAGEHI_SIZE) < 0) {
+ log_error(c128rom_log, "Couldn't load basic ROM `%s'.", rom_name);
+ return -1;
+ }
+ return 0;
+}
+
+/* Check if Basic ROM (lo) exists */
int c128rom_load_basiclo(const char *rom_name)
{
if (!rom_loaded) {
@@ -413,9 +455,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load Basic ROM. */
- if (sysfile_load(rom_name, machine_name, c128memrom_basic_rom, C128_BASIC_ROM_IMAGELO_SIZE, C128_BASIC_ROM_IMAGELO_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load basic ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -422,6 +462,7 @@
return 0;
}
+/* Check if Basic ROM (hi) exists */
int c128rom_load_basichi(const char *rom_name)
{
if (!rom_loaded) {
@@ -429,9 +470,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load Basic ROM. */
- if (sysfile_load(rom_name, machine_name, &c128memrom_basic_rom[C128_BASIC_ROM_IMAGELO_SIZE], C128_BASIC_ROM_IMAGEHI_SIZE, C128_BASIC_ROM_IMAGEHI_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load basic ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -438,10 +477,13 @@
return 0;
}
+/******************************************************************************/
+
int c128rom_chargen_setup(void)
{
int machine_type;
- uint8_t *chargen;
+ const char *resname = NULL;
+ const char *rom_name = NULL;
if (!rom_loaded) {
return 0;
@@ -451,28 +493,28 @@
switch (machine_type) {
case C128_MACHINE_INT:
- chargen = chargen_int;
+ resname = "ChargenIntName";
break;
case C128_MACHINE_ITALIAN:
- chargen = chargen_it;
+ resname = "ChargenITName";
break;
case C128_MACHINE_FRENCH:
- chargen = chargen_fr;
+ resname = "ChargenFRName";
break;
case C128_MACHINE_GERMAN:
- chargen = chargen_de;
+ resname = "ChargenDEName";
break;
case C128_MACHINE_FINNISH:
- chargen = chargen_fi;
+ resname = "ChargenFIName";
break;
case C128_MACHINE_SWEDISH:
- chargen = chargen_se;
+ resname = "ChargenSEName";
break;
case C128_MACHINE_SWISS:
- chargen = chargen_ch;
+ resname = "ChargenCHName";
break;
case C128_MACHINE_NORWEGIAN:
- chargen = chargen_no;
+ resname = "ChargenNOName";
break;
default:
log_error(c128rom_log, "Unknown machine type %i.", machine_type);
@@ -479,11 +521,20 @@
return -1;
}
- memcpy(mem_chargen_rom, chargen, C128_CHARGEN_ROM_SIZE);
+ if (resources_get_string(resname, &rom_name) < 0) {
+ return -1;
+ }
+ /* Load chargen ROM. */
+ if (sysfile_load(rom_name, machine_name, mem_chargen_rom, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
+ log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ return -1;
+ }
+
return 0;
}
+/* Check if international Chargen ROM is available. */
int c128rom_load_chargen_int(const char *rom_name)
{
if (!rom_loaded) {
@@ -491,9 +542,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_int, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -500,6 +549,7 @@
return 0;
}
+/* Check if german Chargen ROM is available. */
int c128rom_load_chargen_de(const char *rom_name)
{
if (!rom_loaded) {
@@ -507,9 +557,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_de, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -516,6 +564,7 @@
return 0;
}
+/* Check if italian french ROM is available. */
int c128rom_load_chargen_fr(const char *rom_name)
{
if (!rom_loaded) {
@@ -523,9 +572,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_fr, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -532,6 +579,7 @@
return 0;
}
+/* Check if swedish Chargen ROM is available. */
int c128rom_load_chargen_se(const char *rom_name)
{
if (!rom_loaded) {
@@ -539,9 +587,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_se, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -548,6 +594,7 @@
return 0;
}
+/* Check if swiss Chargen ROM is available. */
int c128rom_load_chargen_ch(const char *rom_name)
{
if (!rom_loaded) {
@@ -555,9 +602,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_ch, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -564,6 +609,7 @@
return 0;
}
+/* Check if norwegian Chargen ROM is available. */
int c128rom_load_chargen_no(const char *rom_name)
{
if (!rom_loaded) {
@@ -571,9 +617,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_no, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -580,6 +624,7 @@
return 0;
}
+/* Check if finnish Chargen ROM is available. */
int c128rom_load_chargen_fi(const char *rom_name)
{
if (!rom_loaded) {
@@ -587,9 +632,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_fi, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -596,6 +639,7 @@
return 0;
}
+/* Check if italian Chargen ROM is available. */
int c128rom_load_chargen_it(const char *rom_name)
{
if (!rom_loaded) {
@@ -603,9 +647,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load chargen ROM. */
- if (sysfile_load(rom_name, machine_name, chargen_it, C128_CHARGEN_ROM_SIZE, C128_CHARGEN_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load character ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -612,35 +654,33 @@
return 0;
}
-int c64rom_cartkernal_active = 0;
+/******************************************************************************/
-int c128rom_load_kernal64(const char *rom_name, uint8_t *cartkernal)
+int c128rom_kernal64_setup(void)
{
+ const char *rom_name = NULL;
+
if (!rom_loaded) {
return 0;
}
- if (cartkernal == NULL) {
- if (c64rom_cartkernal_active == 1) {
- return -1;
- }
+ if (resources_get_string("Kernal64Name", &rom_name) < 0) {
+ return -1;
+ }
- if (!util_check_null_string(rom_name)) {
- /* Load C64 kernal ROM. */
- if (sysfile_load(rom_name, machine_name, c64memrom_kernal64_rom, C128_KERNAL64_ROM_SIZE, C128_KERNAL64_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load C64 kernal ROM `%s'.", rom_name);
- return -1;
- }
- }
- } else {
- memcpy(c64memrom_kernal64_rom, cartkernal, 0x2000);
- c64rom_cartkernal_active = 1;
+ /* Load C64 kernal ROM. */
+ if (sysfile_load(rom_name, machine_name, c64memrom_kernal64_rom, C128_KERNAL64_ROM_SIZE, C128_KERNAL64_ROM_SIZE) < 0) {
+ log_error(c128rom_log, "Couldn't load C64 kernal ROM `%s'.", rom_name);
+ return -1;
}
+
memcpy(c64memrom_kernal64_trap_rom, c64memrom_kernal64_rom, C128_KERNAL64_ROM_SIZE);
+
return 0;
}
-int c128rom_load_basic64(const char *rom_name)
+/* check if C64 kernal ROM exists */
+int c128rom_load_kernal64(const char *rom_name)
{
if (!rom_loaded) {
return 0;
@@ -647,9 +687,7 @@
}
if (!util_check_null_string(rom_name)) {
- /* Load basic ROM. */
- if (sysfile_load(rom_name, machine_name, c64memrom_basic64_rom, C128_BASIC64_ROM_SIZE, C128_BASIC64_ROM_SIZE) < 0) {
- log_error(c128rom_log, "Couldn't load C64 basic ROM `%s'.", rom_name);
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
return -1;
}
}
@@ -656,166 +694,128 @@
return 0;
}
-int mem_load(void)
+int c128rom_basic64_setup(void)
{
const char *rom_name = NULL;
- if (c128rom_log == LOG_DEFAULT) {
- c128rom_log = log_open("C128MEM");
+ if (!rom_loaded) {
+ return 0;
}
- mem_initialize_memory();
-
- rom_loaded = 1;
-
- if (resources_get_string("BasicLoName", &rom_name) < 0) {
+ if (resources_get_string("Basic64Name", &rom_name) < 0) {
return -1;
}
- if (c128rom_load_basiclo(rom_name) < 0) {
- return -1;
- }
- if (resources_get_string("BasicHiName", &rom_name) < 0) {
+ /* Load Basic ROM. */
+ if (sysfile_load(rom_name, machine_name, c64memrom_basic64_rom, C128_BASIC64_ROM_SIZE, C128_BASIC64_ROM_SIZE) < 0) {
+ log_error(c128rom_log, "Couldn't load C64 basic ROM `%s'.", rom_name);
return -1;
}
- if (c128rom_load_basichi(rom_name) < 0) {
- return -1;
- }
- if (resources_get_string("KernalIntName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_kernal_int(rom_name) < 0) {
- return -1;
- }
+ return 0;
+}
- if (resources_get_string("KernalDEName", &rom_name) < 0) {
- return -1;
+/* Check if C64 basic ROM exists. */
+int c128rom_load_basic64(const char *rom_name)
+{
+ if (!rom_loaded) {
+ return 0;
}
- if (c128rom_load_kernal_de(rom_name) < 0) {
- return -1;
- }
- if (resources_get_string("KernalFIName", &rom_name) < 0) {
- return -1;
+ if (!util_check_null_string(rom_name)) {
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
+ return -1;
+ }
}
- if (c128rom_load_kernal_fi(rom_name) < 0) {
- return -1;
- }
+ return 0;
+}
- if (resources_get_string("KernalFRName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_kernal_fr(rom_name) < 0) {
- return -1;
- }
+/******************************************************************************/
- if (resources_get_string("KernalITName", &rom_name) < 0) {
+static int c128rom_check_res_file(const char* resname)
+{
+ const char *rom_name = NULL;
+ if (resources_get_string(resname, &rom_name) < 0) {
return -1;
}
- if (c128rom_load_kernal_it(rom_name) < 0) {
+ if (!rom_loaded) {
return -1;
}
-
- if (resources_get_string("KernalNOName", &rom_name) < 0) {
- return -1;
+ if (!util_check_null_string(rom_name)) {
+ if (sysfile_locate(rom_name, machine_name, NULL) < 0) {
+ return -1;
+ }
}
- if (c128rom_load_kernal_no(rom_name) < 0) {
- return -1;
- }
+ return 0;
+}
- if (resources_get_string("KernalSEName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_kernal_se(rom_name) < 0) {
- return -1;
- }
- if (resources_get_string("KernalCHName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_kernal_ch(rom_name) < 0) {
- return -1;
- }
+int mem_load(void)
+{
+ const char *rom_name = NULL;
- c128rom_kernal_setup();
-
- if (resources_get_string("ChargenIntName", &rom_name) < 0) {
- return -1;
+ if (c128rom_log == LOG_DEFAULT) {
+ c128rom_log = log_open("C128MEM");
}
- if (c128rom_load_chargen_int(rom_name) < 0) {
- return -1;
- }
- if (resources_get_string("ChargenDEName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_chargen_de(rom_name) < 0) {
- return -1;
- }
+ mem_initialize_memory();
- if (resources_get_string("ChargenFRName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_chargen_fr(rom_name) < 0) {
- return -1;
- }
+ rom_loaded = 1;
- if (resources_get_string("ChargenSEName", &rom_name) < 0) {
+ if ((c128rom_check_res_file("BasicLoName") < 0) ||
+ (c128rom_check_res_file("BasicHiName") < 0)) {
return -1;
}
- if (c128rom_load_chargen_se(rom_name) < 0) {
- return -1;
- }
- if (resources_get_string("ChargenCHName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_chargen_ch(rom_name) < 0) {
- return -1;
- }
+ c128rom_basic_setup();
- if (resources_get_string("ChargenNOName", &rom_name) < 0) {
+ if ((c128rom_check_res_file("KernalIntName") < 0) ||
+ (c128rom_check_res_file("KernalDEName") < 0) ||
+ (c128rom_check_res_file("KernalFIName") < 0) ||
+ (c128rom_check_res_file("KernalFRName") < 0) ||
+ (c128rom_check_res_file("KernalITName") < 0) ||
+ (c128rom_check_res_file("KernalNOName") < 0) ||
+ (c128rom_check_res_file("KernalSEName") < 0) ||
+ (c128rom_check_res_file("KernalCHName") < 0)) {
return -1;
}
- if (c128rom_load_chargen_no(rom_name) < 0) {
- return -1;
- }
- if (resources_get_string("ChargenFIName", &rom_name) < 0) {
- return -1;
- }
- if (c128rom_load_chargen_fi(rom_name) < 0) {
- return -1;
- }
+ c128rom_kernal_setup();
- if (resources_get_string("ChargenITName", &rom_name) < 0) {
+ if ((c128rom_check_res_file("ChargenIntName") < 0) ||
+ (c128rom_check_res_file("ChargenDEName") < 0) ||
+ (c128rom_check_res_file("ChargenFRName") < 0) ||
+ (c128rom_check_res_file("ChargenSEName") < 0) ||
+ (c128rom_check_res_file("ChargenCHName") < 0) ||
+ (c128rom_check_res_file("ChargenNOName") < 0) ||
+ (c128rom_check_res_file("ChargenFIName") < 0) ||
+ (c128rom_check_res_file("ChargenITName") < 0)) {
return -1;
}
- if (c128rom_load_chargen_it(rom_name) < 0) {
- return -1;
- }
c128rom_chargen_setup();
- if (resources_get_string("Kernal64Name", &rom_name) < 0) {
+ if (c128rom_check_res_file("Kernal64Name") < 0) {
return -1;
}
- if (c128rom_load_kernal64(rom_name, NULL) < 0) {
- return -1;
- }
+ c128rom_kernal64_setup();
- if (resources_get_string("Basic64Name", &rom_name) < 0) {
+ if (c128rom_check_res_file("Basic64Name") < 0) {
return -1;
}
- if (c128rom_load_basic64(rom_name) < 0) {
- return -1;
- }
+ c128rom_basic64_setup();
return 0;
}
+/* FIXME: the extra parameter cartkernal was used to replace the kernal
+ with a cartridge kernal rom image.
+
+ CAUTION: The current code does NOT use this anymore, cartkernal is always NULL
+*/
int c64rom_load_kernal(const char *rom_name, uint8_t *cartkernal)
{
- return c128rom_load_kernal64(rom_name, cartkernal);
+ /* CAUTION: this is the only place where c128rom_load_kernal64 gets called
+ * with cartkernal potentially being not NULL */
+ return c128rom_load_kernal64(rom_name);
}
Modified: trunk/vice/src/c128/c128rom.h
===================================================================
--- trunk/vice/src/c128/c128rom.h 2025-08-31 13:34:57 UTC (rev 45745)
+++ trunk/vice/src/c128/c128rom.h 2025-09-01 19:07:14 UTC (rev 45746)
@@ -48,13 +48,17 @@
int c128rom_load_chargen_no(const char *rom_name);
int c128rom_load_chargen_se(const char *rom_name);
-int c128rom_load_kernal64(const char *rom_name, uint8_t *cartkernal);
+int c128rom_load_kernal64(const char *rom_name);
int c128rom_load_basic64(const char *rom_name);
int c128rom_basic_checksum(void);
int c128rom_kernal_checksum(void);
+
int c128rom_kernal_setup(void);
int c128rom_chargen_setup(void);
+int c128rom_basic_setup(void);
+int c128rom_kernal64_setup(void);
+int c128rom_basic64_setup(void);
/* BASICLO + BASICHI */
#define C128_BASIC_85_CHECKSUM 38592
Modified: trunk/vice/src/c64/c64rom.c
===================================================================
--- trunk/vice/src/c64/c64rom.c 2025-08-31 13:34:57 UTC (rev 45745)
+++ trunk/vice/src/c64/c64rom.c 2025-09-01 19:07:14 UTC (rev 45746)
@@ -158,7 +158,8 @@
return rev;
}
-int c64rom_cartkernal_active = 0;
+/* FIXME: this flag is strange, it is only ever set to 1 and never to 0 */
+static int c64rom_cartkernal_active = 0;
#define NUM_TRAP_DEVICES 9 /* FIXME: is there a better constant ? */
static int trapfl[NUM_TRAP_DEVICES];
@@ -188,9 +189,11 @@
}
}
-/* the extra parameter cartkernal is used to replace the kernal
- with a cartridge kernal rom image, if it is NULL normal kernal
- is used */
+/* FIXME: the extra parameter cartkernal was used to replace the kernal
+ with a cartridge kernal rom image.
+
+ CAUTION: The current code does NOT use this anymore, cartkernal is always NULL
+*/
int c64rom_load_kernal(const char *rom_name, uint8_t *cartkernal)
{
int rev;
Modified: trunk/vice/src/c64/c64rom.h
===================================================================
--- trunk/vice/src/c64/c64rom.h 2025-08-31 13:34:57 UTC (rev 45745)
+++ trunk/vice/src/c64/c64rom.h 2025-09-01 19:07:14 UTC (rev 45746)
@@ -107,6 +107,4 @@
int c64rom_isloaded(void);
-extern int c64rom_cartkernal_active;
-
#endif
Modified: trunk/vice/src/c64dtv/c64dtvflash.c
===================================================================
--- trunk/vice/src/c64dtv/c64dtvflash.c 2025-08-31 13:34:57 UTC (rev 45745)
+++ trunk/vice/src/c64dtv/c64dtvflash.c 2025-09-01 19:07:14 UTC (rev 45746)
@@ -48,7 +48,14 @@
#include "c64dtvflash.h"
/* #define DEBUG */
+/* #define DEBUG_DTVFLASH */
+#ifdef DEBUG_DTVFLASH
+#define DBG(x) log_printf x
+#else
+#define DBG(x)
+#endif
+
#define DTVROM_PALV2_NAME_DEFAULT "dtvrom.bin" /* FIXME: rename (who made this?) */
#define DTVROM_PALV3_NAME_DEFAULT "dtvrom.bin" /* FIXME: rename (who made this?) */
#define DTVROM_NTSCV2_NAME_DEFAULT "dtvrom.bin" /* FIXME: rename (who made this?) */
@@ -61,9 +68,12 @@
static int flash_log_enabled = 0;
#endif
+/* Flag: nonzero if the DTV ROMs are available. */
+static int rom_loaded = 0;
+
#define C64_ROM_SIZE 0x200000
-/* Filenames of C64DTV RAM/ROM */
+/* Filenames of C64DTV RAM/ROM(s) */
static char *c64dtvflash_filename[DTVMODEL_NUM] = { NULL, NULL, NULL, NULL, NULL };
static int c64dtvflash_revision = 0;
@@ -445,13 +455,13 @@
/* ------------------------------------------------------------------------- */
-int c64dtvflash_rom_loaded = 0;
-
-static int c64dtvflash_load_rom(int idx)
+static int c64dtvflash_rom_setup(int idx)
{
int retval = 0; /* need to change this when ui gets changed for error indication */
- /*int idx = c64dtvflash_revision;*/ /* DTVFlashRevision */
+ if (!rom_loaded) {
+ return 0;
+ }
#ifdef DEBUG
if (flash_log_enabled) {
log_message(c64dtvflash_log, "loading ROM");
@@ -493,11 +503,15 @@
memcpy(c64dtvflash_mem + 0xd000, mem_chargen_rom,
C64_CHARGEN_ROM_SIZE);
}
- c64dtvflash_rom_loaded = retval;
return retval;
}
+static int c64dtvflash_load_rom(int idx)
+{
+ return c64dtvflash_rom_setup(idx);
+}
+
void c64dtvflash_init(void)
{
#ifdef DEBUG
@@ -506,6 +520,8 @@
}
#endif
+ rom_loaded = 1;
+
c64dtvflash_load_rom(c64dtvflash_revision); /* DTVFlashRevision */
#ifdef DEBUG
@@ -572,14 +588,11 @@
}
if (c64dtvflash_mem_rw && c64dtvflash_filename[idx] != NULL && *c64dtvflash_filename[idx] != '\0') {
+ /* flush (old) image */
if (util_file_save(c64dtvflash_filename[idx], c64dtvflash_mem, 0x200000) < 0) {
-#ifdef DEBUG
- log_message(c64dtvflash_log, "Writing C64DTV ROM image %s failed.", c64dtvflash_filename[idx]);
-#endif
+ log_error(c64dtvflash_log, "Writing C64DTV ROM image %s failed.", c64dtvflash_filename[idx]);
} else {
-#ifdef DEBUG
log_message(c64dtvflash_log, "Wrote C64DTV ROM image %s.", c64dtvflash_filename[idx]);
-#endif
}
}
@@ -598,6 +611,7 @@
lib_free(complete_path);
+ /* (re)load ROM */
if (c64dtvflash_filename[idx] != NULL && *c64dtvflash_filename[idx] != '\0') {
retval = c64dtvflash_load_rom(idx);
}
Modified: trunk/vice/src/c64dtv/c64dtvflash.h
===================================================================
--- trunk/vice/src/c64dtv/c64dtvflash.h 2025-08-31 13:34:57 UTC (rev 45745)
+++ trunk/vice/src/c64dtv/c64dtvflash.h 2025-09-01 19:07:14 UTC (rev 45746)
@@ -47,6 +47,4 @@
extern uint8_t c64dtvflash_mem_lock[];
extern uint8_t c64dtvflash_state;
-extern int c64dtvflash_rom_loaded;
-
#endif
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|