3

I'm a newbie in Arch Linux. I've tried to compile IRAF package from github and I've got multiple definition error.

/usr/bin/ld: xppcode.o:/home/nastya/iraf/unix/boot/spp/xpp/xppcode.c:109: multiple definition of `errflag'; xppmain.o:/home/nastya/iraf/unix/boot/spp/xpp/xppmain.c:21: first defined here
collect2: error: ld returned 1 exit status
make: *** [Makefile:19: sysgen] Error 1

My operating system is Manjaro Linux. I use gcc (GCC) 10.1.0.

I've also tried to compile this package on other LINUX distros (on Ubuntu, Debian) and everything was fine.

The problem appears only on Arch. I also tried to use different versions of GCC (5.5 and 7.5.0) and it doesn't solve the problem.

I've also faced this problem earlier during attempt to install another package (GALFIT) on Arch and in that case it perfectly installed on other LINUX distros except Arch.

I appreciate any help and advice.

robni
  • 904
  • 2
  • 6
  • 20
  • 2
    Add `-fcommon` to your `CFLAGS`, and report the bug back to the developers. – n. m. could be an AI Jun 06 '20 at 21:44
  • Is it possible that it's not gcc but another binary, say ld that is a different version than what you had on the platforms where the built was successful? I have had similar problems in the past, when one distribution shipped with different binaries for various purposes. Since the OSes are different, a great many things can cause the errors. Have you tried installing the package from the AUR? – qmeeus Jun 06 '20 at 21:46
  • @qmeeus, Yes, I've tried to install this package from AUR first. But I wasn't able to do it and I've got `curl: (22) The requested URL returned error: 404 Not Found ==> ERROR: Failure while downloading http://iraf.noao.edu/iraf/ftp/iraf/v216/PCIX/as.pcix.gen.gz Aborting... Error downloading sources: iraf ` And then I decided to install it from github. – Alderamin Cepheus Jun 06 '20 at 22:03
  • Then your best bet is to report it to the devs on github as suggested in the first comment :) – qmeeus Jun 06 '20 at 22:12
  • @qmeeus But this problem appears not only with this particular package, so I guess, something is wrong with my gcc or manjaro ( I've already reported to the devs, but I doubt they will answer) – Alderamin Cepheus Jun 06 '20 at 23:02
  • 1
    `-fcommon` used to be the default gcc flag. Since gcc-10 it is not anymore. It is a decision deliberately made by gcc developers. Whether it is a right or wrong decision is up to you to judge. – n. m. could be an AI Jun 17 '20 at 12:09

0 Answers0