diff options
author | Jari Vetoniemi <mailroxas@gmail.com> | 2014-03-18 19:35:10 +0200 |
---|---|---|
committer | Jari Vetoniemi <mailroxas@gmail.com> | 2014-03-18 19:35:10 +0200 |
commit | ff314f3c5e1b30fed112adb97ab5d29f5a2e108b (patch) | |
tree | 977e1e7fe3d8e9567d898185dccf62c00e0fda88 /client | |
parent | 02435064485e8cfdebf29e2279ca5b6cd8bb140b (diff) | |
download | bemenu-ff314f3c5e1b30fed112adb97ab5d29f5a2e108b.tar.gz bemenu-ff314f3c5e1b30fed112adb97ab5d29f5a2e108b.tar.bz2 bemenu-ff314f3c5e1b30fed112adb97ab5d29f5a2e108b.zip |
Add project skeleton
Diffstat (limited to 'client')
-rw-r--r-- | client/CMakeLists.txt | 26 | ||||
-rw-r--r-- | client/client.c | 30 |
2 files changed, 56 insertions, 0 deletions
diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt new file mode 100644 index 0000000..70ecd4b --- /dev/null +++ b/client/CMakeLists.txt @@ -0,0 +1,26 @@ +SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY bin) + +# Sources +SET(CLIENT_SOURCE client.c) +SET(CLIENT_INCLUDE) +SET(CLIENT_LIBRARIES bemenu) + +# Warnings +IF (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX) + SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wno-variadic-macros -Wno-long-long") + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wno-variadic-macros -Wno-long-long") +ENDIF () + +IF (UNIX AND CMAKE_COMPILER_IS_GNUCC) + SET(CMAKE_POSITION_INDEPENDENT_CODE ON) + IF (${CMAKE_VERSION} VERSION_LESS 2.8.9) + ADD_DEFINITIONS(-fPIC) + ENDIF () +ENDIF () + +# Compile +INCLUDE_DIRECTORIES(${CLIENT_INCLUDE}) +ADD_EXECUTABLE(client ${CLIENT_SOURCE}) +TARGET_LINK_LIBRARIES(client ${CLIENT_LIBRARIES}) + +# vim: set ts=8 sw=4 tw=0 : diff --git a/client/client.c b/client/client.c new file mode 100644 index 0000000..de5468e --- /dev/null +++ b/client/client.c @@ -0,0 +1,30 @@ +/** + * @file client.c + * + * Sample client using the libbemenu. + * Also usable as dmenu replacement. + */ + +#include <stdlib.h> + +/** + * Main method + * + * This function gives and takes the life of our program. + * + * @param argc Number of arguments from command line + * @param argv Pointer to array of the arguments + * @return exit status of the program + */ +int main(int argc, char **argv) +{ + (void)argc, (void)argv; + + /* + * code goes here + */ + + return EXIT_SUCCESS; +} + +/* vim: set ts=8 sw=4 tw=0 :*/ |