Page 1 of 1

How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 10 Dec 2020 08:10
by cwithern173
Hi guys. I'm new to this forum so apologies if I break any of the forum's rules here.

I've been trying to run JGR's Patch Pack (v0.39.1) without any luck. I downloaded the .tar.gz file from GitHub and checked compiling.md, but I couldn't understand the instructions. So I decided to follow some threads from a few years ago, like this one: viewtopic.php?f=33&t=73469&start=20 . However, I got stuck at the second step. I got "No such file or directory" when I executed /.configure . I googled a bit and apparently cd searches within the directory (or something like that) and /.configure executes a script named "configure" which doesn't exist in the folder (I think). Can anyone help?

PS: I'm not an expert at this computer stuff by any means so do correct me if I'm wrong.

Re: How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 10 Dec 2020 12:29
by Auge
Hello
cwithern173 wrote: 10 Dec 2020 08:10 I've been trying to run JGR's Patch Pack (v0.39.1) without any luck. I downloaded the .tar.gz file from GitHub and checked compiling.md, but I couldn't understand the instructions. So I decided to follow some threads from a few years ago, like this one: viewtopic.php?f=33&t=73469&start=20 . However, I got stuck at the second step. I got "No such file or directory" when I executed /.configure . I googled a bit and apparently cd searches within the directory (or something like that) and /.configure executes a script named "configure" which doesn't exist in the folder (I think).
The chain with the .configure command is outdated. JGR described the list of commands in this forum entry (below the quote). If you already cloned the repository, yo have to start with git checkout ... or one of the following commands (the first commands are os dependent and for Debian-based Linux-distributions).

Tschö, Auge

Re: How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 11 Dec 2020 04:47
by cwithern173
Thank you very much Auge!

I adapted the commands a bit (used brew install instead of sudo apt-get for the first command, and omitted the second one). Eventually though, I managed to run it, albeit with some errors (5 textures missing, 1377 strings missed in this translation ?( ).

PS: Do I have to mark this thread closed or something?

Re: How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 11 Dec 2020 11:01
by kamnet
cwithern173 wrote: 11 Dec 2020 04:47 I adapted the commands a bit (used brew install instead of sudo apt-get for the first command, and omitted the second one).
It would be helpful if you could post the step-by-step directions you used to successfully compile, so that others will have an up-to-date guide on how to do it. Compiling JGRPP on the various MacOS installs is among the top frequently requested things.
Eventually though, I managed to run it, albeit with some errors (5 textures missing, 1377 strings missed in this translation ?( ).


It's nothing to worry about, unless you're only fluent in one foreign language that has missing translations for some words. It doesn't affect gameplay though.
PS: Do I have to mark this thread closed or something?
Nope. We leave it open so that others can continue to contribute, when applicable.

Re: How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 11 Dec 2020 15:35
by cwithern173
Ah OK, I'll type out the commands I executed then.

brew install xz
brew install lzo
brew install fcitx-remote-for-osx

brew install build-essential cmake git
git clone https://github.com/JGRennison/OpenTTD-patches.git jgrpp
cd jgrpp
git checkout jgrpp-0.39.1
mkdir build
cd build
brew install cmake
cmake ..
make

My initial install (eg. right after I had made my previous post) was generally fine, but I couldn't join multiplayer servers. So, I added the top three commands during my second install as the terminal window threw these warnings: (note: I still get network synchronisation as well as possible connection errors from time to time)

Liblzma warning:

CMake Warning at cmake/LinkPackage.cmake:21 (message):
LIBLZMA not found; compiling OpenTTD without LIBLZMA is strongly
disencouraged
Call Stack (most recent call first):
CMakeLists.txt:228 (link_package)

Lzo warning:

CMake Warning at cmake/LinkPackage.cmake:21 (message):
LZO not found; compiling OpenTTD without LZO is strongly disencouraged
Call Stack (most recent call first):
CMakeLists.txt:229 (link_package)

Fcitx warning:

By not providing "FindFcitx.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Fcitx", but
CMake did not find one.

Could not find a package configuration file provided by "Fcitx" with any of
the following names:

FcitxConfig.cmake
fcitx-config.cmake

Add the installation prefix of "Fcitx" to CMAKE_PREFIX_PATH or set
"Fcitx_DIR" to a directory containing one of the above files. If "Fcitx"
provides a separate development package or SDK, be sure it has been
installed.

There were also other errors shown, which I'm guessing did not affect the game that much; here are some of them.

Those related to Gestalt:

/Users/[REDACTED]/jgrpp/src/os/macosx/macos.mm:72:16: warning:
'gestaltSystemVersionMajor' is deprecated: first deprecated in macOS 10.8
- Use NSProcessInfo's operatingSystemVersion property instead.
[-Wdeprecated-declarations]
if (Gestalt(gestaltSystemVersionMajor, &version...

which I assume relates to checking version numbers.

Unused variables:

/Users/[REDACTED]/jgrpp/src/gfx.cpp:98:19: warning: unused variable
'DIRTY_BLOCK_WIDTH' [-Wunused-const-variable]
static const uint DIRTY_BLOCK_WIDTH = 64;

Overrides:

/Users/[REDACTED]/jgrpp/src/plans_gui.cpp:250:15: warning: 'OnPaint' overrides a
member function but is not marked 'override'
[-Winconsistent-missing-override]
virtual void OnPaint()
^
/Users/[REDACTED]/jgrpp/src/window_gui.h:612:15: note: overridden virtual function
is here
virtual void OnPaint()
^
Vehicle cache mismatches:

dbg: [desync] [load]: vehicle cache mismatch: cached_max_speed: type 0, vehicle 15 (14217), company 2, unit number 16, wagon 15, engine: Covered hopper , GRF: 454E0601, North Korean Trains Set 1.11.3, north_korean_train_set-1.11.3/dprktrains.grf

etc.

If my interpretation is wrong, please do tell me! Everything I've written here is a product of guessing and Googling.

Re: How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 11 Dec 2020 19:31
by rowdog

Code: Select all

CMake Warning at cmake/LinkPackage.cmake:21 (message):
LIBLZMA not found; compiling OpenTTD without LIBLZMA is strongly
disencouraged
That says that your compile didn't find the LZMA library. It looks to be the same with LZO and fcitix. Apparently your compile didn't pick up the brew install.

Re: How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 11 Dec 2020 22:30
by JGR
Fcitx is for CJK language input on Linux. You don't need this if you use a Mac and/or don't use an IME.
I wouldn't bother trying to install it.

Re: How to Run JGR Patch on MacOS 10.15.7 Catalina?

Posted: 12 Dec 2020 03:11
by cwithern173
That says that your compile didn't find the LZMA library. It looks to be the same with LZO and fcitix. Apparently your compile didn't pick up the brew install.
I think you misunderstood me here. When I did my first install of JGRPatch I got some warnings. So, when I installed it the second time around, I made sure to do brew install on these libraries so that I could avoid those warnings.
Fcitx is for CJK language input on Linux. You don't need this if you use a Mac and/or don't use an IME. I wouldn't bother trying to install it.
Huh. No wonder all the installation guides were in Chinese.