Hello Ben,
Those directions work for most Linux platforms. However, the default compiler on Alma Linux 8 is too old to be able to compile HTCondor. On Alma Linux 8 we build with gcc-12. So, you need to set that up sometime before you run cmake. Here are the commands:
. /opt/rh/gcc-toolset-12/enable
export CC=$(which cc)
export CXX=$(which c++)
That should get you going again.
...Tim
Dear all,
I am trying to build condor tag v23.3.0 on a RHEL8 machine using the approach described here [1].
I am running in interactive mode:
docker run --rm=true --user condor -t -i htcondor/nmi-build:x86_64_AlmaLinux8-23030008 /bin/bash
cd /tmp
git clone -b devel_v23.3.0 https://github.com/benoitroland/C4P-HTCondor.git
cd C4P-HTCondor
mkdir __build
cd __build
cmake ..
make -j 8 install
where the branch devel_v23.3.0 of C4P-HTCondor is build from the condor tag v23.3.0 (git checkout tags/v23.3.0 -b devel_v23.3.0).
A 20% of the build process, I got the error [2] associated with command_strings.cpp.
Maybe I am doing some basic error...
Did some of you have some time to reproduce this on the RHEL8 machine?
Otherwise, I would like to ask you; which tag or branch should I use to have a successful build?
[preferentially a tag or branch as close as possible to the latest development, but not the main, because the container-based build is failing there as well]
Thanks a lot in advance for your help!
Cheers,
ben
[1] https://github.com/htcondor/htcondor/blob/main/INSTALL.md
[2] [ 20%] Building CXX object src/condor_utils/CMakeFiles/condor_utils_objects.dir/condor_adtypes.cpp.o
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp: In function 'const char* getCollectorCommandString(int)':
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:53:77: error: 'constexpr auto sortByFirst(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 63]' called in a constant _expression_
constexpr static const auto table = sortByFirst(makeCollectorCommandTable());
^
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:30:7: note: 'constexpr auto sortByFirst(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 63]' is not usable as a 'constexpr' function because:
auto sortByFirst(const std::array<std::pair<int, const char *>, N> &table) {
^~~~~~~~~~~
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:32:11: error: call to non-'constexpr' function 'void std::sort(_RAIter, _RAIter, _Compare) [with _RAIter = std::pair<int, const char*>*; _Compare = sortByFirst(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 63]::<lambda(const std::pair<int, const char*>&, const std::pair<int, const char*>&)>]'
std::sort(sorted.begin(), sorted.end(),
~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[](const std::pair<int, const char *> &lhs,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
const std::pair<int, const char *> &rhs) {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
return lhs.first < rhs.first;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
});
~~
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp: In function 'const char* getCommandString(int)':
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:67:68: error: 'constexpr auto sortByFirst(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 198]' called in a constant _expression_
constexpr static const auto table = sortByFirst(makeCommandTable());
^
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:30:7: note: 'constexpr auto sortByFirst(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 198]' is not usable as a 'constexpr' function because:
auto sortByFirst(const std::array<std::pair<int, const char *>, N> &table) {
^~~~~~~~~~~
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:32:11: error: call to non-'constexpr' function 'void std::sort(_RAIter, _RAIter, _Compare) [with _RAIter = std::pair<int, const char*>*; _Compare = sortByFirst(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 198]::<lambda(const std::pair<int, const char*>&, const std::pair<int, const char*>&)>]'
std::sort(sorted.begin(), sorted.end(),
~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[](const std::pair<int, const char *> &lhs,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
const std::pair<int, const char *> &rhs) {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
return lhs.first < rhs.first;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
});
~~
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp: In function 'int getCommandNum(const char*)':
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:81:69: error: 'constexpr auto sortBySecond(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 198]' called in a constant _expression_
constexpr static const auto table = sortBySecond(makeCommandTable());
^
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:41:6: note: 'constexpr auto sortBySecond(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 198]' is not usable as a 'constexpr' function because:
auto sortBySecond(const std::array<std::pair<int, const char *>, N> &table) {
^~~~~~~~~~~~
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:43:11: error: call to non-'constexpr' function 'void std::sort(_RAIter, _RAIter, _Compare) [with _RAIter = std::pair<int, const char*>*; _Compare = sortBySecond(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 198]::<lambda(const std::pair<int, const char*>&, const std::pair<int, const char*>&)>]'
std::sort(sorted.begin(), sorted.end(),
~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[](const std::pair<int, const char *> &lhs,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
const std::pair<int, const char *> &rhs) {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
return istring_view(lhs.second) < istring_view(rhs.second);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
});
~~
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp: In function 'int getCollectorCommandNum(const char*)':
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:92:78: error: 'constexpr auto sortBySecond(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 63]' called in a constant _expression_
constexpr static const auto table = sortBySecond(makeCollectorCommandTable());
^
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:41:6: note: 'constexpr auto sortBySecond(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 63]' is not usable as a 'constexpr' function because:
auto sortBySecond(const std::array<std::pair<int, const char *>, N> &table) {
^~~~~~~~~~~~
/tmp/C4P-HTCondor/src/condor_utils/command_strings.cpp:43:11: error: call to non-'constexpr' function 'void std::sort(_RAIter, _RAIter, _Compare) [with _RAIter = std::pair<int, const char*>*; _Compare = sortBySecond(const std::array<std::pair<int, const char*>, N>&) [with long unsigned int N = 63]::<lambda(const std::pair<int, const char*>&, const std::pair<int, const char*>&)>]'
std::sort(sorted.begin(), sorted.end(),
~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[](const std::pair<int, const char *> &lhs,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
const std::pair<int, const char *> &rhs) {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
return istring_view(lhs.second) < istring_view(rhs.second);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
});
~~
[ 20%] Building CXX object src/condor_utils/CMakeFiles/condor_utils_objects.dir/condor_attributes.cpp.o
make[2]: *** [src/condor_utils/CMakeFiles/condor_utils_objects.dir/build.make:417: src/condor_utils/CMakeFiles/condor_utils_objects.dir/command_strings.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [CMakeFiles/Makefile2:19165: src/condor_utils/CMakeFiles/condor_utils_objects.dir/all] Error 2
make: *** [Makefile:166: all] Error 2
_______________________________________________ HTCondor-users mailing list To unsubscribe, send a message to htcondor-users-request@xxxxxxxxxxx with a subject: Unsubscribe You can also unsubscribe by visiting https://lists.cs.wisc.edu/mailman/listinfo/htcondor-users The archives can be found at: https://lists.cs.wisc.edu/archive/htcondor-users/
-- Tim Theisen (he, him, his) Release Manager HTCondor & Open Science Grid Center for High Throughput Computing Department of Computer Sciences University of Wisconsin - Madison 4261 Computer Sciences and Statistics 1210 W Dayton St Madison, WI 53706-1685 +1 608 265 5736