mirror of
https://github.com/lbonn/rofi
synced 2025-02-18 13:58:30 +00:00
Remove xdg as dependency, glib provides this.
This commit is contained in:
parent
98dfbddadb
commit
0be8e7ffa9
3 changed files with 1 additions and 17 deletions
|
@ -6,14 +6,12 @@ bin_PROGRAMS=rofi
|
||||||
LIBS=\
|
LIBS=\
|
||||||
@xft_LIBS@\
|
@xft_LIBS@\
|
||||||
@x11_LIBS@\
|
@x11_LIBS@\
|
||||||
@xdgbasedir_LIBS@\
|
|
||||||
@xinerama_LIBS@\
|
@xinerama_LIBS@\
|
||||||
@pango_LIBS@
|
@pango_LIBS@
|
||||||
|
|
||||||
AM_CFLAGS=\
|
AM_CFLAGS=\
|
||||||
@xft_CFLAGS@\
|
@xft_CFLAGS@\
|
||||||
@x11_CFLAGS@\
|
@x11_CFLAGS@\
|
||||||
@xdgbasedir_CFLAGS@\
|
|
||||||
@xinerama_CFLAGS@\
|
@xinerama_CFLAGS@\
|
||||||
@pango_CFLAGS@\
|
@pango_CFLAGS@\
|
||||||
-DMANPAGE_PATH="\"$(mandir)/man1/rofi.1\""\
|
-DMANPAGE_PATH="\"$(mandir)/man1/rofi.1\""\
|
||||||
|
|
|
@ -30,7 +30,6 @@ PKG_PROG_PKG_CONFIG
|
||||||
PKG_CHECK_MODULES([xft], [xft])
|
PKG_CHECK_MODULES([xft], [xft])
|
||||||
PKG_CHECK_MODULES([x11], [x11])
|
PKG_CHECK_MODULES([x11], [x11])
|
||||||
PKG_CHECK_MODULES([xinerama], [xinerama])
|
PKG_CHECK_MODULES([xinerama], [xinerama])
|
||||||
PKG_CHECK_MODULES([xdgbasedir], [libxdg-basedir])
|
|
||||||
PKG_CHECK_MODULES([pango], [pango pangoxft])
|
PKG_CHECK_MODULES([pango], [pango pangoxft])
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -60,8 +60,6 @@
|
||||||
#include <i3/ipc.h>
|
#include <i3/ipc.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <basedir.h>
|
|
||||||
|
|
||||||
#include "run-dialog.h"
|
#include "run-dialog.h"
|
||||||
#include "ssh-dialog.h"
|
#include "ssh-dialog.h"
|
||||||
#include "dmenu-dialog.h"
|
#include "dmenu-dialog.h"
|
||||||
|
@ -79,8 +77,6 @@ int config_i3_mode = 0;
|
||||||
char *i3_socket_path = NULL;
|
char *i3_socket_path = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
xdgHandle xdg_handle;
|
|
||||||
const char *cache_dir = NULL;
|
const char *cache_dir = NULL;
|
||||||
unsigned int NumlockMask = 0;
|
unsigned int NumlockMask = 0;
|
||||||
Display *display = NULL;
|
Display *display = NULL;
|
||||||
|
@ -1967,9 +1963,6 @@ static void cleanup ()
|
||||||
// TODO, not happy with this.
|
// TODO, not happy with this.
|
||||||
parse_xresource_free ();
|
parse_xresource_free ();
|
||||||
|
|
||||||
// Whipe the handle.. (not working)
|
|
||||||
xdgWipeHandle ( &xdg_handle );
|
|
||||||
|
|
||||||
for ( unsigned int i = 0; i < num_switchers; i++ ) {
|
for ( unsigned int i = 0; i < num_switchers; i++ ) {
|
||||||
// only used for script dialog.
|
// only used for script dialog.
|
||||||
if ( switchers[i].cb_data != NULL ) {
|
if ( switchers[i].cb_data != NULL ) {
|
||||||
|
@ -2061,14 +2054,8 @@ static void setup_switchers ( void )
|
||||||
|
|
||||||
int main ( int argc, char *argv[] )
|
int main ( int argc, char *argv[] )
|
||||||
{
|
{
|
||||||
// Initialize xdg, so we can grab the xdgCacheHome
|
|
||||||
if ( xdgInitHandle ( &xdg_handle ) == NULL ) {
|
|
||||||
fprintf ( stderr, "Failed to initialize XDG\n" );
|
|
||||||
return EXIT_FAILURE;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Get the path to the cache dir.
|
// Get the path to the cache dir.
|
||||||
cache_dir = xdgCacheHome ( &xdg_handle );
|
cache_dir = g_get_user_cache_dir ();
|
||||||
|
|
||||||
// Register cleanup function.
|
// Register cleanup function.
|
||||||
atexit ( cleanup );
|
atexit ( cleanup );
|
||||||
|
|
Loading…
Add table
Reference in a new issue