Skip to content

Commit

Permalink
first release
Browse files Browse the repository at this point in the history
  • Loading branch information
VPROFi committed Aug 25, 2023
0 parents commit bba721f
Show file tree
Hide file tree
Showing 42 changed files with 5,821 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "vendor/far2l"]
path = vendor/far2l
url = https://github.com/VPROFi/far2l.git
19 changes: 19 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
cmake_minimum_required(VERSION 3.0.2)

project(processes)

#set(CMAKE_BUILD_TYPE Debug)
set(CMAKE_BUILD_TYPE Release)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_C_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

# build far2l
add_subdirectory(vendor/far2l)

# build plugin
set(PROJECT_SOURCE_DIR ${CMAKE_SOURCE_DIR}/vendor/far2l)
get_directory_property(INSTALL_DIR DIRECTORY ${PROJECT_SOURCE_DIR} DEFINITION INSTALL_DIR)

add_subdirectory(src)
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# processplugin

TODO:
Плагин только умеет выводить процессы, и удалять их. Нужно расширять.

Плагин позволяет (linux и macos):
* просматривать, редактировать информацию о процессах

The plugin allows (linux and macos):
* view and edit information about processes, ...

Build instruction like far2l (https://github.com/VPROFi/far2l)

If your want build inside other version far2l - put content ./src into ./far2l/processes and add to ./far2l/CMakeLists.txt add_subdirectory (processes)
69 changes: 69 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
cmake_minimum_required(VERSION 3.0.2)

project(processes)

get_directory_property(PROJECT_SOURCE_DIR DIRECTORY ../ DEFINITION PROJECT_SOURCE_DIR)
get_directory_property(INSTALL_DIR DIRECTORY ${PROJECT_SOURCE_DIR} DEFINITION INSTALL_DIR)

message("processes PROJECT_SOURCE_DIR ${PROJECT_SOURCE_DIR} ${CMAKE_SYSTEM_NAME}")

set(SOURCES
farconnect.cpp
fardialog.cpp
farpanel.cpp
plugincfg.cpp
plugin.cpp
farapi.cpp
progress.cpp
procplugin.cpp
procpanel.cpp
process/process.cpp
process/processes.cpp
common/errname.c
common/log.c
common/sizestr.c
common/utf8util.c
common/procutil.c
)


set(CMAKE_CXX_STANDARD 17)
set(CMAKE_C_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")

# GCC 6+ has a warning for an ABI change due to a bug introduced in GCC 5:
# http://gcc.gnu.org/bugzilla/show_bug.cgi?id=77728. As we are building all of
# drcachesim and not linking to other C++ code, we can just ignore it.
if (ARM AND CMAKE_COMPILER_IS_GNUCC)
include(CheckCXXCompilerFlag)
CHECK_CXX_COMPILER_FLAG(-Wno-psabi GCC_HAS_NO_PSABI)
if (GCC_HAS_NO_PSABI)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-psabi")
endif (GCC_HAS_NO_PSABI)
endif ()

add_library(processes MODULE ${SOURCES})
target_link_libraries(processes utils far2l)

target_compile_definitions(processes PRIVATE -DUSEUCD=OFF -DWINPORT_DIRECT -DUNICODE -DFAR_DONT_USE_INTERNALS)

target_include_directories(processes PRIVATE .)
target_include_directories(processes PRIVATE ./process)
target_include_directories(processes PRIVATE ${PROJECT_SOURCE_DIR}/utils/include)
target_include_directories(processes PRIVATE ${PROJECT_SOURCE_DIR}/far2l/far2sdk)
target_include_directories(processes PRIVATE ${PROJECT_SOURCE_DIR}/far2l/Include)
target_include_directories(processes PRIVATE ${PROJECT_SOURCE_DIR}/WinPort)

set_target_properties(processes
PROPERTIES
LIBRARY_OUTPUT_DIRECTORY "${INSTALL_DIR}/Plugins/processes/plug"
PREFIX ""
SUFFIX ".far-plug-wide")

add_custom_command(TARGET processes POST_BUILD
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/configs
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/configs "${INSTALL_DIR}/Plugins/processes"
)
Loading

0 comments on commit bba721f

Please sign in to comment.