Generic build scripts

You can get help here if Freeciv doesn't start on your computer, or if you keep getting fatal errors while playing etc.
cazfi
Elite
Posts: 1559
Joined: Tue Jan 29, 2013 6:54 pm

Re: Generic build scripts

Postby cazfi » Mon Oct 01, 2018 4:11 am

I ported script to Ubuntu-18.04 LTS (bionic): http://files.freeciv.org/tools/freeciv- ... tu18.04.sh
and Linux Mint19: http://files.freeciv.org/tools/freeciv- ... -mint19.sh

These scripts are identical short of the output they give when run with --version parameter.

They are based on Mint18 script, version 1.01. Versions of the new scripts are 1.00.

Compared to Mint18 script:
- Support for gtk3.22 gui added as ubuntu-18.04 and mint19 have sufficiently new gtk+-3

cazfi
Elite
Posts: 1559
Joined: Tue Jan 29, 2013 6:54 pm

Re: Generic build scripts

Postby cazfi » Tue Oct 02, 2018 9:19 am

cazfi wrote:I ported the script to Manjaro Linux: http://files.freeciv.org/tools/freeciv- ... manjaro.sh


New version (1.01) of the Manjaro script.
- Build freeciv with sound support enabled

User avatar
Corbeau
Elite
Posts: 840
Joined: Mon Jan 13, 2014 11:13 pm

Re: Generic build scripts

Postby Corbeau » Mon Nov 12, 2018 7:24 pm

Hello.

I got this:

Code: Select all

Traceback (most recent call last):
  File "/usr/lib/command-not-found", line 27, in <module>
    from CommandNotFound.util import crash_guard
ModuleNotFoundError: No module named 'CommandNotFound'

cazfi
Elite
Posts: 1559
Joined: Tue Jan 29, 2013 6:54 pm

Re: Generic build scripts

Postby cazfi » Tue Nov 13, 2018 3:26 am

Corbeau wrote:Hello.

I got this:

Code: Select all

Traceback (most recent call last):
  File "/usr/lib/command-not-found", line 27, in <module>
    from CommandNotFound.util import crash_guard
ModuleNotFoundError: No module named 'CommandNotFound'

Uh. Is that all the output the script gives?

From the name "command-not-found" I guess there's two problems; 1) some command is not found, and 2) handling of that error case fails in your shell.

We don't know what is the command that is not found since problem (2) causes its name not to be shown. So we need to resolve (2) first.

Does similar error occur when you give an arbitrary non-existing command in your shell?

https://forums.linuxmint.com/viewtopic.php?t=219943
https://unix.stackexchange.com/question ... se-command

Some other hits suggest uninstalling 'command-not-found' package as a workaround ('sudo apt-get remove command-not-found')

cazfi
Elite
Posts: 1559
Joined: Tue Jan 29, 2013 6:54 pm

Re: Generic build scripts

Postby cazfi » Tue Nov 13, 2018 4:25 pm

cazfi wrote:From the name "command-not-found" I guess there's two problems; 1) some command is not found, and 2) handling of that error case fails in your shell.

We don't know what is the command that is not found since problem (2) causes its name not to be shown. So we need to resolve (2) first.

Just occurred to me that it might be the script itself that is not found if you are not used to running scripts in unix/linux. Unlike in Windows, commands are not looked from the current directory by default, so trying to run "freeciv-mint19.sh" does not work. You need to explicitly give path, i.e.,current directory: "./freeciv-mint19.sh". And before that you have to give yourself permissions to run the script (it most likely isn't executable after you downloaded it): "chmod +x freeciv-mint19.sh"

User avatar
Corbeau
Elite
Posts: 840
Joined: Mon Jan 13, 2014 11:13 pm

Re: Generic build scripts

Postby Corbeau » Tue Nov 13, 2018 10:35 pm

I did make it executable immediately and yeah, the ./ thing occurred to me afterwards, but it didn't help.

And I just checked, permissions are -rwer-er-e, so it's definitely executable.

However, a weird thing - at least to me: TAB is usually used to finish the command or a file name I'm typing. But it isn't catching this one. Once I get enough letters, TAB inserts some other file. Any clues?

nutzer
Posts: 9
Joined: Sun Oct 15, 2017 10:01 am

Re: Generic build scripts

Postby nutzer » Sun Nov 18, 2018 10:40 am

Why not do the more obvious before the more difficult? I see build scripts as vulnerable entities for the many environmental implications they normally bear (and which can fail). I would suggest rather to update the "install" documentation with useful information about the required packages which need to be loaded for particular client versions. I'm lacking experience for cross-Unix identity of such libraries but it may be worth an investigation. For instance, "libgtk2.0-dev" is the name of a required library, is this name then identical on all platforms? This would make things easier, but the general path is to supply correct library names and the corresponding install calls in the documents.