rcheevos: initial package

This is a dependency of newer game.libretro versions

Signed-off-by: Matthias Reichl <hias@horus.com>
This commit is contained in:
Matthias Reichl 2022-11-11 11:55:07 +01:00
parent f3f89e87a7
commit 898996e762
2 changed files with 82 additions and 0 deletions

View File

@ -0,0 +1,18 @@
# SPDX-License-Identifier: GPL-2.0
# Copyright (C) 2022-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="rcheevos"
PKG_VERSION="9.2.0"
PKG_SHA256="c8ed6ca74f905ea0c256250e46cced579922880001337e7c3d3d68179ad89d4e"
PKG_LICENSE="MIT"
PKG_SITE="https://github.com/RetroAchievements/rcheevos"
PKG_URL="https://github.com/RetroAchievements/rcheevos/archive/v${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain"
PKG_LONGDESC="Library to parse and evaluate achievements and leaderboards for RetroAchievements"
PKG_BUILD_FLAGS="+pic"
post_unpack() {
# rcheevos doesn't come with any build files, use a copy of the cmake file in
# game.libretro (depends/common/rcheevos/CMakeLists.txt)
cp "${PKG_DIR}/source/CMakeLists.txt" "${PKG_BUILD}"
}

View File

@ -0,0 +1,64 @@
project(rcheevos)
cmake_minimum_required(VERSION 3.0)
# Disable Lua for now
add_definitions(-DRC_DISABLE_LUA)
include_directories(
include
)
add_library(${PROJECT_NAME}lib
src/rcheevos/alloc.c
src/rcheevos/compat.c
src/rcheevos/condition.c
src/rcheevos/condset.c
src/rcheevos/consoleinfo.c
src/rcheevos/format.c
src/rcheevos/lboard.c
src/rcheevos/memref.c
src/rcheevos/operand.c
src/rcheevos/richpresence.c
src/rcheevos/runtime.c
src/rcheevos/runtime_progress.c
src/rcheevos/trigger.c
src/rcheevos/value.c
src/rhash/cdreader.c
src/rhash/hash.c
src/rhash/md5.c
src/rurl/url.c
)
#add_dependencies(rcheevos
# lua # TODO
#)
#target_link_libraries(rcheevos
# lua
#)
install(TARGETS
${PROJECT_NAME}lib
ARCHIVE DESTINATION
lib
DESTINATION
lib
)
install(
FILES
include/rcheevos.h
include/rconsoles.h
include/rhash.h
include/rurl.h
DESTINATION
include/${PROJECT_NAME}
)
#install(
# DIRECTORY
# include
# DESTINATION
# include
#)