ps2dev / ps2toolchain

This program will automatically build and install a compiler and other tools used in the creation of homebrew software for the Sony PlayStation® 2 videogame system.
BSD 2-Clause "Simplified" License
239 stars 73 forks source link

Merging Newlib updates and POSIX compatibility #46

Closed uyjulian closed 4 years ago

uyjulian commented 6 years ago

See the following: https://github.com/BoGanon/ps2sdk (posix branch)
https://github.com/BoGanon/ps2toolchain (my_changes and newlib-3.0.0 branches)

It would be nice to have the branches merged. I'll cherry-pick small changes first, then see what's left.

fjtrujy commented 6 years ago

Good news!!! If you need help, just ping me, I will do my best to help you!

Thanks

sp193 commented 6 years ago

It is really great that somebody is making such major changes that are not easy to complete, but I feel that it is better to have a better separation of the patches. The current patches are not very clearly labelled and I do not even understand how all of them work or if they are all necessary. In the case of the Newlib patches, I cannot seem to tell which ones are actually required for this project of consolidating Newlib.

I have no idea why we must have POSIX compliance when Sony did not, which will cause some of our functions to not be compatible with the documentation. Furthermore, his series of patches from the POSIX branch seem to be lumped with other changes.

@ragnarok2040 worked on Newlib 3.0.0. However, that version will not compile normally under GCC v3, due to its dependency on some type definitions that only GCC v4 and later will supply. We are having to hack up our tools, just to make it work. So here we also have a choice: should we actually be hacking up GCC to support a new Newlib version? Are there any benefits from doing so? If there are not so many benefits, then would it not be better to use an older version of Newlib, unless a new toolchain is completed?

He also changed GCC to have the G option set to 0 by default (affects all projects and is likely a MIPS-wide setting), but I feel it should be fixed by setting the Newlib compile flags to use G0 during building instead. So I think his patches need some reviewing and explanation.

sp193 commented 6 years ago

If you guys are willing to help with sorting out his work, that would be great. I cannot commit resources to this effort over the next few weeks (and over the past months), hence why I did nothing.

We can have discussions here to discuss what we want and do not want.

fjtrujy commented 6 years ago

Hello @sp193 ! Thanks for you quick reply. As I said I'm more than happy to help you with this, I'm not an expert over here, so, I don't know if jump to the GCC v4 will bring benefits.

By the way, now that you are mentioning the to have the G option set to 0 by default, do you know if the option 0 is working fine in the current status? I'm suffering weird issues with this.

Thanks

sp193 commented 6 years ago

We are not moving to GCC v4, since we are stuck with v3.2 due to our console having non-standard MIPS architectures. My point is that we are not, hence there is a need to either go with a version of Newlib that is compatible with v3.2 or to hack up the old toolchain to make it compatible with new Newlib versions. If you tried to compile Newlib v3.0 with GCC 3.2, it will normally fail.

As of now, we have no newer toolchain that will work with certainly no issues related to code generation for the R5900, while also having support for MMI. Which is why we are still using GCC v3.2.

When G is set to 0, small data will not be put into the small data section at all. The $gp register is not used as a consequence. This is equivalent to using the mno-gpopt option. A program must have all parts compiled with the same G value, if mgpopt is used. Although a program that uses mgpopt may link with a library that does not. Hence when we compile a library, it should be compiled with mno-gpopt, so that all programs can link with it, regardless of what G value was used. For years, we were using G0 as an option while building Newlib. It went missing sometime back due to a mistake, but was added back. If all other MIPS targets have a non-zero default for G, which is the impression that I am getting, why should we change it?

uyjulian commented 6 years ago

Here are a list of changes: For posix branch of ps2sdk:

