How to get sqlite3.lib x64?
Hi, I try to get sqlite3.lib for 64 Bit windows os. I tried implib with the def file and the 64 Bit dll: implib sqlite3_implib.lib sqlite3.def /system -> App crash (Windows 10) With the dll file defined: implib sqlite3_implib.lib sqlite3.dll /system -> Error message: Error(10): Error: cannot read DLL input file I have the MS Build tools installed, but the example from the SQLite site only shows, how to build a X86 dll file from the C source code but not how to build the X86_64 lib file for windows: cl sqlite3.c -link -dll -out:sqlite3.dll I tried different combinations but without success. Could you give me some hints? Kind regards André
Re: getting started with web server - vibe.d dub giving link error
On Sunday, 23 October 2016 at 19:23:04 UTC, Karabuta wrote: On Sunday, 23 October 2016 at 14:53:48 UTC, aman wrote: On Saturday, 22 October 2016 at 17:23:58 UTC, Karabuta wrote: [...] This time i started out with a fresh Ubuntu server and followed instructions on the blog. Here's output. Please help:- /usr/lib/gcc/x86_64-linux-gnu/5/include/d/core/atomic.d:1381:13: error: static assert "Invalid template type specified." static assert(0, "Invalid template type specified."); ^ ../.dub/packages/vibe-d-0.7.29/source/vibe/http/server.d:1388:51: note: instantiated from here: atomicLoad!(cast(MemoryOrder)5, shared(HTTPServerContext)[]) else return cast(HTTPServerContext[])atomicLoad(g_contexts); ^ gdc failed with exit code 1. I used DMD compiler for the tutorial, you are using GCC which might be the problem. GCC compiler seems too outdated. Try using DMD Oh, I see. Actually it got installed auto-magically during dub installation I guess. Now I installed dmd with the script mention on the dlang download page. curl -fsS https://dlang.org/install.sh | bash -s dmd I ran dub again. Here's the error this time! dub Performing "debug" build using dmd for x86_64. vibe-d:utils 0.7.29: target for configuration "library" is up to date. vibe-d:data 0.7.29: target for configuration "library" is up to date. vibe-d:core 0.7.29: target for configuration "libevent" is up to date. vibe-d:http 0.7.29: target for configuration "library" is up to date. vibe-d:diet 0.7.29: target for configuration "library" is up to date. vibe-d:mail 0.7.29: target for configuration "library" is up to date. vibe-d:mongodb 0.7.29: target for configuration "library" is up to date. vibe-d:redis 0.7.29: target for configuration "library" is up to date. vibe-d:web 0.7.29: target for configuration "library" is up to date. vibe-d 0.7.29: target for configuration "libevent" is up to date. testdub ~master: building configuration "application"... Linking... cc: No such file or directory --- errorlevel 255 dmd failed with exit code 255
Re: New to D
Dne 22.10.2016 v 11:04 Mike Parker via Digitalmars-d-learn napsal(a): On Saturday, 22 October 2016 at 08:05:12 UTC, Daniel Kozak wrote: uint[string] dictionary; should be uint[size_t] dictionary; because size_t is 32bit on x86 system and 64bit on x86_64 and you are trying to put array length to dictionary which is size_t I believe you meant: size_t[string]; Yes :)
Re: getting started with web server - vibe.d dub giving link error
On Sunday, 23 October 2016 at 14:53:48 UTC, aman wrote: On Saturday, 22 October 2016 at 17:23:58 UTC, Karabuta wrote: [...] This time i started out with a fresh Ubuntu server and followed instructions on the blog. Here's output. Please help:- /usr/lib/gcc/x86_64-linux-gnu/5/include/d/core/atomic.d:1381:13: error: static assert "Invalid template type specified." static assert(0, "Invalid template type specified."); ^ ../.dub/packages/vibe-d-0.7.29/source/vibe/http/server.d:1388:51: note: instantiated from here: atomicLoad!(cast(MemoryOrder)5, shared(HTTPServerContext)[]) else return cast(HTTPServerContext[])atomicLoad(g_contexts); ^ gdc failed with exit code 1. I used DMD compiler for the tutorial, you are using GCC which might be the problem. GCC compiler seems too outdated. Try using DMD
Re: No trace of cumulativeFold except in the source.
On Sunday, 23 October 2016 at 10:19:07 UTC, Jonathan M Davis wrote: On Sunday, October 23, 2016 10:10:40 e-y-e via Digitalmars-d-learn wrote: ... Per http://dlang.org/changelog/2.071.0.html 2.071.0 came out at the beginning of April, and 2.072 has been slow in coming, so we've only had point releases since then, and a new function would not be added with a point release. But yes, per the current release scheme, normally, there would have been a new major release by now (it is finally in beta though). - Jonathan M Davis On this topic, do you think a 'cumulativeSum' specialisation based on the 'sum' specialisation be welcome in phobos? Here's a quick prototype, obviously not library standard but the basic logic is there: https://gist.github.com/anonymous/4fb79b4aba79b59348273288993740cb
Re: getting started with web server - vibe.d dub giving link error
On Saturday, 22 October 2016 at 17:23:58 UTC, Karabuta wrote: On Saturday, 22 October 2016 at 17:21:45 UTC, Karabuta wrote: On Saturday, 22 October 2016 at 14:50:14 UTC, aman wrote: I just started on vibe.d on fedora and the experience is not pretty getting hello-world running. Please help. Below are the details. [...] I wrote a blog post at https://aberba.gtihub.io which has Fedora users covered. But somehow GitHub pages is not working so you can find it here too https://github.com/aberba/aberba.github.io/blob/master/_posts/2016-08-20-hello-world-app-with-the-vibe.d-web-framework.md Sorry for the typo, blog link is rather https://aberba.github.io/#blog This time i started out with a fresh Ubuntu server and followed instructions on the blog. Here's output. Please help:- /usr/lib/gcc/x86_64-linux-gnu/5/include/d/core/atomic.d:1381:13: error: static assert "Invalid template type specified." static assert(0, "Invalid template type specified."); ^ ../.dub/packages/vibe-d-0.7.29/source/vibe/http/server.d:1388:51: note: instantiated from here: atomicLoad!(cast(MemoryOrder)5, shared(HTTPServerContext)[]) else return cast(HTTPServerContext[])atomicLoad(g_contexts); ^ gdc failed with exit code 1.
Re: No trace of cumulativeFold except in the source.
On Sunday, October 23, 2016 10:10:40 e-y-e via Digitalmars-d-learn wrote: > On Sunday, 23 October 2016 at 09:11:08 UTC, Jonathan M Davis > > wrote: > > On Sunday, October 23, 2016 07:46:19 e-y-e via > > > > Digitalmars-d-learn wrote: > >> ... > > > > It's not a bug. It's just too new. You looked at the master > > branch on github, whereas what you're probably using on your > > computer is 2.071.2, which does not have cumulativeFold, > > because it was added at some point after 2.071.2. > > > > - Jonathan M Davis > > Ok, that checks out. I looked at the commit and it was in April > so I just assumed it would be in the release by now. Per http://dlang.org/changelog/2.071.0.html 2.071.0 came out at the beginning of April, and 2.072 has been slow in coming, so we've only had point releases since then, and a new function would not be added with a point release. But yes, per the current release scheme, normally, there would have been a new major release by now (it is finally in beta though). - Jonathan M Davis
Re: No trace of cumulativeFold except in the source.
On Sunday, 23 October 2016 at 09:11:08 UTC, Jonathan M Davis wrote: On Sunday, October 23, 2016 07:46:19 e-y-e via Digitalmars-d-learn wrote: ... It's not a bug. It's just too new. You looked at the master branch on github, whereas what you're probably using on your computer is 2.071.2, which does not have cumulativeFold, because it was added at some point after 2.071.2. - Jonathan M Davis Ok, that checks out. I looked at the commit and it was in April so I just assumed it would be in the release by now.
Re: No trace of cumulativeFold except in the source.
On Sunday, October 23, 2016 07:46:19 e-y-e via Digitalmars-d-learn wrote: > Recently I needed to use a cumulative sum function, so I looked > in phobos' documentation for 'cumulative' but found nothing > useful. Then I looked in the forums for it and found nothing > useful. But when I searched phobos for it I found cumulativeFold > in std.algorithm.iteration: > https://github.com/dlang/phobos/blob/master/std/algorithm/iteration.d#L312 > 7. So I tried this: > > auto cumulativeSum(Range)(Range r) > { > import std.algorithm.iteration : cumulativeFold; > > return r.cumulativeFold!((a, b) => a +b); > } > > but when I run it I get 'Error: module std.algorithm.iteration > import 'cumulativeFold' not found'. Anyone can reproduce this? > looking at the source I can't see how it could possibly occur but > it is certainly a bug right? It's not a bug. It's just too new. You looked at the master branch on github, whereas what you're probably using on your computer is 2.071.2, which does not have cumulativeFold, because it was added at some point after 2.071.2. - Jonathan M Davis
Re: getting started with web server - vibe.d dub giving link error
On Saturday, 22 October 2016 at 17:23:58 UTC, Karabuta wrote: On Saturday, 22 October 2016 at 17:21:45 UTC, Karabuta wrote: On Saturday, 22 October 2016 at 14:50:14 UTC, aman wrote: I just started on vibe.d on fedora and the experience is not pretty getting hello-world running. Please help. Below are the details. [...] I wrote a blog post at https://aberba.gtihub.io which has Fedora users covered. But somehow GitHub pages is not working so you can find it here too https://github.com/aberba/aberba.github.io/blob/master/_posts/2016-08-20-hello-world-app-with-the-vibe.d-web-framework.md Sorry for the typo, blog link is rather https://aberba.github.io/#blog Hi, still no progress. It seems to be accessing some sha module and then not finding symbols. I also tried cgi.d and that also wont work ia a "hello world" friendly way.
No trace of cumulativeFold except in the source.
Recently I needed to use a cumulative sum function, so I looked in phobos' documentation for 'cumulative' but found nothing useful. Then I looked in the forums for it and found nothing useful. But when I searched phobos for it I found cumulativeFold in std.algorithm.iteration: https://github.com/dlang/phobos/blob/master/std/algorithm/iteration.d#L3127. So I tried this: auto cumulativeSum(Range)(Range r) { import std.algorithm.iteration : cumulativeFold; return r.cumulativeFold!((a, b) => a +b); } but when I run it I get 'Error: module std.algorithm.iteration import 'cumulativeFold' not found'. Anyone can reproduce this? looking at the source I can't see how it could possibly occur but it is certainly a bug right?