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

Cmake error when building against XLC on z/OS 2.4 #6764

Open
Deigue opened this issue Oct 13, 2022 · 2 comments
Open

Cmake error when building against XLC on z/OS 2.4 #6764

Deigue opened this issue Oct 13, 2022 · 2 comments

Comments

@Deigue
Copy link
Contributor

Deigue commented Oct 13, 2022

Seeing an error building with cmake when attempting to build omr on a z/OS 2.4 system. An error is seen while going through metalc files as shown below. This same build is working completely fine when attempted on a z/OS 2.3 system.
Both cases using the XLC compiler.

Following steps:

Make build directory and enter it.
cmake ..
cmake --build .

Strack trace:

[ 35%] Building C object port/CMakeFiles/omrport_obj.dir/unix/omrshmem.c.o
[ 35%] Built target omrport_obj
[ 35%] Generating zos390/omrlpdat.o
Error: Unknown option -mgoff
gmake[2]: *** [port/zos390/omrlpdat.o] Error 16
gmake[1]: *** [port/CMakeFiles/omrport_metalc.dir/all] Error 2
gmake: *** [all] Error 2

Additionally, only having the following changes in this commit added seem to fix this error when using the XLC compiler on z/OS 2.4
29bfa5a (Commit from my fork of omr)
(i.e: Using agoff instead of mgoff)

Attempting the build on z/OS 2.4 computer with the zos-master branch, cmake command runs successfully and builds 100%.

Trying to do a quick search on related issues, this came up: #5449
But I am unsure if it is actually related to the abovementioned problem.

@babsingh
Copy link
Contributor

Can you try the cmds from https://ci.eclipse.org/omr/job/PullRequest-zos_390-64/3893/console?

cmake -Wdev -C../cmake/caches/Travis.cmake -DCMAKE_C_COMPILER=/bin/c89 -DCMAKE_CXX_COMPILER=/bin/xlc -DOMR_DDR=OFF -DOMR_THR_FORK_SUPPORT=0 ..
make -j4 

@Deigue
Copy link
Contributor Author

Deigue commented Oct 31, 2022

> make -j4
Scanning dependencies of target trace
Scanning dependencies of target header_check
[  0%] Generating zos390/omrlpdat.o
Scanning dependencies of target pugixml
[  0%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/ArgParser.cpp.o
[  0%] Built target header_check
Scanning dependencies of target omrtestutil
[  0%] Building CXX object third_party/pugixml-1.5/CMakeFiles/pugixml.dir/pugixml.cpp.o
[  0%] Building CXX object fvtest/util/CMakeFiles/omrtestutil.dir/printerrorhelper.cpp.o
Error: Unknown option -mgoff
port/CMakeFiles/omrport_metalc.dir/build.make:61: recipe for target 'port/zos390/omrlpdat.o' failed
make[2]: *** [port/zos390/omrlpdat.o] Error 16
CMakeFiles/Makefile2:654: recipe for target 'port/CMakeFiles/omrport_metalc.dir/all' failed
make[1]: *** [port/CMakeFiles/omrport_metalc.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[  0%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/CFileWriter.cpp.o
[  0%] Building CXX object fvtest/util/CMakeFiles/omrtestutil.dir/testvmhelper.cpp.o
[  0%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/DATFileWriter.cpp.o
[  0%] Linking CXX static library ../../libpugixml.a
../../libpugixml.a
[  0%] Built target pugixml
[  0%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/FileReader.cpp.o
[  0%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/FileUtils.cpp.o
[  0%] Linking CXX static library ../../libomrtestutil.a
../../libomrtestutil.a
[  0%] Built target omrtestutil
[  0%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/Port.cpp.o
[  1%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/StringUtils.cpp.o
[  1%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/TDFParser.cpp.o
[  1%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/TraceGen.cpp.o
[  1%] Building CXX object tools/tracegen/CMakeFiles/trace.dir/TraceHeaderWriter.cpp.o
[  1%] Linking CXX static library ../../libtrace.a
../../libtrace.a
[  1%] Built target trace
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2

Still seemed to be failing with the commands from above ran ... although at a different spot now.

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

No branches or pull requests

2 participants