├── .gitignore ├── certificate.p12 ├── org.ppsspp.ppsspp.png ├── Preferences └── PPSSPP │ ├── org.ppsspp.ppsspp.png │ ├── org.ppsspp.ppsspp@2x.png │ ├── org.ppsspp.ppsspp@3x.png │ ├── en.lproj │ └── Localizable.strings │ └── PPSSPP.plist ├── control ├── ent.xml ├── Makefile └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | ppsspp -------------------------------------------------------------------------------- /certificate.p12: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Halo-Michael/ppsspp-builder/HEAD/certificate.p12 -------------------------------------------------------------------------------- /org.ppsspp.ppsspp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Halo-Michael/ppsspp-builder/HEAD/org.ppsspp.ppsspp.png -------------------------------------------------------------------------------- /Preferences/PPSSPP/org.ppsspp.ppsspp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Halo-Michael/ppsspp-builder/HEAD/Preferences/PPSSPP/org.ppsspp.ppsspp.png -------------------------------------------------------------------------------- /Preferences/PPSSPP/org.ppsspp.ppsspp@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Halo-Michael/ppsspp-builder/HEAD/Preferences/PPSSPP/org.ppsspp.ppsspp@2x.png -------------------------------------------------------------------------------- /Preferences/PPSSPP/org.ppsspp.ppsspp@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Halo-Michael/ppsspp-builder/HEAD/Preferences/PPSSPP/org.ppsspp.ppsspp@3x.png -------------------------------------------------------------------------------- /Preferences/PPSSPP/en.lproj/Localizable.strings: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Halo-Michael/ppsspp-builder/HEAD/Preferences/PPSSPP/en.lproj/Localizable.strings -------------------------------------------------------------------------------- /control: -------------------------------------------------------------------------------- 1 | Package: org.ppsspp.ppsspp-dev-latest 2 | Name: PPSSPP (Dev-Latest) 3 | Architecture: iphoneos-arm 4 | Description: A PSP emulator 5 | Icon: file:///Library/PPSSPPRepoIcons/org.ppsspp.ppsspp-dev-latest.png 6 | Homepage: https://build.ppsspp.org/ 7 | Depends: preferenceloader 8 | Conflicts: com.myrepospace.theavenger.PPSSPP, net.angelxwind.ppsspp, net.angelxwind.ppsspp-testing, org.ppsspp.ppsspp, org.ppsspp.ppsspp-dev-working, org.ppsspp.ppssppgold-dev-working, org.ppsspp.ppssppgold-dev-latest 9 | Provides: com.myrepospace.theavenger.PPSSPP, net.angelxwind.ppsspp, net.angelxwind.ppsspp-testing 10 | Replaces: com.myrepospace.theavenger.PPSSPP, net.angelxwind.ppsspp, net.angelxwind.ppsspp-testing 11 | Depiction: https://cydia.ppsspp.org/?page/org.ppsspp.ppsspp-dev-latest 12 | Maintainer: Henrik Rydgård 13 | Author: Henrik Rydgård 14 | Section: Games 15 | Version: 0v -------------------------------------------------------------------------------- /ent.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | platform-application 6 | 7 | com.apple.developer.kernel.extended-virtual-addressing 8 | 9 | com.apple.developer.kernel.increased-memory-limit 10 | 11 | com.apple.developer.networking.multicast 12 | 13 | com.apple.private.security.container-manager 14 | 15 | com.apple.private.security.no-sandbox 16 | 17 | com.apple.private.security.storage.AppDataContainers 18 | 19 | com.apple.security.iokit-user-client-class 20 | 21 | AGXDeviceUserClient 22 | IOMobileFramebufferUserClient 23 | IOSurfaceRootUserClient 24 | 25 | get-task-allow 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /Preferences/PPSSPP/PPSSPP.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | entry 6 | 7 | cell 8 | PSLinkCell 9 | icon 10 | org.ppsspp.ppsspp.png 11 | label 12 | PPSSPP 13 | 14 | items 15 | 16 | 17 | cell 18 | PSGroupCell 19 | label 20 | PPSSPP SETTINGS 21 | 22 | 23 | cell 24 | PSSwitchCell 25 | default 26 | 27 | defaults 28 | org.ppsspp.ppsspp 29 | key 30 | enable_external_display 31 | label 32 | enable_external_display 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | .PHONY: all clean 2 | 3 | LDID=/usr/local/bin/ldid 4 | MAKE=/usr/local/opt/make/libexec/gnubin/make 5 | SED=/usr/local/opt/gnu-sed/libexec/gnubin/sed 6 | 7 | all: ipa deb 8 | 9 | application: 10 | if [[ ! -d ppsspp ]]; \ 11 | then \ 12 | echo "You are using this script in the wrong path!"; \ 13 | exit 1; \ 14 | fi; \ 15 | if [[ -d ppsspp/build-ios ]]; \ 16 | then \ 17 | exit 0; \ 18 | fi; \ 19 | cd ppsspp; \ 20 | echo "const char *PPSSPP_GIT_VERSION = \"$$(git describe --always)\";" > git-version.cpp; \ 21 | echo "#define PPSSPP_GIT_VERSION_NO_UPDATE 1" >> git-version.cpp; \ 22 | mkdir build-ios; \ 23 | cd build-ios; \ 24 | cmake -DCMAKE_TOOLCHAIN_FILE=../cmake/Toolchains/ios.cmake ..; \ 25 | ${MAKE} -j$$(sysctl -n hw.ncpu); \ 26 | ln -s ./ Payload; \ 27 | echo $$(git describe --tags --match="v*" | ${SED} -e 's@-\([^-]*\)-\([^-]*\)$$@-\1-\2@;s@^v@@;s@%@~@g') > PPSSPP.app/Version.txt; \ 28 | ${LDID} -w -S -IlibMoltenVK -K../../certificate.p12 -Upassword PPSSPP.app/Frameworks/libMoltenVK.dylib; \ 29 | ${LDID} -w -S../../ent.xml -K../../certificate.p12 -Upassword PPSSPP.app 30 | 31 | ipa: application 32 | cd ppsspp/build-ios; \ 33 | version_number=$$(git describe --tags --match="v*" | ${SED} -e 's@-\([^-]*\)-\([^-]*\)$$@-\1-\2@;s@^v@@;s@%@~@g'); \ 34 | zip -r9 ../../PPSSPP_0v$${version_number}.ipa Payload/PPSSPP.app; \ 35 | 36 | deb: application 37 | cd ppsspp/build-ios; \ 38 | version_number=$$(git describe --tags --match="v*" | ${SED} -e 's@-\([^-]*\)-\([^-]*\)$$@-\1-\2@;s@^v@@;s@%@~@g'); \ 39 | package_name="org.ppsspp.ppsspp-dev-latest_0v$${version_number}_iphoneos-arm"; \ 40 | mkdir $$package_name; \ 41 | mkdir $${package_name}/DEBIAN; \ 42 | cp ../../control $${package_name}/DEBIAN; \ 43 | echo $${version_number} >> $${package_name}/DEBIAN/control; \ 44 | chmod 0755 $${package_name}/DEBIAN/control; \ 45 | mkdir $${package_name}/Library; \ 46 | mkdir $${package_name}/Library/PPSSPPRepoIcons; \ 47 | cp ../../org.ppsspp.ppsspp.png $${package_name}/Library/PPSSPPRepoIcons/org.ppsspp.ppsspp-dev-latest.png; \ 48 | mkdir $${package_name}/Library/PreferenceLoader; \ 49 | mkdir $${package_name}/Library/PreferenceLoader/Preferences; \ 50 | cp -a ../../Preferences/PPSSPP $${package_name}/Library/PreferenceLoader/Preferences/; \ 51 | mkdir $${package_name}/Applications; \ 52 | cp -a PPSSPP.app $${package_name}/Applications/; \ 53 | dpkg -b $${package_name} ../../$${package_name}.deb 54 | 55 | clean: 56 | rm -rf ppsspp/git-version.cpp ppsspp/build-ios *.ipa *.deb 57 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | PPSSPP builder for iOS 2 | ====================== 3 | 4 | * Before you read the README: This README is OUT OF TIME and didn't get any update for long time. 5 | 6 | How to use it: 7 | -------------- 8 | 9 | * Cd to the ppsspp-builder folder and from the command line run: 10 | 11 | git clone https://github.com/hrydgard/ppsspp.git 12 | cd ppsspp 13 | git submodule update --init --recursive 14 | 15 | * Before start, if you want to build a better compatibility version*: 16 | Change Xcode Command Line Tools to 9.4.1. 17 | 18 | * If you want to build an ipa 19 | run: 20 | 21 | make ipa 22 | 23 | * If you want to build an deb 24 | run: 25 | 26 | make deb 27 | 28 | * If you want to build both 29 | run: 30 | 31 | make all 32 | 33 | *Notice: 34 | -------------- 35 | What means "a better compatibility version"? 36 | PPSSPP has three cpu cores to simulate psp and run our game -- interpreter Dynarec (JIT) IR interpreter. Among them, Dynarec (JIT) mode is the most efficient and can get better simulation results. 37 | It sounds pretty good? But what's wrong with this? 38 | Due to its closed nature, the iOS system is not allowed us directly called some function when we want to call. Some function can't even be called at all (Like Task_for_pid_0? :P). This is to protect the iOS system from malware, so Apple filters Some "safe and reliable" APIs are available for users/developers to call, and this includes JIT. 39 | So we have no way? 40 | No :P ,in fact, we have two ways to get around this limitation of Apple. 41 | In order to make it easier for developers to debug their applications, Apple will open up some additional functions for apps that are being debugged by xcode (even if they should not be used in the released app in their plan), which includes JIT! Yes, this is exactly what we need! 42 | But it is impossible for every player to use PPSSPP with a computer? 43 | Yes, so we need to fake a state and let the system think that "app is being debugged by xcode" 44 | We using syscall makes the system think "app is being debugged by xcode", so that players can use JIT even if they don't connect to the computer. 45 | Have any other problems? 46 | Unfortunately, yes. First, even if we call syscall in the code, if you use opactor to install ipa (whether or not you jailbreak), the get-task-allow entitlement in the PPSSPP main program will be destroyed - you will not be able to use JIT. (There have a bug in iOS11 which allowed you to simulate the xcode debug state without the get-task-allow entitlement, so you can still enable JIT). 47 | Even if you successfully use the system call to enable JIT, sometimes for some reason, iOS will always wait for signals from Xcode. It will make PPSSPP freezing when exit. When using cmake to build PPSSPP xcode project with iOS12 sdk, since the iOS12 SDK will add strange assertion code to the project, this will result in more frequent exit freezing. So we need to use iOS11 sdk and cmake to build PPSSPP xcode project. (It is important to note that this can only reduce the frequency of such problems, but not really solve the problem). 48 | It means build "a better compatibility version". 49 | If you want build quicker: 50 | You can just use the latest xcode command line tools to build everything. While this can be a problem for players who use syscall to call JIT, this has no effect on players who use Cydia Substrate to call JIT. 51 | Therefore, the best practice is to use the jailbreak tool that enables CS_DEBUGGED to jailbreak so that PPSSPP can enable JIT directly by calling Cydia Substrate. 52 | 53 | What am I using: 54 | -------------- 55 | * If you are not jailbreak 56 | Install ipa by using impactor -> not on iOS11 -> Can't use JIT 57 | Install ipa by using impactor -> on iOS11 -> Use syscall to use JIT 58 | * If you are jailbreakd ;P 59 | Install ipa by using impactor -> not on iOS11 -> Can't use JIT 60 | Install ipa by using impactor -> on iOS11 -> Use syscall to use JIT 61 | Install ipa by using AppSync -> CS_DEBUGGED is opened -> Use Cydia Substrate to use JIT 62 | Install ipa by using AppSync -> CS_DEBUGGED is not opened -> Use syscall to use JIT 63 | Install deb -> CS_DEBUGGED is opened -> Use Cydia Substrate to use JIT 64 | Install deb -> CS_DEBUGGED is not opened -> Use syscall to use JIT 65 | 66 | * Since I haven't used Substitute and I don't know how it works, I don't know how JIT will work on devices that used using Substitute's jailbreak tools (like Electra). 67 | 68 | The last: 69 | -------------- 70 | Due to my limited level, the above content may be incorrect or insufficient. Welcome to create issues or create pull requests. :P 71 | --------------------------------------------------------------------------------