CRiSTiK24 / AddCI-CDLibreCAD_3

Creating a CI/CD for Librecad3
http://librecad.org
Other
4 stars 2 forks source link

Windows Install #8

Open flywire opened 2 years ago

flywire commented 2 years ago

A few things aren't clear:

  1. Is it a computer or user install?
  2. Why add LibreCAD3 to path? (anyway, WARNING! PATH too long installer unable to modify PATH!)
  3. Is intention to provide prereleae binaries as debug version?
  4. Support for of old version of OpenGL?

The installer file should have a meaningful name.

flywire commented 2 years ago

Installs as Librecad shortcut, expect LibreCAD3.

2. Why add LibreCAD3 to path?

I note it is optional in the install with no explanation.

Without adding to path it will not start and can't find files which are not on my computer:

  1. VCRUNTIME140D.dll
  2. MSVCP140D.dll
  3. VCRUNTIME140_1D.dll
  4. ucrtbased.dll

I assume these are the debug versions of the dlls. Following installation, the software should run.

CRiSTiK24 commented 2 years ago

Hi flywire! The tool that I'm using to create the installer for windows is CPack, which uses NSIS to create it.

  1. I guess both. I haven't done anything for the functionality, but I can check out if there is a way to restrict it if needed.
  2. I will try to see if there is any way to solve the issue, i had the same but thought it was a personal problem since my path is very long.
  3. On the other side the binaries that you mention (VCRUNTIME140D.dll...) are installed by CMake in the same file with:
    include(InstallRequiredSystemLibraries)

    It automatically tries to add to the package some needed libraries.

  4. So this should work in any modern computer, but if using a VM or old system then using the instructions wroten in "Installation" will be needed. 5.Sure, what name would you want, something like "LibreCAD3.exe"?

All the code for Cpack/NSIS should be in the root CMakeLists.txt, here is it:

#Cpack -> NSIS
#General Vars
set(CPACK_PACKAGE_NAME "LibreCAD3")
set(CPACK_PACKAGE_VENDOR "LibreCAD")
set(CPACK_PACKAGE_VERSION_MAJOR "0")
set(CPACK_PACKAGE_VERSION_MINOR "1")
set(CPACK_PACKAGE_VERSION_PATCH "1")
set(CPACK_SOURCE_PACKAGE_FILE_NAME ${CPACK_PACKAGE_NAME}) #name of the install folder
set(CPACK_PACKAGE_DESCRIPTION "LibreCAD is a free Open Source CAD application for Windows, Apple and Linux. Support and documentation are free from our large, dedicated community of users, contributors and developers.")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Open Source 2D-CAD")
set(CPACK_PACKAGE_HOMEPAGE_URL "https://librecad.org/")
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE") 
#NSIS Vars
set(CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL "ON")
set(CPACK_NSIS_MODIFY_PATH "ON")
set(CPACK_CREATE_DESKTOP_LINKS "ON")
set(CPACK_NSIS_DISPLAY_NAME ${CPACK_PACKAGE_NAME})
set(CPACK_NSIS_PACKAGE_NAME ${CPACK_PACKAGE_NAME})
set(CPACK_NSIS_HELP_LINK "https://github.com/LibreCAD/LibreCAD_3")
set(CPACK_NSIS_URL_INFO_ABOUT ${CPACK_PACKAGE_HOMEPAGE_URL})
set(CPACK_NSIS_CONTACT "https://librecad.zulipchat.com/login/")
set(CPACK_NSIS_FINISH_TITLE "Thanks for installing LibreCAD 3")
#For the shortcut
set(CPACK_PACKAGE_EXECUTABLES
    "librecad" "Librecad shortcut"
)
set(CPACK_CREATE_DESKTOP_LINKS 
    "librecad"
)
include(CPack)