You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by Heromyth <gi...@git.apache.org> on 2017/09/29 01:50:24 UTC

[GitHub] thrift pull request #1380: Support x64 build mode on Windows with DMD v2.076...

GitHub user Heromyth opened a pull request:

    https://github.com/apache/thrift/pull/1380

    Support x64 build mode on Windows with DMD v2.076.0.

    This request is used to update the last pull request #1263 using latest thrift. 
    Running `make check` failed  because of missing some third-party libraries.
    I have run all the test codes by hand in Visual Studio Code with DMD 2.076.0 on Windows 10 and Linux . All the tests passed.
    The auto-test tool for D need improved. Maybe it's better to use CMake or DUB (a build tool for D).

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/Heromyth/thrift master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/thrift/pull/1380.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1380
    
----
commit 4ebcd59129f94d5ee6f5e28d123992e19679a2ea
Author: ZhangXuePing <zh...@putao.com>
Date:   2017-09-28T09:54:40Z

    Support x64 build mode on Windows with DMD v2.076.0.

----


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    On the Travis build - the Ubuntu Trusty image is using D 2.070.0 (see: https://github.com/apache/thrift/tree/master/build/docker).
    
    Currently we don't really have an official record and mechanism for minimum required versions of things.  The closest thing is a store in the backlog that I opened recently:  https://issues.apache.org/jira/browse/THRIFT-4344
    
    It sounds like we may need to make a decision as to how old an environment we want to continue to support for D in future thrift releases.  The project has been really relaxed in support, for example the Perl library claims to require only v5.10.0 or later which is ancient (trusty has 5.18.2 for example).  What I'm finding is that the matrix for CI builds is just too wide and unruly, and we need to start making some decisions about how far back we need to support with each release.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    It looks like you may not have static link libraries for libevent, and openssl on your system?  It also looks like automake didn't figure it out properly.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by Heromyth <gi...@git.apache.org>.
Github user Heromyth commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    The D compiler upgrades quite frequently. The latest version is not always compatible with the older one.
    I have a CMake module for D. However it needs more time to add the module to Thrift and to reorganize the test codes. My project will use Thrift and I want to make the Thrift-D lib stable firstly. 


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    Any news?


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by Heromyth <gi...@git.apache.org>.
Github user Heromyth commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    1) Merged with the latest Thrift code.
    2) Tested with DMD 2.078 on Linux Mint 18.3
    3) All unittests are passed and all tests run succesfully.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    I'd like to see this squashed to one commit and rebased one more time; our CI builds are not in good shape but I can run it on my local system to prove it out and they deal with CI issues when that system is back and operating (sourceforge has been down for days and we depend on some components hosted there).


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by Heromyth <gi...@git.apache.org>.
Github user Heromyth commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    I got the same error messages in DMD 2.070.0.


---

[GitHub] thrift pull request #1380: Support x64 build mode on Windows with DMD v2.076...

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on a diff in the pull request:

    https://github.com/apache/thrift/pull/1380#discussion_r172314698
  
    --- Diff: lib/d/Makefile.am ---
    @@ -136,54 +110,22 @@ docs: $(d_publicsources) src/thrift/index.d
     #
     # Hook custom library targets into the automake all/install targets.
     #
    -all-local: $(all_targets)
    +all-local:
    +	dub build --config=library --arch=x86_64 --build=debug --compiler=dmd
    --- End diff --
    
    Multiple problems:
    
    1. All builds are 64-bit.
    2. All builds are debug.
    3. All builds require dmd.  autoconf detects any of the three dlang compilers that might be installed.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by Heromyth <gi...@git.apache.org>.
Github user Heromyth commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    I have updated all my patches base on the latest Thrift.
    All the patches are tested with DMD 2.077.1 on  Linux Mint 18.3.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by Heromyth <gi...@git.apache.org>.
Github user Heromyth commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    I found one reason why the `make check` failed.
    
    The command line used by DMD (Failed):
    `dmd -g -ofunittest/debug/thrift/server/transport/ssl -unittest -w -wi -I../../lib/d/src src/thrift/server/transport/ssl.d libthriftd-event.a libthriftd-ssl.a libthriftd.a -L-levent -L-lcrypto -L-lssl unittest/emptymain.d `
    
    The underlying command line generated by DMD  (Failed):
    `cc unittest/debug/thrift/server/transport/ssl.o -o unittest/debug/thrift/server/transport/ssl -g -m64` **-levent -lcrypto -lssl** ` -L/usr/lib/x86_64-linux-gnu -Xlinker --export-dynamic libthriftd-event.a libthriftd-ssl.a libthriftd.a -Xlinker -Bstatic -lphobos2 -Xlinker -Bdynamic -lpthread -lm -lrt -ldl`
    
    The correct command line reorderd by me (Succeeded):
    `cc unittest/debug/thrift/server/transport/ssl.o -o unittest/debug/thrift/server/transport/ssl -g -m64 -L/usr/lib/x86_64-linux-gnu -Xlinker --export-dynamic libthriftd-event.a libthriftd-ssl.a libthriftd.a -Xlinker -Bstatic -lphobos2 -Xlinker -Bdynamic `**-levent -lcrypto -lssl** `-lpthread -lm -lrt -ldl`
    
    I have no idea how to fix this by far.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    The tutorials didn't get updated and as a result fail to build in the autotools build (build/docket/script/autotools.sh) which is what some of the Travis CI build jobs do.  I am attempting to fix this.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    I like the notion that the makefile system won't be responsible for dependency checking.  We're doing the same thing with the dotnet builds now.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by Heromyth <gi...@git.apache.org>.
Github user Heromyth commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    Yes, it still needs more works. I'll check them all.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    I can't (well, won't) merge a PR with 100 commits.  I also fixed dmd invocation on linux earlier today and fixed the link ordering issue.  So if you can rebase and squash to one commit, that would be helpful.  Linux is using 2.077.1 on the artful build; 2.078.0 and higher fail with a backwards incompatibility issue, I believe.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    THRIFT-3458 is also related, and the approach in THRIFT-3458 would allow us to add the apache git repo to dub directly so we should move in that direction, but still try to use dub to build in lib/d, test/d, tutorial/d.  I closed THRIFT-4504 as a duplicate of THRIFT-3458.  If we can get this PR to the point where there is a dub file at the top level of the repository that builds lib/d, that will allow us to add the apache repo to the dub registry and have it build and publish a dub package.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    Opened THRIFT-4504 to track this.


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by jeking3 <gi...@git.apache.org>.
Github user jeking3 commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    To address the last sentence in your comment above: We're standardizing on cmake and moving everything towards that, albeit slowly.  Could you tell me if this makes older D versions unusable on Windows, and if so which D version on Windows would be the earliest supported?


---

[GitHub] thrift issue #1380: Support x64 build mode on Windows with DMD v2.076.0.

Posted by Heromyth <gi...@git.apache.org>.
Github user Heromyth commented on the issue:

    https://github.com/apache/thrift/pull/1380
  
    I'm using DUB to build thrift-d module. All the unittests are passed. There are still some bugs which lead  some tests failed. I'm fixing them.


---