Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ISSUE]: Problems compiling with the latest PS2SDK #3

Open
1 task done
CosmicScale opened this issue Jul 17, 2024 · 4 comments
Open
1 task done

[ISSUE]: Problems compiling with the latest PS2SDK #3

CosmicScale opened this issue Jul 17, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@CosmicScale
Copy link
Contributor

Checks

  • I have checked existing issues for duplicates and found none

Describe the issue

I'm trying to compile PS1VModeNeg from source but just like many homebrew apps, it will not compile on the latest SDK without modifications. I've resolved a number of the errors and warnings, but now I'm stuck.

The ELF file compiles but just displays a black screen when run. I get this warning when compiling:

mips64r5900el-ps2-elf-gcc -D_EE -Os -mno-gpopt -G0 -Wall -I/usr/local/ps2dev/ps2sdk/ee/include -I/usr/local/ps2dev/ps2sdk/common/include -I. -Tlinkfile -L/usr/local/ps2dev/ps2sdk/ee/lib -s -o PS1VModeNeg.elf main.o cnf_lite.o -lcdvd -ldebug -lc -lkernel /usr/local/ps2dev/ee/bin/../lib/gcc/mips64r5900el-ps2-elf/14.1.0/../../../../mips64r5900el-ps2-elf/bin/ld: warning: cannot find entry symbol _start; defaulting to 00084000

Console model

SCPH-50001

@CosmicScale CosmicScale added the bug Something isn't working label Jul 17, 2024
@10522
Copy link

10522 commented Jul 18, 2024

@AKuHAK or @sp193 can probably help with this issue.

@AKuHAK
Copy link
Member

AKuHAK commented Jul 18, 2024

@CosmicScale rickgaiser/neutrino#23 (comment)
Just note that DKWDRV has more options for video modes for PS1 disks

@fjtrujy
Copy link

fjtrujy commented Jul 18, 2024

This piece of software was never compiled with modern PS2DEV toolchain. (we can notice it in the CI/CD https://github.com/ps2homebrew/PS1VModeNeg/blob/main/.github/workflows/compilation.yml#L10 it is using 1.0 instead of latest)
You can do it but it requires some modifications:

  1. You need to update the linkfile, most probably you can reuse the existing in neutrino
  2. You need to update the Makefile, there are several things here wrong:
  1. Besides all said before, You can't load a binary with start address 0x84000 directly, it requires another loader in the middle, in the case of this app looks to be by using the ps2-packer as you can see here: https://github.com/ps2homebrew/PS1VModeNeg/blob/main/main.c#L398 . This basically means, you need to compress the binary and load that compressed version

Finally, my recommendation is that you show us the modified code (create a draft PR), adding it also to the CI/CD, otherwise it will be impossible to know if the modifications that you have done are right.

Cheers

@CosmicScale
Copy link
Contributor Author

Thanks @fjtrujy, I've done as you suggested and made a draft PR with your suggested changes and a few of my own. Using the linkfile from neutrino resulted in a lot of errors, I used the linkfile from wLaunchELF instead.

It now compiles without any errors or warnings but when I run the app, all I get is a black screen.

#4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants