Add win32 VERSION_INFO resource blocks for the DLLs
This commit is contained in:
parent
426f6dd485
commit
3f711b8958
|
@ -26,12 +26,14 @@ set_source_files_properties( bitmap2cmp_gui.cpp PROPERTIES
|
|||
COMPILE_DEFINITIONS "COMPILING_DLL"
|
||||
)
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# BITMAP2COMPONENT_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( bitmap2component )
|
||||
else()
|
||||
set( BITMAP2COMPONENT_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/bitmap2component.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if( APPLE )
|
||||
# setup bundle
|
||||
|
|
|
@ -46,12 +46,13 @@ set( CVPCB_SRCS
|
|||
tools/cvpcb_fpviewer_selection_tool.cpp
|
||||
)
|
||||
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# CVPCB_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( cvpcb )
|
||||
mingw_resource_compiler( cvpcb-dll )
|
||||
else()
|
||||
set( CVPCB_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/cvpcb.rc )
|
||||
set( CVPCB_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/cvpcb-dll.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
|
@ -60,6 +61,7 @@ add_library( cvpcb_kiface MODULE
|
|||
cvpcb.cpp
|
||||
${CVPCB_SRCS}
|
||||
${CVPCB_DIALOGS}
|
||||
${CVPCB_RESOURCES}
|
||||
)
|
||||
|
||||
set_target_properties( cvpcb_kiface PROPERTIES
|
||||
|
|
|
@ -305,13 +305,14 @@ if( KICAD_SPICE )
|
|||
)
|
||||
endif()
|
||||
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# EESCHEMA_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( eeschema )
|
||||
else()
|
||||
set( EESCHEMA_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/eeschema.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Create a C++ compilable string initializer containing markdown text into a *.h file:
|
||||
add_custom_command(
|
||||
|
@ -487,6 +488,10 @@ if( APPLE )
|
|||
DESTINATION "${OSX_BUNDLE_INSTALL_PLUGIN_DIR}/sim" )
|
||||
endif()
|
||||
else()
|
||||
if( MSVC )
|
||||
target_sources( eeschema_kiface PRIVATE ${CMAKE_SOURCE_DIR}/resources/msw/eeschema-dll.rc )
|
||||
endif()
|
||||
|
||||
install( TARGETS eeschema
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary
|
||||
|
|
|
@ -80,12 +80,14 @@ set( GERBVIEW_EXTRA_SRCS
|
|||
${CMAKE_SOURCE_DIR}/common/page_info.cpp
|
||||
)
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# GERBVIEW_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( gerbview )
|
||||
else()
|
||||
set( GERBVIEW_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/gerbview.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if( APPLE )
|
||||
# setup bundle
|
||||
|
@ -203,6 +205,10 @@ if( APPLE )
|
|||
" COMPONENT Runtime
|
||||
)
|
||||
else()
|
||||
if( MSVC )
|
||||
target_sources( gerbview_kiface PRIVATE ${CMAKE_SOURCE_DIR}/resources/msw/gerbview-dll.rc )
|
||||
endif()
|
||||
|
||||
install( TARGETS gerbview
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary
|
||||
|
|
|
@ -38,12 +38,14 @@ set( KICAD_SRCS
|
|||
tools/kicad_manager_control.cpp
|
||||
)
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# KICAD_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( kicad )
|
||||
else()
|
||||
set( KICAD_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/kicad.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if( APPLE )
|
||||
set( KICAD_RESOURCES kicad.icns kicad_doc.icns )
|
||||
|
|
|
@ -52,13 +52,14 @@ set( PL_EDITOR_EXTRA_SRCS
|
|||
${CMAKE_SOURCE_DIR}/common/page_info.cpp
|
||||
)
|
||||
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# PL_EDITOR_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( pl_editor )
|
||||
else()
|
||||
set( PL_EDITOR_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/pl_editor.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
if( APPLE )
|
||||
|
@ -158,6 +159,10 @@ if( APPLE )
|
|||
" COMPONENT Runtime
|
||||
)
|
||||
else()
|
||||
if( MSVC )
|
||||
target_sources( pl_editor_kiface PRIVATE ${CMAKE_SOURCE_DIR}/resources/msw/pl_editor-dll.rc )
|
||||
endif()
|
||||
|
||||
install( TARGETS pl_editor
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary
|
||||
|
|
|
@ -49,12 +49,14 @@ set( PCB_CALCULATOR_SRCS
|
|||
../common/env_vars.cpp # needed on MSW to avoid a link issue (a symbol not found)
|
||||
)
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# PCB_CALCULATOR_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( pcb_calculator )
|
||||
else()
|
||||
set( PCB_CALCULATOR_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/pcb_calculator.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if( APPLE )
|
||||
# setup bundle
|
||||
|
@ -92,6 +94,7 @@ add_library( pcb_calculator_kiface MODULE
|
|||
pcb_calculator.cpp
|
||||
${PCB_CALCULATOR_SRCS}
|
||||
)
|
||||
|
||||
set_target_properties( pcb_calculator_kiface PROPERTIES
|
||||
OUTPUT_NAME pcb_calculator
|
||||
PREFIX ${KIFACE_PREFIX}
|
||||
|
@ -145,6 +148,10 @@ if( APPLE )
|
|||
" COMPONENT Runtime
|
||||
)
|
||||
else()
|
||||
if( MSVC )
|
||||
target_sources( pcb_calculator_kiface PRIVATE ${CMAKE_SOURCE_DIR}/resources/msw/pcb_calculator-dll.rc )
|
||||
endif()
|
||||
|
||||
install( TARGETS pcb_calculator
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary
|
||||
|
|
|
@ -554,13 +554,14 @@ if( DOXYGEN_FOUND )
|
|||
)
|
||||
endif()
|
||||
|
||||
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# PCBNEW_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler( pcbnew )
|
||||
else()
|
||||
set( PCBNEW_RESOURCES ${CMAKE_SOURCE_DIR}/resources/msw/pcbnew.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
# Create a C++ compilable string initializer containing markdown text into a *.h file:
|
||||
|
@ -773,6 +774,10 @@ if( APPLE )
|
|||
" COMPONENT Runtime
|
||||
)
|
||||
else()
|
||||
if( MSVC )
|
||||
target_sources( pcbnew_kiface PRIVATE ${CMAKE_SOURCE_DIR}/resources/msw/pcbnew-dll.rc )
|
||||
endif()
|
||||
|
||||
install( TARGETS pcbnew
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
#define RC_VER_FILE_DESCRIPTION "KiCad Dynamic Link Library " KICAD_WIN32_RC_PRODVER_STR
|
||||
#define RC_VER_INTERNALNAME "_cvpcb"
|
||||
#define RC_VER_ORIGINALFILENAME "_cvpcb.kiface"
|
||||
|
||||
#include "kiwin32-dll.rc"
|
|
@ -1,3 +0,0 @@
|
|||
icon_cvpcb ICON "../bitmaps_png/icons/icon_cvpcb.ico"
|
||||
|
||||
#include "kiwin32.rc"
|
|
@ -0,0 +1,4 @@
|
|||
#define RC_VER_FILE_DESCRIPTION "KiCad Schematic Editor " KICAD_WIN32_RC_PRODVER_STR
|
||||
#define RC_VER_INTERNALNAME "_eeschema"
|
||||
#define RC_VER_ORIGINALFILENAME "_eeschema.kiface"
|
||||
#include "kiwin32-dll.rc"
|
|
@ -0,0 +1,4 @@
|
|||
#define RC_VER_FILE_DESCRIPTION "KiCad Gerber Viewer " KICAD_WIN32_RC_PRODVER_STR
|
||||
#define RC_VER_INTERNALNAME "_gerbview"
|
||||
#define RC_VER_ORIGINALFILENAME "_gerbview.kiface"
|
||||
#include "kiwin32-dll.rc"
|
|
@ -0,0 +1,40 @@
|
|||
#include <winver.h> // defines VS_VERSION_INFO
|
||||
#include <kicad_build_version.h>
|
||||
|
||||
#ifndef DEBUG
|
||||
#define VER_DEBUG 0
|
||||
#else
|
||||
#define VER_DEBUG VS_FF_DEBUG
|
||||
#endif
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION KICAD_WIN32_RC_FILEVER
|
||||
PRODUCTVERSION KICAD_WIN32_RC_PRODVER
|
||||
FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
|
||||
FILEFLAGS (VER_DEBUG)
|
||||
FILEOS VOS__WINDOWS32
|
||||
FILETYPE VFT_DLL
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "040904E4"
|
||||
BEGIN
|
||||
// this gets dispalyed in the windows 10 task manager
|
||||
VALUE "FileDescription", RC_VER_FILE_DESCRIPTION
|
||||
VALUE "FileVersion", KICAD_WIN32_RC_FILEVER_STR
|
||||
//original filename without extension
|
||||
VALUE "InternalName", RC_VER_INTERNALNAME
|
||||
VALUE "LegalCopyright", "Copyright (C) 2021 KiCad Developers"
|
||||
// the exe name
|
||||
VALUE "OriginalFilename", RC_VER_ORIGINALFILENAME
|
||||
// name of distributed package
|
||||
VALUE "ProductName", "KiCad EDA"
|
||||
VALUE "ProductVersion", KICAD_WIN32_RC_PRODVER_STR
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x409, 1252
|
||||
END
|
||||
END
|
|
@ -0,0 +1,4 @@
|
|||
#define RC_VER_FILE_DESCRIPTION "KiCad PCB Calculator " KICAD_WIN32_RC_PRODVER_STR
|
||||
#define RC_VER_INTERNALNAME "_pcb_calculator"
|
||||
#define RC_VER_ORIGINALFILENAME "_pcb_calculator.kiface"
|
||||
#include "kiwin32-dll.rc"
|
|
@ -0,0 +1,4 @@
|
|||
#define RC_VER_FILE_DESCRIPTION "KiCad PCB Editor " KICAD_WIN32_RC_PRODVER_STR
|
||||
#define RC_VER_INTERNALNAME "_pcbnew"
|
||||
#define RC_VER_ORIGINALFILENAME "_pcbnew.kiface"
|
||||
#include "kiwin32-dll.rc"
|
|
@ -0,0 +1,4 @@
|
|||
#define RC_VER_FILE_DESCRIPTION "KiCad Drawing Sheet Editor " KICAD_WIN32_RC_PRODVER_STR
|
||||
#define RC_VER_INTERNALNAME "_pl_editor"
|
||||
#define RC_VER_ORIGINALFILENAME "_pl_editor.kiface"
|
||||
#include "kiwin32-dll.rc"
|
Loading…
Reference in New Issue