Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
CMake
CMake
Commits
01d143c7
Commit
01d143c7
authored
Jul 29, 2008
by
Brad King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ENH: Provide context in path ordering warnings
parent
478fbdfc
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
12 deletions
+16
-12
Source/cmComputeLinkInformation.cxx
Source/cmComputeLinkInformation.cxx
+3
-3
Source/cmOrderDirectories.cxx
Source/cmOrderDirectories.cxx
+10
-7
Source/cmOrderDirectories.h
Source/cmOrderDirectories.h
+3
-2
No files found.
Source/cmComputeLinkInformation.cxx
View file @
01d143c7
...
...
@@ -256,10 +256,10 @@ cmComputeLinkInformation
// Allocate internals.
this
->
OrderLinkerSearchPath
=
new
cmOrderDirectories
(
this
->
GlobalGenerator
,
target
->
GetName
()
,
new
cmOrderDirectories
(
this
->
GlobalGenerator
,
target
,
"linker search path"
);
this
->
OrderRuntimeSearchPath
=
new
cmOrderDirectories
(
this
->
GlobalGenerator
,
target
->
GetName
()
,
new
cmOrderDirectories
(
this
->
GlobalGenerator
,
target
,
"runtime search path"
);
this
->
OrderDependentRPath
=
0
;
...
...
@@ -362,7 +362,7 @@ cmComputeLinkInformation
{
this
->
SharedDependencyMode
=
SharedDepModeDir
;
this
->
OrderDependentRPath
=
new
cmOrderDirectories
(
this
->
GlobalGenerator
,
target
->
GetName
()
,
new
cmOrderDirectories
(
this
->
GlobalGenerator
,
target
,
"dependent library path"
);
}
...
...
Source/cmOrderDirectories.cxx
View file @
01d143c7
...
...
@@ -18,6 +18,7 @@
#include "cmGlobalGenerator.h"
#include "cmSystemTools.h"
#include "cmake.h"
#include <assert.h>
...
...
@@ -239,11 +240,11 @@ bool cmOrderDirectoriesConstraintLibrary::FindConflict(std::string const& dir)
//----------------------------------------------------------------------------
cmOrderDirectories
::
cmOrderDirectories
(
cmGlobalGenerator
*
gg
,
c
onst
char
*
name
,
c
mTarget
*
target
,
const
char
*
purpose
)
{
this
->
GlobalGenerator
=
gg
;
this
->
Name
=
name
;
this
->
Target
=
target
;
this
->
Purpose
=
purpose
;
this
->
Computed
=
false
;
}
...
...
@@ -510,22 +511,24 @@ void cmOrderDirectories::DiagnoseCycle()
// Construct the message.
cmOStringStream
e
;
e
<<
"
WARNING:
Cannot generate a safe "
<<
this
->
Purpose
<<
" for target "
<<
this
->
Name
e
<<
"Cannot generate a safe "
<<
this
->
Purpose
<<
" for target "
<<
this
->
Target
->
Get
Name
()
<<
" because there is a cycle in the constraint graph:
\n
"
;
// Display the conflict graph.
for
(
unsigned
int
i
=
0
;
i
<
this
->
ConflictGraph
.
size
();
++
i
)
{
ConflictList
const
&
clist
=
this
->
ConflictGraph
[
i
];
e
<<
"dir "
<<
i
<<
" is ["
<<
this
->
OriginalDirectories
[
i
]
<<
"]
\n
"
;
e
<<
"
dir "
<<
i
<<
" is ["
<<
this
->
OriginalDirectories
[
i
]
<<
"]
\n
"
;
for
(
ConflictList
::
const_iterator
j
=
clist
.
begin
();
j
!=
clist
.
end
();
++
j
)
{
e
<<
" dir "
<<
j
->
first
<<
" must precede it due to "
;
e
<<
"
dir "
<<
j
->
first
<<
" must precede it due to "
;
this
->
ConstraintEntries
[
j
->
second
]
->
Report
(
e
);
e
<<
"
\n
"
;
}
}
cmSystemTools
::
Message
(
e
.
str
().
c_str
());
e
<<
"Some of these libraries may not be found correctly."
;
this
->
GlobalGenerator
->
GetCMakeInstance
()
->
IssueMessage
(
cmake
::
WARNING
,
e
.
str
(),
this
->
Target
->
GetBacktrace
());
}
Source/cmOrderDirectories.h
View file @
01d143c7
...
...
@@ -24,6 +24,7 @@
class
cmGlobalGenerator
;
class
cmOrderDirectoriesConstraint
;
class
cmOrderDirectoriesConstraintLibrary
;
class
cmTarget
;
/** \class cmOrderDirectories
* \brief Compute a safe runtime path order for a set of shared libraries.
...
...
@@ -31,7 +32,7 @@ class cmOrderDirectoriesConstraintLibrary;
class
cmOrderDirectories
{
public:
cmOrderDirectories
(
cmGlobalGenerator
*
gg
,
c
onst
char
*
name
,
cmOrderDirectories
(
cmGlobalGenerator
*
gg
,
c
mTarget
*
target
,
const
char
*
purpose
);
~
cmOrderDirectories
();
void
AddRuntimeLibrary
(
std
::
string
const
&
fullPath
,
const
char
*
soname
=
0
);
...
...
@@ -44,7 +45,7 @@ public:
std
::
vector
<
std
::
string
>
const
&
GetOrderedDirectories
();
private:
cmGlobalGenerator
*
GlobalGenerator
;
std
::
string
Name
;
cmTarget
*
Target
;
std
::
string
Purpose
;
bool
Computed
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment