================
@@ -58,3 +59,45 @@ def test_platform_process_launch_gdb_server(self):
self.runCmd("target create {}".format(self.getBuildArtifact("a.out")))
self.expect("run", substrs=["unable to launch a GDB server on"],
error=True)
+
+ @skipIfRemote
+ @skipUnlessPlatform(["linux"])
+ @add_test_categories(["lldb-server"])
+ def test_lldb_server_weird_symlinks(self):
+ self.build()
+
+ hostname = socket.getaddrinfo("localhost", 0,
proto=socket.IPPROTO_TCP)[0][4][0]
+ listen_url = "[%s]:0" % hostname
+
+ port_file = self.getBuildArtifact("port")
+ commandline_args = [
+ "platform",
+ "--listen",
+ listen_url,
+ "--socket-file",
+ port_file,
+ ]
+
+ # Run lldb-server from a symlink without any binary called
"lldb-server" in the directory.
+ llgs_hiding_directory = self.getBuildArtifact("hiding-directory")
+ new_lldb_server_link = self.getBuildArtifact(
+ "lldb-server-with-an-unconventional-name"
+ )
+ new_lldb_server = os.path.join(llgs_hiding_directory, "lldb-server")
+ os.makedirs(llgs_hiding_directory)
+ shutil.copy(lldbgdbserverutils.get_lldb_server_exe(), new_lldb_server)
----------------
labath wrote:
Do you need to make the copy if you're not going to delete it?
https://github.com/llvm/llvm-project/pull/131609
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits