gdc-8 lang fails on link

Asked by Aleksandr

gdc-8 lang fails on link after installing g++. gdc-7 & gdc-9 work as expected.

    No LSB modules are available.
    Distributor ID: Ubuntu
    Description: Ubuntu 18.04.4 LTS
    Release: 18.04
    Codename: bionic

Steps to reproduce:

# Install g++
add-apt-repository ppa:ubuntu-toolchain-r/test -y
apt-get update -y

apt-get -y install "g++-7"
apt-get -y install "g++-8"
apt-get -y install "g++-9"

# Install gdc-8
apt-get -y install gdc-8

# Simple program

cat >simple.d <<EOF
 import std.stdio : stdin, writeln;

 void simple(int n, int otherNumber)

 void main()
  int n;
  stdin.readf("%d\n", &n);
  int otherNumber;
  stdin.readf("%d\n", &otherNumber);

  simple(n, otherNumber);

gdc-8 simple.d

/tmp/ccQm5EYZ.o: In function `_Dmain':
simple.d:(.text+0x66): undefined reference to `_D3std5stdio23__T10makeGlobalS5stdinZ10makeGlobalFNbNcNdNiZS3std5stdio4File'
simple.d:(.text+0xa0): undefined reference to `_D3std5stdio23__T10makeGlobalS5stdinZ10makeGlobalFNbNcNdNiZS3std5stdio4File'

Question information

English Edit question
Ubuntu gcc-8 Edit question
No assignee Edit question
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :

If you are using a PPA you may want to contact the PPA maintainer if there are issues with the packages from that source causing issues

Revision history for this message
Manfred Hampl (m-hampl) said :

This seems to be the problem that is discussed in

Can you help with this problem?

Provide an answer of your own, or ask Aleksandr for more information if necessary.

To post a message you must log in.