+ 53ccc4a001257479b73cd574b2d9f856026e118a Remove common/include/io_common.h
+ 61de4c1f2f102cf2829c635a7f8b6553a384fb92 Replace fio_stat_t/fio_dirent_t and add fcntl.h for EE and IOP.
+ 54c1b8009eea812e8a7e8163771897b9e9f601fa Sanitize the standard C library headers
+ a48c3fffe59af6464dd3e0641ac1690f2fcce463 Fix compile issues and add some standard definitions
+ bb5294af9fed7260af22e06037153ee5d7316bba Add some additional headers to common/sys for compatibility.
+ d7c8085a6626d945f5319a185546ab9962f1f81c Fix undefined type error in netman.h
+ b94d870fbb1a96e7906e1a70aba8d1c494ac9f12 Add install-headers rule and use symbolic linking for common headers.
+ 5063500dc3d635a53c508d1e787495283a64a949 Fix samples
+ 540664fcef995aad459e21d5e8093568553fc6ec Add working mktime and stubs for time/times
+ d2e0716923d5806c473c80b9a1cf0adcb4f30014 Fix locale.h and add working stubs of setlocale/localeconv
+ 2aed72ddfda49a3b349a262a48413baf604c12e7 Flesh out sys/stat.h and sys/types.h
+ ebeebc9447b86a641124c235e01dc1d5ddf9291a Add internal ee/kernel/src/kernel/string.h
+ d3d95c6f27b867881519de61072f204e6cfcd9dd Remove libc/include from ee/Rules.make
+ 82b54e5899dfa09f8407fe89ae62f3334a46e389 Move libfileio out of kernel and add POSIX functions to fileXio/fileio
+ 404112ed8962f0fed1245bc5a0b41cdc1ce403ed Add rule to copy subdirs for samples
+ aa52437a982cba84e4cc5e66d1764214df140985 Add tests for mktime, fwrite, opendir, closedir, and readdir
+ 98a1061562187bff2f265193b58f546bbf80a1d6 Remove opendir/readdir/closedir/rewinddir stubs
+ 0151f258e6f817970baa339a9592b5e957c7eda1 Fix opendir/readdir/closedir and move unlink to file I/O libraries
+ 7c622b36fe8b55b2373a80d2b1e0058065b1f940 Fix fopen extended mode support and add offset checking to fseek
+ 6cf405c94b96ff4624871e3ca9e34c30d66636d3 Add file permission flags to open call for erl.
+ 3d2721ec95b2992b71efc5c59d35a0c203cde2f4 Fix setlocale when empty string is passed.
+ f0a9c25fd6dd32fb1bee403296a7c36cda5a7b20 Add sbrk declaration to unistd.h
+ 66c9f38fffb3f0d4cda1008de3cee71c7b544c57 Remove trailing whitespace
+ 5b7b38ddb054587039bc129c4bec477baf55454d Initial commit of fdlibm 5.3 to ps2sdk
+ 3ada0fe8fcb8a1a078fd6dbceeae6cfcc95fd073 Update fdlibm 5.3 with last changes from Julia language maintainers.
+ 867da19282267017e32b181e8f04a8528c9797ce Move math.h to fdlibm/include and flesh out declarations.
+ b9f647b57b6d023f10cf396f20940d5908b5ac62 Fix all compiler warnings and add missing isinff and isnanf definitions
+ 596b3edc48892ce1dbf538a2afdc2031a334dfe8 Update fdlibm with bugfixes from FreeBSD
+ 50b3baf3d92a197e34a8b87ee347b1477fc684bc Remove s_finite.c and s_finitef.c
+ 10e8fbd846c9edb791b6c545f61ed1a4454bc797 Remove w_dremf.c
+ f5e435201495e99d186cdcfb3ab727dda5a75261 Add newline to end of strings.h
+ 856b0230f9e476d4d495a0835a31c901b16d2527 Add tgammaf wrapper around tgamma
+ 3c01e266f13985bfe16b673d1fdd2d8c6e3f0879 Add EXTRACT_WORD64 and INSERT_WORD64 to math_private.h
+ ea70aee0a7ba5532efd9d578adb2f8d54e15403f Change finite to isfinite for scalb and scalbf
+ dc23d5f2bacd52486a41e2fff8ac4b1987b8694c Change uint64_t to u_int64_t for parity with u_int32_t
+ 9ad3d0b432f77e3df3c01d35a5b350e8c8ebed34 Add accuracy fix for exp(1.0) from openlibm
+ e8e552b1466ddb00b27886871c304c387cc399a7 Change pio2 in e_asinf.c back to double precision
+ 37259eb24a7c9d21e770574c2c1ff6f891ae6246 Rename s_isinff.c to s_isinf.c and prefix symbol names with underscores
+ a22edfd9ad01a7837013434e4aca8fb0d438d1a1 Add scalbln and scalblnf definitions wrapped around scalbn and scalbnf
+ b57b9b1a27b77648398dbb57d5950f5a531f91a3 Add fenv.h tailored for r5900
+ 37b080d9226d279c32f4d8e766b1d4d414c42c94 Add fma() from FreeBSD with some fixes for nonstandard code.
+ 5e47a6b615076cd339bd18a728fe6ad5b157681d Add fmaf() from FreeBSD with fixes for nonstandard code.
+ e316555b3e5afca741e0d54893296a98b600c03b Add fdim, fdimf, fmax, and fmin from FreeBSD
+ 3ee1aaaad9d52e835cc30f458c333c3546bffe29 Add remquo() and round() from FreeBSD
+ 0406d727892ed8bf9c48d6ead7a2e3732e697b1e Add lround(), lroundf() from FreeBSD with fixes for nonstandard code.
+ 3193fd8310f5bdea148cfcbc8444a942905fcab6 Add llround(), llroundf() from FreeBSD
+ b88a6b1eeb27b4dd00f2112dfbfb3868522d2b77 Add lrint(),lrintf() from FreeBSD with fixes for nonstandard code
+ 08f5cb82cba9b56597047cd9f232ad25a27811c1 Add llrint(),llrintf() from FreeBSD
+ fd7844e54be8cd12b6fd91d7346b1b306bfa51b0 Add nearbyint(),nearbyintf() from FreeBSD
+ 73c0717b5273451859ffd12b2a5be6dfd757392e Add __fpclassify(),__fpclassifyf()
+ 24875d594178f76895a515e659b2b7dbd9855904 Add __isfinite(),__isfinitef()
+ a532fdaeb429e16c5690909451dac83bf73f8e0e Add __isnormal(),__isnormalf()
+ 5aa71876883fab7e4d0f96997daa6a9fa734601e Change signbit(),signbitf() to __signbit(),__signbitf()
+ f80137a4451790ca26c96704e9f60b31e3d247fb Move isnanf() to s_isnan.c and add underscore prefix to symbol names
+ d831b1755874d728fed380a7d2ffce0e396cbd6a Finish math.h with c99 macros and declarations for added functions
+ 0475b42f909802e13d75bce9ebdadbacbcdd5312 Update fdlibm Makefile
+ 3f983ff383c5b0ec60e7af1fc20762afd694f3bf Forgot to remove stdio.h from fileio.c when debugging
+ a20c8d86c4d79e83a5af6b463d05327503e5103a Add nan(),nanf() from FreeBSD modified to be libc independent
+ 6472712fb6bdc58a5969e231bfc5b8c5cbf84da1 Remove old hypot implementation
+ 7f10097b0ae7ed9c06831a77afb4b365e2542436 Add slightly faster hypot
+ afada0480e49f8e0afdfa8b539ee9e2e92ab0227 Update FDLIBM
+ b1650c49d3aacd24e20c3d761e25259ef8d6c9cc Update FDLIBM
+ aa8e5d6ab5591aadd826d78da0f7a7bb690d2ca0 Update FDLIBM. Added constants for added accuracy when rounding towards zero.
+ 33c551802f3c4d6d1224b422fcc3b37643ce062e Update FDLIBM. Optimized sqrt and sqrtf.
+ 50eb331e607a987b21d9dd3cc33e2bba1159667e Update fenv.c and fenv.h. Added external symbols and additional support for soft floats.
+ 5a1e9e2c2a6b3411c718ee6867459113c78d3a57 Update FDLIBM Makefile
+ 9c7d5291185fba31af56c28cc1af2a08bc4ce11d Added LICENSE for FDLIBM
+ 22209d913f9cd963b45fff25be7db31c2a93d128 Support %ll format in printf.
+ ef57fbbc3d06b45ecc2c480c4b7b4fdb7f055269 Fix for pad_close() to wait for padPortClose to return 0.
+ 23a642382726bca6cbe6482ffe3638f8a8835836 Change SUBDIRS to add one directory per line in Makefiles
+ bc714fe0e4838a4f0574b158716bcd807e9e70e0 Cleanup $ID$, headers, fix compile-time errors from merge.
+ e015fb6363508f0bb63c87e42fb54cc330495b10 Fix install-headers rule for installing headers.
+ 64d8236f709a76050f56cdc585ae86879cea7d08 Change '#ifdef F_...' to #if defined(F_...) || defined(DOXYGEN)
+ 7aba1584a7cc2e753ddf4c96d6fe5bff78b2e552 Fix file permissions to non-executable
+ 23b12b2df54b73d2869fc4efd92f0667180e4f13 Comment out PAD defines in input.h
+ 027d8465f0b6dea4bf629311794552ee0206ff86 (DOXYGEN) Create libpad group and fix warnings.
+ f4e50debc28591954f5d889ba722ccb79c78e875 (DOXYGEN) Fix warnings.
+ 036926072c1286c9f55779b638cc6f46a540e8d2 (DOXYGEN) Add audsrv group and fix warnings.
+ 2e683c78869d4c8d97f63719fbf2d89ebe9944d9 (DOXYGEN) Add libcdvd group and fix warnings.
+ 3ca756645d17845eaba630fe292c51f1399a02f5 (DOXYGEN) Add libmc group and fix warnings.
+ f4aa99a06b71a6b53f6d71e875f9f09051d845a6 (PACKET) Remove packet_increment_qwc declaration.
+ 1f0f9d2e56317688f07aabd5f73bcce917978e17 (TCPIP) Use sys/time.h, sys/fcntl.h, and fix doxygen warnings.
+ 1d9fd3e5bd3164c6d615947beddef7ebe30f000f Fix typo in README.md
+ 71ed540f0f1d283a42f7277b1960d09da68b38c9 (DOXYGEN) Fix ee/debug warnings.
+ feab0a3fae8e25cdafad4f8a2e571364ad4fd5dd (FILEXIO) Fix conflict with common/ps2ip_rpc.h
+ 7f6069df2a2fffe0f9b456db0dca1cf5119ce348 (FILEIO) Remove redundant fio_stat_t and fio_dirent_t.
+ 3380e90bcc382a1bab3857fa54e443534435de78 (DOXYGEN) Add SBV Patches group to sbv_patches
+ 41f14c984f1fc0aaf2b0de2c1a63cc891f1bc80a (DOXYGEN) Create FileXio group
+ 40385e2312028ac813fad8a251d13607ad0172af (DOXYGEN) Create Fileio group
+ 7749520e2ce81b10c243f5b7b25a58db302c7ea2 Fixup comments in common/include/sys/stat.h
+ b644fd5e0055ab050a7c9fd1f2455f4998207c57 (DOXYGEN) Fix file descriptions
+ 5735e17d14dc38f5ca063acc694516fdbdcddbbd (POSIX) Use better values in common/include/sys/param.h
+ 1c4f0ec361a385d3454cbd05ee949c61d7c1e815 (LICENSE) Add FDLIBM's copyright license to LICENSE
+ 13d2ccc28bb34e4c0c1bd4b7df38eed31fe0a007 (MAKEFILE) Fix install of AUTHORS,CHANGELOG,ID,LICENSE,README.md
+ 9e0255efd67831a60d0bc6b6be939ed1a7413fdf (MAKEFILE) Fix install-headers and add install of fdlibm headers
+ d8f1dcde6449436d7dba2bb998bedea1922aeaaf (LICENSE) Rename LICENSE to LICENSE.md
+ b4d6a124e13318f8d5ac6f30165deddcd4485ac5 (LICENSE) Add heading for AFL 2.0 license
+ a620d646e620c87352c0e58d59edb97c59198987 (POSIX) Make sure stat() returns 0 on success
+ c413e22b5a92b87e3babd35dc888a1d95950a3bc (MAKEFILE) Fix running ee-gcc when it doesn't exist
+ f101ffcf1c6690756dce27cfbc24ed62b64a38c5 (MAKEFILE) Fix for parallel jobs, wildcard usage, and build speed
+ 984901588dd036d7e6bce2633babdf0869a4c30a (MAKEFILE) Forgot to rename LICENSE to LICENSE.md in Makefile
+ cf4862ebfbf3b850a98fba5c2acfdb6e27216f09 Fix feature testing for gcc-3.2.3 and add finitef for libstdc++
+ 34cfa896b4afe39d979dd75c12b1a1963fe97521 Fix standards checking in math.h
+ 4eb2eb096d254b3bc406a2a4534a901156ec1732 (LIBC) Add declarations to headers so gcc-3.2.3 doesn't fix them.
+ 5d0706ece253c23b1e3fb77c8c52b201322eca36 (FDLIBM) Fix -std=c99 and non-ansi C builds
+ 6246a44a24a2adacb45cbcba6d12a2370a2bac08 (MAKEFILE) Fix race condition for .c files in iop/Rules.make
+ 7e6d5af2963d6fe779a916cca33c4591d755cc97 (MAKEFILE) Clean up the main Makefile a little.
+ 97359983524724fceff315f186147c015e714ab8 (MAKEFILE) Remove messages from samples/Makefile
+ 6f5c150a8d6701ad7d5d2f5521d478fc03633616 (MAKEFILE) Prevent possible race condition in tools/Rules.make
+ a2ee54bbcab203ff301c6a1f4585b5322ef47d2f (MAKEFILE) Reorganize main Makefile
+ c1ad77960f28fde2829f639071f7128c537eac3a (LIBC) Move common/include/sys into libc/include
+ 745640a7d260a1b187538394bb36047f658b739f (LIBHDD) Move sys/ioctl.h to sys/libhdd_ioctl.h
+ 8b6ba1086a49d719896a00d6166418d5dd8d3bcd (LIBC) Moved standard headers to ee/libc/include
+ 4c02abffadc9790ce5031ff507eae4e901dd0b40 (LWIP) Revert including sys/time.h
+ d92d3a9f099c9838966880e6fc4cc5d630e64642 (IO) Replace use of standard SEEK and O_* file flags
+ 44c89f357e2dd9c4c943c21ed51d12d4853bd858 (MAKEFILE) Remove inclusion of ps2sdk's libc headers
+ 0cb0f835fe72d9e013e438f31c74a606c5a37715 (MAKEFILE) Create include/sys, make relative symlinks for common headers
+ efe92628319494189a5dae15a27a8091c3525758 (LIBC) Fix warnings when compiling with newlib
+ c8fcc7ce2040820464eb8c94becd028016487682 (LIBC) Add ps2_sbrk to kernel Makefile and make crt0.s work with newlib
+ a4ce67fd947cb3455851d21e7a09730309619080 (LIBC) Added DOXYGEN tests for loadfile and fixed for newlib
+ 2eb064ad0ebcc7f5ece1f88d427dace861320c99 (MAKEFILE) Install libc and libm to $(PS2SDK)/ee/libc for now
+ 390b0e764cd7e12fb0e1a1181cbbc92463d56f48 (LIBC) Update stdio.h, stdlib.h, sys/param.h, sys/stat.h
+ 399bfc0237ca9c3b7e7ae1ae2878dc78b0bbe217 (LIBC) Fix libc errors
+ 338267e1721665f03fd60af0bf5051886bb5c8ca (LIBC) Remove ps2_sbrk from being added. Fix fctnl.h
+ 88418d4ba979dc4857bd2ec05e1fcf5a08569e3e (KERNEL) Remove inclusion of kernel/src/unistd.h
+ a2c3969ae9c641f173579ec8e2caeadce5bae664 (ERL) Install samples to erl subdirectory
+ 82d797af15980549bbe254ae27284bd952610be4 (KERNEL) Forgot to add sio_printf.o to SIO_OBJS
+ 26a36446a19879a2c19606d79d33bddc656364aa (LIBC) Fix mcount
+ f106e9ca4bd64f05b84cf7f39d249f29def56b31 Fix samples
+ 3ffc7f5d9fdc3eab27e1859fb4c570bba8305d1c (LIBC) Missed another header in mcount
+ ed09fb7053e2117f4c2b9a4f5f70dc0fe0246202 (LIBC) Fix headers
+ 11c26eabd167a120d59145b460a19fa4d1b38c65 (LIBC) Add long long support to vxprintf
+ d6baa597592e9f70a1453b8443126ead6b119328 (FILEXIO) Add back inclusion of stdarg for fileXioOpen
+ 8e4c3626e4b57bde54a7bf9a0c1c270123108aad (LIBC) Fix exit, atexit, and make crt0.s compatible with newlib.
+ 042a2a2fbf7dd7ad68582a5397c27b6718ebf2a6 (LIBC) Add long long support for vxwprintf
+ c7b3c077bcbde404512a164c4887b30dab81c76d (COMMON) Added ee_int.h to common, it's a stdint.h replacement.
+ b03e6d578af15f3579ecd20bb8414dee2240ae12 Forgot LL for long long types.
+ 986d616015e28c3c9833806f213aa56fca4e813b Fix header guard
+ 8b0a3311e9d1eed3f434aa20aa1401cd3555accc (COMMON) Add ee_inttypes.h and move ee_int.h to ee_stdint.h
+ fc06b95f333493e4cd10f066a07c1a0adb578968 (LIBC) Use long for least 64-bit types and fix unsigned 64-bit max.
+ 7651cc6384552139a2a292c8ef10da285ba8cb2b (FILEXIO) Fix undefined ENOPKG with newlib-3.0.0
+ c64866d69bb19143a2c8106b4514011ac03b3f0a (FILEIO) Fix mkdir definition for newlib-3.0.0
+ a75ed224524dcc09fe0a0014180fc09c9b1227c2 (CRT0) Compatible crt0 with newlib
+ 2da230ab0fdd4e35b455212763394acf9e37863a (FILEIO) Forgot Makefile
+ 9e3cc1e9e09cbadd8e37f5396f1877c61b1edfa6 (FILEIO) Use nonstandard IO_* flags for fio and fileXio functions.
+ 8c5e85ff00f86ec4cb0db935cf542d2e0a893f07 (LIBC) Remove weak attributes
+ f90b3200567fc79d44cea634e6e9ebe816aaa1d1 (LIBC) Add initfini array support
+ a25ab44e7b4cbace41909cd11bb41fcee37b54c7 (LIBC) Comment out gnu c99 builtin types in limits.h
+ c548da4a20dab475a36191a5af7a8210f757e0bf (CRT0) Documenting changes for ctors, dtors.
+ 006ee171a0caf219dd2cfa60a913b933185397d1 (FILEIO) Fix visibility of readdir entries.
+ 4eb8b29a87b8f3428c41be3bfd644b38b775edcb (LIBC) Clean up of libc, add setvbuf and setbuf.
+ c5312ecd741e6446a1de1f77131b9ea5ef1ad3b5 (MAKEFILE) Use abspath for PS2SDK var and some tidying up.
+ c4ae554ed5d348f8993f37af2613be85fd6b9815 (NETWORK) Add -sdt=c99 to fix compiling with newlib-3.0.0.
+ a1c3a7107f625101593b3c5bfd99f678226bde20 (LIBC) Update regression test sample.
+ 0e2aef6e2ed15847e1258394533861479f8543ff (LIBC) Remove libc and fdlibm
+ 6eb9b6945901fede58bd88b7d0c5f8eb4c29a292 (IO) Remove IO headers with bad flags and modes
+ b47eec37e516e2826acf8c89675f9198231af225 (IO) Add correct I/O flags and types
+ 134292444f846dda3148d441aad388d538409d64 (IO) Fix 14-15 year old IOMANX misconception.
+ c08599ae3b60a414768a39e9940fa3d139d823e8 (IO) Use IO_MC_* flags for devfs
+ ee608b3eceadcf3c82a3630ee33b56c8686db36e (NEWLIB) Add fstat, sbrk, isatty, and fixup stat definition.
+ 9caf150431ba008eb8b3c48ae8718323313549b2 (PFS) Define mystery value for mkdir and symlink
+ 716b013ddf0376cf4e7b93050a2e665858ee4c75 (FAKEHOST) Remove. It redirects a mount point to "host:".
+ a0a7def3367d6f7d994f81b83e6334420c6aee90 (IOMANX) Document IOMAN and rename confusing flag meant for fileXio.
+ 3d2d1e2fedcf64593162e61d9feb0b489aa785a5 (USBHDFSD) Compile with iomanX.
+ ac72d29e37d372cdca5180a840ce2f8bc415a8cb (IEEE1394) Compile with iomanX.
+ 81ab23d6f1078295ac246d4f2c0d6b0fdf3b2a54 (MEMORYCARD) Compile with IOMAN.
+ f71460373cc1a6d025ee508dfa5643eeb471544a (IO) Add smaller internal_dirent_t type to remain backward compatible.
+ 0780e02a1707730bec26f304c6509a0c35cc0adf (PS2NETFS) Use a buffer for dread reply.
+ 673704acb7a2e163aa8ba5c838225233cba34183 (IO) Use IO_DIRENT_SIZE and FIO_DIRENT_SIZE for writing data.
+ a897d1504a16708ed7e13728434c1544fffde9bd (ERRNO) Use extern int errno when compiling with newlib.
+ e6a12674e1800d979388bc1646ba2d2c7d4f2ee0 (FILEXIO) Do file mode conversion in CopyFile, check dirent in GetDir.
+ ea4bfad2378a84da48c227f5ba0864d14c84f0ea Remove kernel/unistd.h and kernel/dirent.h
+ 25466508d9506731716d9bff18816c06474a60c6 (FILEIO) Remove newlib functions, add fioReadMC, and fix stat functions.
+ 846dbb0f85c29c20b96aa9805df69ee5f16363fc (DOXYGEN) Add more groups and use @name command to group macros.
+ d0cb03e16ef61ec508975f492c4486e459790b30 (KERNEL) Replace ps2_sbrk.
+ 5f8227284325e5d330dd4b54f79b9453c571ae18 (IOMANX) Document possible reason for IO_DIROPEN flag.
+ b4140d3ef7e45c8e2b28bf1a67261b9251b970b2 (DOXYGEN) Clean up comments and spacing around documented groups.
+ 0d53f2b04f4217581ec01ff0421c0c7eebcb6ce1 (ERRNO) Revert errno changes.
+ d529521860b7499817eb2f9d4666e7dadf744d2d (SBRK) Return previous heap end.
+ b58026205c5be85fd7e54f3ab1e0bb9d35abf345 (STARTUP) Remove weak libc definitions. Add weak iop_start.
+ 9b5bf7ca5b067bc545a04e71034a70c940dd21a5 (CRT0) Forgot to nop the delay slot when calling atexit.
+ 26408c84224dd09ada0d74c8f26d8da687abf072 (FILEIO) Move FILEIO RPC client back into kernel
+ e305282f6423577d5c4a0d763f8b123bb5b835e0 (ERL) Fix global namespace for static libraries.
+ f1a931d2adc5ea8ef619249e5cfdc0e60afb49e8 Replace __R5900 with _R5900 in ee_limits.h
+ 3fdbf2b65835ef4ae32f3c9ed94f08f4ec100251 (GCC) Fix GCC version checks and add -nodefaultlibs to erl-loader.
+ bce4041ab16d52bdf6c849bf623060056a1e8e54 (Makefiles) Update for newlib-3.0.0 and new toolchain
+ 48edeea0e9341bf8d768711604368a0a53695111 (KERNEL) Move includes from kernel.h to source files.
+ ce98216174f336366add60c7f66dcc6de68934fd (SAMPLES) Move old libc samples to kernel/samples
+ a9b70701feda3d724f5d1887f0f34b13e7eb38fd (SAMPLE) Update debug Makefile.sample for new toolchain.
+ 07d3998a93be34ae47f3d56c6b05ae9995807169 (SAMPLE) Update draw samples' Makefile.sample for new toolchain.
+ 502f43552b977fe1777425187fdef14243d25ef9 (SAMPLE) Update erl samples' Makefile.sample
+ c5b8ff90836b3f5212fe7e8cffedf010aee41972 (SAMPLE) Update Makefile.eeglobal samples
+ 10296e8b339947e11777dc1156143dce5a0e184c (SAMPLE) Update graph and font Makefile.sample files
+ d4e4e23c1dc3259c9a1647faf7db64a7933c602f (EE) Make include directory for ee and move common EE headers there.
+ ac803475d68084133986b448e1dbb74cee433e12 (EE) Merge draw and graph headers.
+ 2bb48c08b10f270412089932758cab608e18f0c8 (IOP) Move common IOP headers to iop/include.
+ 17b9eaa9a1e223f596903ba0116f5e50749d9d20 (EE & IOP) Add ee/include and iop/include to Rules.make
+ 584bd43616a1fb2549eb6c3a2f8998a05bfe7de1 (MAKEFILE) Update IOP_CC version check and clean up vars and output.
+ e5cfc2904d41738238ac14f2470e4ef1bf707d26 (IOPREBOOT) Add back to SUBDIRS in ee/Makefile.
+ 480abfe3bde9bd7f968f51f13c63269ca0bfd6e4 (SAMPLES) More sample fixes and updates.
+ 54f6b7c5084f7bc551635897bf3309dc122d2d6a (SAMPLES) Fix sample Makefiles and errors except for memorycard.
+ 64b700d3c474e23bb4c48a2f86fd9baf40dce02f (LIBMC) Add strcpy_sjis and strcpy_ascii and update sample Makefile.
+ 06292e75b1b355e0bc28b48869387a14ecbb6674 (MAKEFILE) Move erl-loader clean and release rules.
+ 2e8fe3da95287598ea62032640499de13457a577 (ERL-LOADER) Fix boot path parsing if argc is 0 and argv is NULL.
+ b11a1d13f78527b9331934b11d89991394495e99 (DMA) Merge dma headers.
+ 17982ab3186687e81058da9bb9289c3aba540377 (SAMPLES) Fix some warnings.
+ 378e91015d6e22c113c9a70d9a219c657ad72944 (MAKEFILE) Add Defs.make to install rule.

