Commit graph

18 commits

Author SHA1 Message Date
Romain Vimont 9826c5c4a4 Remove HiDPI compilation flag
Always enable HiDPI support, there is no reason to expose a compilation
flag.
2021-04-04 15:00:13 +02:00
Romain Vimont a46733906a Replace noconsole binary by a wrapper script
This simplifies the build system.

Refs <https://github.com/Genymobile/scrcpy/issues/1975#issuecomment-745314161>
2020-12-22 18:51:59 +01:00
Romain Vimont 902b99174d Fix server debugger for Android >= 9
Add a compilation flag to select the debugger method to use:
 - old: Android < 9
 - new: Android >= 9

See <https://github.com/Genymobile/scrcpy/issues/1187#issuecomment-599075661>
2020-03-19 19:15:43 +01:00
Romain Vimont 683f7ca848 Document how to attach a debugger to the server 2019-11-03 19:42:37 +01:00
Romain Vimont 3da95b52bd Rename scrcpy-server.jar to scrcpy-server
The server name ending with .jar has several drawbacks:
 - meson requires the jar executable to attempt to modify it:
     <https://github.com/Genymobile/scrcpy/issues/404#issuecomment-456065923>
     <https://github.com/mesonbuild/meson/issues/4844>
 - meson warns during "ninja install"
     <https://github.com/Genymobile/scrcpy/issues/458>
 - some users try to execute it on the computer as a java executable

Removing the extension solves all these problems.
2019-10-31 10:54:29 +01:00
Romain Vimont 02692ffa42 Rename "build_" to "compile_"
Recent versions of meson complain about an option having name starting
with "build_":

> DEPRECATION: Option uses prefix "build_", which is reserved for Meson.
> This will become an error in the future.

Use "compile_" instead.
2019-07-29 15:19:07 +02:00
Romain Vimont 8ca36406b9 Remove compilation flag "skip_frames"
It is unused since ebccb9f6cc.
2019-06-12 11:43:18 +02:00
Romain Vimont 53310a925a Disable portable build by default
The default value of a boolean meson option is true. We want
non-portable build by default.
2019-06-12 11:26:23 +02:00
Romain Vimont 2755bfc255 Improve portable builds
In portable builds, scrcpy-server.jar was supposed to be present in the
current directory, so in practice it worked only if scrcpy was launched
from its own directory.

Instead, find the absolute path of the executable and build a suitable
path to use scrcpy-server.jar from the same directory.
2019-06-11 17:44:07 +02:00
Romain Vimont eb34098add Simplify portable build configuration
To create a portable build (with scrcpy-server.jar accessible from the
scrcpy directory), replace OVERRIDE_SERVER_PATH by a simple compilation
flag: PORTABLE.

This paves the way to use more complex rules to determine the path of
scrcpy-server.jar in portable builds.
2019-06-11 17:44:07 +02:00
Romain Vimont f705a73149 Use a meson option to crossbuild for Windows
Meson decided to crossbuild for Windows as soon as
meson.is_cross_build() returned true. This made non-Windows crossbuilds
fail.

Instead, add an explicit option "crossbuild_windows".

Fixes <https://github.com/Genymobile/scrcpy/issues/165>.
2018-06-05 20:45:41 +02:00
Romain Vimont aedc2c2da9 Also build "noconsole" binary for Windows
On Windows, an application is either console or gui, it cannot be both.

Scrcpy should be both: it outputs important information to console, but
we still want to be able to ignore the console and launch it without a
visible cmd.exe window.

Therefore, build two binaries:
 - scrcpy.exe
 - scrcpy-noconsole.exe
2018-05-28 20:45:54 +02:00
Romain Vimont fffeedffda Expose High DPI support configuration flag
The High DPI support is enabled by default, so that the renderer use the
full definition of High DPI screens.

However, there are still mouse coordinates problems on some MacOS having
High DPI support (but not all), so expose a way to disable it.
2018-03-07 18:07:02 +01:00
Romain Vimont 089378926b Rename SCRCPY_SERVER_JAR to SCRCPY_SERVER_PATH
The server is currently a JAR, but it may ba an APK or a DEX, so the
variable name should not contain the type.

Rename the environment variable, the Meson options and the C
definitions.
2018-02-16 15:36:25 +01:00
Romain Vimont fb0e467585 Add description for meson options
The descriptions are displayed in the result of:

    mesonconf builddir
2018-02-15 11:28:19 +01:00
Romain Vimont 42882702d7 Expose skip_frames as a build option
It can be initially configured by:

    meson builddir -Dskip_frames=false

Or on an existing builddir by:

    mesonconf builddir -Dskip_frames=false
2018-02-15 11:24:18 +01:00
Romain Vimont 07983d914f Accept prebuilt server
Expose a 'prebuilt_server' option to pass the path of the prebuilt
binary, so that the build does not require Android SDK.

Usage:

    meson builddir -Dprebuilt_server=/tmp/my_prebuilt_server.jar
2018-02-14 16:28:21 +01:00
Romain Vimont c2127d0819 Replace meson subprojects by subdir
Since Meson 0.44, subproject_dir may not be '.' anymore. This implies we
must move app/ and server/ to a subprojects/ directory, which requires
to also change some gradle files.

Instead, just use subdir(), with options to disable building of the app
or the server.
2018-02-14 14:03:56 +01:00