I've tested to build my project a few days ago with dub from git master, it's now working has expected, it builds a shared library.

I did notice some quirks, it's not possible to add a sufix to the generated file (or am I wrong?), I've used the "postBuildCommands" to mv the generated shared lib to a file name containing the version ( from libxxx.so to libxxx.so.1.1.1). the strange is that if you declare this project has a dependency on another project it will use there the postBuildCommands as if they were declared on the subsequent project as normal after the linker, failing of course.
I've noticed the same behavior with the "lflags", they were also present on the subsequent project link command. So at the moment I can build a project has a sharedLib but not declare in other projects as a dependency.

Not sure if it's already there, but maybe can you consider for sharedLibs to add a field that would allow to add an additional suffix to the generated file? Currently Dub adds only ".so", but shared libs usually contain in the name also the version.

Another request/wish I would like to make is that if it's possible since we declared one project as a dependency to get also in this project a "$PACKAGE_DIR" similar variable, from the required project?
This would be great because it would allow to specify on the dependant project for the executable file, the rpath value and other settings from the library/required project, without having to have them hard coded in the ".json" file.

Maybe it's clear if I provide examples of the project files.

sharedLibrary project:

{ "name":"mysharedlib",
"targetType": "dynamicLibrary",
"libs":["phobos2"],
"targetPath":"./lib",
"lflags":["-soname=libmysharedlib.so.0"]}

Project (builds but includes code from the library):

{ "name":"proj",
"targetType": "executable",
"dependencies": { "mysharedlib": {"version":"~master"}}}

This will build and link but the binary will have my lib code included, not has a shared dependency.

How I'm creating it having a shared lib dependency:

{ "name":"proj",
"targetType": "executable",
"libs":["mysharedlib"],
"dflags": ["-I../mysharedlibfolder/include"],
"lflags":["-L../mysharedlibfolder/lib","-rpath=$PACKAGE_DIR/../mysharedlibfolder/lib"]

Has you can see I need to make a hard reference to the library project in all this *flags, it would be good to have a variable to allow this to be referenced independent of where the lib project stays.

$ ldd myexe
libmysharedlib.so.0 => /home/user/projfolder/../mysharedlibfolder/lib/libsru.so.0 (0x00007f98efc54000)
libphobos2.so.0.63 => /usr/lib/x86_64-linux-gnu/libphobos2.so.0.63 (0x00007f98eec0b000)

Thank you.