Skip to content

Commit

Permalink
Update Vagrant image to Ubuntu focal.
Browse files Browse the repository at this point in the history
  • Loading branch information
andreasrosdal committed Aug 6, 2020
1 parent ea407de commit c94b4e1
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 4 deletions.
4 changes: 2 additions & 2 deletions Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
# please see the online documentation at vagrantup.com.

# Every Vagrant virtual environment requires a box to build off of.
config.vm.box = "ubuntu-bionic64"
config.vm.box = "ubuntu-focal64"

config.vm.provider "virtualbox"

config.vm.box_url = "https://cloud-images.ubuntu.com/bionic/current/bionic-server-cloudimg-amd64-vagrant.box"
config.vm.box_url = "https://cloud-images.ubuntu.com/focal/20200804/focal-server-cloudimg-amd64-vagrant.box"

if Vagrant::Util::Platform.windows?
config.vm.network :forwarded_port, guest: 80, host: 80, host_ip: "127.0.0.1"
Expand Down
3 changes: 2 additions & 1 deletion freeciv/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ apply_patches.sh - applies patches against the Freeciv C source code.

version.txt - contains the Git revision of Freeciv to check out from Git.

The Freeciv C server is installed to $HOME/freeciv.
The Freeciv C server is copied to the /tmp directory, and built there, then installed to $HOME/freeciv.
Building in /tmp is a workaround for a file permission issue on Vagrant/VirtialBox.
10 changes: 9 additions & 1 deletion freeciv/prepare_freeciv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,14 @@ if ! ./apply_patches.sh ; then
exit 1
fi

( cd freeciv
echo "Copying Freeciv to /tmp, and compiling Freeciv in /tmp"
# Copying Freeciv to /tmp, is a workaround for compiling Freeciv in a Vagrant box on VirtualBox, since in this environment
# autogen.sh can fail with this error: "./conftest: Permission denied", which seems to be related to executable file permissions in a VirtualBox file system.
cp freeciv /tmp -rf
cp freeciv-web.project /tmp

( cd /tmp/freeciv
./autogen.sh CFLAGS="-O3" --enable-mapimg=magickwand --with-project-definition=../freeciv-web.project --enable-fcweb --enable-json --disable-delta-protocol --disable-nls --disable-fcmp --enable-freeciv-manual --disable-ruledit --enable-fcdb=no --enable-ai-static=classic,threaded --prefix=${HOME}/freeciv/ && make -s -j$(nproc)
)

cp -rfu /tmp/freeciv . || echo "done"
2 changes: 2 additions & 0 deletions scripts/install/deb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ dependencies="\
autoconf \
automake \
autotools-dev \
build-essential \
curl \
git \
gnupg \
Expand All @@ -40,6 +41,7 @@ dependencies="\
pkg-config \
pngcrush \
procps \
python \
python3-minimal \
python3-pip \
python3-setuptools \
Expand Down
1 change: 1 addition & 0 deletions scripts/install/systems
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@ Ubuntu bionic deb.sh
Ubuntu xenial deb.sh
Ubuntu trusty deb.sh
Ubuntu artful deb.sh
Ubuntu focal deb.sh
Debian stretch deb.sh

0 comments on commit c94b4e1

Please sign in to comment.