-
Notifications
You must be signed in to change notification settings - Fork 11.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
This patch tries to fix an issue with the windows debug builds where the PDB file for python scripted interfaces cannot be opened since its path length exceed the windows `MAX_PATH` limit: #101672 (comment) This patch addresses the issue by building all the interfaces as a single library plugin that initiliazes each component as part of its `Initialize` method, instead of building each interface as its own library plugin. This keeps the build artifact path length smaller while respecting the naming convention and without making any exception in the build system. Fixes #104895. Signed-off-by: Med Ismail Bennani <[email protected]>
- Loading branch information
1 parent
8056d92
commit 3565332
Showing
16 changed files
with
101 additions
and
98 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 0 additions & 16 deletions
16
...Plugins/ScriptInterpreter/Python/Interfaces/OperatingSystemPythonInterface/CMakeLists.txt
This file was deleted.
Oops, something went wrong.
41 changes: 41 additions & 0 deletions
41
.../source/Plugins/ScriptInterpreter/Python/Interfaces/ScriptInterpreterPythonInterfaces.cpp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
//===-- ScriptInterpreterPythonInterfaces.cpp -----------------------------===// | ||
// | ||
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. | ||
// See https://llvm.org/LICENSE.txt for license information. | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
|
||
#include "lldb/Core/PluginManager.h" | ||
#include "lldb/Host/Config.h" | ||
#include "lldb/lldb-enumerations.h" | ||
|
||
#if LLDB_ENABLE_PYTHON | ||
|
||
#include "ScriptInterpreterPythonInterfaces.h" | ||
|
||
using namespace lldb; | ||
using namespace lldb_private; | ||
|
||
LLDB_PLUGIN_DEFINE(ScriptInterpreterPythonInterfaces) | ||
|
||
llvm::StringRef | ||
ScriptInterpreterPythonInterfaces::GetPluginDescriptionStatic() { | ||
return "Script Interpreter Python Interfaces"; | ||
} | ||
|
||
void ScriptInterpreterPythonInterfaces::Initialize() { | ||
OperatingSystemPythonInterface::Initialize(); | ||
ScriptedPlatformPythonInterface::Initialize(); | ||
ScriptedProcessPythonInterface::Initialize(); | ||
ScriptedThreadPlanPythonInterface::Initialize(); | ||
} | ||
|
||
void ScriptInterpreterPythonInterfaces::Terminate() { | ||
OperatingSystemPythonInterface::Terminate(); | ||
ScriptedPlatformPythonInterface::Terminate(); | ||
ScriptedProcessPythonInterface::Terminate(); | ||
ScriptedThreadPlanPythonInterface::Terminate(); | ||
} | ||
|
||
#endif |
36 changes: 36 additions & 0 deletions
36
lldb/source/Plugins/ScriptInterpreter/Python/Interfaces/ScriptInterpreterPythonInterfaces.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
//===-- ScriptInterpreterPythonInterfaces.h ---------------------*- C++ -*-===// | ||
// | ||
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. | ||
// See https://llvm.org/LICENSE.txt for license information. | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
|
||
#ifndef LLDB_PLUGINS_SCRIPTINTERPRETER_PYTHON_SCRIPTINTERPRETERPYTHONINTERFACES_H | ||
#define LLDB_PLUGINS_SCRIPTINTERPRETER_PYTHON_SCRIPTINTERPRETERPYTHONINTERFACES_H | ||
|
||
#include "lldb/Core/PluginInterface.h" | ||
#include "lldb/Host/Config.h" | ||
#include "lldb/lldb-private.h" | ||
|
||
#if LLDB_ENABLE_PYTHON | ||
|
||
#include "OperatingSystemPythonInterface.h" | ||
#include "ScriptedPlatformPythonInterface.h" | ||
#include "ScriptedProcessPythonInterface.h" | ||
#include "ScriptedThreadPlanPythonInterface.h" | ||
|
||
namespace lldb_private { | ||
class ScriptInterpreterPythonInterfaces : public PluginInterface { | ||
public: | ||
static void Initialize(); | ||
static void Terminate(); | ||
static llvm::StringRef GetPluginNameStatic() { | ||
return "script-interpreter-python-interfaces"; | ||
} | ||
static llvm::StringRef GetPluginDescriptionStatic(); | ||
}; | ||
} // namespace lldb_private | ||
|
||
#endif // LLDB_ENABLE_PYTHON | ||
#endif // LLDB_PLUGINS_SCRIPTINTERPRETER_PYTHON_SCRIPTINTERPRETERPYTHONINTERFACES_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 0 additions & 16 deletions
16
...lugins/ScriptInterpreter/Python/Interfaces/ScriptedPlatformPythonInterface/CMakeLists.txt
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 0 additions & 16 deletions
16
...Plugins/ScriptInterpreter/Python/Interfaces/ScriptedProcessPythonInterface/CMakeLists.txt
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 0 additions & 16 deletions
16
...gins/ScriptInterpreter/Python/Interfaces/ScriptedThreadPlanPythonInterface/CMakeLists.txt
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters