Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
 into develop
  • Loading branch information
stfnp committed Mar 18, 2018
2 parents b43ba05 + 8a63554 commit fa313cc
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 19 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ set(APPLICATION_MAINTAINER "Stefan Pfeifer")
set(APPLICATION_COPYRIGHT "Copyright (C) 2016-2018 Stefan Pfeifer")
set(APPLICATION_LICENSE "GNU General Public License v3.0")
set(APPLICATION_DESCRIPTION_SHORT "Bow and arrow physics simulation")
set(APPLICATION_DESCRIPTION_LONG "Software tool for simulating the static and dynamic performance of user-defined bow designs")
set(APPLICATION_DESCRIPTION_LONG "Software tool for simulating the static and dynamic performance of bow designs")

# External libraries

Expand Down
28 changes: 12 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ This is however not strictly necessary, you can just as well run CMake yourself.
The first build may take an hour or longer, depending on your hardware.
This is because some necessary external dependencies will be downloaded and compiled first (see `CMakeLists.txt` for details).

The instructions mention exact version numbers for all the tools and libraries used.
These aren't strict requirements, just a reference for how the official releases were built.

## Windows

### Prerequisites
Expand All @@ -28,18 +31,18 @@ This is because some necessary external dependencies will be downloaded and comp

* [CMake 3.10.2](https://cmake.org/download/). Check the installer option to add CMake to the system path.

* [Qt 5.10.1 (Open Source)](https://www.qt.io/download). The necessary components depend on the target architecture:
* Qt 5.10.1 32-bit (MSVC 2015)
* Qt 5.10.1 64-bit (MSVC 2015)
* [Qt (Open Source)](https://www.qt.io/download). The necessary components depend on the target architecture:
* Qt 5.7.1 32-bit (MSVC 2015)
* Qt 5.7.1 64-bit (MSVC 2015)

### Compiling with Qt Creator

Download or clone this repository and open `CMakeLists.txt` with Qt Creator.
Pick the kit *Desktop Qt 5.10.1 MSVC2015 32bit* or *64bit* and configure the project.
Pick the kit *Desktop Qt 5.7.1 MSVC2015 32bit* or *64bit* and configure the project.

Select the build type (e.g. *Release*) and perform a build.

If Qt Creator didn't auto-detect the C++ compiler or CMake, go to *Projects*, *Manage Kits...* and set them manually (*Microsoft Visual C++ Compiler 15.0 x86* for the 32bit Kit, *amd64* for the 64bit one).
If Qt Creator didn't auto-detect the C and C++ compiler or CMake, go to *Projects*, *Manage Kits...* and set them manually (*Microsoft Visual C++ Compiler 15.0 x86* for the 32bit Kit, *amd64* for the 64bit one).

Using the default CMake generator (*NMake Makefiles JOM*) might give you an error like this: "The C compiler ... is not able to compile a simple test program".
This can be solved by adding the directory `Qt/Tools/QtCreator/bin` of the Qt installation to the system path.
Expand All @@ -54,23 +57,17 @@ Building the Windows installer requires some additional tools,

In Qt Creator, check the target `iss-installer` under *Projects*, *Build Steps*, *Details* and perform a build.

## Linux
## Linux (Debian 9.4.0)

### Prerequisites

* GCC C and C++ Compilers. On Ubuntu they're in the `build-essentials` package.

* CMake. Package `cmake` on Ubuntu.

* [Qt 5.10.1 (Open Source)](https://www.qt.io/download). Install the following components:
* Qt 5.10.1 Desktop gcc 64-bit

* Additional graphics libraries. On Ubuntu those are `mesa-common-dev`, `libglu1-mesa-dev` and `libxt-dev`.
* Tools: `qtcreator`, `cmake`
* Libraries: `qtbase5-dev`, `libqt5x11extras5-dev`

### Compiling with Qt Creator

Download or clone this repository and open `CMakeLists.txt` with Qt Creator.
Pick the kit *Desktop Qt 5.10.1 GCC 64bit* and configure the project.
Pick the kit *Desktop* and configure the project.

Select the build type (e.g. *Release*) and perform a build.

Expand All @@ -83,6 +80,5 @@ Building the debian package requires `dpkg` to be installed. In Qt Creator, chec
Building the AppImage requires [linuxdeployqt](https://github.com/probonopd/linuxdeployqt/releases), which is itself an AppImage.
Download it from github and make it make it executable via `chmod a+x ...`.
Ensure that it is found as `linuxdeployqt` by the command line, for example by dropping or linking it in your `/usr/local/bin/` folder.
Also make sure that the `qmake` executable is found and points to the correct Qt installation (e.g. `/home/Qt/5.10.1/gcc_64/bin/qmake`).

In Qt Creator, check the target `appimage` under *Projects*, *Build Steps*, *Details* and perform a build.
2 changes: 1 addition & 1 deletion platforms/linux/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,6 @@ add_custom_command(
OUTPUT Bow_Simulator-x86_64.AppImage
DEPENDS linux-files
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_BINARY_DIR}/linux-files ${CMAKE_BINARY_DIR}/appimage
COMMAND linuxdeployqt ${CMAKE_BINARY_DIR}/appimage/usr/share/applications/bow-simulator.desktop -appimage -no-plugins -no-translations
COMMAND linuxdeployqt ${CMAKE_BINARY_DIR}/appimage/usr/share/applications/bow-simulator.desktop -appimage -bundle-non-qt-libs -no-translations
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
)
2 changes: 1 addition & 1 deletion platforms/linux/control.in
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ Maintainer: @APPLICATION_MAINTAINER@
Homepage: @APPLICATION_WEBSITE@
Description: @APPLICATION_DESCRIPTION_SHORT@
@APPLICATION_DESCRIPTION_LONG@
Depends: qt5-default
Depends: qt5-default, libqt5x11extras5

0 comments on commit fa313cc

Please sign in to comment.