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

Haiku fixes #1603

Merged
merged 3 commits into from
Aug 8, 2023
Merged
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
9 changes: 9 additions & 0 deletions cmake/Conky.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,15 @@ if(OS_SOLARIS)
set(conky_libs ${conky_libs} -L/usr/local/lib)
endif(OS_SOLARIS)

if(OS_HAIKU)
# For asprintf
add_definitions(-D_GNU_SOURCE) # Standard definitions
set(
CMAKE_REQUIRED_DEFINITIONS
"${CMAKE_REQUIRED_DEFINITIONS} -D_GNU_SOURCE"
)
endif(OS_HAIKU)

# Do version stuff
set(VERSION_MAJOR "1")
set(VERSION_MINOR "19")
Expand Down
3 changes: 2 additions & 1 deletion src/display-x11.cc
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,12 @@
#include "display-x11.hh"
#include "gui.h"
#include "llua.h"
#include "x11.h"

/* TODO: cleanup global namespace */
#ifdef BUILD_X11

#include "x11.h"

// TODO: cleanup externs (move to conky.h ?)
#ifdef OWN_WINDOW
extern int fixed_size, fixed_pos;
Expand Down
4 changes: 4 additions & 0 deletions src/haiku.cc
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,10 @@ double get_battery_perct_bar(struct text_object *obj) {
return batperct;
}

void get_battery_power_draw(char *buffer, unsigned int n, const char *bat) {
// TODO
}

int open_acpi_temperature(const char *name) { return -1; }

void get_acpi_ac_adapter(char *p_client_buffer, size_t client_buffer_size,
Expand Down
1 change: 1 addition & 0 deletions src/timeinfo.cc
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
#include <clocale>
#include <cstring>
#include <ctime>
#include <stdio.h>
#include "conky.h"
#include "logging.h"
#include "text_object.h"
Expand Down