https://bugs.llvm.org/show_bug.cgi?id=44179

            Bug ID: 44179
           Summary: llvm-config --system-libs prints entire libxml2 path
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Keywords: regression
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedb...@nondot.org
          Reporter: v...@freedesktop.org
                CC: compn...@compnerd.org, htmldevelo...@gmail.com,
                    llvm-bugs@lists.llvm.org

llvm-config --system-libs now prints the entire libxml2 path.

Before
$ llvm-config --system-libs
-lz -lrt -ldl -ltinfo -lpthread -lm -lxml2

Now
$ llvm-config --system-libs
-lz -lrt -ldl -ltinfo -lpthread -lm -l/usr/lib/x86_64-linux-gnu/libxml2.so

This leads to linking errors if depending on llvm-config --system-libs during
compilation.
/usr/bin/ld: cannot find -l/usr/lib/x86_64-linux-gnu/libxml2


This new behavior is introduced with these llvm-10 commits.

commit cfcfd8a056eb7c01bc76b745ce9f7839f0dcbc42
Author: Saleem Abdulrasool <compn...@compnerd.org>
Date:   Wed Nov 27 12:55:46 2019 -0800

    build: avoid cached literals being linked against

    If the value of the LibXml2 search is cached, it can cause an errant
    link against LIBXML2_LIBRARIES-NOTFOUND if libxml2 is not found. Add
    a guard against this.  Should repair the build bots.

commit 340e7c0b77a7037afefe7255503afe362967b577
Author: Saleem Abdulrasool <compn...@compnerd.org>
Date:   Wed Nov 27 12:34:36 2019 -0800

    build: avoid hardcoding the libxml2 library name

    FindLibXml2 will set the LIBXML2_LIBRARIES variable to the libraries that
    we must link against. This will be an empty string if libxml2 is not
    found. Avoid hardcoding the library name as xml2 in the configuration.
    Simplify the usage in the WindowsManifest library.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to