Luanti 5.16.0-dev
Loading...
Searching...
No Matches
porting.cpp File Reference
#include "porting.h"
#include <unistd.h>
#include <sys/utsname.h>
#include <spawn.h>
#include "debug.h"
#include "filesys.h"
#include "log.h"
#include "util/string.h"
#include "util/tracy_wrapper.h"
#include <vector>
#include <csignal>
#include <cstdarg>
#include <cstdio>
#include <signal.h>
#include <atomic>
Include dependency graph for porting.cpp:

Namespaces

namespace  porting

Functions

volatile std::sig_atomic_t * porting::signal_handler_killstatus ()
static void porting::signal_handler (int sig)
void porting::signal_handler_init (void)
std::string porting::getDataPath (const char *subpath)
static void porting::pathRemoveFile (char *path, char delim)
static bool porting::detectMSVCBuildDir (const std::string &path)
static std::string porting::detectSystemInfo ()
const std::string & porting::get_sysinfo ()
u32 porting::getMemorySizeMB ()
static bool porting::getCurrentWorkingDir (char *buf, size_t len)
static bool porting::getExecPathFromProcfs (char *buf, size_t buflen)
bool porting::getCurrentExecPath (char *buf, size_t len)
static const char * porting::getHomeOrFail ()
bool porting::setSystemPaths ()
static void porting::migrateCachePath ()
static void porting::createCacheDirTag ()
void porting::initializePaths ()
bool porting::secure_rand_fill_buf (void *buf, size_t len)
void porting::osSpecificInit ()
void porting::attachOrCreateConsole ()
int porting::mt_snprintf (char *buf, const size_t buf_size, const char *fmt,...)
static bool porting::open_uri (const std::string &uri)
bool porting::open_url (const std::string &url)
 Opens URL in default web browser.
bool porting::open_directory (const std::string &path)
 Opens a directory in the default file manager.

Variables

static volatile std::sig_atomic_t porting::g_killed = false
std::string porting::path_share = "UNINITIALIZED"
std::string porting::path_user = "UNINITIALIZED"
std::string porting::path_locale = "UNINITIALIZED"
std::string porting::path_cache = "UNINITIALIZED"