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

Added ARK compat layer #17

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cmake_minimum_required (VERSION 3.1)

project(infinity VERSION 2.0.3)
project(infinity VERSION 2.0.5)

if (NOT CMAKE_TOOLCHAIN_FILE)
set(CMAKE_TOOLCHAIN_FILE ${CMAKE_SOURCE_DIR}/cmake/psp-toolchain.cmake)
Expand Down Expand Up @@ -29,4 +29,4 @@ SET(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR})
SET(CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VERSION_MINOR})
SET(CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VERSION_PATCH})
set(CPACK_PACKAGE_FILE_NAME ${PROJECT_NAME}-${PROJECT_VERSION})
include(CPack)
include(CPack)
290 changes: 280 additions & 10 deletions app/3rdparty/intraFont-G/Makefile
Original file line number Diff line number Diff line change
@@ -1,14 +1,284 @@
PSPSDK = $(shell psp-config --pspsdk-path)
PSPDIR = $(shell psp-config --psp-prefix)
# CMAKE generated file: DO NOT EDIT!
# Generated by "Unix Makefiles" Generator, CMake Version 3.16

CFLAGS = -O2 -G0
# Default target executed when no arguments are given to make.
default_target: all

OBJS = intraFont.o libccc.o
TARGET_LIB = libintrafont.a
.PHONY : default_target

include $(PSPSDK)/lib/build.mak
# Allow only one "make -f Makefile2" at a time, but pass parallelism.
.NOTPARALLEL:


#=============================================================================
# Special targets provided by cmake.

# Disable implicit rules so canonical targets will work.
.SUFFIXES:


# Remove some rules from gmake that .SUFFIXES does not remove.
SUFFIXES =

.SUFFIXES: .hpux_make_needs_suffix_list


# Suppress display of executed commands.
$(VERBOSE).SILENT:


# A target that is always out of date.
cmake_force:

.PHONY : cmake_force

#=============================================================================
# Set environment variables for the build.

# The shell in which to execute make rules.
SHELL = /bin/sh

# The CMake executable.
CMAKE_COMMAND = /usr/bin/cmake

# The command to remove a file.
RM = /usr/bin/cmake -E remove -f

# Escaping for special characters.
EQUALS = =

# The top-level source directory on which CMake was run.
CMAKE_SOURCE_DIR = /home/aaron/projects/Infinity-master

# The top-level build directory on which CMake was run.
CMAKE_BINARY_DIR = /home/aaron/projects/Infinity-master

#=============================================================================
# Targets provided globally by CMake.

# Special rule for the target install/strip
install/strip: preinstall
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Installing the project stripped..."
/usr/bin/cmake -DCMAKE_INSTALL_DO_STRIP=1 -P cmake_install.cmake
.PHONY : install/strip

# Special rule for the target install/strip
install/strip/fast: preinstall/fast
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Installing the project stripped..."
/usr/bin/cmake -DCMAKE_INSTALL_DO_STRIP=1 -P cmake_install.cmake
.PHONY : install/strip/fast

# Special rule for the target install/local
install/local: preinstall
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Installing only the local directory..."
/usr/bin/cmake -DCMAKE_INSTALL_LOCAL_ONLY=1 -P cmake_install.cmake
.PHONY : install/local

# Special rule for the target install/local
install/local/fast: preinstall/fast
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Installing only the local directory..."
/usr/bin/cmake -DCMAKE_INSTALL_LOCAL_ONLY=1 -P cmake_install.cmake
.PHONY : install/local/fast

# Special rule for the target edit_cache
edit_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "No interactive CMake dialog available..."
/usr/bin/cmake -E echo No\ interactive\ CMake\ dialog\ available.
.PHONY : edit_cache

# Special rule for the target edit_cache
edit_cache/fast: edit_cache

.PHONY : edit_cache/fast

# Special rule for the target package_source
package_source:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Run CPack packaging tool for source..."
cd /home/aaron/projects/Infinity-master && /usr/bin/cpack --config ./CPackSourceConfig.cmake /home/aaron/projects/Infinity-master/CPackSourceConfig.cmake
.PHONY : package_source

# Special rule for the target package_source
package_source/fast: package_source

.PHONY : package_source/fast

# Special rule for the target install
install: preinstall
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Install the project..."
/usr/bin/cmake -P cmake_install.cmake
.PHONY : install

# Special rule for the target install
install/fast: preinstall/fast
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Install the project..."
/usr/bin/cmake -P cmake_install.cmake
.PHONY : install/fast

# Special rule for the target list_install_components
list_install_components:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Available install components are: \"Unspecified\""
.PHONY : list_install_components

# Special rule for the target list_install_components
list_install_components/fast: list_install_components

.PHONY : list_install_components/fast

# Special rule for the target rebuild_cache
rebuild_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake to regenerate build system..."
/usr/bin/cmake -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
.PHONY : rebuild_cache

# Special rule for the target rebuild_cache
rebuild_cache/fast: rebuild_cache

.PHONY : rebuild_cache/fast

# Special rule for the target package
package: preinstall
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Run CPack packaging tool..."
cd /home/aaron/projects/Infinity-master && /usr/bin/cpack --config ./CPackConfig.cmake
.PHONY : package

# Special rule for the target package
package/fast: package

.PHONY : package/fast

# The main all target
all: cmake_check_build_system
cd /home/aaron/projects/Infinity-master && $(CMAKE_COMMAND) -E cmake_progress_start /home/aaron/projects/Infinity-master/CMakeFiles /home/aaron/projects/Infinity-master/app/3rdparty/intraFont-G/CMakeFiles/progress.marks
cd /home/aaron/projects/Infinity-master && $(MAKE) -f CMakeFiles/Makefile2 app/3rdparty/intraFont-G/all
$(CMAKE_COMMAND) -E cmake_progress_start /home/aaron/projects/Infinity-master/CMakeFiles 0
.PHONY : all

# The main clean target
clean:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f CMakeFiles/Makefile2 app/3rdparty/intraFont-G/clean
.PHONY : clean

# The main clean target
clean/fast: clean

.PHONY : clean/fast

# Prepare targets for installation.
preinstall: all
cd /home/aaron/projects/Infinity-master && $(MAKE) -f CMakeFiles/Makefile2 app/3rdparty/intraFont-G/preinstall
.PHONY : preinstall

# Prepare targets for installation.
preinstall/fast:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f CMakeFiles/Makefile2 app/3rdparty/intraFont-G/preinstall
.PHONY : preinstall/fast

# clear depends
depend:
cd /home/aaron/projects/Infinity-master && $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 1
.PHONY : depend

# Convenience name for target.
app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/rule:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f CMakeFiles/Makefile2 app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/rule
.PHONY : app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/rule

# Convenience name for target.
intrafont: app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/rule

.PHONY : intrafont

# fast build rule for target.
intrafont/fast:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build.make app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build
.PHONY : intrafont/fast

intraFont.obj: intraFont.c.obj

.PHONY : intraFont.obj

# target to build an object file
intraFont.c.obj:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build.make app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/intraFont.c.obj
.PHONY : intraFont.c.obj

intraFont.i: intraFont.c.i

.PHONY : intraFont.i

# target to preprocess a source file
intraFont.c.i:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build.make app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/intraFont.c.i
.PHONY : intraFont.c.i

intraFont.s: intraFont.c.s

.PHONY : intraFont.s

# target to generate assembly for a file
intraFont.c.s:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build.make app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/intraFont.c.s
.PHONY : intraFont.c.s

libccc.obj: libccc.c.obj

.PHONY : libccc.obj

# target to build an object file
libccc.c.obj:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build.make app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/libccc.c.obj
.PHONY : libccc.c.obj

libccc.i: libccc.c.i

.PHONY : libccc.i

# target to preprocess a source file
libccc.c.i:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build.make app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/libccc.c.i
.PHONY : libccc.c.i

libccc.s: libccc.c.s

.PHONY : libccc.s

# target to generate assembly for a file
libccc.c.s:
cd /home/aaron/projects/Infinity-master && $(MAKE) -f app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/build.make app/3rdparty/intraFont-G/CMakeFiles/intrafont.dir/libccc.c.s
.PHONY : libccc.c.s

# Help Target
help:
@echo "The following are some of the valid targets for this Makefile:"
@echo "... all (the default if no target is provided)"
@echo "... clean"
@echo "... depend"
@echo "... install/strip"
@echo "... install/local"
@echo "... edit_cache"
@echo "... package_source"
@echo "... install"
@echo "... list_install_components"
@echo "... rebuild_cache"
@echo "... package"
@echo "... intrafont"
@echo "... intraFont.obj"
@echo "... intraFont.i"
@echo "... intraFont.s"
@echo "... libccc.obj"
@echo "... libccc.i"
@echo "... libccc.s"
.PHONY : help



#=============================================================================
# Special targets to cleanup operation of make.

# Special rule to run CMake to check the build system integrity.
# No rule that depends on this can have commands that come from listfiles
# because they might be regenerated.
cmake_check_build_system:
cd /home/aaron/projects/Infinity-master && $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 0
.PHONY : cmake_check_build_system