For newlib-3.0.0 branch of ps2toolchain:

+ 2cc969e6a19a2efed8ada6bca4892aee05edceeb Add final newlib-3.0.0 patch
+ 58633355af542697efaf9f1e3f58e5cb23561034 Update gcc-3.2.3 patch for newlib-3.0.0 and build scripts
+ 16d541c4353d019c0951a09315a22436464cc986 Fix building in source directories.
+ cfd13b549d3862854cc7a9bd9d072e3ecef4b60b (BINUTILS) Merge patches, fix DESTDIR support, add ps2sdk SEARCH_DIR.
+ 8133b650f8b0dfebcf9ba4a0d5a63fa9e1a7a5af (SCRIPTS) Test for existing files and use gcc-core and gcc-g++.
+ cbc743f15de1841c568190977ca1893726ebad36 Forgot to add gcc-core to sources for gcc-stage2.
+ 4af6982ac8d399c7e4d6f3a6c078874eee583cee (NEWLIB) Allow customizing profiling support. Add NEWLIB.md.
+ 617ac7571f51128897df7f3e3270738209fe4b77 (BINUTILS) Add $PS2SDK/iop/lib to SEARCH_DIR for IOP.
+ e958152847e86a104b0be01f1807cfca7cf49af8 (GCC) Add ps2sdk to default search directories and add LIB_SPEC.
+ d7bf53184f4d5f779b5c9d7373e737ce67c6db49 Remove interim build directories.
+ 7a469922627b8f1dee9fd7f21a879166a6a1f99a (NEWLIB) Fix multiple definitions of _dummy_link_sycalls.
+ 7b3693d3629b9e8c65045df86813de0524fe7d43 Remove toolchain-sudo.sh.
+ ed1b5131cf9883b9560dbb728d40bdd166801f1a Now toolchain.sh creates a user friendly ps2dev.sh environment script.
+ c40891c59014592523f842b6d0c33157d98bf623 (README) Some minor edits.
+ 4f6a5d05608c83a9a65e01398ef029a3f6c8f49d (PS2SDK) Avoid reset --hard when updating ps2sdk.
+ e1238e365784b71bd8f269de1852d3380a797ce3 (NEWLIB) Add TARGET_CFLAGS="-G0" and fix a typo with MCOUNT_USE_T0.
+ 81d18aceafed7702eb25e1d39c71ad36a799d371 (GCC) Use -G0 by default.
+ 16142f5aee95e9c2ae737297a050118e7401305c (PS2SDK) Switch to Boganon/ps2sdk for successful builds for now.
+ 73a56fda9fcc422c60675e555a61e045f5bd891e (PS2SDK) Remove conditional exits during build stage.
+ b7d1e82f3e25c6d5b556dd0e694dbcaaacff6ea7 (PS2SDK) Check ps2sdk install return value, too.
+ 1dae0450efe4b67bb012cfc942b82f901dc45ed4 (STAGE2) With -G0 default, no longer need to add cxx flags.
+ 403580c5358dd280830aa4514329cea3ac0044b0 (PS2SDK) Test for build success before installing.
+ 862c1cf2e5e6376409619d5a9c8f284002539ed7 (PS2CLIENT) New version of ps2client and fsclient.
+ b44aceea01b019a92541d028b40b215f599a3e68 (BINUTILS) Set g_switch_value to 0 by default for R5900 and IRX.
+ 07542e3a3a5272a870b3939d2b08aae70ac9db15 (NEWLIB) GCC < 4 doesn't have __builtin_bswap and fix alignment macro.

For my_changes branch of ps2toolchain:

+ 8106458139cb25e54c628ce76ea9c0aaa46da8ee Fix vmulaq opcode syntax.
+ d8b56587b5ead8d1a8f6e94aefdd7da7e3e8c32b Fix dissassembler output for Q register.
+ 1f212c82aea6072df81569277f29f44525275332 Add patch to fix support  for DESTDIR in binutils-2.14.
+ a6c94778eeb72a64dcd85aef6bf38b8a737e10d6 Add DESTDIR support to newlib-1.10.0. Partial fix for linking to newlib.
+ 2f038e8963f181a1850b0c2572ce89b938fdbc5c Fix the random sys-include problems when cross-compiling gcc-3.2.3.
+ 174156c33ce20ce13033d890c50f80935c19aa4e Change move instruction to "or" and "por" on r5900.
+ c0864fc7c22594bd5c7f9e1fb06efc2cc487fd1b Add gcc-3.2.3-ps2sdk.diff to patches.
+ ac3da950d5095b915c4f32f9d7553b10917d25a6 Add changes to autoconf scripts too
+ b20201267e34b32e2d57b98ae6317d2a6bb75ce2 Prevent libstdc++-v3 from using mips atomicity.h
+ bd25b09c4d2a60c0dd458f10daa45aea12a5b90f Move libstdc++-v3 fix to main gcc-3.2.3-PS2.patch
+ e9464b8fe730dd111810dc57514df8427858ed57 Add gcc-3.2.3 patch to fix some warnings
+ eb581e2195dd3e9de4ef5f3111f011c0ef7200c5 Add optional gcc patch to rename c++filt to c++filt-gnu.
+ 3509394df37107c382f2ac31e7dd1a8ba35af31e Revert "Set default parameters for compiling and linking EE binaries"
+ 2198a18330fa4286996ed68185193dc00cf0f52b :rewind: Remove hardcoding ps2sdk libc.a to LIB_SPEC
+ b4a549756471c4164f011332b2dcfe368a847789 Add additional patches for gcc
+ bd01487dcc0639f474ee012ee24211778cbf87e7 Fix returning 1 in md_apply_fix3 in gas/config/tc-dvp.c
+ c5172199925c60a46d720329ce07ce4790e25897 Revert "Fix returning 1 in md_apply_fix3 in gas/config/tc-dvp.c"
+ 76d173354a47e970008b60ed03262ea3d044549f gcc-3.2.3 version of C++ template patch
+ c7feea183e7a235945390e9765a28fff0dc74bfa Update poisoned malloc and mklibgcc serialization patches
+ 49e29b2dd10e8d1df96b11144325314858154ab2 (ee-gcc) Fix ICE when compiling complex in libm. Add c99 types.
+ 41e5b1e9a763673a174627c7996f9d1f89e50e15 Use long types for everything but maxint_t and maxuint_t.
+ 021c8514bc981ee3302071ed20e3270dc74467a2 Remove old c++ template patch for gcc-3.2.3 flavored version.
+ d2c451e1d707e2572ea7e9d5ff8b50fdf85833e4 Accidentally deleted the save-temps line from CC1_SPEC
+ 4c46baa00dc29c295b3b8e6f69f1999417e528c8 Initial version of newlib-3.0.0 support.
+ 58ad35e0dcf3db3ce63afa5908142233a1c4abdc (NEWLIB) Add new newlib-3.0.0 patch
+ 0e12058ace70686de62a47e75e43bd3326bbfb47 (NEWLIB) Latest version of newlib-3.0.0 patch for the r5900.
sp193 commented 6 years ago

Thank you for the nicely-formatted logs, but I meant to ask if you have actually looked through his commits and tried out his work. Do you agree with all the changes he made? For example, he also removed the toolchain-sudo script - then how will Linux users of distributions with the root account disabled, install the SDK?

I once tried to consolidate his changes for supporting Newlib, but some of his required changes go between unrelated commits. Surely, a number of things should be adopted as well, but it's all lumped together with the major change that we are discussing.

uyjulian commented 6 years ago

Not all the changes. I plan to cherry-pick out some changes, like the fdlibm update and doxygen changes, then put them in a PR along with my Makefile, asm macro wrappers, and spacing changes.
After that, I will cherry-pick out the remaining changes into a separate branch to see what's left.

sp193 commented 6 years ago

Great! If I can help with anything, please feel free to ask. Although my time is very limited today, which is why things that need my attention, take really long to be completed now.

As for Newlib, if you ever touch those patches: please test the final result as well, if you can. Has anybody actually made a working app, with the new Newlib...

By the way, by "spacing changes", I hope you don't mean converting all tabs so spaces. I really don't like that idea because it looks ugly IMO. Plus I have to press space multiple times for increasing identation by a level, when a single press on the TAB key would do. Please don't do that.

uyjulian commented 6 years ago

Oh, for the spacing changes, I'm planning to do the opposite: converting all spaces to tabs. I set UseTab in clang-format to ForContinuationAndIndentation.

fjtrujy commented 4 years ago

Hello, Thanks for all your effort @uyjulian and @sp193 but after the https://github.com/ps2dev/ps2toolchain/pull/58, this issue can be closed.

Create a different one if you wanna discuss over there the spaces/indentation

Thanks