Menu

#39 Ensure that `-luuid' finds the w32 library on Cygwin

open
nobody
None
5
2017-03-21
2015-03-06
Ken Brown
No

In the build of the Syscalls module on Cygwin, -luuid will pick up /usr/lib/libuuid.dll.a instead of /usr/lib/w32api/libuuid.a if the builder has the libuuid-devel package installed. Fix attached.

1 Attachments

Discussion

  • Sam Steingold

    Sam Steingold - 2016-08-26

    I think ./src/m4/libtool.m4:2227 should take care of that:

    sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
    

    could you please investigate what this is not happening?
    thanks

     
  • Ken Brown

    Ken Brown - 2016-08-26

    The search path order specified in libtool.m4 is correct in most cases. In the case of -luuid, however, it makes /usr/lib/libuuid.dll.a precede /usr/lib/w32api/libuuid.a. The latter is what we want in this particular case, so we have to explicitly override the standard search order.

     
  • Sam Steingold

    Sam Steingold - 2016-08-26

    isn't the right solution

    sys_lib_search_path_spec="/usr/lib/w32api $sys_lib_search_path_spec"
    
     
  • Ken Brown

    Ken Brown - 2016-08-26

    No. Cygwin is a Posix platform, and we almost always prefer libraries in /usr/lib to libraries in /usr/lib/w32api. In the context of the present patch, however, shlobj.h is a w32 header, and it needs the w32 version of uuid. So this is an exception.

     
  • Ken Brown

    Ken Brown - 2017-03-21

    Something like this patch is still needed in order to build clisp on Cygwin if the builder has the libuuid-devel package installed. Unfortunately, the patch stopped working as of the following changeset:

    changeset: 15725:4c9d0558e61e
    user: Bruno Haible bruno@clisp.org
    date: Sun Feb 19 16:45:35 2017 +0100
    summary: Modernize: Really update to the newest gnulib.

    What happens after this changeset is that the definition of ac_cv_build in modules/syscalls/configure occurs later than the line defining LIBS. I don't know why that would happen, given that modules/syscalls/configure.in didn't change, and I haven't been able to figure out how to fix it.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.