Why do I get this error while running the compiler? - operating-system

I was able to install i386-elf-g ++ but there is an error running the command:
i386-elf-g ++: fatal error: cannot execute 'cc1plus': execvp: No such file or directory
But I looked at the gcc and g ++ versions:
g++ (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
I have no idea what might be wrong.

Related

GPG: Generating key fails with cannot get input error

I was trying to generate new GPG key on my Ubuntu 16.10 for GitHub. However, it ended with an error message gpg: Sorry, no terminal at all requested - can't get input. I tried gpg2 as well with no difference.
Including terminal output:
greeny#greenyNB:~$ gpg2 --gen-key
gpg (GnuPG) 2.1.11; Copyright (C) 2016 Free Software Foundation, Inc.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
gpg: Sorry, no terminal at all requested - can't get input
greeny#greenyNB:~$ gpg --gen-key
gpg (GnuPG) 1.4.20; Copyright (C) 2015 Free Software Foundation, Inc.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
gpg: Sorry, no terminal at all requested - can't get input
How can I fix this to be able to generate GPG key?
Thanks to Jens Erat for his comment, solution: remove no-tty line from gpg.conf.

Use Makefile + Eclipse + Mac + g++ + mpic++

I have installed gcc 5.3.0(g++) and compiled mpich(mpic++) using that.
I already have my own Makefile, when i make from command line everything perfectly.
I also imported the project to eclipse PTP (Mars) and set the build option to make and set build folder to my source folder. Added my mpic++ and g++ paths to eclipse path environment variable.
When i build from eclipse, it finds and executes my make command, it even finds out my mpic++ but internally its using clang but not gcc
When i check mpic++ version on command line, i get
MacBook-Pro:mpi$ mpic++ --version
g++ (GCC) 5.3.0
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
And i added the same command to my make file so that i can check whats happening on eclipse, I get this
( mpic++ --version; )
Apple LLVM version 7.0.2 (clang-700.1.81)
Target: x86_64-apple-darwin15.0.0
Thread model: posix
So i am not sure what i missed here. How do i change my eclipse to use gcc instead of clang?
Thanks in advance.

ec2 server postgres error "version `GLIBC_2.14' not found"

While trying to \i create_db.sql psql throws the error:
psql:create_db.sql:123: ERROR: could not load library
"/usr/lib64/pgsql/plpgsql.so": /lib64/libc.so.6: version
`GLIBC_2.14' not found (required by /usr/lib64/pgsql/plpgsql.so)
Line 123 of create_db.sql is the last line of the file, at the end of a a function definition:
$$ language plpgsql;
Versions of stuff:
$ psql --version
psql (PostgreSQL) 9.2.7
$ /lib64/libc.so.6 --version
GNU C Library (GNU libc) stable release version 2.17, by Roland McGrath et al.
Copyright (C) 2012 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 4.8.2 20131212 (Red Hat 4.8.2-7).
Compiled on a Linux 3.2.5 system on 2014-06-09.
Available extensions:
The C stubs add-on version 2.1.2.
crypt add-on version 2.1 by Michael Glad and others
GNU Libidn by Simon Josefsson
Native POSIX Threads Library by Ulrich Drepper et al
BIND-8.2.3-T5B
RT using linux kernel aio
libc ABIs: UNIQUE IFUNC
For bug reporting instructions, please see:
<http://www.gnu.org/software/libc/bugs.html>.
Do I need to have glibc exactly version 2.14 or should 2.17 work too?
Your PostgreSQL install, or your OS install in general, is at least somewhat broken.
At a guess, you must've force-installed some RPM you found somewhere random instead of configuring repositories and using yum install to install PostgreSQL.
You don't need an exactly matching glibc version. It just has to declare that it's compatible with the required version by exposing a suitable GLIBC_ symbol .
e.g. on my Fedora 20, with glibc 2.18, I'd have no problems running programs compiled for glibc 2.14 because:
$ /lib64/libc.so.6 --version
GNU C Library (GNU libc) stable release version 2.18, by Roland McGrath et al.
$ nm /lib64/libc.so.6| grep GLIBC_2.14
0000000000000000 A GLIBC_2.14
my glibc declares that it's compatible with 2.14.

How to setup Mingw32 with dwimperl

I installed dwimperl in windows and I want to use it with mingw32 command line.
In mingw32 there is perl version 5.8.x but i want to use perl 5.14 from mingw32. Any ideas how can i solve this problem?
Dwimperl has already included the mingw
C:\Users\jm> gcc --version
gcc (GCC) 4.4.7 20111023 (prerelease) [svn/rev.180339 - mingw-w64/oz]
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C:\Users\jm> where gcc
C:\Dwimperl\c\bin\gcc.exe

pdftotext on Centos 6 64bit?

I have a HostGator VPS server, and want to be able to run pdftotext, part of xpdf (http://www.foolabs.com/xpdf/download.html).
After testing this out on my Mac, it worked fine, so I went to installing it on my VPS server.
I followed the installation instructions and it all isntalled flawlessly:
Copy the executables (xpdf, pdftotext, etc.) to to /usr/local/bin.
Copy the man pages (*.1 and *.5) to /usr/local/man/man1 and /usr/local/man/man5.
Copy the sample-xpdfrc file to /usr/local/etc/xpdfrc
Then I tested it out:
root#*** [~]# pdftotext
pdftotext: /lib64/libc.so.6: version `GLIBC_2.11' not found (required by pdftotext)
So as you can see, it couldn't find /lib64/libc.so.6. /lib64/libc.so.6 is there, however, as shown by this:
root#*** [~]# /lib64/libc.so.6
GNU C Library stable release version 2.5, by Roland McGrath et al.
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 4.1.2 20080704 (Red Hat 4.1.2-52).
Compiled on a Linux 2.6.9 system on 2012-03-19.
Available extensions:
The C stubs add-on version 2.1.2.
crypt add-on version 2.1 by Michael Glad and others
GNU Libidn by Simon Josefsson
GNU libio by Per Bothner
NIS(YP)/NIS+ NSS modules 0.19 by Thorsten Kukuk
Native POSIX Threads Library by Ulrich Drepper et al
BIND-8.2.3-T5B
RT using linux kernel aio
Thread-local storage support included.
For bug reporting instructions, please see:
<http://www.gnu.org/software/libc/bugs.html>.
I then contacted HostGator, where they told me that it will not work on my server, as it can't find /lib64/libc.so.6, and is therefor not available on Centos 6 64bit.
If this is indeed true, are there any alternatives to pdftotext that do a simple and fast conversion that would work on this server? Is it possible that the pdftotext can be complied for a different version, or that I installed it incorrectly with permissions?
Neither of these commands will work:
yum install xpdf
yum install poppler-utils
xpdf will install poppler-utils anyway and this will result in this pdftotext
pdftotext version 0.26.5
Copyright 2005-2014 The Poppler Developers - http://poppler.freedesktop.org
Copyright 1996-2011 Glyph & Cog, LLC
This is not the version you want. You want this one:
pdftotext version 4.03 [www.xpdfreader.com]
Copyright 1996-2021 Glyph & Cog, LLC
This will require going to www.xpdfreader.com and then clicking on "Download". Use the latest versions from this page to set up the newer pdftotext command.
I actually compiled the sources myself:
cd /tmp
wget https://dl.xpdfreader.com/xpdf-4.03.tar.gz
tar -xf xpdf-4.03.tar.gz
cd xpdf-4.03
mkdir build
cmake -DCMAKE_BUILD_TYPE=Release
If successful you should see:
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/xpdf-4.03
Then just type:
make
It should end with:
[100%] Built target pdftotext
Then type
make install
Now when you type pdftotext you should see:
pdftotext version 4.03 [www.xpdfreader.com]
Copyright 1996-2021 Glyph & Cog, LLC
Note: I wrote all my code for pdftotext version 4.03. Took me a while to realise 4.03 and 0.26 produce vastly different results.