mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-10-29 16:26:39 +01:00
Fix build errors
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
#include "fastfetch.h"
|
||||
#include "common/io.h"
|
||||
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
#include <fcntl.h>
|
||||
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@
|
||||
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <sys/types.h> //mode_t
|
||||
#include <sys/stat.h> //mode_t
|
||||
|
||||
bool ffWriteFDBuffer(int fd, const FFstrbuf* content);
|
||||
bool ffWriteFileData(const char* fileName, size_t dataSize, const void* data);
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#include "fastfetch.h"
|
||||
#include "common/settings.h"
|
||||
#include "common/library.h"
|
||||
#include "common/io.h"
|
||||
#include "common/thread.h"
|
||||
#include "common/io.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
@@ -280,7 +280,6 @@ FFvariant ffSettingsGetXFConf(const FFinstance* instance, const char* channelNam
|
||||
|
||||
#ifdef FF_HAVE_SQLITE3
|
||||
#include <sqlite3.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
typedef struct SQLiteData
|
||||
{
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
#include <dirent.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
static const char* parseEnv()
|
||||
{
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
#include "packages.h"
|
||||
#include "common/parsing.h"
|
||||
|
||||
#include <dirent.h>
|
||||
|
||||
static uint32_t getNumElements(const char* dirname, unsigned char type)
|
||||
{
|
||||
@@ -28,17 +31,17 @@ static uint32_t countBrewPackages(const char* dirname)
|
||||
ffStrbufInitS(&baseDir, dirname);
|
||||
|
||||
uint32_t result = 0;
|
||||
uint32_t baseDirLength = baseDir->length;
|
||||
uint32_t baseDirLength = baseDir.length;
|
||||
|
||||
ffStrbufAppendS(baseDir, "/Caskroom");
|
||||
result += getNumElements(baseDir->chars, DT_DIR);
|
||||
ffStrbufSubstrBefore(baseDir, baseDirLength);
|
||||
ffStrbufAppendS(&baseDir, "/Caskroom");
|
||||
result += getNumElements(baseDir.chars, DT_DIR);
|
||||
ffStrbufSubstrBefore(&baseDir, baseDirLength);
|
||||
|
||||
ffStrbufAppendS(baseDir, "/Cellar");
|
||||
result += getNumElements(baseDir->chars, DT_DIR);
|
||||
ffStrbufSubstrBefore(baseDir, baseDirLength);
|
||||
ffStrbufAppendS(&baseDir, "/Cellar");
|
||||
result += getNumElements(baseDir.chars, DT_DIR);
|
||||
ffStrbufSubstrBefore(&baseDir, baseDirLength);
|
||||
|
||||
ffStrbufDestroy(baseDir);
|
||||
ffStrbufDestroy(&baseDir);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,15 +1,12 @@
|
||||
#include "packages.h"
|
||||
#include "common/io.h"
|
||||
#include "common/parsing.h"
|
||||
#include "common/processing.h"
|
||||
#include "common/properties.h"
|
||||
#include "common/settings.h"
|
||||
#include "common/processing.h"
|
||||
#include "common/parsing.h"
|
||||
#include "detection/os/os.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <dirent.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
static uint32_t getNumElementsImpl(const char* dirname, unsigned char type)
|
||||
{
|
||||
|
||||
@@ -31,8 +31,8 @@ void ffDetectPackagesImpl(const FFinstance* instance, FFPackagesResult* result)
|
||||
|
||||
FFstrbuf scoopPath;
|
||||
ffStrbufInitF(&scoopPath, "%s/scoop/apps/*", getenv("USERPROFILE"));
|
||||
counts->scoop = getNumElements(scoopPath.chars, FILE_ATTRIBUTE_DIRECTORY);
|
||||
if(counts->scoop > 0)
|
||||
counts->scoop-- // scoop
|
||||
result->scoop = getNumElements(scoopPath.chars, FILE_ATTRIBUTE_DIRECTORY);
|
||||
if(result->scoop > 0)
|
||||
result->scoop-- // scoop
|
||||
ffStrbufDestroy(&scoopPath);
|
||||
}
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
#include "detection/terminalshell/terminalshell.h"
|
||||
#include "common/io.h"
|
||||
|
||||
#include <sys/stat.h>
|
||||
|
||||
#ifdef FF_HAVE_FREETYPE
|
||||
#include "common/library.h"
|
||||
#include <ft2build.h>
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#ifdef WIN32
|
||||
#include "util/windows/getline.h"
|
||||
|
||||
Reference in New Issue
Block a user