Skip to content

Commit

Permalink
feat: build Release successfully
Browse files Browse the repository at this point in the history
Signed-off-by: Dylan <[email protected]>
  • Loading branch information
nmgwddj committed Oct 12, 2024
1 parent 1d95276 commit 5453e6d
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
[Oo]bj/
[Ll]og/
build/
bin/
bin/*.*

# Visual Studio 2015/2017 cache/options directory
.vs/
Expand Down
5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ else ()
add_definitions(-DSUPPORTLOCALPLAYER)
endif ()

set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG "${CMAKE_SOURCE_DIR}/bin")
set(CMAKE_PDB_OUTPUT_DIRECTORY_DEBUG "${CMAKE_SOURCE_DIR}/pdb")
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE "${CMAKE_SOURCE_DIR}/bin")
set(CMAKE_PDB_OUTPUT_DIRECTORY_RELEASE "${CMAKE_SOURCE_DIR}/pdb")

set(CMAKE_INCLUDE_CURRENT_DIR ON)
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
set_property(GLOBAL PROPERTY PREDEFINED_TARGETS_FOLDER "cmake")
Expand Down
4 changes: 2 additions & 2 deletions conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ def requirements(self):
self.requires("tinyxml/2.6.2")
self.requires("nim/10.5.0-beta.2@yunxin/testing")
self.requires("nertc/4.1.1@yunxin/stable")
self.requires("cef/2623@yunxin/stable")
self.requires("libcef/3.2623.1401@yunxin/stable")
self.requires("ne_live_player/1.1.1@yunxin/stable")
self.requires("image_ole/4.2.0@yunxin/stable")
self.requires("ne_transfer/0.1.0@yunxin/stable")

def imports(self):
script_path = os.path.split(os.path.realpath(__file__))[0]
binary_path = os.path.join(script_path, "bin")
self.copy("*.*", binary_path, "bin", "cef")
self.copy("*.*", binary_path, "bin", "libcef")
self.copy("*.*", binary_path, "bin", "nim")
self.copy("*.*", binary_path, "bin", "nertc")
self.copy("*.*", binary_path, "bin", "ne_live_player")
Expand Down
9 changes: 0 additions & 9 deletions nim_win_demo/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
project(nim_demo DESCRIPTION "NetEase IM Demo")

set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG "${CMAKE_SOURCE_DIR}/bin")
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE "${CMAKE_SOURCE_DIR}/bin")

add_definitions(
-DWITH_ENCRYPT
)
Expand Down Expand Up @@ -70,12 +67,6 @@ target_link_libraries(${PROJECT_NAME}
${CONAN_LIBS}
)

if (CMAKE_BUILD_TYPE MATCHES "Release")
target_link_libraries(${PROJECT_NAME} nim_libcef)
else ()
target_link_libraries(${PROJECT_NAME} nim_libcef_d)
endif ()

set_target_properties(${PROJECT_NAME}
PROPERTIES
LINK_FLAGS "/SUBSYSTEM:WINDOWS /DELAYLOAD:nim_libcef.dll /DELAYLOAD:NELivePlayer.dll"
Expand Down
3 changes: 0 additions & 3 deletions tool_kits/cef/cef_render/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ SET(TARGET_NAME render)

PROJECT(${TARGET_NAME} DESCRIPTION "NetEase IM Demo CEF Render Process")

SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG "${CMAKE_SOURCE_DIR}/bin")
SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE "${CMAKE_SOURCE_DIR}/bin")

INCLUDE_DIRECTORIES(
${CMAKE_CURRENT_LIST_DIR}/../
${CMAKE_CURRENT_LIST_DIR}/../../
Expand Down
1 change: 1 addition & 0 deletions tool_kits/cef/cef_render/main.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include "include/cef_client.h"
#include "app/client_app.h"
#include <locale.h>

int WINAPI wWinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPWSTR lpszCmdLine, int nCmdShow)
{
Expand Down

0 comments on commit 5453e6d

Please sign in to comment.