Menu

#536 case-sensitive header file names

v1.0 (example)
open
nobody
None
5
2016-04-28
2016-04-28
Michael Roy
No

Name : mingw64-headers
Version : 4.0.4
Release : 5.fc23
Architecture: noarch
Install Date: Tue 19 Apr 2016 10:38:45 PM MSK

Unable to compile zookeeper with MS-stylized names of headers, e.g. "WS2tcpip.h", until I changed them to lowercase:

$ diff -ur zookeeper-3.5.1-alpha.orig/src/c/src zookeeper-3.5.1-alpha/src/c/src
diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c zookeeper-3.5.1-alpha/src/c/src/addrvec.c
--- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c 2015-07-28 10:20:16.000000000 +0300
+++ zookeeper-3.5.1-alpha/src/c/src/addrvec.c 2016-04-27 22:02:29.534994865 +0300
@@ -21,7 +21,7 @@
#include <assert.h>
#include <errno.h>
#ifdef WIN32
-#include <WS2tcpip.h>
+#include <ws2tcpip.h>
#include "winport.h"
#endif

diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h zookeeper-3.5.1-alpha/src/c/src/addrvec.h
--- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h 2015-07-28 10:20:16.000000000 +0300
+++ zookeeper-3.5.1-alpha/src/c/src/addrvec.h 2016-04-27 20:23:55.779675120 +0300
@@ -25,7 +25,7 @@
#include <netinet in.h="">
#include <netdb.h>
#else
-#include <WinSock2.h>
+#include <winsock2.h>
#include "winstdint.h"
#endif

MS VC infortunately has the names in the "MSOwnWay"-notation, while Linux has a case-sensitive filesystem... well most of them...

Related

Bugs: #536

