From ab11e37b5a4ee5c6148c4b9972342609d5be1017 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 15:10:49 +0000 Subject: [PATCH 001/118] Update build-ed64-example-rom.yml --- .github/workflows/build-ed64-example-rom.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 607a9776..d4a95398 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -14,11 +14,8 @@ jobs: - name: Install Libdragon container run: | sudo npm install -g libdragon - libdragon make - libdragon make install - libdragon make tools-install - # libdragon init - # libdragon install + libdragon init + libdragon install - name: Setup Build environment run: | From f5ecf7b7f0583b0bd09ead44e16a5beee309f485 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 15:17:26 +0000 Subject: [PATCH 002/118] Fix build warnings. --- ED64-XIO/src/bios.c | 2 +- ED64-XIO/src/sys.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ED64-XIO/src/bios.c b/ED64-XIO/src/bios.c index a69d4f91..532aeafd 100644 --- a/ED64-XIO/src/bios.c +++ b/ED64-XIO/src/bios.c @@ -121,7 +121,7 @@ void ed64_bios_init() { ed64_bios_rom_savetype_set(ED64_SAVE_OFF); /* Always successful for now */ - return 0; + //return 0; } /** diff --git a/ED64-XIO/src/sys.c b/ED64-XIO/src/sys.c index 6d69abb7..b948dde7 100644 --- a/ED64-XIO/src/sys.c +++ b/ED64-XIO/src/sys.c @@ -165,12 +165,12 @@ void sys_n64_pi_read(void *ram, unsigned long pi_address, unsigned long len) { data_cache_hit_writeback_invalidate(ram, len); disable_interrupts(); - while (dma_busy()); + while (dma_wait()); IO_WRITE(PI_STATUS_REG, 3); PI_regs->ram_address = ram; PI_regs->pi_address = pi_address; //(pi_address | 0x10000000) & 0x1FFFFFFF; PI_regs->write_length = len - 1; - while (dma_busy()); + while (dma_wait()); enable_interrupts(); } @@ -182,12 +182,12 @@ void sys_n64_pi_write(void *ram, unsigned long pi_address, unsigned long len) { data_cache_hit_writeback(ram, len); disable_interrupts(); - while (dma_busy()); + while (dma_wait()); IO_WRITE(PI_STATUS_REG, 3); PI_regs->ram_address = ram; PI_regs->pi_address = pi_address; //(pi_address | 0x10000000) & 0x1FFFFFFF; PI_regs->read_length = len - 1; - while (dma_busy()); + while (dma_wait()); enable_interrupts(); From 37f4424c5a55b9d7f0d4399235d70dbbad2d1ded Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 15:21:36 +0000 Subject: [PATCH 003/118] Further fix for dma_wait() --- ED64-XIO/src/sys.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ED64-XIO/src/sys.c b/ED64-XIO/src/sys.c index b948dde7..9c1f2750 100644 --- a/ED64-XIO/src/sys.c +++ b/ED64-XIO/src/sys.c @@ -165,12 +165,12 @@ void sys_n64_pi_read(void *ram, unsigned long pi_address, unsigned long len) { data_cache_hit_writeback_invalidate(ram, len); disable_interrupts(); - while (dma_wait()); + ma_wait(); IO_WRITE(PI_STATUS_REG, 3); PI_regs->ram_address = ram; PI_regs->pi_address = pi_address; //(pi_address | 0x10000000) & 0x1FFFFFFF; PI_regs->write_length = len - 1; - while (dma_wait()); + dma_wait(); enable_interrupts(); } @@ -182,12 +182,12 @@ void sys_n64_pi_write(void *ram, unsigned long pi_address, unsigned long len) { data_cache_hit_writeback(ram, len); disable_interrupts(); - while (dma_wait()); + dma_wait(); IO_WRITE(PI_STATUS_REG, 3); PI_regs->ram_address = ram; PI_regs->pi_address = pi_address; //(pi_address | 0x10000000) & 0x1FFFFFFF; PI_regs->read_length = len - 1; - while (dma_wait()); + dma_wait(); enable_interrupts(); From f18bd624bb3f2c5264da4fda57c8f4c7ef904ae9 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 15:23:28 +0000 Subject: [PATCH 004/118] Correct spelling in last commit. --- ED64-XIO/src/sys.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ED64-XIO/src/sys.c b/ED64-XIO/src/sys.c index 9c1f2750..9b8c7da7 100644 --- a/ED64-XIO/src/sys.c +++ b/ED64-XIO/src/sys.c @@ -165,7 +165,7 @@ void sys_n64_pi_read(void *ram, unsigned long pi_address, unsigned long len) { data_cache_hit_writeback_invalidate(ram, len); disable_interrupts(); - ma_wait(); + dma_wait(); IO_WRITE(PI_STATUS_REG, 3); PI_regs->ram_address = ram; PI_regs->pi_address = pi_address; //(pi_address | 0x10000000) & 0x1FFFFFFF; From d29caae64509f75ea8a7740fe0341136476a6030 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 15:36:53 +0000 Subject: [PATCH 005/118] try fatff weak import --- ED64-XIO/ff/diskio.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ED64-XIO/ff/diskio.h b/ED64-XIO/ff/diskio.h index fd84b0e6..25fb02a5 100644 --- a/ED64-XIO/ff/diskio.h +++ b/ED64-XIO/ff/diskio.h @@ -26,12 +26,12 @@ typedef enum { /* Prototypes for disk control functions */ -DSTATUS disk_initialize (BYTE pdrv); -DSTATUS disk_status (BYTE pdrv); -DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); -DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); -DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); -DWORD get_fattime (void); +DSTATUS disk_initialize (BYTE pdrv) __attribute__((weak_import)); +DSTATUS disk_status (BYTE pdrv) __attribute__((weak_import)); +DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count) __attribute__((weak_import)); +DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count) __attribute__((weak_import)); +DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff) __attribute__((weak_import)); +DWORD get_fattime (void) __attribute__((weak_import)); /* Disk Status Bits (DSTATUS) */ From 6e469911b8130e076fb13f3347257640ffab7d88 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 15:40:57 +0000 Subject: [PATCH 006/118] Use inbuilt libdragon fatFS? --- ED64-XIO/ff/diskio.c | 204 +++++++++++++++++++++---------------------- ED64-XIO/ff/diskio.h | 118 ++++++++++++------------- 2 files changed, 161 insertions(+), 161 deletions(-) diff --git a/ED64-XIO/ff/diskio.c b/ED64-XIO/ff/diskio.c index 6c4f61f5..f748dbed 100644 --- a/ED64-XIO/ff/diskio.c +++ b/ED64-XIO/ff/diskio.c @@ -1,138 +1,138 @@ -/*-----------------------------------------------------------------------*/ -/* Low level disk I/O module skeleton for FatFs (C)ChaN, 2016 */ -/*-----------------------------------------------------------------------*/ -/* If a working storage control module is available, it should be */ -/* attached to the FatFs via a glue function rather than modifying it. */ -/* This is an example of glue functions to attach various exsisting */ -/* storage control modules to the FatFs module with a defined API. */ -/*-----------------------------------------------------------------------*/ +// /*-----------------------------------------------------------------------*/ +// /* Low level disk I/O module skeleton for FatFs (C)ChaN, 2016 */ +// /*-----------------------------------------------------------------------*/ +// /* If a working storage control module is available, it should be */ +// /* attached to the FatFs via a glue function rather than modifying it. */ +// /* This is an example of glue functions to attach various exsisting */ +// /* storage control modules to the FatFs module with a defined API. */ +// /*-----------------------------------------------------------------------*/ -#include "ff.h" /* Obtains integer types */ -#include "diskio.h" /* Declarations of disk functions */ -#include "everdrive.h" +// #include "ff.h" /* Obtains integer types */ +// #include "diskio.h" /* Declarations of disk functions */ +// #include "everdrive.h" -/* Definitions of physical drive number for each drive */ -#define DEV_SD 0 /* Example: Map SD card to physical drive 0 */ -#define DEV_RAM 1 /* Example: Map Ramdisk to physical drive 1 */ -#define DEV_USB 2 /* Example: Map USB MSD to physical drive 2 */ +// /* Definitions of physical drive number for each drive */ +// #define DEV_SD 0 /* Example: Map SD card to physical drive 0 */ +// #define DEV_RAM 1 /* Example: Map Ramdisk to physical drive 1 */ +// #define DEV_USB 2 /* Example: Map USB MSD to physical drive 2 */ -//extern SD_HandleTypeDef hsd; -/*-----------------------------------------------------------------------*/ -/* Get Drive Status */ +// //extern SD_HandleTypeDef hsd; +// /*-----------------------------------------------------------------------*/ +// /* Get Drive Status */ -/*-----------------------------------------------------------------------*/ -DSTATUS dstat; -BYTE dresp; +// /*-----------------------------------------------------------------------*/ +// DSTATUS dstat; +// BYTE dresp; -DSTATUS disk_status( - BYTE pdrv /* Physical drive nmuber to identify the drive */ - ) { +// DSTATUS disk_status( +// BYTE pdrv /* Physical drive nmuber to identify the drive */ +// ) { - return dstat; -} +// return dstat; +// } -/*-----------------------------------------------------------------------*/ -/* Initialize a Drive */ +// /*-----------------------------------------------------------------------*/ +// /* Initialize a Drive */ -/*-----------------------------------------------------------------------*/ +// /*-----------------------------------------------------------------------*/ -DSTATUS disk_initialize( - BYTE pdrv /* Physical drive nmuber to identify the drive */ - ) { +// DSTATUS disk_initialize( +// BYTE pdrv /* Physical drive nmuber to identify the drive */ +// ) { - dresp = sd_disk_init(); - dstat = 0; - if (dresp)dstat = STA_NOINIT; +// dresp = sd_disk_init(); +// dstat = 0; +// if (dresp)dstat = STA_NOINIT; - return dstat; -} +// return dstat; +// } -/*-----------------------------------------------------------------------*/ -/* Read Sector(s) */ +// /*-----------------------------------------------------------------------*/ +// /* Read Sector(s) */ -/*-----------------------------------------------------------------------*/ +// /*-----------------------------------------------------------------------*/ -DRESULT disk_read( - BYTE pdrv, /* Physical drive nmuber to identify the drive */ - BYTE *buff, /* Data buffer to store read data */ - DWORD sector, /* Start sector in LBA */ - UINT count /* Number of sectors to read */ - ) { +// DRESULT disk_read( +// BYTE pdrv, /* Physical drive nmuber to identify the drive */ +// BYTE *buff, /* Data buffer to store read data */ +// DWORD sector, /* Start sector in LBA */ +// UINT count /* Number of sectors to read */ +// ) { - dresp = sd_disk_read(buff, sector, count); - if (dresp)return RES_ERROR; - return RES_OK; -} +// dresp = sd_disk_read(buff, sector, count); +// if (dresp)return RES_ERROR; +// return RES_OK; +// } -/*-----------------------------------------------------------------------*/ -/* Write Sector(s) */ -/*-----------------------------------------------------------------------*/ +// /*-----------------------------------------------------------------------*/ +// /* Write Sector(s) */ +// /*-----------------------------------------------------------------------*/ -#if FF_FS_READONLY == 0 +// #if FF_FS_READONLY == 0 -DRESULT disk_write( - BYTE pdrv, /* Physical drive nmuber to identify the drive */ - const BYTE *buff, /* Data to be written */ - DWORD sector, /* Start sector in LBA */ - UINT count /* Number of sectors to write */ - ) { +// DRESULT disk_write( +// BYTE pdrv, /* Physical drive nmuber to identify the drive */ +// const BYTE *buff, /* Data to be written */ +// DWORD sector, /* Start sector in LBA */ +// UINT count /* Number of sectors to write */ +// ) { - dresp = sd_disk_write((BYTE *) buff, sector, count); - if (dresp)return RES_ERROR; - return RES_OK; -} +// dresp = sd_disk_write((BYTE *) buff, sector, count); +// if (dresp)return RES_ERROR; +// return RES_OK; +// } -#endif +// #endif -/*-----------------------------------------------------------------------*/ -/* Miscellaneous Functions */ +// /*-----------------------------------------------------------------------*/ +// /* Miscellaneous Functions */ -/*-----------------------------------------------------------------------*/ +// /*-----------------------------------------------------------------------*/ -DRESULT disk_ioctl( - BYTE pdrv, /* Physical drive nmuber (0..) */ - BYTE cmd, /* Control code */ - void *buff /* Buffer to send/receive control data */ - ) { - DRESULT res = RES_ERROR; +// DRESULT disk_ioctl( +// BYTE pdrv, /* Physical drive nmuber (0..) */ +// BYTE cmd, /* Control code */ +// void *buff /* Buffer to send/receive control data */ +// ) { +// DRESULT res = RES_ERROR; - switch (cmd) { - case CTRL_SYNC: - res = sd_disk_close_rw(); - dresp = res; - res = res == 0 ? RES_OK : RES_ERROR; - break; +// switch (cmd) { +// case CTRL_SYNC: +// res = sd_disk_close_rw(); +// dresp = res; +// res = res == 0 ? RES_OK : RES_ERROR; +// break; - case GET_SECTOR_COUNT: - *(DWORD*) buff = 0; - res = RES_OK; - break; +// case GET_SECTOR_COUNT: +// *(DWORD*) buff = 0; +// res = RES_OK; +// break; - case GET_SECTOR_SIZE: - *(DWORD*) buff = 512; - res = RES_OK; - break; +// case GET_SECTOR_SIZE: +// *(DWORD*) buff = 512; +// res = RES_OK; +// break; - case GET_BLOCK_SIZE: - *(DWORD*) buff = 512; - res = RES_OK; - break; - } +// case GET_BLOCK_SIZE: +// *(DWORD*) buff = 512; +// res = RES_OK; +// break; +// } - return res; -} +// return res; +// } -DWORD get_fattime (void) -{ - //TODO: add ability to use the X7 or V3 RTC. - return ((DWORD)(FF_NORTC_YEAR - 1980) << 25 | - (DWORD)FF_NORTC_MON << 21 | - (DWORD)FF_NORTC_MDAY << 16); -} +// DWORD get_fattime (void) +// { +// //TODO: add ability to use the X7 or V3 RTC. +// return ((DWORD)(FF_NORTC_YEAR - 1980) << 25 | +// (DWORD)FF_NORTC_MON << 21 | +// (DWORD)FF_NORTC_MDAY << 16); +// } diff --git a/ED64-XIO/ff/diskio.h b/ED64-XIO/ff/diskio.h index 25fb02a5..8d5742cc 100644 --- a/ED64-XIO/ff/diskio.h +++ b/ED64-XIO/ff/diskio.h @@ -1,78 +1,78 @@ -/*-----------------------------------------------------------------------/ -/ Low level disk interface modlue include file (C)ChaN, 2019 / -/-----------------------------------------------------------------------*/ +// /*-----------------------------------------------------------------------/ +// / Low level disk interface modlue include file (C)ChaN, 2019 / +// /-----------------------------------------------------------------------*/ -#ifndef _DISKIO_DEFINED -#define _DISKIO_DEFINED +// #ifndef _DISKIO_DEFINED +// #define _DISKIO_DEFINED -#ifdef __cplusplus -extern "C" { -#endif +// #ifdef __cplusplus +// extern "C" { +// #endif -/* Status of Disk Functions */ -typedef BYTE DSTATUS; +// /* Status of Disk Functions */ +// typedef BYTE DSTATUS; -/* Results of Disk Functions */ -typedef enum { - RES_OK = 0, /* 0: Successful */ - RES_ERROR, /* 1: R/W Error */ - RES_WRPRT, /* 2: Write Protected */ - RES_NOTRDY, /* 3: Not Ready */ - RES_PARERR /* 4: Invalid Parameter */ -} DRESULT; +// /* Results of Disk Functions */ +// typedef enum { +// RES_OK = 0, /* 0: Successful */ +// RES_ERROR, /* 1: R/W Error */ +// RES_WRPRT, /* 2: Write Protected */ +// RES_NOTRDY, /* 3: Not Ready */ +// RES_PARERR /* 4: Invalid Parameter */ +// } DRESULT; -/*---------------------------------------*/ -/* Prototypes for disk control functions */ +// /*---------------------------------------*/ +// /* Prototypes for disk control functions */ -DSTATUS disk_initialize (BYTE pdrv) __attribute__((weak_import)); -DSTATUS disk_status (BYTE pdrv) __attribute__((weak_import)); -DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count) __attribute__((weak_import)); -DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count) __attribute__((weak_import)); -DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff) __attribute__((weak_import)); -DWORD get_fattime (void) __attribute__((weak_import)); +// DSTATUS disk_initialize (BYTE pdrv); +// DSTATUS disk_status (BYTE pdrv); +// DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); +// DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); +// DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); +// DWORD get_fattime (void); -/* Disk Status Bits (DSTATUS) */ +// /* Disk Status Bits (DSTATUS) */ -#define STA_NOINIT 0x01 /* Drive not initialized */ -#define STA_NODISK 0x02 /* No medium in the drive */ -#define STA_PROTECT 0x04 /* Write protected */ +// #define STA_NOINIT 0x01 /* Drive not initialized */ +// #define STA_NODISK 0x02 /* No medium in the drive */ +// #define STA_PROTECT 0x04 /* Write protected */ -/* Command code for disk_ioctrl fucntion */ +// /* Command code for disk_ioctrl fucntion */ -/* Generic command (Used by FatFs) */ -#define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ -#define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ -#define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ -#define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ -#define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ +// /* Generic command (Used by FatFs) */ +// #define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ +// #define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ +// #define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ +// #define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ +// #define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ -/* Generic command (Not used by FatFs) */ -#define CTRL_POWER 5 /* Get/Set power status */ -#define CTRL_LOCK 6 /* Lock/Unlock media removal */ -#define CTRL_EJECT 7 /* Eject media */ -#define CTRL_FORMAT 8 /* Create physical format on the media */ +// /* Generic command (Not used by FatFs) */ +// #define CTRL_POWER 5 /* Get/Set power status */ +// #define CTRL_LOCK 6 /* Lock/Unlock media removal */ +// #define CTRL_EJECT 7 /* Eject media */ +// #define CTRL_FORMAT 8 /* Create physical format on the media */ -/* MMC/SDC specific ioctl command */ -#define MMC_GET_TYPE 10 /* Get card type */ -#define MMC_GET_CSD 11 /* Get CSD */ -#define MMC_GET_CID 12 /* Get CID */ -#define MMC_GET_OCR 13 /* Get OCR */ -#define MMC_GET_SDSTAT 14 /* Get SD status */ -#define ISDIO_READ 55 /* Read data form SD iSDIO register */ -#define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ -#define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ +// /* MMC/SDC specific ioctl command */ +// #define MMC_GET_TYPE 10 /* Get card type */ +// #define MMC_GET_CSD 11 /* Get CSD */ +// #define MMC_GET_CID 12 /* Get CID */ +// #define MMC_GET_OCR 13 /* Get OCR */ +// #define MMC_GET_SDSTAT 14 /* Get SD status */ +// #define ISDIO_READ 55 /* Read data form SD iSDIO register */ +// #define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ +// #define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ -/* ATA/CF specific ioctl command */ -#define ATA_GET_REV 20 /* Get F/W revision */ -#define ATA_GET_MODEL 21 /* Get model name */ -#define ATA_GET_SN 22 /* Get serial number */ +// /* ATA/CF specific ioctl command */ +// #define ATA_GET_REV 20 /* Get F/W revision */ +// #define ATA_GET_MODEL 21 /* Get model name */ +// #define ATA_GET_SN 22 /* Get serial number */ -#ifdef __cplusplus -} -#endif +// #ifdef __cplusplus +// } +// #endif -#endif +// #endif From 00276964ec405c0bfd122d4cc5c6a33681016482 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 15:45:21 +0000 Subject: [PATCH 007/118] Try only diskio.h commented out. --- ED64-XIO/ff/diskio.c | 204 +++++++++++++++++++++---------------------- 1 file changed, 102 insertions(+), 102 deletions(-) diff --git a/ED64-XIO/ff/diskio.c b/ED64-XIO/ff/diskio.c index f748dbed..6c4f61f5 100644 --- a/ED64-XIO/ff/diskio.c +++ b/ED64-XIO/ff/diskio.c @@ -1,138 +1,138 @@ -// /*-----------------------------------------------------------------------*/ -// /* Low level disk I/O module skeleton for FatFs (C)ChaN, 2016 */ -// /*-----------------------------------------------------------------------*/ -// /* If a working storage control module is available, it should be */ -// /* attached to the FatFs via a glue function rather than modifying it. */ -// /* This is an example of glue functions to attach various exsisting */ -// /* storage control modules to the FatFs module with a defined API. */ -// /*-----------------------------------------------------------------------*/ +/*-----------------------------------------------------------------------*/ +/* Low level disk I/O module skeleton for FatFs (C)ChaN, 2016 */ +/*-----------------------------------------------------------------------*/ +/* If a working storage control module is available, it should be */ +/* attached to the FatFs via a glue function rather than modifying it. */ +/* This is an example of glue functions to attach various exsisting */ +/* storage control modules to the FatFs module with a defined API. */ +/*-----------------------------------------------------------------------*/ -// #include "ff.h" /* Obtains integer types */ -// #include "diskio.h" /* Declarations of disk functions */ -// #include "everdrive.h" +#include "ff.h" /* Obtains integer types */ +#include "diskio.h" /* Declarations of disk functions */ +#include "everdrive.h" -// /* Definitions of physical drive number for each drive */ -// #define DEV_SD 0 /* Example: Map SD card to physical drive 0 */ -// #define DEV_RAM 1 /* Example: Map Ramdisk to physical drive 1 */ -// #define DEV_USB 2 /* Example: Map USB MSD to physical drive 2 */ +/* Definitions of physical drive number for each drive */ +#define DEV_SD 0 /* Example: Map SD card to physical drive 0 */ +#define DEV_RAM 1 /* Example: Map Ramdisk to physical drive 1 */ +#define DEV_USB 2 /* Example: Map USB MSD to physical drive 2 */ -// //extern SD_HandleTypeDef hsd; -// /*-----------------------------------------------------------------------*/ -// /* Get Drive Status */ +//extern SD_HandleTypeDef hsd; +/*-----------------------------------------------------------------------*/ +/* Get Drive Status */ -// /*-----------------------------------------------------------------------*/ -// DSTATUS dstat; -// BYTE dresp; +/*-----------------------------------------------------------------------*/ +DSTATUS dstat; +BYTE dresp; -// DSTATUS disk_status( -// BYTE pdrv /* Physical drive nmuber to identify the drive */ -// ) { +DSTATUS disk_status( + BYTE pdrv /* Physical drive nmuber to identify the drive */ + ) { -// return dstat; -// } + return dstat; +} -// /*-----------------------------------------------------------------------*/ -// /* Initialize a Drive */ +/*-----------------------------------------------------------------------*/ +/* Initialize a Drive */ -// /*-----------------------------------------------------------------------*/ +/*-----------------------------------------------------------------------*/ -// DSTATUS disk_initialize( -// BYTE pdrv /* Physical drive nmuber to identify the drive */ -// ) { +DSTATUS disk_initialize( + BYTE pdrv /* Physical drive nmuber to identify the drive */ + ) { -// dresp = sd_disk_init(); -// dstat = 0; -// if (dresp)dstat = STA_NOINIT; + dresp = sd_disk_init(); + dstat = 0; + if (dresp)dstat = STA_NOINIT; -// return dstat; -// } + return dstat; +} -// /*-----------------------------------------------------------------------*/ -// /* Read Sector(s) */ +/*-----------------------------------------------------------------------*/ +/* Read Sector(s) */ -// /*-----------------------------------------------------------------------*/ +/*-----------------------------------------------------------------------*/ -// DRESULT disk_read( -// BYTE pdrv, /* Physical drive nmuber to identify the drive */ -// BYTE *buff, /* Data buffer to store read data */ -// DWORD sector, /* Start sector in LBA */ -// UINT count /* Number of sectors to read */ -// ) { +DRESULT disk_read( + BYTE pdrv, /* Physical drive nmuber to identify the drive */ + BYTE *buff, /* Data buffer to store read data */ + DWORD sector, /* Start sector in LBA */ + UINT count /* Number of sectors to read */ + ) { -// dresp = sd_disk_read(buff, sector, count); -// if (dresp)return RES_ERROR; -// return RES_OK; -// } + dresp = sd_disk_read(buff, sector, count); + if (dresp)return RES_ERROR; + return RES_OK; +} -// /*-----------------------------------------------------------------------*/ -// /* Write Sector(s) */ -// /*-----------------------------------------------------------------------*/ +/*-----------------------------------------------------------------------*/ +/* Write Sector(s) */ +/*-----------------------------------------------------------------------*/ -// #if FF_FS_READONLY == 0 +#if FF_FS_READONLY == 0 -// DRESULT disk_write( -// BYTE pdrv, /* Physical drive nmuber to identify the drive */ -// const BYTE *buff, /* Data to be written */ -// DWORD sector, /* Start sector in LBA */ -// UINT count /* Number of sectors to write */ -// ) { +DRESULT disk_write( + BYTE pdrv, /* Physical drive nmuber to identify the drive */ + const BYTE *buff, /* Data to be written */ + DWORD sector, /* Start sector in LBA */ + UINT count /* Number of sectors to write */ + ) { -// dresp = sd_disk_write((BYTE *) buff, sector, count); -// if (dresp)return RES_ERROR; -// return RES_OK; -// } + dresp = sd_disk_write((BYTE *) buff, sector, count); + if (dresp)return RES_ERROR; + return RES_OK; +} -// #endif +#endif -// /*-----------------------------------------------------------------------*/ -// /* Miscellaneous Functions */ +/*-----------------------------------------------------------------------*/ +/* Miscellaneous Functions */ -// /*-----------------------------------------------------------------------*/ +/*-----------------------------------------------------------------------*/ -// DRESULT disk_ioctl( -// BYTE pdrv, /* Physical drive nmuber (0..) */ -// BYTE cmd, /* Control code */ -// void *buff /* Buffer to send/receive control data */ -// ) { -// DRESULT res = RES_ERROR; +DRESULT disk_ioctl( + BYTE pdrv, /* Physical drive nmuber (0..) */ + BYTE cmd, /* Control code */ + void *buff /* Buffer to send/receive control data */ + ) { + DRESULT res = RES_ERROR; -// switch (cmd) { -// case CTRL_SYNC: -// res = sd_disk_close_rw(); -// dresp = res; -// res = res == 0 ? RES_OK : RES_ERROR; -// break; + switch (cmd) { + case CTRL_SYNC: + res = sd_disk_close_rw(); + dresp = res; + res = res == 0 ? RES_OK : RES_ERROR; + break; -// case GET_SECTOR_COUNT: -// *(DWORD*) buff = 0; -// res = RES_OK; -// break; + case GET_SECTOR_COUNT: + *(DWORD*) buff = 0; + res = RES_OK; + break; -// case GET_SECTOR_SIZE: -// *(DWORD*) buff = 512; -// res = RES_OK; -// break; + case GET_SECTOR_SIZE: + *(DWORD*) buff = 512; + res = RES_OK; + break; -// case GET_BLOCK_SIZE: -// *(DWORD*) buff = 512; -// res = RES_OK; -// break; -// } + case GET_BLOCK_SIZE: + *(DWORD*) buff = 512; + res = RES_OK; + break; + } -// return res; -// } + return res; +} -// DWORD get_fattime (void) -// { -// //TODO: add ability to use the X7 or V3 RTC. -// return ((DWORD)(FF_NORTC_YEAR - 1980) << 25 | -// (DWORD)FF_NORTC_MON << 21 | -// (DWORD)FF_NORTC_MDAY << 16); -// } +DWORD get_fattime (void) +{ + //TODO: add ability to use the X7 or V3 RTC. + return ((DWORD)(FF_NORTC_YEAR - 1980) << 25 | + (DWORD)FF_NORTC_MON << 21 | + (DWORD)FF_NORTC_MDAY << 16); +} From d175b6f714f78175b6c468be05ee9f26d03d3b12 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 17:05:50 +0000 Subject: [PATCH 008/118] Add NDEBUG flag to exclude libdragon SD support for moment. --- ED64-XIO/Makefile | 2 +- ED64-XIO/ff/diskio.h | 118 +++++++++++++++++++++---------------------- 2 files changed, 60 insertions(+), 60 deletions(-) diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index 0c9fbe7c..d71a839a 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -38,7 +38,7 @@ HEADERTITLE = $(PROG_NAME) LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld ASFLAGS := -mtune=vr4300 -march=vr4300 -CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) +CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) -NDEBUG SOURCES_ASM := $(wildcard $(SRCDIR)/*.s) SOURCES := $(wildcard $(SRCDIR)/*.c) diff --git a/ED64-XIO/ff/diskio.h b/ED64-XIO/ff/diskio.h index 8d5742cc..fd84b0e6 100644 --- a/ED64-XIO/ff/diskio.h +++ b/ED64-XIO/ff/diskio.h @@ -1,78 +1,78 @@ -// /*-----------------------------------------------------------------------/ -// / Low level disk interface modlue include file (C)ChaN, 2019 / -// /-----------------------------------------------------------------------*/ +/*-----------------------------------------------------------------------/ +/ Low level disk interface modlue include file (C)ChaN, 2019 / +/-----------------------------------------------------------------------*/ -// #ifndef _DISKIO_DEFINED -// #define _DISKIO_DEFINED +#ifndef _DISKIO_DEFINED +#define _DISKIO_DEFINED -// #ifdef __cplusplus -// extern "C" { -// #endif +#ifdef __cplusplus +extern "C" { +#endif -// /* Status of Disk Functions */ -// typedef BYTE DSTATUS; +/* Status of Disk Functions */ +typedef BYTE DSTATUS; -// /* Results of Disk Functions */ -// typedef enum { -// RES_OK = 0, /* 0: Successful */ -// RES_ERROR, /* 1: R/W Error */ -// RES_WRPRT, /* 2: Write Protected */ -// RES_NOTRDY, /* 3: Not Ready */ -// RES_PARERR /* 4: Invalid Parameter */ -// } DRESULT; +/* Results of Disk Functions */ +typedef enum { + RES_OK = 0, /* 0: Successful */ + RES_ERROR, /* 1: R/W Error */ + RES_WRPRT, /* 2: Write Protected */ + RES_NOTRDY, /* 3: Not Ready */ + RES_PARERR /* 4: Invalid Parameter */ +} DRESULT; -// /*---------------------------------------*/ -// /* Prototypes for disk control functions */ +/*---------------------------------------*/ +/* Prototypes for disk control functions */ -// DSTATUS disk_initialize (BYTE pdrv); -// DSTATUS disk_status (BYTE pdrv); -// DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); -// DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); -// DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); -// DWORD get_fattime (void); +DSTATUS disk_initialize (BYTE pdrv); +DSTATUS disk_status (BYTE pdrv); +DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); +DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); +DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); +DWORD get_fattime (void); -// /* Disk Status Bits (DSTATUS) */ +/* Disk Status Bits (DSTATUS) */ -// #define STA_NOINIT 0x01 /* Drive not initialized */ -// #define STA_NODISK 0x02 /* No medium in the drive */ -// #define STA_PROTECT 0x04 /* Write protected */ +#define STA_NOINIT 0x01 /* Drive not initialized */ +#define STA_NODISK 0x02 /* No medium in the drive */ +#define STA_PROTECT 0x04 /* Write protected */ -// /* Command code for disk_ioctrl fucntion */ +/* Command code for disk_ioctrl fucntion */ -// /* Generic command (Used by FatFs) */ -// #define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ -// #define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ -// #define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ -// #define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ -// #define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ +/* Generic command (Used by FatFs) */ +#define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ +#define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ +#define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ +#define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ +#define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ -// /* Generic command (Not used by FatFs) */ -// #define CTRL_POWER 5 /* Get/Set power status */ -// #define CTRL_LOCK 6 /* Lock/Unlock media removal */ -// #define CTRL_EJECT 7 /* Eject media */ -// #define CTRL_FORMAT 8 /* Create physical format on the media */ +/* Generic command (Not used by FatFs) */ +#define CTRL_POWER 5 /* Get/Set power status */ +#define CTRL_LOCK 6 /* Lock/Unlock media removal */ +#define CTRL_EJECT 7 /* Eject media */ +#define CTRL_FORMAT 8 /* Create physical format on the media */ -// /* MMC/SDC specific ioctl command */ -// #define MMC_GET_TYPE 10 /* Get card type */ -// #define MMC_GET_CSD 11 /* Get CSD */ -// #define MMC_GET_CID 12 /* Get CID */ -// #define MMC_GET_OCR 13 /* Get OCR */ -// #define MMC_GET_SDSTAT 14 /* Get SD status */ -// #define ISDIO_READ 55 /* Read data form SD iSDIO register */ -// #define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ -// #define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ +/* MMC/SDC specific ioctl command */ +#define MMC_GET_TYPE 10 /* Get card type */ +#define MMC_GET_CSD 11 /* Get CSD */ +#define MMC_GET_CID 12 /* Get CID */ +#define MMC_GET_OCR 13 /* Get OCR */ +#define MMC_GET_SDSTAT 14 /* Get SD status */ +#define ISDIO_READ 55 /* Read data form SD iSDIO register */ +#define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ +#define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ -// /* ATA/CF specific ioctl command */ -// #define ATA_GET_REV 20 /* Get F/W revision */ -// #define ATA_GET_MODEL 21 /* Get model name */ -// #define ATA_GET_SN 22 /* Get serial number */ +/* ATA/CF specific ioctl command */ +#define ATA_GET_REV 20 /* Get F/W revision */ +#define ATA_GET_MODEL 21 /* Get model name */ +#define ATA_GET_SN 22 /* Get serial number */ -// #ifdef __cplusplus -// } -// #endif +#ifdef __cplusplus +} +#endif -// #endif +#endif From df0558430d78c5e37d17c35281e151783dd6640c Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 17:12:23 +0000 Subject: [PATCH 009/118] Fix for last commit --- ED64-XIO/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index d71a839a..82b26049 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -35,10 +35,10 @@ HEADERDIR :=$(ROOTDIR)/mips64-elf/lib HEADERNAME = header HEADERTITLE = $(PROG_NAME) -LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld +LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld -DNDEBUG ASFLAGS := -mtune=vr4300 -march=vr4300 -CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) -NDEBUG +CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) SOURCES_ASM := $(wildcard $(SRCDIR)/*.s) SOURCES := $(wildcard $(SRCDIR)/*.c) From 6f0ebd4297d315fd6e804912e78cf9c045a718e8 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 17:15:03 +0000 Subject: [PATCH 010/118] Double fix for libdragon debug flag. --- ED64-XIO/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index 82b26049..38d59539 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -35,10 +35,10 @@ HEADERDIR :=$(ROOTDIR)/mips64-elf/lib HEADERNAME = header HEADERTITLE = $(PROG_NAME) -LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld -DNDEBUG +LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld ASFLAGS := -mtune=vr4300 -march=vr4300 -CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) +CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) -DNDEBUG SOURCES_ASM := $(wildcard $(SRCDIR)/*.s) SOURCES := $(wildcard $(SRCDIR)/*.c) From 50115e5e8700aa2324e0ccc87d31408e66dba79d Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 17:21:30 +0000 Subject: [PATCH 011/118] Use libdragon diskio def? --- ED64-XIO/ff/diskio.h | 118 +++++++++++++++++++++---------------------- 1 file changed, 59 insertions(+), 59 deletions(-) diff --git a/ED64-XIO/ff/diskio.h b/ED64-XIO/ff/diskio.h index fd84b0e6..8d5742cc 100644 --- a/ED64-XIO/ff/diskio.h +++ b/ED64-XIO/ff/diskio.h @@ -1,78 +1,78 @@ -/*-----------------------------------------------------------------------/ -/ Low level disk interface modlue include file (C)ChaN, 2019 / -/-----------------------------------------------------------------------*/ +// /*-----------------------------------------------------------------------/ +// / Low level disk interface modlue include file (C)ChaN, 2019 / +// /-----------------------------------------------------------------------*/ -#ifndef _DISKIO_DEFINED -#define _DISKIO_DEFINED +// #ifndef _DISKIO_DEFINED +// #define _DISKIO_DEFINED -#ifdef __cplusplus -extern "C" { -#endif +// #ifdef __cplusplus +// extern "C" { +// #endif -/* Status of Disk Functions */ -typedef BYTE DSTATUS; +// /* Status of Disk Functions */ +// typedef BYTE DSTATUS; -/* Results of Disk Functions */ -typedef enum { - RES_OK = 0, /* 0: Successful */ - RES_ERROR, /* 1: R/W Error */ - RES_WRPRT, /* 2: Write Protected */ - RES_NOTRDY, /* 3: Not Ready */ - RES_PARERR /* 4: Invalid Parameter */ -} DRESULT; +// /* Results of Disk Functions */ +// typedef enum { +// RES_OK = 0, /* 0: Successful */ +// RES_ERROR, /* 1: R/W Error */ +// RES_WRPRT, /* 2: Write Protected */ +// RES_NOTRDY, /* 3: Not Ready */ +// RES_PARERR /* 4: Invalid Parameter */ +// } DRESULT; -/*---------------------------------------*/ -/* Prototypes for disk control functions */ +// /*---------------------------------------*/ +// /* Prototypes for disk control functions */ -DSTATUS disk_initialize (BYTE pdrv); -DSTATUS disk_status (BYTE pdrv); -DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); -DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); -DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); -DWORD get_fattime (void); +// DSTATUS disk_initialize (BYTE pdrv); +// DSTATUS disk_status (BYTE pdrv); +// DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); +// DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); +// DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); +// DWORD get_fattime (void); -/* Disk Status Bits (DSTATUS) */ +// /* Disk Status Bits (DSTATUS) */ -#define STA_NOINIT 0x01 /* Drive not initialized */ -#define STA_NODISK 0x02 /* No medium in the drive */ -#define STA_PROTECT 0x04 /* Write protected */ +// #define STA_NOINIT 0x01 /* Drive not initialized */ +// #define STA_NODISK 0x02 /* No medium in the drive */ +// #define STA_PROTECT 0x04 /* Write protected */ -/* Command code for disk_ioctrl fucntion */ +// /* Command code for disk_ioctrl fucntion */ -/* Generic command (Used by FatFs) */ -#define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ -#define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ -#define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ -#define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ -#define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ +// /* Generic command (Used by FatFs) */ +// #define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ +// #define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ +// #define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ +// #define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ +// #define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ -/* Generic command (Not used by FatFs) */ -#define CTRL_POWER 5 /* Get/Set power status */ -#define CTRL_LOCK 6 /* Lock/Unlock media removal */ -#define CTRL_EJECT 7 /* Eject media */ -#define CTRL_FORMAT 8 /* Create physical format on the media */ +// /* Generic command (Not used by FatFs) */ +// #define CTRL_POWER 5 /* Get/Set power status */ +// #define CTRL_LOCK 6 /* Lock/Unlock media removal */ +// #define CTRL_EJECT 7 /* Eject media */ +// #define CTRL_FORMAT 8 /* Create physical format on the media */ -/* MMC/SDC specific ioctl command */ -#define MMC_GET_TYPE 10 /* Get card type */ -#define MMC_GET_CSD 11 /* Get CSD */ -#define MMC_GET_CID 12 /* Get CID */ -#define MMC_GET_OCR 13 /* Get OCR */ -#define MMC_GET_SDSTAT 14 /* Get SD status */ -#define ISDIO_READ 55 /* Read data form SD iSDIO register */ -#define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ -#define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ +// /* MMC/SDC specific ioctl command */ +// #define MMC_GET_TYPE 10 /* Get card type */ +// #define MMC_GET_CSD 11 /* Get CSD */ +// #define MMC_GET_CID 12 /* Get CID */ +// #define MMC_GET_OCR 13 /* Get OCR */ +// #define MMC_GET_SDSTAT 14 /* Get SD status */ +// #define ISDIO_READ 55 /* Read data form SD iSDIO register */ +// #define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ +// #define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ -/* ATA/CF specific ioctl command */ -#define ATA_GET_REV 20 /* Get F/W revision */ -#define ATA_GET_MODEL 21 /* Get model name */ -#define ATA_GET_SN 22 /* Get serial number */ +// /* ATA/CF specific ioctl command */ +// #define ATA_GET_REV 20 /* Get F/W revision */ +// #define ATA_GET_MODEL 21 /* Get model name */ +// #define ATA_GET_SN 22 /* Get serial number */ -#ifdef __cplusplus -} -#endif +// #ifdef __cplusplus +// } +// #endif -#endif +// #endif From f07a29027336f405e5c23df9024b887b8e90d5ec Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 17:56:37 +0000 Subject: [PATCH 012/118] Uncomment diskio --- ED64-XIO/ff/diskio.h | 118 +++++++++++++++++++++---------------------- 1 file changed, 59 insertions(+), 59 deletions(-) diff --git a/ED64-XIO/ff/diskio.h b/ED64-XIO/ff/diskio.h index 8d5742cc..ca5092e9 100644 --- a/ED64-XIO/ff/diskio.h +++ b/ED64-XIO/ff/diskio.h @@ -1,78 +1,78 @@ -// /*-----------------------------------------------------------------------/ -// / Low level disk interface modlue include file (C)ChaN, 2019 / -// /-----------------------------------------------------------------------*/ +/*-----------------------------------------------------------------------/ +/ Low level disk interface module include file (C)ChaN, 2019 / +/-----------------------------------------------------------------------*/ -// #ifndef _DISKIO_DEFINED -// #define _DISKIO_DEFINED +#ifndef _DISKIO_DEFINED +#define _DISKIO_DEFINED -// #ifdef __cplusplus -// extern "C" { -// #endif +#ifdef __cplusplus +extern "C" { +#endif -// /* Status of Disk Functions */ -// typedef BYTE DSTATUS; +/* Status of Disk Functions */ +typedef BYTE DSTATUS; -// /* Results of Disk Functions */ -// typedef enum { -// RES_OK = 0, /* 0: Successful */ -// RES_ERROR, /* 1: R/W Error */ -// RES_WRPRT, /* 2: Write Protected */ -// RES_NOTRDY, /* 3: Not Ready */ -// RES_PARERR /* 4: Invalid Parameter */ -// } DRESULT; +/* Results of Disk Functions */ +typedef enum { + RES_OK = 0, /* 0: Successful */ + RES_ERROR, /* 1: R/W Error */ + RES_WRPRT, /* 2: Write Protected */ + RES_NOTRDY, /* 3: Not Ready */ + RES_PARERR /* 4: Invalid Parameter */ +} DRESULT; -// /*---------------------------------------*/ -// /* Prototypes for disk control functions */ +/*---------------------------------------*/ +/* Prototypes for disk control functions */ -// DSTATUS disk_initialize (BYTE pdrv); -// DSTATUS disk_status (BYTE pdrv); -// DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); -// DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); -// DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); -// DWORD get_fattime (void); +DSTATUS disk_initialize (BYTE pdrv); +DSTATUS disk_status (BYTE pdrv); +DRESULT disk_read (BYTE pdrv, BYTE* buff, LBA_t sector, UINT count); +DRESULT disk_write (BYTE pdrv, const BYTE* buff, LBA_t sector, UINT count); +DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff); +DWORD get_fattime (void); -// /* Disk Status Bits (DSTATUS) */ +/* Disk Status Bits (DSTATUS) */ -// #define STA_NOINIT 0x01 /* Drive not initialized */ -// #define STA_NODISK 0x02 /* No medium in the drive */ -// #define STA_PROTECT 0x04 /* Write protected */ +#define STA_NOINIT 0x01 /* Drive not initialized */ +#define STA_NODISK 0x02 /* No medium in the drive */ +#define STA_PROTECT 0x04 /* Write protected */ -// /* Command code for disk_ioctrl fucntion */ +/* Command code for disk_ioctrl fucntion */ -// /* Generic command (Used by FatFs) */ -// #define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ -// #define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ -// #define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ -// #define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ -// #define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ +/* Generic command (Used by FatFs) */ +#define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */ +#define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */ +#define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS) */ +#define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */ +#define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */ -// /* Generic command (Not used by FatFs) */ -// #define CTRL_POWER 5 /* Get/Set power status */ -// #define CTRL_LOCK 6 /* Lock/Unlock media removal */ -// #define CTRL_EJECT 7 /* Eject media */ -// #define CTRL_FORMAT 8 /* Create physical format on the media */ +/* Generic command (Not used by FatFs) */ +#define CTRL_POWER 5 /* Get/Set power status */ +#define CTRL_LOCK 6 /* Lock/Unlock media removal */ +#define CTRL_EJECT 7 /* Eject media */ +#define CTRL_FORMAT 8 /* Create physical format on the media */ -// /* MMC/SDC specific ioctl command */ -// #define MMC_GET_TYPE 10 /* Get card type */ -// #define MMC_GET_CSD 11 /* Get CSD */ -// #define MMC_GET_CID 12 /* Get CID */ -// #define MMC_GET_OCR 13 /* Get OCR */ -// #define MMC_GET_SDSTAT 14 /* Get SD status */ -// #define ISDIO_READ 55 /* Read data form SD iSDIO register */ -// #define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ -// #define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ +/* MMC/SDC specific ioctl command */ +#define MMC_GET_TYPE 10 /* Get card type */ +#define MMC_GET_CSD 11 /* Get CSD */ +#define MMC_GET_CID 12 /* Get CID */ +#define MMC_GET_OCR 13 /* Get OCR */ +#define MMC_GET_SDSTAT 14 /* Get SD status */ +#define ISDIO_READ 55 /* Read data form SD iSDIO register */ +#define ISDIO_WRITE 56 /* Write data to SD iSDIO register */ +#define ISDIO_MRITE 57 /* Masked write data to SD iSDIO register */ -// /* ATA/CF specific ioctl command */ -// #define ATA_GET_REV 20 /* Get F/W revision */ -// #define ATA_GET_MODEL 21 /* Get model name */ -// #define ATA_GET_SN 22 /* Get serial number */ +/* ATA/CF specific ioctl command */ +#define ATA_GET_REV 20 /* Get F/W revision */ +#define ATA_GET_MODEL 21 /* Get model name */ +#define ATA_GET_SN 22 /* Get serial number */ -// #ifdef __cplusplus -// } -// #endif +#ifdef __cplusplus +} +#endif -// #endif +#endif From 994756456ca9536c5a21603621bf0132dbe537cc Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 18:53:49 +0000 Subject: [PATCH 013/118] Add no debug to libdragon build in CI? --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index d4a95398..dea11f91 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon install + libdragon install -DNDEBUG - name: Setup Build environment run: | From d2358aa1f3386c0877d40332c8232fba0e5efd44 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 18:56:17 +0000 Subject: [PATCH 014/118] Revert last commit. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index dea11f91..d4a95398 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon install -DNDEBUG + libdragon install - name: Setup Build environment run: | From 14d6fcf886b9321ca878ad699e599066b3567ec8 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:29:00 +0000 Subject: [PATCH 015/118] Try specific commands for libdragon make. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index d4a95398..1c958293 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon install + libdragon -- make lidragon -DNDEBUG - name: Setup Build environment run: | From 837e07a61a7a21a5a4fb096cfdcc6d06e1c7a511 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:30:15 +0000 Subject: [PATCH 016/118] Fix spelling --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 1c958293..a5194bb6 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon -- make lidragon -DNDEBUG + libdragon -- make libdragon -DNDEBUG - name: Setup Build environment run: | From c41ca22edfa23f93a29fed35198d18791c04b701 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:32:28 +0000 Subject: [PATCH 017/118] try without hyphens --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index a5194bb6..4e14dfa6 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon -- make libdragon -DNDEBUG + libdragon make libdragon -DNDEBUG - name: Setup Build environment run: | From 09257e8fb5cc27d6878755c118bad56fd93a238f Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:38:25 +0000 Subject: [PATCH 018/118] No flags (not cmake). --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 4e14dfa6..7fc57c7a 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon make libdragon -DNDEBUG + libdragon make libdragon NDEBUG - name: Setup Build environment run: | From 052e86bea749d4d636d89810e5da70f37ab10fbb Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:40:59 +0000 Subject: [PATCH 019/118] with flags... --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 7fc57c7a..22ef71c4 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon make libdragon NDEBUG + libdragon -- make libdragon NDEBUG - name: Setup Build environment run: | From 8bbb114bf347b01b2c4496987b903afafc29eda0 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:47:46 +0000 Subject: [PATCH 020/118] try again. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 22ef71c4..e24e06a7 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon -- make libdragon NDEBUG + libdragon -- make libdragon -NDEBUG - name: Setup Build environment run: | From 102cbc6f02feffd13c7b7cafca2b936a838e7621 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:50:34 +0000 Subject: [PATCH 021/118] try with folder --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index e24e06a7..6e2eacb1 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon -- make libdragon -NDEBUG + libdragon -- make ./libdragon NDEBUG - name: Setup Build environment run: | From 2faaff464240d9e58066d119b92c55509f431650 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 19:59:09 +0000 Subject: [PATCH 022/118] try within folder --- .github/workflows/build-ed64-example-rom.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 6e2eacb1..2d154898 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,7 +15,11 @@ jobs: run: | sudo npm install -g libdragon libdragon init - libdragon -- make ./libdragon NDEBUG + cd ./.libdragon + ls + libdragon make NDEBUG + cd .. + - name: Setup Build environment run: | From 6a04ac32aa019cd7732cd112f20fa08af9c7ecf4 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 20:01:49 +0000 Subject: [PATCH 023/118] should work... --- .github/workflows/build-ed64-example-rom.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 2d154898..1ac37ed2 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,10 +15,7 @@ jobs: run: | sudo npm install -g libdragon libdragon init - cd ./.libdragon - ls libdragon make NDEBUG - cd .. - name: Setup Build environment From 32c2f8bd2ffc9e623caf13bffc9acb92f03e6cb0 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 21:28:40 +0000 Subject: [PATCH 024/118] Roll the default docker... --- .github/workflows/build-ed64-example-rom.yml | 15 ++++++++++----- ED64-XIO/Makefile | 2 +- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 1ac37ed2..97304174 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -11,18 +11,23 @@ jobs: - uses: actions/checkout@v2 name: Checkout Code - - name: Install Libdragon container + - name: Install Toolchain Docker Container run: | - sudo npm install -g libdragon - libdragon init - libdragon make NDEBUG + docker pull ghcr.io/dragonminded/libdragon:latest + + - name: Setup Libdragon + run: | + docker run \ + --mount type=bind,source=$(pwd),target=/libdragon \ + --workdir=/libdragon \ + ghcr.io/dragonminded/libdragon:latest \ + ./make libdragon -NDEBUG - name: Setup Build environment run: | cd ${{ github.workspace }}/ED64-XIO/ mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj - libdragon start - name: Build ROM run: cd ${{ github.workspace }}/ED64-XIO/ && libdragon make ${{ matrix.releasetype }} diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index 38d59539..0c9fbe7c 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -38,7 +38,7 @@ HEADERTITLE = $(PROG_NAME) LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld ASFLAGS := -mtune=vr4300 -march=vr4300 -CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) -DNDEBUG +CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) SOURCES_ASM := $(wildcard $(SRCDIR)/*.s) SOURCES := $(wildcard $(SRCDIR)/*.c) From 026755058e74ba0c5afee332fbfe88f4b53ac865 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 21:31:36 +0000 Subject: [PATCH 025/118] remove . from make. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 97304174..94f16293 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -21,7 +21,7 @@ jobs: --mount type=bind,source=$(pwd),target=/libdragon \ --workdir=/libdragon \ ghcr.io/dragonminded/libdragon:latest \ - ./make libdragon -NDEBUG + make libdragon -NDEBUG - name: Setup Build environment From b0b3180eddad109915f42639fdd96092d0b7bbd4 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 21:35:00 +0000 Subject: [PATCH 026/118] remove flag --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 94f16293..f02b1bd7 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -21,7 +21,7 @@ jobs: --mount type=bind,source=$(pwd),target=/libdragon \ --workdir=/libdragon \ ghcr.io/dragonminded/libdragon:latest \ - make libdragon -NDEBUG + make libdragon NDEBUG - name: Setup Build environment From 7ab2c7bc7a4466cf3d9bc373a25558e4d8887bb7 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 21:47:41 +0000 Subject: [PATCH 027/118] use FF code from libdragon --- .github/workflows/build-ed64-example-rom.yml | 16 +++++----------- ED64-XIO/Makefile | 6 +++--- 2 files changed, 8 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f02b1bd7..d4a95398 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -11,23 +11,17 @@ jobs: - uses: actions/checkout@v2 name: Checkout Code - - name: Install Toolchain Docker Container + - name: Install Libdragon container run: | - docker pull ghcr.io/dragonminded/libdragon:latest - - - name: Setup Libdragon - run: | - docker run \ - --mount type=bind,source=$(pwd),target=/libdragon \ - --workdir=/libdragon \ - ghcr.io/dragonminded/libdragon:latest \ - make libdragon NDEBUG - + sudo npm install -g libdragon + libdragon init + libdragon install - name: Setup Build environment run: | cd ${{ github.workspace }}/ED64-XIO/ mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj + libdragon start - name: Build ROM run: cd ${{ github.workspace }}/ED64-XIO/ && libdragon make ${{ matrix.releasetype }} diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index 0c9fbe7c..251450d9 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -38,17 +38,17 @@ HEADERTITLE = $(PROG_NAME) LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld ASFLAGS := -mtune=vr4300 -march=vr4300 -CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) +CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) -NDEBUG SOURCES_ASM := $(wildcard $(SRCDIR)/*.s) SOURCES := $(wildcard $(SRCDIR)/*.c) SOURCES_EDLIB := $(wildcard $(SRCDIR_EDLIB)/*.c) -SOURCES_FFLIB := $(wildcard $(SRCDIR_FFLIB)/*.c) +#SOURCES_FFLIB := $(wildcard $(SRCDIR_FFLIB)/*.c) OBJECTS_ASM := $(SOURCES_ASM:$(SRCDIR)/%.s=$(OBJDIR)/%.o) OBJECTS := $(SOURCES:$(SRCDIR)/%.c=$(OBJDIR)/%.o) OBJECTS_EDLIB := $(SOURCES_EDLIB:$(SRCDIR_EDLIB)/%.c=$(OBJDIR)/%.o) -OBJECTS_FFLIB := $(SOURCES_FFLIB:$(SRCDIR_FFLIB)/%.c=$(OBJDIR)/%.o) +O#BJECTS_FFLIB := $(SOURCES_FFLIB:$(SRCDIR_FFLIB)/%.c=$(OBJDIR)/%.o) $(PROG_NAME).v64: $ $(PROG_NAME).elf From c4d754b9157218b102fd630a6fb7a05cee5541f3 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 21:50:57 +0000 Subject: [PATCH 028/118] Correct makefile --- ED64-XIO/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index 251450d9..92cbdb2e 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -38,7 +38,7 @@ HEADERTITLE = $(PROG_NAME) LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld ASFLAGS := -mtune=vr4300 -march=vr4300 -CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) -NDEBUG +CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) #-NDEBUG SOURCES_ASM := $(wildcard $(SRCDIR)/*.s) SOURCES := $(wildcard $(SRCDIR)/*.c) @@ -48,7 +48,7 @@ SOURCES_EDLIB := $(wildcard $(SRCDIR_EDLIB)/*.c) OBJECTS_ASM := $(SOURCES_ASM:$(SRCDIR)/%.s=$(OBJDIR)/%.o) OBJECTS := $(SOURCES:$(SRCDIR)/%.c=$(OBJDIR)/%.o) OBJECTS_EDLIB := $(SOURCES_EDLIB:$(SRCDIR_EDLIB)/%.c=$(OBJDIR)/%.o) -O#BJECTS_FFLIB := $(SOURCES_FFLIB:$(SRCDIR_FFLIB)/%.c=$(OBJDIR)/%.o) +#OBJECTS_FFLIB := $(SOURCES_FFLIB:$(SRCDIR_FFLIB)/%.c=$(OBJDIR)/%.o) $(PROG_NAME).v64: $ $(PROG_NAME).elf From 67ead91e99a8fcd7e7f18aedfa9ea9f9cc33b5a4 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 21:59:09 +0000 Subject: [PATCH 029/118] Fix size. --- ED64-XIO/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index 92cbdb2e..07e7a531 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -1,5 +1,5 @@ PROG_NAME = ED64-XIO-SAMPLE -ROMSIZE = 256K +ROMSIZE = 1048576B ifdef SystemRoot From 1b9a242ba2509a8eace3ab05e86ec7d230dbb456 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 22:33:36 +0000 Subject: [PATCH 030/118] try different flag... --- .github/workflows/build-ed64-example-rom.yml | 5 +++++ ED64-XIO/Makefile | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index d4a95398..fef42f42 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,6 +15,11 @@ jobs: run: | sudo npm install -g libdragon libdragon init + cd ./.libdragon + ls + # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' + N64_CFLAGS:=-NDEBUG + cd .. libdragon install - name: Setup Build environment diff --git a/ED64-XIO/Makefile b/ED64-XIO/Makefile index 07e7a531..2ef93bf1 100644 --- a/ED64-XIO/Makefile +++ b/ED64-XIO/Makefile @@ -38,17 +38,17 @@ HEADERTITLE = $(PROG_NAME) LINK_FLAGS = -L$(ROOTDIR)/lib -L$(ROOTDIR)/mips64-elf/lib -ldragon -lc -lm -ldragonsys -Tn64.ld ASFLAGS := -mtune=vr4300 -march=vr4300 -CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) #-NDEBUG +CCFLAGS := -std=gnu99 $(ASFLAGS) $(OPTIMIZE_FLAG) -Wall -Wno-pointer-sign -I$(ROOTDIR)/mips64-elf/include -I$(SRCDIR_FFLIB) -I$(INCDIR) -I$(INCDIR_EDLIB) SOURCES_ASM := $(wildcard $(SRCDIR)/*.s) SOURCES := $(wildcard $(SRCDIR)/*.c) SOURCES_EDLIB := $(wildcard $(SRCDIR_EDLIB)/*.c) -#SOURCES_FFLIB := $(wildcard $(SRCDIR_FFLIB)/*.c) +SOURCES_FFLIB := $(wildcard $(SRCDIR_FFLIB)/*.c) OBJECTS_ASM := $(SOURCES_ASM:$(SRCDIR)/%.s=$(OBJDIR)/%.o) OBJECTS := $(SOURCES:$(SRCDIR)/%.c=$(OBJDIR)/%.o) OBJECTS_EDLIB := $(SOURCES_EDLIB:$(SRCDIR_EDLIB)/%.c=$(OBJDIR)/%.o) -#OBJECTS_FFLIB := $(SOURCES_FFLIB:$(SRCDIR_FFLIB)/%.c=$(OBJDIR)/%.o) +OBJECTS_FFLIB := $(SOURCES_FFLIB:$(SRCDIR_FFLIB)/%.c=$(OBJDIR)/%.o) $(PROG_NAME).v64: $ $(PROG_NAME).elf From bd20fcd540cb6018395a0e6a8909e30420151c70 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 22:43:12 +0000 Subject: [PATCH 031/118] Try commenting install flag. --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index fef42f42..3181bc74 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -16,10 +16,10 @@ jobs: sudo npm install -g libdragon libdragon init cd ./.libdragon - ls + #ls # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' - N64_CFLAGS:=-NDEBUG - cd .. + export N64_CFLAGS:="-NDEBUG" + #cd .. libdragon install - name: Setup Build environment From 15a34f5dae498d4acd9800cfd53d0dec83d9e31b Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 22:47:37 +0000 Subject: [PATCH 032/118] Try removing colon and hyphen --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 3181bc74..88a2843d 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,10 +15,10 @@ jobs: run: | sudo npm install -g libdragon libdragon init - cd ./.libdragon - #ls + # cd ./.libdragon + # ls # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' - export N64_CFLAGS:="-NDEBUG" + export N64_CFLAGS="NDEBUG" #cd .. libdragon install From c305a36d1a6e93baffc2c3761617eaff10f46644 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 23:08:59 +0000 Subject: [PATCH 033/118] try exec function --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 88a2843d..2f4ed98c 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -18,7 +18,7 @@ jobs: # cd ./.libdragon # ls # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' - export N64_CFLAGS="NDEBUG" + libdragon exec 'export N64_CFLAGS="NDEBUG" #cd .. libdragon install From 0ee9e1d81eb618636ce47606a01d4b00cc3001b9 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 23:11:25 +0000 Subject: [PATCH 034/118] fix char --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 2f4ed98c..6f4765d3 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -18,7 +18,7 @@ jobs: # cd ./.libdragon # ls # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' - libdragon exec 'export N64_CFLAGS="NDEBUG" + libdragon exec 'export N64_CFLAGS="NDEBUG"' #cd .. libdragon install From c731280667a9e970aadccaa4a8736c24a9f7706b Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 23:23:13 +0000 Subject: [PATCH 035/118] try without commentation. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 6f4765d3..bc441139 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -18,7 +18,7 @@ jobs: # cd ./.libdragon # ls # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' - libdragon exec 'export N64_CFLAGS="NDEBUG"' + libdragon exec export N64_CFLAGS="NDEBUG" #cd .. libdragon install From a67fc2f19efdcdd693e73bcc8aecced4227fe385 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 23:28:19 +0000 Subject: [PATCH 036/118] try using bash -c --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index bc441139..6b23924a 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -18,7 +18,7 @@ jobs: # cd ./.libdragon # ls # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' - libdragon exec export N64_CFLAGS="NDEBUG" + libdragon exec bash -c 'export N64_CFLAGS="NDEBUG"' #cd .. libdragon install From fc396405af6a9e28b3a5ac9b777a034d24d77619 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 23:31:59 +0000 Subject: [PATCH 037/118] try direct command --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 6b23924a..9f1d3ff6 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,7 +20,7 @@ jobs: # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' libdragon exec bash -c 'export N64_CFLAGS="NDEBUG"' #cd .. - libdragon install + libdragon N64_CFLAGS="NDEBUG" install - name: Setup Build environment run: | From 7eb5a2d3d81d82abf5db5be8b6712f6965f6df81 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 23:35:39 +0000 Subject: [PATCH 038/118] try more local var. --- .github/workflows/build-ed64-example-rom.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 9f1d3ff6..f30e5505 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -18,9 +18,10 @@ jobs: # cd ./.libdragon # ls # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' - libdragon exec bash -c 'export N64_CFLAGS="NDEBUG"' + #libdragon exec bash -c 'export N64_CFLAGS="NDEBUG"' #cd .. - libdragon N64_CFLAGS="NDEBUG" install + libdragon exec bash -c N64_CFLAGS="NDEBUG" + libdragon install - name: Setup Build environment run: | From 281a117bea178e9d4a983c98995d39badebd0271 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Mon, 22 Nov 2021 23:41:47 +0000 Subject: [PATCH 039/118] worth a try... --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f30e5505..a668035e 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,8 +20,8 @@ jobs: # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' #libdragon exec bash -c 'export N64_CFLAGS="NDEBUG"' #cd .. - libdragon exec bash -c N64_CFLAGS="NDEBUG" - libdragon install + #libdragon exec bash -c N64_CFLAGS="NDEBUG" + N64_CFLAGS="NDEBUG" && libdragon install - name: Setup Build environment run: | From 93d984b0dd030bda88dde4032e3ee0ba18d3607b Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:02:30 +0000 Subject: [PATCH 040/118] try sed --- .github/workflows/build-ed64-example-rom.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index a668035e..43d04906 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -17,11 +17,13 @@ jobs: libdragon init # cd ./.libdragon # ls - # sed -z 's/CFLAGS= /CFLAGS= -NDEBUG ' + # sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ./Makefile #libdragon exec bash -c 'export N64_CFLAGS="NDEBUG"' #cd .. #libdragon exec bash -c N64_CFLAGS="NDEBUG" - N64_CFLAGS="NDEBUG" && libdragon install + #N64_CFLAGS="NDEBUG" && libdragon install + sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ./Makefile + libdragon install - name: Setup Build environment run: | From 5e41a6c36382af4bceaaf5c2e8bd448d153fb15a Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:18:52 +0000 Subject: [PATCH 041/118] try this... --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 43d04906..5b43589c 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -22,7 +22,7 @@ jobs: #cd .. #libdragon exec bash -c N64_CFLAGS="NDEBUG" #N64_CFLAGS="NDEBUG" && libdragon install - sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ./Makefile + sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ../libdragon/Makefile libdragon install - name: Setup Build environment From 09d52e0117636dc192d7f816bba3e796adbccc78 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:21:43 +0000 Subject: [PATCH 042/118] Extra try. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 5b43589c..09b58f64 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -22,7 +22,7 @@ jobs: #cd .. #libdragon exec bash -c N64_CFLAGS="NDEBUG" #N64_CFLAGS="NDEBUG" && libdragon install - sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ../libdragon/Makefile + sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ./libdragon/Makefile libdragon install - name: Setup Build environment From 69dff5411d89a74fd5558cc9f882c93ef9b9da69 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:31:04 +0000 Subject: [PATCH 043/118] try backup writing. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 09b58f64..1aac1985 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -22,7 +22,7 @@ jobs: #cd .. #libdragon exec bash -c N64_CFLAGS="NDEBUG" #N64_CFLAGS="NDEBUG" && libdragon install - sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ./libdragon/Makefile + sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS)/CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile libdragon install - name: Setup Build environment From bf144f45be4e0d666bc91107ccec580ad555e225 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:39:18 +0000 Subject: [PATCH 044/118] check this... --- .github/workflows/build-ed64-example-rom.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 1aac1985..633e0685 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -22,7 +22,8 @@ jobs: #cd .. #libdragon exec bash -c N64_CFLAGS="NDEBUG" #N64_CFLAGS="NDEBUG" && libdragon install - sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS)/CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile + # sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile + sed -z 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile libdragon install - name: Setup Build environment From f332e4eacadced9bbaec79f078c01bdafb0e0309 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:44:50 +0000 Subject: [PATCH 045/118] last try. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 633e0685..bcdeed17 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -23,7 +23,7 @@ jobs: #libdragon exec bash -c N64_CFLAGS="NDEBUG" #N64_CFLAGS="NDEBUG" && libdragon install # sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile - sed -z 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile + sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile libdragon install - name: Setup Build environment From c91098e8eeca3cdafd4e98fe9539c0a5a2708fbb Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:50:31 +0000 Subject: [PATCH 046/118] without flag. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index bcdeed17..c058b873 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -23,7 +23,7 @@ jobs: #libdragon exec bash -c N64_CFLAGS="NDEBUG" #N64_CFLAGS="NDEBUG" && libdragon install # sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile - sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile + sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) NDEBUG /' ./libdragon/Makefile libdragon install - name: Setup Build environment From 78ad1b7610104e5bd26bb5e74a026c396bf88602 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Tue, 23 Nov 2021 00:53:43 +0000 Subject: [PATCH 047/118] Try D flag --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index c058b873..b7a5a195 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -23,7 +23,7 @@ jobs: #libdragon exec bash -c N64_CFLAGS="NDEBUG" #N64_CFLAGS="NDEBUG" && libdragon install # sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile - sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) NDEBUG /' ./libdragon/Makefile + sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile libdragon install - name: Setup Build environment From 71a7b70936310993b872221daa2577a3733a421b Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 00:12:48 +0000 Subject: [PATCH 048/118] Patch libdragon. --- .github/workflows/build-ed64-example-rom.yml | 71 +++++++++++++++++--- 1 file changed, 63 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index b7a5a195..0b716b5e 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -15,15 +15,70 @@ jobs: run: | sudo npm install -g libdragon libdragon init - # cd ./.libdragon - # ls - # sed -z 's/CFLAGS=/CFLAGS=-NDEBUG /' ./Makefile - #libdragon exec bash -c 'export N64_CFLAGS="NDEBUG"' - #cd .. - #libdragon exec bash -c N64_CFLAGS="NDEBUG" - #N64_CFLAGS="NDEBUG" && libdragon install - # sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -NDEBUG /' ./libdragon/Makefile + #libdragon exec bash -c 'export N64_CFLAGS="-DNDEBUG"' + #libdragon exec bash -c N64_CFLAGS="-DNDEBUG" + #N64_CFLAGS="-DNDEBUG" && libdragon install sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile + + cd ./libdragon/ + cat > debug_h.patch << EOF + diff --git a/include/debug.h b/include/debug.h + index 1bc8404..9ceec9c 100644 + --- a/include/debug.h + +++ b/include/debug.h + @@ -199,7 +199,7 @@ extern "C" { + #define debug_init_sdlog(fn,fmt) ({ false; }) + #define debug_init_sdfs(prefix,np) ({ false; }) + #define debugf(msg, ...) ({ }) + - #define assertf(expr, msg, ...) ({ }) + + #define assertf(expr, msg, ...) ({ (void)(expr); }) + #endif + + /** @brief Underlying implementation function for assert() and #assertf. */ + diff --git a/src/audio/libxm/context.c b/src/audio/libxm/context.c + index 590e14c..6af483a 100644 + --- a/src/audio/libxm/context.c + +++ b/src/audio/libxm/context.c + @@ -396,7 +396,7 @@ static uint32_t varint_get(uint8_t **pp) { + int xm_context_decompress_pattern(uint8_t *in, int sz, xm_pattern_slot_t *pat) { + uint8_t *in_end = in+sz; + uint8_t *out = (uint8_t*)pat; + - bool direction = (out<=in); + + bool direction = (out<=in); (void)direction; + while (in < in_end) { + int zeros = varint_get(&in); + int runs = zeros & 7; if (runs == 7) runs += varint_get(&in); + diff --git a/src/audio/libxm/play.c b/src/audio/libxm/play.c + index 32d50fe..0a1c22c 100644 + --- a/src/audio/libxm/play.c + +++ b/src/audio/libxm/play.c + @@ -894,7 +894,7 @@ static void xm_row(xm_context_t* ctx) { + fread(cmp_data, cmp_size, 1, ctx->fh); + + int sz = xm_context_decompress_pattern(cmp_data, cmp_size, ctx->slot_buffer); + - assert(sz == dec_size); + + assert(sz == dec_size); (void)sz; + } + ctx->slot_buffer_index = pat_idx; + } + diff --git a/src/debug.c b/src/debug.c + index 5e7d1ab..a9d5700 100644 + --- a/src/debug.c + +++ b/src/debug.c + @@ -2,7 +2,7 @@ + * @file debug.c + * @brief Debugging Support + */ + - + +#undef NDEBUG + #include + #include + #include + EOF + + patch < debug_h.patch + cd .. + libdragon install - name: Setup Build environment From 09dfb72f9dbefb0e69184e8dac2bb918bf0ac659 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 00:18:25 +0000 Subject: [PATCH 049/118] Try no CD --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 0b716b5e..a68c13ea 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,7 +20,7 @@ jobs: #N64_CFLAGS="-DNDEBUG" && libdragon install sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile - cd ./libdragon/ + #cd ./libdragon/ cat > debug_h.patch << EOF diff --git a/include/debug.h b/include/debug.h index 1bc8404..9ceec9c 100644 @@ -77,7 +77,7 @@ jobs: EOF patch < debug_h.patch - cd .. + #cd .. libdragon install From 5e853773777811b9e2f5dc578fef839abbb1a09e Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 00:26:12 +0000 Subject: [PATCH 050/118] Try within folder --- .github/workflows/build-ed64-example-rom.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index a68c13ea..9eaeaaa7 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,8 +20,8 @@ jobs: #N64_CFLAGS="-DNDEBUG" && libdragon install sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile - #cd ./libdragon/ - cat > debug_h.patch << EOF + cd ./libdragon + cat > libdragon.patch << EOF diff --git a/include/debug.h b/include/debug.h index 1bc8404..9ceec9c 100644 --- a/include/debug.h @@ -76,8 +76,8 @@ jobs: #include EOF - patch < debug_h.patch - #cd .. + patch < libdragon.patch + cd .. libdragon install From 3cff8bc1a14bbdc445bf3c261c850ea0ea6ce527 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 00:35:57 +0000 Subject: [PATCH 051/118] Try patch flag. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 9eaeaaa7..c0b87db8 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -76,7 +76,7 @@ jobs: #include EOF - patch < libdragon.patch + patch -p1 < libdragon.patch cd .. libdragon install From dc6969e742690fdaadef85cd5efc936111a38eeb Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 00:42:32 +0000 Subject: [PATCH 052/118] fallback to sed?! --- .github/workflows/build-ed64-example-rom.yml | 61 +------------------- 1 file changed, 1 insertion(+), 60 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index c0b87db8..f36136c3 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -19,66 +19,7 @@ jobs: #libdragon exec bash -c N64_CFLAGS="-DNDEBUG" #N64_CFLAGS="-DNDEBUG" && libdragon install sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile - - cd ./libdragon - cat > libdragon.patch << EOF - diff --git a/include/debug.h b/include/debug.h - index 1bc8404..9ceec9c 100644 - --- a/include/debug.h - +++ b/include/debug.h - @@ -199,7 +199,7 @@ extern "C" { - #define debug_init_sdlog(fn,fmt) ({ false; }) - #define debug_init_sdfs(prefix,np) ({ false; }) - #define debugf(msg, ...) ({ }) - - #define assertf(expr, msg, ...) ({ }) - + #define assertf(expr, msg, ...) ({ (void)(expr); }) - #endif - - /** @brief Underlying implementation function for assert() and #assertf. */ - diff --git a/src/audio/libxm/context.c b/src/audio/libxm/context.c - index 590e14c..6af483a 100644 - --- a/src/audio/libxm/context.c - +++ b/src/audio/libxm/context.c - @@ -396,7 +396,7 @@ static uint32_t varint_get(uint8_t **pp) { - int xm_context_decompress_pattern(uint8_t *in, int sz, xm_pattern_slot_t *pat) { - uint8_t *in_end = in+sz; - uint8_t *out = (uint8_t*)pat; - - bool direction = (out<=in); - + bool direction = (out<=in); (void)direction; - while (in < in_end) { - int zeros = varint_get(&in); - int runs = zeros & 7; if (runs == 7) runs += varint_get(&in); - diff --git a/src/audio/libxm/play.c b/src/audio/libxm/play.c - index 32d50fe..0a1c22c 100644 - --- a/src/audio/libxm/play.c - +++ b/src/audio/libxm/play.c - @@ -894,7 +894,7 @@ static void xm_row(xm_context_t* ctx) { - fread(cmp_data, cmp_size, 1, ctx->fh); - - int sz = xm_context_decompress_pattern(cmp_data, cmp_size, ctx->slot_buffer); - - assert(sz == dec_size); - + assert(sz == dec_size); (void)sz; - } - ctx->slot_buffer_index = pat_idx; - } - diff --git a/src/debug.c b/src/debug.c - index 5e7d1ab..a9d5700 100644 - --- a/src/debug.c - +++ b/src/debug.c - @@ -2,7 +2,7 @@ - * @file debug.c - * @brief Debugging Support - */ - - - +#undef NDEBUG - #include - #include - #include - EOF - - patch -p1 < libdragon.patch - cd .. - + sed -z -i.bak 's/#define assertf(expr, msg, ...)/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h libdragon install - name: Setup Build environment From 0035e323f2564071068404b5efae04cd5544b34c Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 00:55:24 +0000 Subject: [PATCH 053/118] Missing bit from sed. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f36136c3..f0d3c82e 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -19,7 +19,7 @@ jobs: #libdragon exec bash -c N64_CFLAGS="-DNDEBUG" #N64_CFLAGS="-DNDEBUG" && libdragon install sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile - sed -z -i.bak 's/#define assertf(expr, msg, ...)/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h + sed -z -i.bak 's/#define assertf(expr, msg, ...) ({ })/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h libdragon install - name: Setup Build environment From 2b124529f01a601b1b5bd354269a3aa4294f8373 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 01:06:42 +0000 Subject: [PATCH 054/118] Add undef for NDBUG. --- .github/workflows/build-ed64-example-rom.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f0d3c82e..aaae746d 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,6 +20,8 @@ jobs: #N64_CFLAGS="-DNDEBUG" && libdragon install sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile sed -z -i.bak 's/#define assertf(expr, msg, ...) ({ })/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h + sed -z -i.bak '1s/^/#undef NDEBUG\n/' ./libdragon/src/debug.c + libdragon install - name: Setup Build environment From 6d8c5d00d7468f7158593bab4943a27b8e1d491f Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 01:12:16 +0000 Subject: [PATCH 055/118] Fix xm. --- .github/workflows/build-ed64-example-rom.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index aaae746d..9b9eaa65 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -21,7 +21,8 @@ jobs: sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile sed -z -i.bak 's/#define assertf(expr, msg, ...) ({ })/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h sed -z -i.bak '1s/^/#undef NDEBUG\n/' ./libdragon/src/debug.c - + sed -z -i.bak 's/bool direction = (out<=in);/bool direction = (out<=in); (void)direction;/' ./libdragon/src/audio/libxm/context.c + sed -z -i.bak 's/assert(sz == dec_size);/assert(sz == dec_size); (void)sz;/' ./libdragon/src/audio/libxm/play.c libdragon install - name: Setup Build environment From 29df90c593ae7e8c68c4e31983898c792442f56e Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Thu, 25 Nov 2021 01:30:50 +0000 Subject: [PATCH 056/118] debug check for file debug.c --- .github/workflows/build-ed64-example-rom.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 9b9eaa65..a3ab058c 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -21,6 +21,7 @@ jobs: sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile sed -z -i.bak 's/#define assertf(expr, msg, ...) ({ })/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h sed -z -i.bak '1s/^/#undef NDEBUG\n/' ./libdragon/src/debug.c + cat ./libdragon/src/debug.c sed -z -i.bak 's/bool direction = (out<=in);/bool direction = (out<=in); (void)direction;/' ./libdragon/src/audio/libxm/context.c sed -z -i.bak 's/assert(sz == dec_size);/assert(sz == dec_size); (void)sz;/' ./libdragon/src/audio/libxm/play.c libdragon install From ba1b9737f8b97c12ee718ba9014fd066571aa1fe Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 17:35:15 +0000 Subject: [PATCH 057/118] Change CI to use tagged libdragon. --- .github/workflows/build-ed64-example-rom.yml | 38 +++++++++++++------- 1 file changed, 26 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index a3ab058c..2cf430fe 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -10,21 +10,35 @@ jobs: steps: - uses: actions/checkout@v2 name: Checkout Code + # with: + # path: code + - name: Checkout tools repo + uses: actions/checkout@v2 + with: + repository: dragonminded/libdragon + path: libdragon + ref: '89d17be8563a44a9b95873d436832a1222757cdc' + - name: Install Libdragon container run: | - sudo npm install -g libdragon - libdragon init - #libdragon exec bash -c 'export N64_CFLAGS="-DNDEBUG"' - #libdragon exec bash -c N64_CFLAGS="-DNDEBUG" - #N64_CFLAGS="-DNDEBUG" && libdragon install - sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile - sed -z -i.bak 's/#define assertf(expr, msg, ...) ({ })/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h - sed -z -i.bak '1s/^/#undef NDEBUG\n/' ./libdragon/src/debug.c - cat ./libdragon/src/debug.c - sed -z -i.bak 's/bool direction = (out<=in);/bool direction = (out<=in); (void)direction;/' ./libdragon/src/audio/libxm/context.c - sed -z -i.bak 's/assert(sz == dec_size);/assert(sz == dec_size); (void)sz;/' ./libdragon/src/audio/libxm/play.c - libdragon install + docker run \ + --mount type=bind,source=$(pwd),target=/libdragon \ + --workdir=/libdragon \ + ghcr.io/dragonminded/libdragon:latest \ + ./build.sh + + # sudo npm install -g libdragon + # libdragon init + # #libdragon exec bash -c 'export N64_CFLAGS="-DNDEBUG"' + # #libdragon exec bash -c N64_CFLAGS="-DNDEBUG" + # #N64_CFLAGS="-DNDEBUG" && libdragon install + # sed -z -i.bak 's/CFLAGS+=$(N64_CFLAGS) /CFLAGS+=$(N64_CFLAGS) -DNDEBUG /' ./libdragon/Makefile + # sed -z -i.bak 's/#define assertf(expr, msg, ...) ({ })/#define assertf(expr, msg, ...) ({ (void)(expr); })/' ./libdragon/include/debug.h + # sed -z -i.bak '1s/^/#undef NDEBUG\n/' ./libdragon/src/debug.c + # sed -z -i.bak 's/bool direction = (out<=in);/bool direction = (out<=in); (void)direction;/' ./libdragon/src/audio/libxm/context.c + # sed -z -i.bak 's/assert(sz == dec_size);/assert(sz == dec_size); (void)sz;/' ./libdragon/src/audio/libxm/play.c + # libdragon install - name: Setup Build environment run: | From 5e4d9b601fea80336b6e6c5e49d8431af82a412f Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 17:40:09 +0000 Subject: [PATCH 058/118] try without defining extra path. --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 2cf430fe..96d8af2a 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -16,7 +16,7 @@ jobs: uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: libdragon + # path: libdragon ref: '89d17be8563a44a9b95873d436832a1222757cdc' @@ -26,7 +26,7 @@ jobs: --mount type=bind,source=$(pwd),target=/libdragon \ --workdir=/libdragon \ ghcr.io/dragonminded/libdragon:latest \ - ./build.sh + ./build.sh libdragon # sudo npm install -g libdragon # libdragon init @@ -39,12 +39,12 @@ jobs: # sed -z -i.bak 's/bool direction = (out<=in);/bool direction = (out<=in); (void)direction;/' ./libdragon/src/audio/libxm/context.c # sed -z -i.bak 's/assert(sz == dec_size);/assert(sz == dec_size); (void)sz;/' ./libdragon/src/audio/libxm/play.c # libdragon install + # libdragon start - name: Setup Build environment run: | cd ${{ github.workspace }}/ED64-XIO/ mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj - libdragon start - name: Build ROM run: cd ${{ github.workspace }}/ED64-XIO/ && libdragon make ${{ matrix.releasetype }} From b9840adf82cc9f5a2ac07bc995f5bf4b3505ff32 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:00:51 +0000 Subject: [PATCH 059/118] patch warnings as errors. only build libdragon and tools. --- .github/workflows/build-ed64-example-rom.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 96d8af2a..fd084ca7 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -19,6 +19,8 @@ jobs: # path: libdragon ref: '89d17be8563a44a9b95873d436832a1222757cdc' + - name: patch libdragon make (workaround ignore warnings as errors) + run: sed -z -i.bak 's/ -Wall -Werror / /' ./libdragon/Makefile - name: Install Libdragon container run: | @@ -26,7 +28,8 @@ jobs: --mount type=bind,source=$(pwd),target=/libdragon \ --workdir=/libdragon \ ghcr.io/dragonminded/libdragon:latest \ - ./build.sh libdragon + make libdragon && make install &&\ + make tools && make tools-install # sudo npm install -g libdragon # libdragon init From ad2d3e5323be54c7e2a001158374e502f69adbf0 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:03:20 +0000 Subject: [PATCH 060/118] correct path. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index fd084ca7..b14aa295 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,7 +20,7 @@ jobs: ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: patch libdragon make (workaround ignore warnings as errors) - run: sed -z -i.bak 's/ -Wall -Werror / /' ./libdragon/Makefile + run: sed -z -i.bak 's/ -Wall -Werror / /' ${{ github.workspace }}/libdragon/Makefile - name: Install Libdragon container run: | From 98a31c92da54c8f4fad630c14999b67b09e4c5cc Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:07:50 +0000 Subject: [PATCH 061/118] Futher try. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index b14aa295..43911e00 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,7 +20,7 @@ jobs: ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: patch libdragon make (workaround ignore warnings as errors) - run: sed -z -i.bak 's/ -Wall -Werror / /' ${{ github.workspace }}/libdragon/Makefile + run: sed -z -i.bak 's/ -Wall -Werror / /' /libdragon/Makefile - name: Install Libdragon container run: | From e9f60bf8d87c2aaeff4f243b67ad91878f78f58f Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:10:55 +0000 Subject: [PATCH 062/118] add ls for debugging --- .github/workflows/build-ed64-example-rom.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 43911e00..610f1728 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -20,15 +20,17 @@ jobs: ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: patch libdragon make (workaround ignore warnings as errors) - run: sed -z -i.bak 's/ -Wall -Werror / /' /libdragon/Makefile + run: | + ls + sed -z -i.bak 's/ -Wall -Werror / /' /libdragon/Makefile - name: Install Libdragon container - run: | - docker run \ - --mount type=bind,source=$(pwd),target=/libdragon \ - --workdir=/libdragon \ - ghcr.io/dragonminded/libdragon:latest \ - make libdragon && make install &&\ + run: >- + docker run + --mount type=bind,source=$(pwd),target=/libdragon + --workdir=/libdragon + ghcr.io/dragonminded/libdragon:latest + make libdragon && make install && make tools && make tools-install # sudo npm install -g libdragon From ed9392da7f24f573308918ccd55a65b21a3127b4 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:12:26 +0000 Subject: [PATCH 063/118] correct path. --- .github/workflows/build-ed64-example-rom.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 610f1728..f9f1a907 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -21,8 +21,7 @@ jobs: - name: patch libdragon make (workaround ignore warnings as errors) run: | - ls - sed -z -i.bak 's/ -Wall -Werror / /' /libdragon/Makefile + sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - name: Install Libdragon container run: >- From 00e1d7eb6eb69c426aae446d1b0fc5dbcae8d0df Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:18:13 +0000 Subject: [PATCH 064/118] add export for install location --- .github/workflows/build-ed64-example-rom.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f9f1a907..f7fa98ff 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -29,6 +29,7 @@ jobs: --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest + export N64_INST="/usr/local" && make libdragon && make install && make tools && make tools-install From 5000a158b6c3e79c3c9505773d764f29bb344219 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:22:32 +0000 Subject: [PATCH 065/118] remove export, it should already be set! --- .github/workflows/build-ed64-example-rom.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f7fa98ff..f9f1a907 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -29,7 +29,6 @@ jobs: --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest - export N64_INST="/usr/local" && make libdragon && make install && make tools && make tools-install From 8510f31f2ccc0940edc1289eda83be566d96205f Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:25:34 +0000 Subject: [PATCH 066/118] try with env arg --- .github/workflows/build-ed64-example-rom.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f9f1a907..de614be4 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -28,8 +28,9 @@ jobs: docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon + --env N64_INST="/n64_toolchain" ghcr.io/dragonminded/libdragon:latest - make libdragon && make install && + make libdragon && make install make tools && make tools-install # sudo npm install -g libdragon From dff8becd98e01da4a2a9866ecab542f488d0bbb2 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:28:54 +0000 Subject: [PATCH 067/118] add export before docker --- .github/workflows/build-ed64-example-rom.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index de614be4..331700e7 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -22,13 +22,14 @@ jobs: - name: patch libdragon make (workaround ignore warnings as errors) run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile + mkdir -p /usr/local/n64_toolchain + export N64_INST=/usr/local/n64_toolchain - name: Install Libdragon container run: >- docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon - --env N64_INST="/n64_toolchain" ghcr.io/dragonminded/libdragon:latest make libdragon && make install make tools && make tools-install From 561beb159267a3fe2462b6d63ca05689a86df106 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:34:52 +0000 Subject: [PATCH 068/118] Install toolchain to somewhere with permissions! --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 331700e7..dbc5f400 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -22,8 +22,8 @@ jobs: - name: patch libdragon make (workaround ignore warnings as errors) run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - mkdir -p /usr/local/n64_toolchain - export N64_INST=/usr/local/n64_toolchain + mkdir -p ${{ github.workspace }}/n64_toolchain + export N64_INST=${{ github.workspace }}/n64_toolchain - name: Install Libdragon container run: >- From 8e1a58a03543ba9ac2293fc9841cf69c52a49518 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:39:21 +0000 Subject: [PATCH 069/118] add env to docker. --- .github/workflows/build-ed64-example-rom.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index dbc5f400..9a2ba11c 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -30,6 +30,7 @@ jobs: docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon + --env N64_INST ghcr.io/dragonminded/libdragon:latest make libdragon && make install make tools && make tools-install From 437542a087ed44e91c95b4c36b1ce495fbf64eab Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:45:54 +0000 Subject: [PATCH 070/118] comment out libdragon install perhaps we can add it to path later! --- .github/workflows/build-ed64-example-rom.yml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 9a2ba11c..80369eb6 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -22,18 +22,18 @@ jobs: - name: patch libdragon make (workaround ignore warnings as errors) run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - mkdir -p ${{ github.workspace }}/n64_toolchain - export N64_INST=${{ github.workspace }}/n64_toolchain - name: Install Libdragon container run: >- docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon - --env N64_INST + # --env N64_INST ghcr.io/dragonminded/libdragon:latest - make libdragon && make install - make tools && make tools-install + make libdragon + # && make install + make tools + # && make tools-install # sudo npm install -g libdragon # libdragon init @@ -50,6 +50,7 @@ jobs: - name: Setup Build environment run: | + #export N64_INST=${{ github.workspace }}/n64_toolchain cd ${{ github.workspace }}/ED64-XIO/ mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj From 8cad7af40aca3a4c138de7b860b80dadd9fbbf58 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:47:44 +0000 Subject: [PATCH 071/118] yaml fix?! --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 80369eb6..47b8a5f2 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -28,12 +28,12 @@ jobs: docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon - # --env N64_INST + # --env N64_INST ghcr.io/dragonminded/libdragon:latest make libdragon - # && make install + # make install make tools - # && make tools-install + # make tools-install # sudo npm install -g libdragon # libdragon init From 6f7d645aeb5927862398a6afd98ef2945508a9c9 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:50:21 +0000 Subject: [PATCH 072/118] second attempt --- .github/workflows/build-ed64-example-rom.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 47b8a5f2..79ab670d 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -28,12 +28,9 @@ jobs: docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon - # --env N64_INST ghcr.io/dragonminded/libdragon:latest make libdragon - # make install make tools - # make tools-install # sudo npm install -g libdragon # libdragon init From c67585034e8b3fda26928237634aa5780ac474a0 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 18:52:55 +0000 Subject: [PATCH 073/118] add back && --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 79ab670d..2a77b11a 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -29,7 +29,7 @@ jobs: --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest - make libdragon + make libdragon && make tools # sudo npm install -g libdragon From 305c8707c630e747a1efaf5b413ffbb7f9b37af7 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 19:23:09 +0000 Subject: [PATCH 074/118] trial and error! --- .github/workflows/build-ed64-example-rom.yml | 29 +++++++++++++------- 1 file changed, 19 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 2a77b11a..2e97b370 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -10,23 +10,25 @@ jobs: steps: - uses: actions/checkout@v2 name: Checkout Code - # with: - # path: code - - name: Checkout tools repo + with: + path: xio-sample + - name: Checkout libdragon repo uses: actions/checkout@v2 with: repository: dragonminded/libdragon - # path: libdragon + path: libdragon ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: patch libdragon make (workaround ignore warnings as errors) + working-directory: ${{ github.workspace }}/libdragon run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - - name: Install Libdragon container + - name: Buid libdragon + working-directory: ${{ github.workspace }}/libdragon run: >- docker run - --mount type=bind,source=$(pwd),target=/libdragon + --mount type=bind,source=$(pwd),target=/${{ github.workspace }} --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest make libdragon && @@ -46,16 +48,23 @@ jobs: # libdragon start - name: Setup Build environment + working-directory: ${{ github.workspace }}/xio-sample run: | - #export N64_INST=${{ github.workspace }}/n64_toolchain - cd ${{ github.workspace }}/ED64-XIO/ + cd /ED64-XIO/ mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj - name: Build ROM - run: cd ${{ github.workspace }}/ED64-XIO/ && libdragon make ${{ matrix.releasetype }} + working-directory: xio-sample + run: >- + docker run + --mount type=bind,source=$(pwd),target=/${{ github.workspace }} + --workdir=/ED64-XIO + ghcr.io/dragonminded/libdragon:latest + make ${{ matrix.releasetype }} + #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} - name: Upload Artifact uses: actions/upload-artifact@v1.0.0 with: name: ED64-XIO-SAMPLE_N64_ROM-${{ matrix.releasetype }} - path: ${{ github.workspace }}/ED64-XIO/bin/${{ matrix.releasetype }}/ED64-XIO-SAMPLE.v64 + path: ${{ github.workspace }}/**/ED64-XIO/bin/${{ matrix.releasetype }}/ED64-XIO-SAMPLE.v64 From a4bfb196343e3cdba098e625129e7d93ec896b39 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 19:31:13 +0000 Subject: [PATCH 075/118] try this... --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 2e97b370..af748f5c 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -28,8 +28,8 @@ jobs: working-directory: ${{ github.workspace }}/libdragon run: >- docker run - --mount type=bind,source=$(pwd),target=/${{ github.workspace }} - --workdir=/libdragon + --mount type=bind,source=$(pwd),target=${{ github.workspace }} + --workdir=/libdragon/libdragon ghcr.io/dragonminded/libdragon:latest make libdragon && make tools @@ -58,7 +58,7 @@ jobs: run: >- docker run --mount type=bind,source=$(pwd),target=/${{ github.workspace }} - --workdir=/ED64-XIO + --workdir=/xio-sample/ED64-XIO ghcr.io/dragonminded/libdragon:latest make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} From c1f69467211747879c56270bb9ee6fb3ac963e1c Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 19:40:52 +0000 Subject: [PATCH 076/118] next try... --- .github/workflows/build-ed64-example-rom.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index af748f5c..faa313ee 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -11,25 +11,25 @@ jobs: - uses: actions/checkout@v2 name: Checkout Code with: - path: xio-sample + path: xio-sample-repo - name: Checkout libdragon repo uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: libdragon + path: libdragon-repo ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: patch libdragon make (workaround ignore warnings as errors) - working-directory: ${{ github.workspace }}/libdragon + working-directory: libdragon-repo run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - name: Buid libdragon - working-directory: ${{ github.workspace }}/libdragon + working-directory: libdragon-repo run: >- docker run - --mount type=bind,source=$(pwd),target=${{ github.workspace }} - --workdir=/libdragon/libdragon + --mount type=bind,source=$(pwd),target=/libdragon + --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest make libdragon && make tools @@ -48,13 +48,13 @@ jobs: # libdragon start - name: Setup Build environment - working-directory: ${{ github.workspace }}/xio-sample + working-directory: xio-sample-repo run: | cd /ED64-XIO/ mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj - name: Build ROM - working-directory: xio-sample + working-directory: xio-sample-repo run: >- docker run --mount type=bind,source=$(pwd),target=/${{ github.workspace }} From d07a2082f51c61a231fc676c4311af4e653eadeb Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 19:49:43 +0000 Subject: [PATCH 077/118] start work on rom build. --- .github/workflows/build-ed64-example-rom.yml | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index faa313ee..b0775acb 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -1,6 +1,15 @@ name: Build ED64 Example ROM -on: [push, pull_request] +on: + pull_request: + branches: + - master + - dev + push: + branches: + - master + - dev* + jobs: build: runs-on: ubuntu-latest @@ -50,15 +59,15 @@ jobs: - name: Setup Build environment working-directory: xio-sample-repo run: | - cd /ED64-XIO/ - mkdir bin && mkdir bin/release && mkdir bin/debug && mkdir obj + ls + mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj - name: Build ROM working-directory: xio-sample-repo run: >- docker run - --mount type=bind,source=$(pwd),target=/${{ github.workspace }} - --workdir=/xio-sample/ED64-XIO + --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ + --workdir=/xio-sample-repo/ED64-XIO/ ghcr.io/dragonminded/libdragon:latest make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} From a463e7e3610d03ee8d29c84239e0edacc94d325d Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 19:53:09 +0000 Subject: [PATCH 078/118] add ls for debug. --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index b0775acb..63121236 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -69,7 +69,7 @@ jobs: --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ --workdir=/xio-sample-repo/ED64-XIO/ ghcr.io/dragonminded/libdragon:latest - make ${{ matrix.releasetype }} + ls && make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} - name: Upload Artifact From 28e2e104af17baca90713b4ae547d72cc7f06ddb Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:00:23 +0000 Subject: [PATCH 079/118] try sub dir?! --- .github/workflows/build-ed64-example-rom.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 63121236..16c21f04 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -59,15 +59,16 @@ jobs: - name: Setup Build environment working-directory: xio-sample-repo run: | - ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj + cd ED64-XIO + ls - name: Build ROM working-directory: xio-sample-repo run: >- docker run - --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ - --workdir=/xio-sample-repo/ED64-XIO/ + --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ED64-XIO/ + --workdir=/xio-sample-repo/ED64-XIO/ED64-XIO/ ghcr.io/dragonminded/libdragon:latest ls && make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} From e39e193568c15fbcdefc2efaee3ee9158b3d0b99 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:03:45 +0000 Subject: [PATCH 080/118] Try this then... --- .github/workflows/build-ed64-example-rom.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 16c21f04..290b16fe 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -8,7 +8,7 @@ on: push: branches: - master - - dev* + #- dev* jobs: build: @@ -67,10 +67,10 @@ jobs: working-directory: xio-sample-repo run: >- docker run - --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ED64-XIO/ - --workdir=/xio-sample-repo/ED64-XIO/ED64-XIO/ + --mount type=bind,source=$(pwd),target=/xio-sample-repo/ + --workdir=/xio-sample-repo/ ghcr.io/dragonminded/libdragon:latest - ls && make ${{ matrix.releasetype }} + cd ED64-XIO && ls && make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} - name: Upload Artifact From e8867b046ae518adde1ad152062744fe05535fdf Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:11:27 +0000 Subject: [PATCH 081/118] Fix branch build? --- .github/workflows/build-ed64-example-rom.yml | 5 +---- .github/workflows/build-usb64-linux.yml | 6 +++++- .github/workflows/build-usb64-windows.yml | 6 +++++- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 290b16fe..2e117c8d 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -2,13 +2,10 @@ name: Build ED64 Example ROM on: pull_request: - branches: - - master - - dev push: branches: - master - #- dev* + - develop jobs: build: diff --git a/.github/workflows/build-usb64-linux.yml b/.github/workflows/build-usb64-linux.yml index 74687111..a4d46d46 100644 --- a/.github/workflows/build-usb64-linux.yml +++ b/.github/workflows/build-usb64-linux.yml @@ -1,6 +1,10 @@ name: Build Linux Usb64 App -on: [push, pull_request] + pull_request: + push: + branches: + - master + - develop jobs: build: runs-on: ubuntu-latest diff --git a/.github/workflows/build-usb64-windows.yml b/.github/workflows/build-usb64-windows.yml index 79743e3f..a468e5b9 100644 --- a/.github/workflows/build-usb64-windows.yml +++ b/.github/workflows/build-usb64-windows.yml @@ -1,6 +1,10 @@ name: Build Windows Usb64 App -on: [push, pull_request] + pull_request: + push: + branches: + - master + - develop jobs: build: runs-on: windows-latest From d50a27392a6b9ffd6b280934c1f0e68e228937c6 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:15:16 +0000 Subject: [PATCH 082/118] revert buildon ci for the moment... --- .github/workflows/build-ed64-example-rom.yml | 7 +------ .github/workflows/build-usb64-linux.yml | 7 ++----- .github/workflows/build-usb64-windows.yml | 7 ++----- 3 files changed, 5 insertions(+), 16 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 2e117c8d..1a609632 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -1,11 +1,6 @@ name: Build ED64 Example ROM -on: - pull_request: - push: - branches: - - master - - develop +on: [push, pull_request] jobs: build: diff --git a/.github/workflows/build-usb64-linux.yml b/.github/workflows/build-usb64-linux.yml index a4d46d46..84fa7060 100644 --- a/.github/workflows/build-usb64-linux.yml +++ b/.github/workflows/build-usb64-linux.yml @@ -1,10 +1,7 @@ name: Build Linux Usb64 App - pull_request: - push: - branches: - - master - - develop +on: [push, pull_request] + jobs: build: runs-on: ubuntu-latest diff --git a/.github/workflows/build-usb64-windows.yml b/.github/workflows/build-usb64-windows.yml index a468e5b9..1b236678 100644 --- a/.github/workflows/build-usb64-windows.yml +++ b/.github/workflows/build-usb64-windows.yml @@ -1,10 +1,7 @@ name: Build Windows Usb64 App - pull_request: - push: - branches: - - master - - develop +on: [push, pull_request] + jobs: build: runs-on: windows-latest From 25942ecb2417e22f484104e9aa5a4120e84dc4a4 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:18:37 +0000 Subject: [PATCH 083/118] cd unrecognised?! --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 1a609632..43322b07 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -59,10 +59,10 @@ jobs: working-directory: xio-sample-repo run: >- docker run - --mount type=bind,source=$(pwd),target=/xio-sample-repo/ - --workdir=/xio-sample-repo/ + --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ + --workdir=/xio-sample-repo/ED64-XIO/ ghcr.io/dragonminded/libdragon:latest - cd ED64-XIO && ls && make ${{ matrix.releasetype }} + ls && make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} - name: Upload Artifact From 0351f2a2790d883f4a09613a06a5dfe24c2eea38 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:22:25 +0000 Subject: [PATCH 084/118] second path? --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 43322b07..80f699fc 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -59,8 +59,8 @@ jobs: working-directory: xio-sample-repo run: >- docker run - --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ - --workdir=/xio-sample-repo/ED64-XIO/ + --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ED64-XIO/ + --workdir=/xio-sample-repo/ED64-XIO/ED64-XIO/ ghcr.io/dragonminded/libdragon:latest ls && make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} From f4f7dd098bc91360efec605e7c1cab9414769898 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:26:16 +0000 Subject: [PATCH 085/118] interesting! --- .github/workflows/build-ed64-example-rom.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 80f699fc..1d1080d7 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -52,17 +52,15 @@ jobs: working-directory: xio-sample-repo run: | mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj - cd ED64-XIO - ls - name: Build ROM working-directory: xio-sample-repo run: >- docker run - --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ED64-XIO/ - --workdir=/xio-sample-repo/ED64-XIO/ED64-XIO/ + --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ + --workdir=/xio-sample-repo/ED64-XIO/ ghcr.io/dragonminded/libdragon:latest - ls && make ${{ matrix.releasetype }} + ls && cd ED64-XIO/ && ls && make ${{ matrix.releasetype }} #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} - name: Upload Artifact From 4a534829b1d7bdf53696697b6bfb87804bf98a26 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:44:04 +0000 Subject: [PATCH 086/118] lets try this then... --- .github/workflows/build-ed64-example-rom.yml | 32 ++++++-------------- 1 file changed, 10 insertions(+), 22 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 1d1080d7..45fa1ae1 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -11,29 +11,32 @@ jobs: steps: - uses: actions/checkout@v2 name: Checkout Code - with: - path: xio-sample-repo + # with: + # path: xio-sample-repo - name: Checkout libdragon repo uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: libdragon-repo + #path: libdragon-repo ref: '89d17be8563a44a9b95873d436832a1222757cdc' + - name: Setup Build environment + run: | + mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj + - name: patch libdragon make (workaround ignore warnings as errors) - working-directory: libdragon-repo run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - - name: Buid libdragon - working-directory: libdragon-repo + - name: Buid libdragon and ROM run: >- docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest make libdragon && - make tools + make tools && + ls && cd ../ED64-XIO/ && ls && make ${{ matrix.releasetype }} # sudo npm install -g libdragon # libdragon init @@ -48,21 +51,6 @@ jobs: # libdragon install # libdragon start - - name: Setup Build environment - working-directory: xio-sample-repo - run: | - mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj - - - name: Build ROM - working-directory: xio-sample-repo - run: >- - docker run - --mount type=bind,source=$(pwd),target=/xio-sample-repo/ED64-XIO/ - --workdir=/xio-sample-repo/ED64-XIO/ - ghcr.io/dragonminded/libdragon:latest - ls && cd ED64-XIO/ && ls && make ${{ matrix.releasetype }} - #run: cd /ED64-XIO/ && libdragon make ${{ matrix.releasetype }} - - name: Upload Artifact uses: actions/upload-artifact@v1.0.0 with: From 354d04adf255f39bcb51437d858ffba2ba5dc6b3 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 20:53:35 +0000 Subject: [PATCH 087/118] re-evaluate docker use. --- .github/workflows/build-ed64-example-rom.yml | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 45fa1ae1..bc35e497 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -11,29 +11,34 @@ jobs: steps: - uses: actions/checkout@v2 name: Checkout Code - # with: - # path: xio-sample-repo + with: + path: xio-sample-repo - name: Checkout libdragon repo uses: actions/checkout@v2 with: repository: dragonminded/libdragon - #path: libdragon-repo + path: libdragon-repo ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: Setup Build environment + working-directory: xio-sample-repo run: | + ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj - name: patch libdragon make (workaround ignore warnings as errors) + working-directory: libdragon-repo run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - name: Buid libdragon and ROM + working-directory: ${{ github.workspace }} run: >- docker run - --mount type=bind,source=$(pwd),target=/libdragon - --workdir=/libdragon + --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ + --workdir=${{ github.workspace }}/ ghcr.io/dragonminded/libdragon:latest + cd libdragon && make libdragon && make tools && ls && cd ../ED64-XIO/ && ls && make ${{ matrix.releasetype }} From b3700277e7a438f174af1f531696554827910f37 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:02:33 +0000 Subject: [PATCH 088/118] See what happens! --- .github/workflows/build-ed64-example-rom.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index bc35e497..14a9d95e 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -32,16 +32,19 @@ jobs: sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile - name: Buid libdragon and ROM - working-directory: ${{ github.workspace }} + working-directory: ${{ github.workspace }}/ED64/ run: >- docker run - --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ - --workdir=${{ github.workspace }}/ + --mount type=bind,source=$(pwd),target=/ + --workdir=/ ghcr.io/dragonminded/libdragon:latest cd libdragon && make libdragon && make tools && - ls && cd ../ED64-XIO/ && ls && make ${{ matrix.releasetype }} + ls && + cd ../ED64-XIO/ && + ls && + make ${{ matrix.releasetype }} # sudo npm install -g libdragon # libdragon init From f836887dfe6ca4701e299f69f020af58b177bb90 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:14:59 +0000 Subject: [PATCH 089/118] okay try this... --- .github/workflows/build-ed64-example-rom.yml | 5 +++-- .github/workflows/build-usb64-linux.yml | 8 +++++++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 14a9d95e..192b0fa3 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -35,9 +35,10 @@ jobs: working-directory: ${{ github.workspace }}/ED64/ run: >- docker run - --mount type=bind,source=$(pwd),target=/ - --workdir=/ + --mount type=bind,source=$(pwd),target=/${{ github.workspace }}/ED64/ + --workdir=/${{ github.workspace }}/ED64/ ghcr.io/dragonminded/libdragon:latest + ls && cd libdragon && make libdragon && make tools && diff --git a/.github/workflows/build-usb64-linux.yml b/.github/workflows/build-usb64-linux.yml index 84fa7060..6c079963 100644 --- a/.github/workflows/build-usb64-linux.yml +++ b/.github/workflows/build-usb64-linux.yml @@ -1,6 +1,12 @@ name: Build Linux Usb64 App -on: [push, pull_request] +on: + push: + paths: + - '/**/usb64/*' + pull_request: + paths: + - '/**/usb64/*' jobs: build: From 20c929899aeabc6194f6be5b9769d653823d192b Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:28:22 +0000 Subject: [PATCH 090/118] add dir ls check... --- .github/workflows/build-ed64-example-rom.yml | 17 +++++++++++++++-- .github/workflows/build-usb64-windows.yml | 8 +++++++- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 192b0fa3..fa0045e0 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -1,6 +1,13 @@ name: Build ED64 Example ROM -on: [push, pull_request] +on: [push] //, pull_request] +# on: +# push: +# paths: +# - '/**/ED64-XIO/*' +# pull_request: +# paths: +# - '/**/ED64-XIO/*' jobs: build: @@ -30,12 +37,18 @@ jobs: working-directory: libdragon-repo run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile + ls + + - name: check current work dir + working-directory: ${{ github.workspace }} + run: | + ls -d -- */ - name: Buid libdragon and ROM working-directory: ${{ github.workspace }}/ED64/ run: >- docker run - --mount type=bind,source=$(pwd),target=/${{ github.workspace }}/ED64/ + --mount type=bind,source=$(pwd),target=/root/ --workdir=/${{ github.workspace }}/ED64/ ghcr.io/dragonminded/libdragon:latest ls && diff --git a/.github/workflows/build-usb64-windows.yml b/.github/workflows/build-usb64-windows.yml index 1b236678..c543d600 100644 --- a/.github/workflows/build-usb64-windows.yml +++ b/.github/workflows/build-usb64-windows.yml @@ -1,6 +1,12 @@ name: Build Windows Usb64 App -on: [push, pull_request] +on: + push: + paths: + - '/**/usb64/*' + pull_request: + paths: + - '/**/usb64/*' jobs: build: From 1b4b67b9561a2324a624f14a1cf358a9bf2437ee Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:30:10 +0000 Subject: [PATCH 091/118] correct yaml --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index fa0045e0..1fd94371 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -1,6 +1,6 @@ name: Build ED64 Example ROM -on: [push] //, pull_request] +on: [push] #, pull_request] # on: # push: # paths: From ceafba1b3658cb5bc4d5a90f9de0abfc5de22e40 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:34:56 +0000 Subject: [PATCH 092/118] try listing dirs --- .github/workflows/build-ed64-example-rom.yml | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 1fd94371..a3619bf7 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -43,20 +43,27 @@ jobs: working-directory: ${{ github.workspace }} run: | ls -d -- */ + echo "swith to libdragon" + cd /libdragon-repo/libdragon + ls + echo "switch to XIO" + cd /../../xio-sample-repo/ED64/ + ls + - name: Buid libdragon and ROM working-directory: ${{ github.workspace }}/ED64/ run: >- docker run --mount type=bind,source=$(pwd),target=/root/ - --workdir=/${{ github.workspace }}/ED64/ + --workdir=/${{ github.workspace }}/ ghcr.io/dragonminded/libdragon:latest ls && - cd libdragon && + cd /libdragon-repo/libdragon && make libdragon && make tools && ls && - cd ../ED64-XIO/ && + cd ../../ED64-XIO/ && ls && make ${{ matrix.releasetype }} From 77d8867f57a74851a4c7ac3f1b7795b0026273b5 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:40:41 +0000 Subject: [PATCH 093/118] correct paths --- .github/workflows/build-ed64-example-rom.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index a3619bf7..055e30ac 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -44,10 +44,10 @@ jobs: run: | ls -d -- */ echo "swith to libdragon" - cd /libdragon-repo/libdragon + cd /libdragon-repo/ ls echo "switch to XIO" - cd /../../xio-sample-repo/ED64/ + cd /../../xio-sample-repo/ ls @@ -59,11 +59,11 @@ jobs: --workdir=/${{ github.workspace }}/ ghcr.io/dragonminded/libdragon:latest ls && - cd /libdragon-repo/libdragon && + cd /libdragon-repo/ && make libdragon && make tools && ls && - cd ../../ED64-XIO/ && + cd ../../xio-sample-repo/ED64-XIO/ && ls && make ${{ matrix.releasetype }} From de196530ecbd5d89da50d4e57e57fb54e74e4edd Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:42:02 +0000 Subject: [PATCH 094/118] damn linux --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 055e30ac..c4a8be7d 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -44,10 +44,10 @@ jobs: run: | ls -d -- */ echo "swith to libdragon" - cd /libdragon-repo/ + cd libdragon-repo/ ls echo "switch to XIO" - cd /../../xio-sample-repo/ + cd ../../xio-sample-repo/ ls From 6581273d1e07c036850b40b10f1fc541cd84f414 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:44:01 +0000 Subject: [PATCH 095/118] further corrections --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index c4a8be7d..423c2489 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -47,7 +47,7 @@ jobs: cd libdragon-repo/ ls echo "switch to XIO" - cd ../../xio-sample-repo/ + cd ../xio-sample-repo/ ls @@ -59,11 +59,11 @@ jobs: --workdir=/${{ github.workspace }}/ ghcr.io/dragonminded/libdragon:latest ls && - cd /libdragon-repo/ && + cd libdragon-repo/ && make libdragon && make tools && ls && - cd ../../xio-sample-repo/ED64-XIO/ && + cd ../xio-sample-repo/ED64-XIO/ && ls && make ${{ matrix.releasetype }} From 2829842f66a038ac115605e8ddeba405f9b875d0 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:48:37 +0000 Subject: [PATCH 096/118] Try this --- .github/workflows/build-ed64-example-rom.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 423c2489..3257eacd 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -42,12 +42,12 @@ jobs: - name: check current work dir working-directory: ${{ github.workspace }} run: | - ls -d -- */ + ls echo "swith to libdragon" - cd libdragon-repo/ + cd ./libdragon-repo/ ls echo "switch to XIO" - cd ../xio-sample-repo/ + cd ./../xio-sample-repo/ED64-XIO/ ls @@ -55,15 +55,15 @@ jobs: working-directory: ${{ github.workspace }}/ED64/ run: >- docker run - --mount type=bind,source=$(pwd),target=/root/ + --mount type=bind,source=$(pwd),target=/${{ github.workspace }}/ --workdir=/${{ github.workspace }}/ ghcr.io/dragonminded/libdragon:latest ls && - cd libdragon-repo/ && + cd ./libdragon-repo/ && make libdragon && make tools && ls && - cd ../xio-sample-repo/ED64-XIO/ && + cd ./../xio-sample-repo/ED64-XIO/ && ls && make ${{ matrix.releasetype }} From 1444ecf5f1495036c55fa6a671ca82fde492a3a3 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:50:26 +0000 Subject: [PATCH 097/118] correct docker dirs --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 3257eacd..ab26b20d 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -55,8 +55,8 @@ jobs: working-directory: ${{ github.workspace }}/ED64/ run: >- docker run - --mount type=bind,source=$(pwd),target=/${{ github.workspace }}/ - --workdir=/${{ github.workspace }}/ + --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ + --workdir=${{ github.workspace }}/ ghcr.io/dragonminded/libdragon:latest ls && cd ./libdragon-repo/ && From eaa7ee545f909404f8b39a9782b42835dc10f375 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 21:55:32 +0000 Subject: [PATCH 098/118] correct working dir --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index ab26b20d..76ea6230 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -52,7 +52,7 @@ jobs: - name: Buid libdragon and ROM - working-directory: ${{ github.workspace }}/ED64/ + working-directory: ${{ github.workspace }} run: >- docker run --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ From 45625b818ac67787a5a369e141d1712badc20bb8 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Fri, 3 Dec 2021 22:09:55 +0000 Subject: [PATCH 099/118] just try it! --- .github/workflows/build-ed64-example-rom.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 76ea6230..c28deb29 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -57,6 +57,7 @@ jobs: docker run --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ --workdir=${{ github.workspace }}/ + --env PATH:=$N64_INST/bin;/n64_toolchain ghcr.io/dragonminded/libdragon:latest ls && cd ./libdragon-repo/ && From bc6933e65ec3f979c16c5db3e286a429c6c57c1b Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:07:45 +0000 Subject: [PATCH 100/118] Simplify... --- .github/workflows/build-ed64-example-rom.yml | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index c28deb29..3c5aeb21 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -19,22 +19,22 @@ jobs: - uses: actions/checkout@v2 name: Checkout Code with: - path: xio-sample-repo + path: ${{ github.workspace }} - name: Checkout libdragon repo uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: libdragon-repo + path: ./ED64-XIO/libdragon ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: Setup Build environment - working-directory: xio-sample-repo + #working-directory: xio-sample-repo run: | ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj - name: patch libdragon make (workaround ignore warnings as errors) - working-directory: libdragon-repo + working-directory: libdragon run: | sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile ls @@ -44,10 +44,10 @@ jobs: run: | ls echo "swith to libdragon" - cd ./libdragon-repo/ + cd ./libdragon/ ls echo "switch to XIO" - cd ./../xio-sample-repo/ED64-XIO/ + cd ./../ED64-XIO/ ls @@ -55,16 +55,14 @@ jobs: working-directory: ${{ github.workspace }} run: >- docker run - --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ - --workdir=${{ github.workspace }}/ - --env PATH:=$N64_INST/bin;/n64_toolchain + --mount type=bind,source=$(pwd),target=/ED64-XIO/libdragon/ + --workdir=/ED64-XIO/libdragon/ ghcr.io/dragonminded/libdragon:latest ls && - cd ./libdragon-repo/ && make libdragon && make tools && ls && - cd ./../xio-sample-repo/ED64-XIO/ && + cd ./../ && ls && make ${{ matrix.releasetype }} From e1eea278fe546dcc0783ffa4b01dd5523cff212d Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:10:40 +0000 Subject: [PATCH 101/118] try again... --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 3c5aeb21..1ae8552a 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -18,13 +18,13 @@ jobs: steps: - uses: actions/checkout@v2 name: Checkout Code - with: - path: ${{ github.workspace }} + # with: + # path: ${{ github.workspace }} - name: Checkout libdragon repo uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: ./ED64-XIO/libdragon + #path: ./ED64-XIO/libdragon ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: Setup Build environment From 12b1939db251201479a1805c7529a5175ece3249 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:17:25 +0000 Subject: [PATCH 102/118] And again! --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 1ae8552a..93e697be 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -24,11 +24,11 @@ jobs: uses: actions/checkout@v2 with: repository: dragonminded/libdragon - #path: ./ED64-XIO/libdragon + path: ./ED64/ED64-XIO/libdragon ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: Setup Build environment - #working-directory: xio-sample-repo + working-directory: ${{ github.workspace }}/ED64/ run: | ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj From 087f926c805b4937aa9abc0d9b259969f827255a Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:18:59 +0000 Subject: [PATCH 103/118] and again --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 93e697be..5a741fc8 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -28,7 +28,7 @@ jobs: ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: Setup Build environment - working-directory: ${{ github.workspace }}/ED64/ + #working-directory: ${{ github.workspace }}/ED64/ run: | ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj From 7c9aac27cadaac902cfcc54e6f8ee74e9d52f944 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:22:03 +0000 Subject: [PATCH 104/118] and again... --- .github/workflows/build-ed64-example-rom.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 5a741fc8..fdf7886a 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -24,12 +24,13 @@ jobs: uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: ./ED64/ED64-XIO/libdragon + path: ./ED64-XIO/libdragon ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: Setup Build environment #working-directory: ${{ github.workspace }}/ED64/ run: | + cd ./ED64-XIO/ ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj From 2104315526a45950fb5bff3ab5d93922a7d86a53 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:27:13 +0000 Subject: [PATCH 105/118] correct libdragon path. --- .github/workflows/build-ed64-example-rom.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index fdf7886a..6ccaa6c3 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -28,8 +28,9 @@ jobs: ref: '89d17be8563a44a9b95873d436832a1222757cdc' - name: Setup Build environment - #working-directory: ${{ github.workspace }}/ED64/ + working-directory: ${{ github.workspace }} run: | + ls cd ./ED64-XIO/ ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj @@ -37,8 +38,8 @@ jobs: - name: patch libdragon make (workaround ignore warnings as errors) working-directory: libdragon run: | - sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile ls + sed -z -i.bak 's/ -Wall -Werror / /' ./ED64-XIO/libdragon/Makefile - name: check current work dir working-directory: ${{ github.workspace }} From 10bb02bd77ee28902d6be7a889e2446548fb0967 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:53:12 +0000 Subject: [PATCH 106/118] Further attempt --- .github/workflows/build-ed64-example-rom.yml | 38 ++++++++++---------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 6ccaa6c3..d4cfd084 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -24,41 +24,41 @@ jobs: uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: ./ED64-XIO/libdragon + path: ${{ github.workspace }}/ED64/ED64-XIO/ ref: '89d17be8563a44a9b95873d436832a1222757cdc' - - name: Setup Build environment - working-directory: ${{ github.workspace }} - run: | - ls - cd ./ED64-XIO/ - ls - mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj - - - name: patch libdragon make (workaround ignore warnings as errors) - working-directory: libdragon - run: | - ls - sed -z -i.bak 's/ -Wall -Werror / /' ./ED64-XIO/libdragon/Makefile - name: check current work dir - working-directory: ${{ github.workspace }} + working-directory: ${{ github.workspace }}/ED64/ED64-XIO/ run: | ls - echo "swith to libdragon" + echo "switch to libdragon" cd ./libdragon/ ls echo "switch to XIO" cd ./../ED64-XIO/ ls + - name: Setup Build environment + working-directory: ${{ github.workspace }}}/ED64/ + run: | + ls + mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj + + - name: patch libdragon make (workaround ignore warnings as errors) + working-directory: ${{ github.workspace }}/ED64/ED64-XIO/libdragon + run: | + ls + sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile + + - name: Buid libdragon and ROM - working-directory: ${{ github.workspace }} + working-directory: ${{ github.workspace }}/ED64/ED64-XIO/ run: >- docker run - --mount type=bind,source=$(pwd),target=/ED64-XIO/libdragon/ - --workdir=/ED64-XIO/libdragon/ + --mount type=bind,source=$(pwd),target=/libdragon/ + --workdir=/libdragon/ ghcr.io/dragonminded/libdragon:latest ls && make libdragon && From 5987ff3ea400da237faf44c121136e351fa3cd77 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 00:58:33 +0000 Subject: [PATCH 107/118] try. --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index d4cfd084..8a186eee 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -18,8 +18,8 @@ jobs: steps: - uses: actions/checkout@v2 name: Checkout Code - # with: - # path: ${{ github.workspace }} + with: + path: ${{ github.workspace }} - name: Checkout libdragon repo uses: actions/checkout@v2 with: @@ -29,7 +29,7 @@ jobs: - name: check current work dir - working-directory: ${{ github.workspace }}/ED64/ED64-XIO/ + working-directory: ${{ github.workspace }} run: | ls echo "switch to libdragon" From 046112f76e749330633b5b99f17fe36869e2cbd6 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:05:06 +0000 Subject: [PATCH 108/118] try this --- .github/workflows/build-ed64-example-rom.yml | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 8a186eee..d75ec50d 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -31,22 +31,25 @@ jobs: - name: check current work dir working-directory: ${{ github.workspace }} run: | + ls + echo "switch to ED64-XIO" + cd ./ED64-XIO ls echo "switch to libdragon" cd ./libdragon/ ls - echo "switch to XIO" + echo "switch back to ED64-XIO" cd ./../ED64-XIO/ ls - name: Setup Build environment - working-directory: ${{ github.workspace }}}/ED64/ + working-directory: ${{ github.workspace }}}/ run: | ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj - name: patch libdragon make (workaround ignore warnings as errors) - working-directory: ${{ github.workspace }}/ED64/ED64-XIO/libdragon + working-directory: ${{ github.workspace }}/ED64-XIO/libdragon run: | ls sed -z -i.bak 's/ -Wall -Werror / /' ./Makefile @@ -54,11 +57,11 @@ jobs: - name: Buid libdragon and ROM - working-directory: ${{ github.workspace }}/ED64/ED64-XIO/ + working-directory: ${{ github.workspace }}/ED64-XIO/ run: >- docker run - --mount type=bind,source=$(pwd),target=/libdragon/ - --workdir=/libdragon/ + --mount type=bind,source=$(pwd),target=/${{ github.workspace }}/ED64-XIO/libdragon/ + --workdir=/${{ github.workspace }}/ED64-XIO/libdragon/ ghcr.io/dragonminded/libdragon:latest ls && make libdragon && From 1be291537d22e0cc908e7c673c10883da111e53f Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:07:24 +0000 Subject: [PATCH 109/118] and this --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index d75ec50d..e08fce5b 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: ${{ github.workspace }}/ED64/ED64-XIO/ + path: ${{ github.workspace }}/ED64-XIO/ ref: '89d17be8563a44a9b95873d436832a1222757cdc' From 4a45cca9215c223e3a9580cf048c43f0b4ec8e05 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:09:45 +0000 Subject: [PATCH 110/118] or this --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index e08fce5b..cbb9111b 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v2 with: repository: dragonminded/libdragon - path: ${{ github.workspace }}/ED64-XIO/ + path: ${{ github.workspace }}/ED64-XIO/libdragon/ ref: '89d17be8563a44a9b95873d436832a1222757cdc' From a5d1fc0d061477c55bfae2bff40d755eb893f35d Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:12:22 +0000 Subject: [PATCH 111/118] now? --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index cbb9111b..79f04cb8 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -39,7 +39,7 @@ jobs: cd ./libdragon/ ls echo "switch back to ED64-XIO" - cd ./../ED64-XIO/ + cd .. ls - name: Setup Build environment @@ -67,7 +67,7 @@ jobs: make libdragon && make tools && ls && - cd ./../ && + cd .. && ls && make ${{ matrix.releasetype }} From b36e321b023a458337ac4632836326a0507da793 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:14:49 +0000 Subject: [PATCH 112/118] fix Setup Build environment --- .github/workflows/build-ed64-example-rom.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 79f04cb8..80910b94 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -43,7 +43,7 @@ jobs: ls - name: Setup Build environment - working-directory: ${{ github.workspace }}}/ + working-directory: ${{ github.workspace }} run: | ls mkdir -p ED64-XIO/bin && mkdir -p ED64-XIO/bin/release && mkdir -p ED64-XIO/bin/debug && mkdir obj From 47da6a177069c79fed86820f231cd3e6583ce4e7 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:19:48 +0000 Subject: [PATCH 113/118] correct dir --- .github/workflows/build-ed64-example-rom.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 80910b94..88f69fe0 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -64,6 +64,8 @@ jobs: --workdir=/${{ github.workspace }}/ED64-XIO/libdragon/ ghcr.io/dragonminded/libdragon:latest ls && + cd libdragon && + ls && make libdragon && make tools && ls && From e8aaa57053784524b1616f434c3ca7caab2e1179 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:29:18 +0000 Subject: [PATCH 114/118] some sudo magic? --- .github/workflows/build-ed64-example-rom.yml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 88f69fe0..f55d134a 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -60,17 +60,16 @@ jobs: working-directory: ${{ github.workspace }}/ED64-XIO/ run: >- docker run - --mount type=bind,source=$(pwd),target=/${{ github.workspace }}/ED64-XIO/libdragon/ - --workdir=/${{ github.workspace }}/ED64-XIO/libdragon/ + --mount type=bind,source=$(pwd),target=/libdragon/ + --workdir=/libdragon/ ghcr.io/dragonminded/libdragon:latest - ls && + echo "ED64-XIO dir" && ls && cd libdragon && - ls && - make libdragon && - make tools && - ls && + echo "libdragon dir" && ls && + make libdragon && sudo make install && + make tools && sudo make tools-install cd .. && - ls && + echo "ED64-XIO dir" && ls && make ${{ matrix.releasetype }} # sudo npm install -g libdragon From 9dbe0b85d72f96d9091e20cbff51daedadaee488 Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:37:50 +0000 Subject: [PATCH 115/118] fixes? --- .github/workflows/build-ed64-example-rom.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f55d134a..0c25a389 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -60,14 +60,14 @@ jobs: working-directory: ${{ github.workspace }}/ED64-XIO/ run: >- docker run - --mount type=bind,source=$(pwd),target=/libdragon/ - --workdir=/libdragon/ + --mount type=bind,source=$(pwd),target=/libdragon + --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest echo "ED64-XIO dir" && ls && cd libdragon && echo "libdragon dir" && ls && make libdragon && sudo make install && - make tools && sudo make tools-install + make tools && sudo make tools-install && cd .. && echo "ED64-XIO dir" && ls && make ${{ matrix.releasetype }} From f8d989f8aceaaf816875ae1243571c301e9aee5c Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:42:14 +0000 Subject: [PATCH 116/118] start in dragon dir --- .github/workflows/build-ed64-example-rom.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 0c25a389..f6cfbdad 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -57,14 +57,12 @@ jobs: - name: Buid libdragon and ROM - working-directory: ${{ github.workspace }}/ED64-XIO/ + working-directory: ${{ github.workspace }}/ED64-XIO/libdragon/ run: >- docker run --mount type=bind,source=$(pwd),target=/libdragon --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest - echo "ED64-XIO dir" && ls && - cd libdragon && echo "libdragon dir" && ls && make libdragon && sudo make install && make tools && sudo make tools-install && From 44164e86a263ed245532cf8e12cf7f8d5d0dd79f Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 01:45:34 +0000 Subject: [PATCH 117/118] try. --- .github/workflows/build-ed64-example-rom.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index f6cfbdad..2d506ad8 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -57,12 +57,14 @@ jobs: - name: Buid libdragon and ROM - working-directory: ${{ github.workspace }}/ED64-XIO/libdragon/ + working-directory: ${{ github.workspace }}/ED64-XIO run: >- docker run - --mount type=bind,source=$(pwd),target=/libdragon - --workdir=/libdragon + --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ED64-XIO + --workdir=${{ github.workspace }}/ED64-XIO ghcr.io/dragonminded/libdragon:latest + echo "ED64-XIO dir" && ls && + cd libdragon && echo "libdragon dir" && ls && make libdragon && sudo make install && make tools && sudo make tools-install && From b470aab567a613e6d6203b2b569abf29aef8aa3a Mon Sep 17 00:00:00 2001 From: Robin Jones Date: Sat, 4 Dec 2021 10:34:44 +0000 Subject: [PATCH 118/118] docker dir --- .github/workflows/build-ed64-example-rom.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-ed64-example-rom.yml b/.github/workflows/build-ed64-example-rom.yml index 2d506ad8..677933a9 100644 --- a/.github/workflows/build-ed64-example-rom.yml +++ b/.github/workflows/build-ed64-example-rom.yml @@ -60,8 +60,8 @@ jobs: working-directory: ${{ github.workspace }}/ED64-XIO run: >- docker run - --mount type=bind,source=$(pwd),target=${{ github.workspace }}/ED64-XIO - --workdir=${{ github.workspace }}/ED64-XIO + --mount type=bind,source=$(pwd),target=/libdragon + --workdir=/libdragon ghcr.io/dragonminded/libdragon:latest echo "ED64-XIO dir" && ls && cd libdragon &&