Commit some old code

FossilOrigin-Name: 97ae2bdaee07382649c07e800fe89d61c640c741627302a0e421822bffa8a8bb
This commit is contained in:
nekobit 2023-01-06 04:24:03 +00:00
parent c16d4d1e5a
commit d20f868298
3 changed files with 6 additions and 5 deletions

View File

@ -10,13 +10,15 @@ project(treebird
DESCRIPTION "A very lightweight and beautiful Pleroma frontend"
LANGUAGES C)
# Import local build if it exists.
# This is a current solution unless distributions provide their own packages
if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/mastodont-c")
include(mastodont-c/cmake/mastodont-config.cmake)
# include(mastodont-c/cmake/mastodont-config.cmake)
else()
find_package(MASTODONT REQUIRED)
find_package(Mastodont REQUIRED CONFIG)
endif()
message("${CMAKE_PREFIX_PATH} ${MASTODONT_INCLUDE_DIR}")
add_executable(treebird ${SRC_FILES})
@ -123,5 +125,4 @@ target_include_directories(treebird PUBLIC
target_link_libraries(treebird PUBLIC
${PERL_LIBRARIES}
${CURL_LIBRARIES}
${MASTODONT_LIBRARIES})

View File

@ -8,7 +8,7 @@
#include <pthread.h>
#include <string.h>
#include "memory.h"
#include <mastodont.h>
#include <mastodont/mastodont.h>
#include <stdlib.h>
#include "../config.h"
#include "index.h"

View File

@ -134,7 +134,7 @@ int handle_paths(REQUEST_T req,
for (size_t i = 0; i < paths_len; ++i)
{
if ((res = parse_path(req, ssn, api, paths + i)) != -1)
return;
return res;
}
// Fell out, return 404