Discussion

  • Kai Tietz

    Kai Tietz - 2016-04-28

    Hi

    yes, this is a common issue. thanks for pointing it out. Patch is ok for
    conmit.

    Thanks
    Kai
    Am 28.04.2016 21:31 schrieb "Michael Roy" mclr@users.sf.net:


    Status: open
    Group: v1.0 (example)
    Created: Thu Apr 28, 2016 07:31 PM UTC by Michael Roy
    Last Updated: Thu Apr 28, 2016 07:31 PM UTC
    Owner: nobody

    Name : mingw64-headers
    Version : 4.0.4
    Release : 5.fc23
    Architecture: noarch
    Install Date: Tue 19 Apr 2016 10:38:45 PM MSK

    Unable to compile zookeeper with MS-stylized names of headers, e.g.
    "WS2tcpip.h", until I changed them to lowercase:

    $ diff -ur zookeeper-3.5.1-alpha.orig/src/c/src
    zookeeper-3.5.1-alpha/src/c/src
    diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c
    zookeeper-3.5.1-alpha/src/c/src/addrvec.c
    --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c 2015-07-28
    10:20:16.000000000 +0300
    +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.c 2016-04-27
    22:02:29.534994865 +0300
    @@ -21,7 +21,7 @@

    include <assert.h>

    include <errno.h>

    ifdef WIN32

    -#include <WS2tcpip.h>
    +#include <ws2tcpip.h>

    include "winport.h"

    endif

    diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h
    zookeeper-3.5.1-alpha/src/c/src/addrvec.h
    --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h 2015-07-28
    10:20:16.000000000 +0300
    +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.h 2016-04-27
    20:23:55.779675120 +0300
    @@ -25,7 +25,7 @@

    include <netinet in.h="">

    include <netdb.h>

    else

    -#include <WinSock2.h>
    +#include <winsock2.h>

    include "winstdint.h"

    endif

    MS VC infortunately has the names in the "MSOwnWay"-notation, while Linux
    has a case-sensitive filesystem... well most of them...


    Sent from sourceforge.net because you indicated interest in
    https://sourceforge.net/p/mingw-w64/bugs/536/

    To unsubscribe from further messages, please visit
    https://sourceforge.net/auth/subscriptions/

     

    Related

    Bugs: #536

    • Jonathan Yong

      Jonathan Yong - 2016-04-28

      Kai, these aren't patches for mingw-w64.

      Michael, we cannot change the case without breaking things for everyone else.

       
      • Kai Tietz

        Kai Tietz - 2016-04-29

        Oh, I hadn't a closer look to it. Indeed, we are not responsible for
        this, and won't be able to do much. We made for this all our headers
        by default lower-case, so our include file names are somewhat
        standarized.
        So you either need to adjust sources here for case-sensitive file
        system, or use a case-insensitive one. What ever fits best to you.

        Kai

        2016-04-29 0:50 GMT+02:00 Jonathan Yong jon_y@users.sf.net:

        Kai, these aren't patches for mingw-w64.

        Michael, we cannot change the case without breaking things for everyone
        else.


        [bugs:#536] case-sensitive header file names

        Status: open
        Group: v1.0 (example)
        Created: Thu Apr 28, 2016 07:31 PM UTC by Michael Roy
        Last Updated: Thu Apr 28, 2016 07:31 PM UTC
        Owner: nobody

        Name : mingw64-headers
        Version : 4.0.4
        Release : 5.fc23
        Architecture: noarch
        Install Date: Tue 19 Apr 2016 10:38:45 PM MSK

        Unable to compile zookeeper with MS-stylized names of headers, e.g.
        "WS2tcpip.h", until I changed them to lowercase:

        $ diff -ur zookeeper-3.5.1-alpha.orig/src/c/src
        zookeeper-3.5.1-alpha/src/c/src
        diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c
        zookeeper-3.5.1-alpha/src/c/src/addrvec.c
        --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c 2015-07-28
        10:20:16.000000000 +0300
        +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.c 2016-04-27 22:02:29.534994865
        +0300
        @@ -21,7 +21,7 @@

        include <assert.h>

        include <errno.h>

        ifdef WIN32

        -#include <WS2tcpip.h>
        +#include <ws2tcpip.h>

        include "winport.h"

        endif

        diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h
        zookeeper-3.5.1-alpha/src/c/src/addrvec.h
        --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h 2015-07-28
        10:20:16.000000000 +0300
        +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.h 2016-04-27 20:23:55.779675120
        +0300
        @@ -25,7 +25,7 @@

        include <netinet in.h="">

        include <netdb.h>

        else

        -#include <WinSock2.h>
        +#include <winsock2.h>

        include "winstdint.h"

        endif

        MS VC infortunately has the names in the "MSOwnWay"-notation, while Linux
        has a case-sensitive filesystem... well most of them...


        Sent from sourceforge.net because you indicated interest in
        https://sourceforge.net/p/mingw-w64/bugs/536/

        To unsubscribe from further messages, please visit
        https://sourceforge.net/auth/subscriptions/

         

        Related

        Bugs: #536

        • Michael Roy

          Michael Roy - 2016-04-29

          We made for this all our headers by default lower-case, so our include file names are somewhat standarized.
          Standardized to what? Windows-headers standardized to linux? Huh?

          Consider a Windows-project subjected to compilation in the mingw environment. I suppose it must be well living under MS VC. Of course those developers like their code spiced lavishly with includes like <WinSock2.h>.
          Compiling the project in mingw the developers in the first step will inevitably stumble over these includes. Here in the first step mingw fails to provide the easy move.

          The Windows-project expects the Windows-environment.

           
        • Michael Roy

          Michael Roy - 2016-04-29

          I ought to say that I pointed the little though nasty problem out just to make mingw perform better. For zookeeper it was just all that renames... well almost.

           
          • Kai Tietz

            Kai Tietz - 2016-04-29

            It might be an solution to add to compiler the facility to "normalize"
            file names in include (and other file related) statement(s) ... not
            sure how compiler people will react on this :)

            This seems to me like an issue we can't solve in headers better. At
            least we provide for our stuff a general form of file names ...

            2016-04-29 14:24 GMT+02:00 Michael Roy mclr@users.sf.net:

            I ought to say that I pointed the little though nasty problem out just to
            make mingw perform better. For zookeeper it was just all that renames...
            well almost.


            [bugs:#536] case-sensitive header file names

            Status: open
            Group: v1.0 (example)
            Created: Thu Apr 28, 2016 07:31 PM UTC by Michael Roy
            Last Updated: Thu Apr 28, 2016 07:31 PM UTC
            Owner: nobody

            Name : mingw64-headers
            Version : 4.0.4
            Release : 5.fc23
            Architecture: noarch
            Install Date: Tue 19 Apr 2016 10:38:45 PM MSK

            Unable to compile zookeeper with MS-stylized names of headers, e.g.
            "WS2tcpip.h", until I changed them to lowercase:

            $ diff -ur zookeeper-3.5.1-alpha.orig/src/c/src
            zookeeper-3.5.1-alpha/src/c/src
            diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c
            zookeeper-3.5.1-alpha/src/c/src/addrvec.c
            --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c 2015-07-28
            10:20:16.000000000 +0300
            +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.c 2016-04-27 22:02:29.534994865
            +0300
            @@ -21,7 +21,7 @@

            include <assert.h>

            include <errno.h>

            ifdef WIN32

            -#include <WS2tcpip.h>
            +#include <ws2tcpip.h>

            include "winport.h"

            endif

            diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h
            zookeeper-3.5.1-alpha/src/c/src/addrvec.h
            --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h 2015-07-28
            10:20:16.000000000 +0300
            +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.h 2016-04-27 20:23:55.779675120
            +0300
            @@ -25,7 +25,7 @@

            include <netinet in.h="">

            include <netdb.h>

            else

            -#include <WinSock2.h>
            +#include <winsock2.h>

            include "winstdint.h"

            endif

            MS VC infortunately has the names in the "MSOwnWay"-notation, while Linux
            has a case-sensitive filesystem... well most of them...


            Sent from sourceforge.net because you indicated interest in
            https://sourceforge.net/p/mingw-w64/bugs/536/

            To unsubscribe from further messages, please visit
            https://sourceforge.net/auth/subscriptions/

             

            Related

            Bugs: #536

  • NightStrike

    NightStrike - 2016-04-29

    To that end, you could add a -m switch to cpp that is disabled by default
    on all other hosts and enabled by default on mingw to check for alternate
    cases of the case as written in the include fails. Compiler people will be
    more accepting of the defaults are such that non windows platforms don't
    care.
    On Apr 29, 2016 9:08 AM, "Kai Tietz" ktietz70@users.sf.net wrote:

    It might be an solution to add to compiler the facility to "normalize"
    file names in include (and other file related) statement(s) ... not
    sure how compiler people will react on this :)

    This seems to me like an issue we can't solve in headers better. At
    least we provide for our stuff a general form of file names ...

    2016-04-29 14:24 GMT+02:00 Michael Roy mclr@users.sf.net:

    I ought to say that I pointed the little though nasty problem out just to
    make mingw perform better. For zookeeper it was just all that renames...
    well almost.


    [bugs:#536] https://sourceforge.net/p/mingw-w64/bugs/536/ case-sensitive
    header file names

    Status: open
    Group: v1.0 (example)
    Created: Thu Apr 28, 2016 07:31 PM UTC by Michael Roy
    Last Updated: Thu Apr 28, 2016 07:31 PM UTC
    Owner: nobody

    Name : mingw64-headers
    Version : 4.0.4
    Release : 5.fc23
    Architecture: noarch
    Install Date: Tue 19 Apr 2016 10:38:45 PM MSK

    Unable to compile zookeeper with MS-stylized names of headers, e.g.
    "WS2tcpip.h", until I changed them to lowercase:

    $ diff -ur zookeeper-3.5.1-alpha.orig/src/c/src
    zookeeper-3.5.1-alpha/src/c/src
    diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c
    zookeeper-3.5.1-alpha/src/c/src/addrvec.c
    --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c 2015-07-28
    10:20:16.000000000 +0300
    +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.c 2016-04-27 22:02:29.534994865
    +0300
    @@ -21,7 +21,7 @@
    include <assert.h> include <errno.h>
    ifdef WIN32

    -#include <WS2tcpip.h>
    +#include <ws2tcpip.h>
    include "winport.h"
    endif

    diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h
    zookeeper-3.5.1-alpha/src/c/src/addrvec.h
    --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h 2015-07-28
    10:20:16.000000000 +0300
    +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.h 2016-04-27 20:23:55.779675120
    +0300
    @@ -25,7 +25,7 @@
    include <netinet in.h="">
    include <netdb.h> else

    -#include <WinSock2.h>
    +#include <winsock2.h>
    include "winstdint.h" endif

    MS VC infortunately has the names in the "MSOwnWay"-notation, while Linux

    has a case-sensitive filesystem... well most of them...

    Sent from sourceforge.net because you indicated interest in
    https://sourceforge.net/p/mingw-w64/bugs/536/

    To unsubscribe from further messages, please visit
    https://sourceforge.net/auth/subscriptions/


    Status: open
    Group: v1.0 (example)
    Created: Thu Apr 28, 2016 07:31 PM UTC by Michael Roy
    Last Updated: Thu Apr 28, 2016 07:31 PM UTC
    Owner: nobody

    Name : mingw64-headers
    Version : 4.0.4
    Release : 5.fc23
    Architecture: noarch
    Install Date: Tue 19 Apr 2016 10:38:45 PM MSK

    Unable to compile zookeeper with MS-stylized names of headers, e.g.
    "WS2tcpip.h", until I changed them to lowercase:

    $ diff -ur zookeeper-3.5.1-alpha.orig/src/c/src
    zookeeper-3.5.1-alpha/src/c/src
    diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c
    zookeeper-3.5.1-alpha/src/c/src/addrvec.c
    --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.c 2015-07-28
    10:20:16.000000000 +0300
    +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.c 2016-04-27 22:02:29.534994865
    +0300
    @@ -21,7 +21,7 @@

    include <assert.h>

    include <errno.h>

    ifdef WIN32

    -#include <WS2tcpip.h>
    +#include <ws2tcpip.h>

    include "winport.h"

    endif

    diff -ur zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h
    zookeeper-3.5.1-alpha/src/c/src/addrvec.h
    --- zookeeper-3.5.1-alpha.orig/src/c/src/addrvec.h 2015-07-28
    10:20:16.000000000 +0300
    +++ zookeeper-3.5.1-alpha/src/c/src/addrvec.h 2016-04-27 20:23:55.779675120
    +0300
    @@ -25,7 +25,7 @@

    include <netinet in.h="">

    include <netdb.h>

    else

    -#include <WinSock2.h>
    +#include <winsock2.h>

    include "winstdint.h"

    endif

    MS VC infortunately has the names in the "MSOwnWay"-notation, while Linux
    has a case-sensitive filesystem... well most of them...


    Sent from sourceforge.net because you indicated interest in
    https://sourceforge.net/p/mingw-w64/bugs/536/

    To unsubscribe from further messages, please visit
    https://sourceforge.net/auth/subscriptions/

     

    Related

    Bugs: #536

    • Michael Roy

      Michael Roy - 2016-04-29

      The compiler switch would be right.
      Thank you!

       

      Last edit: Michael Roy 2016-04-29
    • Jonathan Yong

      Jonathan Yong - 2016-05-01

      I strongly disagree that it should be default on, even on mingw, this changes default established behaviors. If users want it, they can always add a new flag themselves.

       

Log in to post a comment.