From: Armaan Bhojwani <3fb650a9-b47e-4604-a282-1dd91953b2ee@anonaddy.me> Date: Mon, 26 Oct 2020 17:47:28 +0000 (-0400) Subject: modified cmake X-Git-Url: https://git.armaanb.net/?p=gen-shell.git;a=commitdiff_plain;h=889d7af2ebb3991457adedf94260ac28ec691f1a modified cmake --- diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9a787c4 --- /dev/null +++ b/.gitignore @@ -0,0 +1,68 @@ + +# Created by https://www.toptal.com/developers/gitignore/api/cmake,linux,c++ +# Edit at https://www.toptal.com/developers/gitignore?templates=cmake,linux,c++ + +### C++ ### +# Prerequisites +*.d + +# Compiled Object files +*.slo +*.lo +*.o +*.obj + +# Precompiled Headers +*.gch +*.pch + +# Compiled Dynamic libraries +*.so +*.dylib +*.dll + +# Fortran module files +*.mod +*.smod + +# Executables +*.exe +*.out +*.app +gen-shell + +### CMake ### +CMakeLists.txt.user +CMakeCache.txt +CMakeFiles +CMakeScripts +Testing +Makefile +cmake_install.cmake +install_manifest.txt +compile_commands.json +CTestTestfile.cmake +_deps +CPackConfig.cmake +CPackSourceConfig.cmake + +### CMake Patch ### +# External projects +*-prefix/ + +### Linux ### +*~ + +# temporary files which can be created if a process still has a handle open of a deleted file +.fuse_hidden* + +# KDE directory preferences +.directory + +# Linux trash folder which might appear on any partition or disk +.Trash-* + +# .nfs files are created when an open file is removed but is still being accessed +.nfs* + +# End of https://www.toptal.com/developers/gitignore/api/cmake,linux,c++ diff --git a/CMakeLists.txt b/CMakeLists.txt index 01081a8..44a96e8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -52,16 +52,10 @@ configure_file ( ${CMAKE_SOURCE_DIR}/cmake.h) add_subdirectory (src) -add_subdirectory (doc) if (EXISTS ${CMAKE_SOURCE_DIR}/test) add_subdirectory (test EXCLUDE_FROM_ALL) endif (EXISTS ${CMAKE_SOURCE_DIR}/test) -set (doc_FILES NEWS ChangeLog INSTALL AUTHORS COPYING) -foreach (doc_FILE ${doc_FILES}) - install (FILES ${doc_FILE} DESTINATION ${GEN-SHELL_DOCDIR}) -endforeach (doc_FILE) - # --- set (CPACK_SOURCE_GENERATOR "TGZ") diff --git a/cmake.h b/cmake.h index 5b19e6c..53869b8 100644 --- a/cmake.h +++ b/cmake.h @@ -6,6 +6,7 @@ /* Package information */ #define PACKAGE "gen-shell" #define VERSION "0.0.1" +#define PACKAGE_BUGREPORT "" #define PACKAGE_NAME "gen-shell" #define PACKAGE_TARNAME "gen-shell" #define PACKAGE_VERSION "0.0.1" @@ -22,11 +23,11 @@ /* cmake information */ #define HAVE_CMAKE -#define CMAKE_VERSION "3.8.1" +#define CMAKE_VERSION "3.18.4" /* Compiling platform */ -/* #undef LINUX */ -#define DARWIN +#define LINUX +/* #undef DARWIN */ /* #undef CYGWIN */ /* #undef FREEBSD */ /* #undef OPENBSD */ @@ -38,7 +39,7 @@ /* #undef UNKNOWN */ /* Found the Readline library */ -#define HAVE_READLINE +/* #undef HAVE_READLINE */ /* Found the pthread library */ /* #undef HAVE_LIBPTHREAD */ diff --git a/commit.h b/commit.h index a968aef..582da05 100644 --- a/commit.h +++ b/commit.h @@ -1,4 +1,4 @@ /* commit.h.in. Creates commit.h during a cmake run */ /* git information */ -#define COMMIT "e6d0532" +#define COMMIT "eb1e18e" diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 787640d..d9c9d54 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -7,7 +7,7 @@ include_directories (${CMAKE_SOURCE_DIR} set (tasksh_SRCS diag.cpp help.cpp prompt.cpp - review.cpp + # review.cpp shell.cpp) set (libshared_SRCS libshared/src/Color.cpp libshared/src/Color.h @@ -28,7 +28,6 @@ add_executable (tasksh_executable main.cpp) target_link_libraries (tasksh_executable tasksh libshared ${TASKSH_LIBRARIES}) -set_property (TARGET tasksh_executable PROPERTY OUTPUT_NAME "tasksh") +set_property (TARGET tasksh_executable PROPERTY OUTPUT_NAME "gen-shell") install (TARGETS tasksh_executable DESTINATION ${TASKSH_BINDIR}) - diff --git a/src/help.cpp b/src/help.cpp index 6571ce2..be2ede2 100644 --- a/src/help.cpp +++ b/src/help.cpp @@ -31,7 +31,7 @@ int cmdHelp () { std::cout << '\n' - << "A generic shell" + << "A generic shell"; return 0; } diff --git a/src/liblibshared.a b/src/liblibshared.a index fe9bdc8..39ece94 100644 Binary files a/src/liblibshared.a and b/src/liblibshared.a differ diff --git a/src/libtasksh.a b/src/libtasksh.a index 385a8c1..236d665 100644 Binary files a/src/libtasksh.a and b/src/libtasksh.a differ diff --git a/src/main.cpp b/src/main.cpp index 269d739..bdac934 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -42,7 +42,7 @@ // tasksh commands. int cmdHelp (); int cmdDiagnostics (); -int cmdReview (const std::vector &, bool); +// int cmdReview (const std::vector &, bool); int cmdShell (const std::vector &); std::string promptCompose (); std::string findTaskwarrior (); @@ -117,7 +117,7 @@ static int commandLoop (bool autoClear) else if (closeEnough ("quit", args[0], 3)) status = -1; else if (closeEnough ("help", args[0], 3)) status = cmdHelp (); else if (closeEnough ("diagnostics", args[0], 3)) status = cmdDiagnostics (); - else if (closeEnough ("review", args[0], 3)) status = cmdReview (args, autoClear); + // else if (closeEnough ("review", args[0], 3)) status = cmdReview (args, autoClear); else if (closeEnough ("exec", args[0], 3) || args[0][0] == '!') status = cmdShell (args); else if (command != "")