diff options
| author | spicyjpeg <thatspicyjpeg@gmail.com> | 2022-09-22 21:36:29 +0200 |
|---|---|---|
| committer | spicyjpeg <thatspicyjpeg@gmail.com> | 2022-09-22 21:36:29 +0200 |
| commit | 86f0064afb8200e60dd80827535cac30d0eab028 (patch) | |
| tree | c7ef61653b157b69fb0956709366996ddbc4ecfa | |
| parent | 5746b6ef9df16447d78e77d00ad21a4dba0fe169 (diff) | |
| download | psn00bsdk-86f0064afb8200e60dd80827535cac30d0eab028.tar.gz | |
Update version number, clean up old headers
30 files changed, 80 insertions, 69 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index b477b54..f7f4f93 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,16 @@ to ensure the changelog can be parsed correctly. ------------------------------------------------------------------------------- +## 2022-09-22 + +spicyjpeg: + +- libpsn00b: Changed the extension of `gtereg.h`, `hwregs_a.h` and `inline_s.h` + to `.inc`. Cleaned up old leftover PSXSDK headers. + +- Updated documentation and added detailed instructions on how to install + prebuilt releases. + ## 2022-08-21: 0.20 spicyjpeg: diff --git a/CMakeLists.txt b/CMakeLists.txt index 181375c..4f255a2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -12,7 +12,7 @@ include(ExternalProject) project( PSn00bSDK LANGUAGES NONE - VERSION 0.19 + VERSION 0.20 DESCRIPTION "Open source PlayStation 1 SDK" HOMEPAGE_URL "http://lameguy64.net/?page=psn00bsdk" ) diff --git a/examples/demos/n00bdemo/smd.s b/examples/demos/n00bdemo/smd.s index f9cf2fe..d25f760 100644 --- a/examples/demos/n00bdemo/smd.s +++ b/examples/demos/n00bdemo/smd.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .include "smd_s.h" diff --git a/examples/demos/n00bdemo/smd_cel.s b/examples/demos/n00bdemo/smd_cel.s index ece0dd8..383f043 100644 --- a/examples/demos/n00bdemo/smd_cel.s +++ b/examples/demos/n00bdemo/smd_cel.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .include "smd_s.h" diff --git a/examples/demos/n00bdemo/smd_flat.s b/examples/demos/n00bdemo/smd_flat.s index 0d48c63..4b47be4 100644 --- a/examples/demos/n00bdemo/smd_flat.s +++ b/examples/demos/n00bdemo/smd_flat.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .include "smd_s.h" diff --git a/libpsn00b/include/ctype.h b/libpsn00b/include/ctype.h index b79498a..24ee9d9 100644 --- a/libpsn00b/include/ctype.h +++ b/libpsn00b/include/ctype.h @@ -1,7 +1,20 @@ -#ifndef _CTYPE_H -#define _CTYPE_H +/* + * PSn00bSDK standard library + * (C) 2019-2022 PSXSDK authors, Lameguy64, spicyjpeg - MPL licensed + */ -extern int tolower(int chr); -extern int toupper(int chr); +#ifndef __CTYPE_H +#define __CTYPE_H -#endif
\ No newline at end of file +#ifdef __cplusplus +extern "C" { +#endif + +int tolower(int chr); +int toupper(int chr); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libpsn00b/include/gtereg.h b/libpsn00b/include/gtereg.inc index 0d051fc..0d051fc 100644 --- a/libpsn00b/include/gtereg.h +++ b/libpsn00b/include/gtereg.inc diff --git a/libpsn00b/include/hwregs_a.h b/libpsn00b/include/hwregs_a.inc index c78b41a..c78b41a 100644 --- a/libpsn00b/include/hwregs_a.h +++ b/libpsn00b/include/hwregs_a.inc diff --git a/libpsn00b/include/inline_s.h b/libpsn00b/include/inline_s.inc index 68e0d07..68e0d07 100644 --- a/libpsn00b/include/inline_s.h +++ b/libpsn00b/include/inline_s.inc diff --git a/libpsn00b/include/string.h b/libpsn00b/include/string.h index 365d238..ceee066 100644 --- a/libpsn00b/include/string.h +++ b/libpsn00b/include/string.h @@ -1,13 +1,10 @@ /* - * string.h - * - * Prototypes for string functions of the C library - * - * PSXSDK + * PSn00bSDK standard library + * (C) 2019-2022 PSXSDK authors, Lameguy64, spicyjpeg - MPL licensed */ -#ifndef _STRING_H -#define _STRING_H +#ifndef __STRING_H +#define __STRING_H #ifdef __cplusplus extern "C" { @@ -19,11 +16,6 @@ char *strpbrk(const char *dst , const char *src); char *strtok(char *s , char *set); char *strstr(const char *big , const char *little); -//int strspn(char *s , char *set); -//int strcspn(char *s , char *set); -//int index(char *s , int c); -//int rindex(char *s , int c); - char *strcat(char *s , const char *append); char *strncat(char *s , const char *append, int n); char *strcpy(char *dst , const char *src); @@ -34,9 +26,6 @@ char *strrchr(const char *s , int c); void *memmove(void *dst , const void *src , int n); void *memchr(void *s , int c , int n); - -// Functions converted to ASM - void *memcpy(void *dst , const void *src , int n); void *memset(void *dst , char c , int n); int memcmp(const void *b1 , const void *b2 , int n); @@ -46,4 +35,3 @@ int memcmp(const void *b1 , const void *b2 , int n); #endif #endif - diff --git a/libpsn00b/include/strings.h b/libpsn00b/include/strings.h index e5e88d4..7223ab9 100644 --- a/libpsn00b/include/strings.h +++ b/libpsn00b/include/strings.h @@ -1,18 +1,19 @@ -/* - * strings.h - * - * PSXSDK +/* + * PSn00bSDK standard library + * (C) 2019-2022 PSXSDK authors, Lameguy64, spicyjpeg - MPL licensed */ -#ifndef _STRINGS_H -#define _STRINGS_H +#ifndef __STRINGS_H +#define __STRINGS_H #include <string.h> -#define bcopy(src,dst,len) memmove(dst,src,len) -#define bzero(ptr, len) memset(ptr, 0, len) -#define bcmp(b1,b2,len) memcmp(b1,b2,len) -#define index(s, c) strchr(s, c) -#define rindex(s, c) strrchr(s, c) +/* Compatibility macros (this header is useless) */ + +#define bcopy(src, dst, len) memmove(dst, src, len) +#define bzero(ptr, len) memset(ptr, 0, len) +#define bcmp(b1, b2, len) memcmp(b1, b2, len) +#define index(s, c) strchr(s, c) +#define rindex(s, c) strrchr(s, c) #endif diff --git a/libpsn00b/psxapi/_initcd.s b/libpsn00b/psxapi/_initcd.s index c3a2861..600d686 100644 --- a/libpsn00b/psxapi/_initcd.s +++ b/libpsn00b/psxapi/_initcd.s @@ -1,7 +1,7 @@ .section .text .set noreorder -.include "hwregs_a.h" +.include "hwregs_a.inc" .global _InitCd .type _InitCd, @function diff --git a/libpsn00b/psxcd/_cd_control.s b/libpsn00b/psxcd/_cd_control.s index c4153ff..5fa336a 100644 --- a/libpsn00b/psxcd/_cd_control.s +++ b/libpsn00b/psxcd/_cd_control.s @@ -1,6 +1,6 @@ .set noreorder -.include "hwregs_a.h" +.include "hwregs_a.inc" .section .text diff --git a/libpsn00b/psxcd/cdgetsector.s b/libpsn00b/psxcd/cdgetsector.s index 9f38e7a..6a29069 100644 --- a/libpsn00b/psxcd/cdgetsector.s +++ b/libpsn00b/psxcd/cdgetsector.s @@ -1,6 +1,6 @@ .set noreorder -.include "hwregs_a.h" +.include "hwregs_a.inc" .section .text diff --git a/libpsn00b/psxcd/cdmix.s b/libpsn00b/psxcd/cdmix.s index 745fb65..40cd181 100644 --- a/libpsn00b/psxcd/cdmix.s +++ b/libpsn00b/psxcd/cdmix.s @@ -1,6 +1,6 @@ .set noreorder -.include "hwregs_a.h" +.include "hwregs_a.inc" .section .text diff --git a/libpsn00b/psxcd/psxcd_asm.s b/libpsn00b/psxcd/psxcd_asm.s index 129bc89..906ab32 100644 --- a/libpsn00b/psxcd/psxcd_asm.s +++ b/libpsn00b/psxcd/psxcd_asm.s @@ -1,6 +1,6 @@ .set noreorder -.include "hwregs_a.h" +.include "hwregs_a.inc" .section .text diff --git a/libpsn00b/psxgpu/readme.txt b/libpsn00b/psxgpu/readme.txt index 2963b6a..67aa110 100644 --- a/libpsn00b/psxgpu/readme.txt +++ b/libpsn00b/psxgpu/readme.txt @@ -17,5 +17,4 @@ Library developer(s): Library header(s): - hwregs_a.h (GNU assembler port defs) psxgpu.h diff --git a/libpsn00b/psxgte/applymatrixlv.s b/libpsn00b/psxgte/applymatrixlv.s index 332a2f8..3180d0f 100644 --- a/libpsn00b/psxgte/applymatrixlv.s +++ b/libpsn00b/psxgte/applymatrixlv.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/compmatrixlv.s b/libpsn00b/psxgte/compmatrixlv.s index 95da5e9..2908eb9 100644 --- a/libpsn00b/psxgte/compmatrixlv.s +++ b/libpsn00b/psxgte/compmatrixlv.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .set MATRIX_r11r12, 0 .set MATRIX_r13r21, 4 diff --git a/libpsn00b/psxgte/initgeom.s b/libpsn00b/psxgte/initgeom.s index 14ca293..d004ecc 100644 --- a/libpsn00b/psxgte/initgeom.s +++ b/libpsn00b/psxgte/initgeom.s @@ -1,6 +1,6 @@ .set noreorder -.include "gtereg.h" +.include "gtereg.inc" .section .text diff --git a/libpsn00b/psxgte/mulmatrix.s b/libpsn00b/psxgte/mulmatrix.s index 19dabe8..08c79c2 100644 --- a/libpsn00b/psxgte/mulmatrix.s +++ b/libpsn00b/psxgte/mulmatrix.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/mulmatrix0.s b/libpsn00b/psxgte/mulmatrix0.s index 874226b..c2fd859 100644 --- a/libpsn00b/psxgte/mulmatrix0.s +++ b/libpsn00b/psxgte/mulmatrix0.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/pushpopmatrix.s b/libpsn00b/psxgte/pushpopmatrix.s index d10687a..ca6b992 100644 --- a/libpsn00b/psxgte/pushpopmatrix.s +++ b/libpsn00b/psxgte/pushpopmatrix.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/readme.txt b/libpsn00b/psxgte/readme.txt index 13067ee..3242474 100644 --- a/libpsn00b/psxgte/readme.txt +++ b/libpsn00b/psxgte/readme.txt @@ -21,9 +21,9 @@ Library developer(s): Library header(s): - gtereg.h + gtereg.inc inline_c.h - inline_s.h + inline_s.inc psxgte.h diff --git a/libpsn00b/psxgte/scalematrix.s b/libpsn00b/psxgte/scalematrix.s index 3e83800..1b2b6dd 100644 --- a/libpsn00b/psxgte/scalematrix.s +++ b/libpsn00b/psxgte/scalematrix.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/scalematrixl.s b/libpsn00b/psxgte/scalematrixl.s index 014b85a..53c2d14 100644 --- a/libpsn00b/psxgte/scalematrixl.s +++ b/libpsn00b/psxgte/scalematrixl.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/square0.s b/libpsn00b/psxgte/square0.s index d037b7e..a8ca107 100644 --- a/libpsn00b/psxgte/square0.s +++ b/libpsn00b/psxgte/square0.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/squareroot.s b/libpsn00b/psxgte/squareroot.s index a038e18..72198b4 100644 --- a/libpsn00b/psxgte/squareroot.s +++ b/libpsn00b/psxgte/squareroot.s @@ -1,7 +1,7 @@ .set noreorder -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxgte/vectornormals.s b/libpsn00b/psxgte/vectornormals.s index 939c4d1..85e94e6 100644 --- a/libpsn00b/psxgte/vectornormals.s +++ b/libpsn00b/psxgte/vectornormals.s @@ -1,8 +1,8 @@ .set noreorder .set noat -.include "gtereg.h" -.include "inline_s.h" +.include "gtereg.inc" +.include "inline_s.inc" .section .text diff --git a/libpsn00b/psxsio/_sio_control.s b/libpsn00b/psxsio/_sio_control.s index bf3b9b9..6378def 100644 --- a/libpsn00b/psxsio/_sio_control.s +++ b/libpsn00b/psxsio/_sio_control.s @@ -1,6 +1,6 @@ .set noreorder -.include "hwregs_a.h" +.include "hwregs_a.inc" .section .text |