install: all
mkdir -p $(PSPDIR)/include $(PSPDIR)/lib
cp *.h $(PSPDIR)/include
cp *.a $(PSPDIR)/lib
4 changes: 3 additions & 1 deletion app/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ set (CONFIGURATION_SOURCES
add_subdirectory(3rdparty/intraFont-G)

add_custom_command(OUTPUT generated_file_data.h generated_file_data.cpp
DEPENDS libconfig kernel_helper bootloader660 bootloader661 infinityboot infinityctrl rebootex mecompat procompat
DEPENDS libconfig kernel_helper bootloader660 bootloader661 infinityboot infinityctrl rebootex mecompat procompat arkcompat
COMMAND $<TARGET_PROPERTY:bin2cpp,EXEC>
libconfig="$<TARGET_FILE:libconfig>"
kernel_helper="$<TARGET_FILE:kernel_helper>"
Expand All @@ -88,6 +88,7 @@ add_custom_command(OUTPUT generated_file_data.h generated_file_data.cpp
rebootex="$<TARGET_FILE:rebootex>"
mecompat="$<TARGET_FILE:mecompat>"
procompat="$<TARGET_FILE:procompat>"
arkcompat="$<TARGET_FILE:arkcompat>"
parallax_left=${CMAKE_CURRENT_SOURCE_DIR}/resources/parallaxleft.tga
parallax_right=${CMAKE_CURRENT_SOURCE_DIR}/resources/parallaxright.tga
symbol_font=${CMAKE_CURRENT_SOURCE_DIR}/resources/symbol.pgf
Expand Down Expand Up @@ -133,6 +134,7 @@ target_link_libraries(configuration
rebootex
mecompat
procompat
arkcompat
)

target_include_directories(configuration PRIVATE 3rdparty ${CMAKE_CURRENT_BINARY_DIR})
Expand Down
Empty file modified app/resources/PARAM.SFO
100755 → 100644
Empty file.
Empty file modified app/resources/PARAM_GO.SFO
100755 → 100644
Empty file.
3 changes: 2 additions & 1 deletion app/src/configscreen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ ConfigScreen::ConfigScreen(ViewManager* viewManager)
std::string basejson =
"[{\"name\":\"PRO "
"CFW\",\"author\":\"Coldbird\",\"path\":\"flash0:/kd/procompat.bin\"},{\"name\":\"ME "
"CFW\",\"author\":\"neur0n\",\"path\":\"flash0:/kd/mecompat.bin\"}]";
"CFW\",\"author\":\"neur0n\",\"path\":\"flash0:/kd/mecompat.bin\"}, "
"{\"name\":\"ARK CFW\",\"author\":\"Acid_Snake\",\"path\":\"flash0:/kd/arkcompat.bin\"}]";
auto list = parseCompatibilityConfig(basejson);
m_list.insert(m_list.begin(), list.begin(), list.end());

Expand Down
6 changes: 6 additions & 0 deletions app/src/installupdate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,12 @@ void InstallUpdate::run(void)
setState(ERROR_WRITE_PROCOMPAT);
return;
}

if (!writeVerifyFile(ARKCOMPAT_EXEC_PATH, files::arkcompat::data))
{
setState(ERROR_WRITE_ARKCOMPAT);
return;
}

auto bootloader = getBootloader(sceKernelDevkitVersion());

Expand Down
1 change: 1 addition & 0 deletions app/src/installupdate.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ class InstallUpdate : public Thread
ERROR_WRITE_REBOOTEX,
ERROR_WRITE_MECOMPAT,
ERROR_WRITE_PROCOMPAT,
ERROR_WRITE_ARKCOMPAT,
ERROR_READ_USERSYSTEMLIB,
ERROR_WRITE_USERSYSTEMLIB,
UPDATE_UNAVAILABLE,
Expand Down
9 changes: 9 additions & 0 deletions app/src/installupdatescreen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,15 @@ void InstallUpdateScreen::render(void)
"and reflash 6.61 before installing.",
TextRenderer::ALIGN_CENTER);
break;
case InstallUpdate::ERROR_WRITE_ARKCOMPAT:
m_latinText->drawVerticalTop(
480.f / 2.f, 50.f, "Could not flash arkcompat.bin.", TextRenderer::ALIGN_CENTER);
m_latinText->drawVerticalTop(480.f / 2.f,
80.f,
"Infinity was not installed on your device.\nPlease exit "
"and reflash 6.61 before installing.",
TextRenderer::ALIGN_CENTER);
break;
case InstallUpdate::ERROR_READ_USERSYSTEMLIB:
m_latinText->drawVerticalTop(480.f / 2.f,
50.f,
Expand Down
1 change: 1 addition & 0 deletions firmware/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ add_subdirectory(infinityctrl)
add_subdirectory(rebootex)
add_subdirectory(mecompat)
add_subdirectory(procompat)
add_subdirectory(arkcompat)
add_subdirectory(bootloader)
add_subdirectory(recovery)
Loading