mirror of
https://github.com/lakinduakash/linux-wifi-hotspot.git
synced 2025-02-16 07:30:09 +00:00
Fix thread initialize erro (xlib)
This commit is contained in:
parent
ed3ca1cf6c
commit
baf690b0ce
@ -3,14 +3,16 @@ project(wihotspot)
|
||||
|
||||
include(FindPkgConfig)
|
||||
pkg_check_modules(GTK gtk+-3.0 REQUIRED)
|
||||
pkg_check_modules(X11 x11 REQUIRED)
|
||||
include_directories(${GTK_INCLUDE_DIRS})
|
||||
include_directories(${X11_INCLUDE_DIRS})
|
||||
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
set (CMAKE_CXX_STANDARD 11)
|
||||
|
||||
add_executable(wihotspot ui/main.c ui/h_prop.c ui/h_prop.h ui/ui.c ui/ui.h ui/read_config.cpp ui/read_config.h)
|
||||
|
||||
target_link_libraries(${PROJECT_NAME} ${GTK_LIBRARIES} config)
|
||||
target_link_libraries(${PROJECT_NAME} ${GTK_LIBRARIES} ${X11_LIBRARIES} config)
|
||||
|
||||
include_directories(/usr/include)
|
||||
|
||||
|
@ -6,6 +6,7 @@
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <stdlib.h>
|
||||
#include <X11/Xlib.h>
|
||||
|
||||
#include "h_prop.h"
|
||||
#include "ui.h"
|
||||
@ -98,6 +99,7 @@ static void on_stop_hp_clicked(GtkWidget *widget, gpointer data) {
|
||||
|
||||
int initUi(int argc, char *argv[]){
|
||||
|
||||
XInitThreads();
|
||||
|
||||
gtk_init(&argc, &argv);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user