Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

openj9 builds at adoptopenjdk not honouring CC/CXX environment variables #1919

Closed
sxa opened this issue May 16, 2018 · 16 comments
Closed

openj9 builds at adoptopenjdk not honouring CC/CXX environment variables #1919

sxa opened this issue May 16, 2018 · 16 comments

Comments

@sxa
Copy link
Contributor

sxa commented May 16, 2018

We discovered an issue building openjdk8+openj9 at adoptopenjdk today.

We're building on CentOS6.9 which has gcc 4.4.7 as the default compiler. The code is using some C++11 specific constructs and therefore requires gcc 4.8. If I set the CC/CXX variables it said it can't find the things that those variables point to. However if I set the path to have the directory containing the gcc 4.8 executables it works ok. I don't really want to leave the PATH in such a state and would much prefer to be able to use the CC/CXX variables. Can we lookg at getting this resolved please?

Log fragments all available in adoptium/temurin-build#327

@DanHeidinga
Copy link
Member

@keithc-ca Can you take a look at this?

@DanHeidinga
Copy link
Member

Marking this as high priority as we want the May release to compiled on centos so the glibc levels are old enough to run on all the supported OS/platforms combos required by the Eclipse IDE release.

@keithc-ca keithc-ca self-assigned this May 16, 2018
@pshipton pshipton added this to the Release 0.9.0 milestone May 16, 2018
@keithc-ca
Copy link
Contributor

I started experimenting with a docker container that doesn't have cc, c++, gcc or g++ some time ago. It appears that the final piece (at least for Linux x64) is captured in https://github.com/keithc-ca/openj9-openjdk-jdk8/tree/gcc (and similar changes for newer JDK versions). I have builds underway.

@sxa
Copy link
Contributor Author

sxa commented May 17, 2018

This may be related - I've got an issue on on the v8 build on Linux/s390x which is similarly failing to find a "working" C compliler, although in this case it's explcitly using ccache with extra environment variables being set for it from https://github.com/ibmruntimes/openj9-openjdk-jdk8/search?utf8=%E2%9C%93&q=CCACHE_SLOPPINESS%3Dtime_macros&type=

checking for gcc... CCACHE_COMPRESS=1  CCACHE_SLOPPINESS=time_macros /usr/local/bin/ccache /usr/bin/gcc-4.8
checking whether the C compiler works... no
configure: error: in `/home/jenkins/workspace/openjdk8_openj9_build_s390x_linux/openjdk/build/linux-s390x-normal-server-release/vm/omr':
configure: error: C compiler cannot create executables
See `config.log' for more details
run_configure.mk:167: recipe for target 'CONFIGURE_SENTINEL_FILE' failed
gmake[3]: *** [CONFIGURE_SENTINEL_FILE] Error 77
buildtools.mk:158: recipe for target 'configure' failed
gmake[2]: *** [configure] Error 2
gmake[2]: *** Waiting for unfinished jobs....

@keithc-ca
Copy link
Contributor

That strikes me as a separate issue, that at first reading seems OMR is having trouble with the multi-word compiler name.

@irinarada
Copy link

@keithc-ca - any news on this one - we'd like to finish off all the items for 0.9.0

@keithc-ca
Copy link
Contributor

I thought I had a solution for this - it was even merged, but unfortunately, it caused trouble for the AIX platform. I am working on fix it.

@irinarada
Copy link

So it works everywhere except for AIX?

@keithc-ca
Copy link
Contributor

Yes, it worked for all supported OpenJ9 platforms except for AIX. There are some details to be worked out involving linking of shared libraries.

@pshipton
Copy link
Member

@sxa555 since you have a workaround, is this required for the OpenJ9 0.9.0 release? If so it may delay the release by a few days.

@DanHeidinga
Copy link
Member

@keithc-ca I know from discussions with you that a lot of progress has been happening on this. Can you provide an update here so everyone is aware?

@keithc-ca
Copy link
Contributor

The work is mostly about making *.spec files consistent in their use of C and C++ compilers and to make use of $(CC) and $(CXX) where it makes sense. See #2106 to follow along. Once those changes are merged, it will be possible to drive everything from the configuration step of openjdk; https://github.com/keithc-ca/openj9-openjdk-jdk8/tree/tools captures my plan for the extension repos.

@irinarada
Copy link

Are we close to finishing this?

@pshipton
Copy link
Member

The fix in #2106 is under review. There are some PR testing failures due to out of space issues atm.

@pshipton
Copy link
Member

Accidentally closed, not all changes are merged yet.

@pshipton
Copy link
Member

Now everything is merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants