OR-Tools
8.0
base/logging.cc
Go to the documentation of this file.
1
// Copyright 2010-2018 Google LLC
2
// Licensed under the Apache License, Version 2.0 (the "License");
3
// you may not use this file except in compliance with the License.
4
// You may obtain a copy of the License at
5
//
6
// http://www.apache.org/licenses/LICENSE-2.0
7
//
8
// Unless required by applicable law or agreed to in writing, software
9
// distributed under the License is distributed on an "AS IS" BASIS,
10
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
// See the License for the specific language governing permissions and
12
// limitations under the License.
13
14
#include "
ortools/base/logging.h
"
15
16
#include <mutex>
// NOLINT
17
18
#include "
ortools/base/commandlineflags.h
"
19
20
DECLARE_bool
(log_prefix);
21
DECLARE_bool
(logtostderr);
22
23
namespace
{
24
std::once_flag init_done;
25
}
// namespace
26
27
void
FixFlagsAndEnvironmentForSwig
() {
28
std::call_once(init_done, [] { google::InitGoogleLogging(
"swig_helper"
); });
29
absl::SetFlag
(&FLAGS_logtostderr,
true
);
30
FLAGS_log_prefix =
false
;
31
}
logging.h
DECLARE_bool
DECLARE_bool(log_prefix)
FixFlagsAndEnvironmentForSwig
void FixFlagsAndEnvironmentForSwig()
Definition:
base/logging.cc:27
absl::SetFlag
void SetFlag(T *flag, const T &value)
Definition:
commandlineflags.h:22
commandlineflags.h
ortools
base
logging.cc
Generated by
1.8.18