Marco Cantu

Syndicate content
Techie Italian Blogging on Delphi and More
Updated: 4 min 2 sec ago

Delphi Blogs of the Week #54

Fri, 07/21/2017 - 08:00

A new round up of Delphi-related news, after my two weeks of vacation around Europe.

Delphi Product Blogs and More

Quickly find add-ons with new GetIt categories by Sarina at https://community.embarcadero.com/blogs/entry/quickly-find-add-ons-with-new-getit-categories (by the way, we are open for ideas and suggestions, given the system is now fairly flexible)

The Enterprise Connector Beta has started by Sarina at https://community.embarcadero.com/blogs/entry/the-enterprise-connector-beta-has-started

Viewing Salesforce Data in RAD Studio Data Explorer by Sarina at https://community.embarcadero.com/article/16541-viewing-salesforce-data-in-rad-studio-data-explorer

#FireMonkey RAD Studio Overview Download Link: http://forms.embarcadero.com/sFireMonkeyRADStudioOverview

Targeting Chrome OS with Delphi via Android and Linux by Jim McKeeth at https://community.embarcadero.com/blogs/entry/targeting-chrome-os-with-delphi-via-android-and-linux

Notable Blog Posts

Send an Email with an Attachment in iOS, Android, and Windows using RAD Studio by Roy Woll at https://www.woll2woll.com/single-post/2017/04/24/Send-an-Email-with-an-Attachment-FireMonkey

ScannerMApp: a QR/barcode scanner app with Delphi, ZXing and TFrameStand by Andrewa Magni at https://blog.andreamagni.eu/2017/06/scannermapp-a-qrbarcode-scanner-app-with-delphi-zxing-and-tframestand/

Using Google Sign-In for Firebase SDK on Android by Allen Drennan at https://blog.grijjy.com/2017/07/20/using-google-sign-in-for-firebase-sdk-on-android/

SIMD Assembly Optimization by Erik van Bilsen at https://blog.grijjy.com/2017/07/10/simd-assembly-optimization/

Building a (real) Linux daemon with Delphi - Part 1 by Paolo Rossi at http://blog.paolorossi.net/2017/07/11/building-a-real-linux-daemon-with-delphi-part-1-2/

4 Years at Embarcadero Technologies by Jim at http://delphi.org/2017/07/4-years-at-embarcadero/

Encode JSON to a FireDAC Memory Table without REST Request by Craig at http://chapmanworld.com/2017/07/07/encode-json-to-a-firedac-memory-table-without-rest-request/

Stay tunes for more news.

Categories: News, Blogs, and Tips

Delphi Blogs of the (Week) Month #53

Thu, 06/29/2017 - 04:08
Embarcadero News

Embarcadero Partners with CData to Offer Enterprise Connectors (press release at http://www.businesswire.com/news/home/20170621005319/en). You can read more on this blog post from Sarina, https://community.embarcadero.com/blogs/entry/new-enterprise-connectors-for-delphi-and-c-builder-join-the-beta. The beta of the components can be found in GetIt for Tokyo customers (Professional and above), in a new "Connectors" category. You can use them to connect with over 70 different business, enterprise and social web services. Very nicely integrated with FireDAC and the IDE.

A patch for Tokyo focused on Android is available, http://blog.marcocantu.com/blog/2017-june-102-android-patch.html

Books, books!

Cary Jensen has a new FireDAC book out. See the announcement at http://caryjensen.blogspot.it/2017/05/delphi-in-depth-firedac-is-now-available.html and a review by Stephen at https://community.embarcadero.com/blogs/entry/firedac-book-using-interbase.

Dalija has a new book project focused on Delphi Memory Management, as you can read at https://plus.google.com/u/0/+DalijaPrasnikar/posts/Kkund4GXpXv and https://plus.google.com/+DalijaPrasnikar/posts/CbEnZdx6fNY.

Blog Posts

Visualize JSON using TTreeView at https://community.embarcadero.com/blogs/entry/visualize-json-using-ttreeview

New FireDAC Database Status Page at https://community.embarcadero.com/blogs/entry/new-firedac-database-status-page

Using the Google Cloud Platform APIs at http://​https://blog.grijjy.com/2017/01/13/using-the-google-cloud-platform-apis/

FireMonkey and VCL Style Packs from DelphiStyles.com at https://community.embarcadero.com/blogs/entry/fmx-and-vcl-style-packs-from-delphistyles-com

Third Party Tools

MIDAS dropbox library at http://www.midaconverter.com/dropbox.html

PasLibVlc - use VideoLAN player in Delphi at http://prog.olsztyn.pl/paslibvlc/

The Light End

Delphi developers use spaces, right? https://stackoverflow.blog/2017/06/15/developers-use-spaces-make-money-use-tabs/

Categories: News, Blogs, and Tips

RAD Studio 10.2 Patch for Android Released

Mon, 06/26/2017 - 02:33

As Sarina already mentioned in the community site, last week Embarcadero released a second patch for Delphi and C++Builder 10.2 Tokyo. The first patch was focused on tool chain issues, while this new one addresses several issues for Android platform support. Namely, some of the fixes relate with the platform changes in editing (causing problems when using the backspace key) while other address regressions (and performance issues) introduced in 10.2 Tokyo and caused by platform changes in threading support.

You can find a list of open Quality Portal issues the patch addresses in the download page at https://cc.embarcadero.com/item/30781. This patch is available also for trial customers.

The matching source code is available only for registered users at https://cc.embarcadero.com/item/30782. Notice that the source code includes changes that affect multiple platforms, but we haven't released the updated DCU files for those other platforms. In other words, PAS and DCU will most likely be out of synch either with or without the source code patch, depending on the target platform, and you should consider enabling this new source code for Android specific projects or using it as reference only.

We know this is no ideal and this patch is intended as a temporary solution, while we complete and test a full update of the product, including all internal fixes and all platforms.

Categories: News, Blogs, and Tips

Celebrating 22 Exciting Years of Innovation with Delphi

Thu, 06/22/2017 - 02:56

Delphi was released over 22 years ago in San Francisco. More than two decades later, the Delphi design philosophy remains steadfastly the same: continual innovation and increasing productivity for developers. Throughout its history, Delphi has been one of the most successful development platforms as it continues to navigate a highly competitive space, maintain its essence as a robust integrative toolset, and serve a large community of passionate developers. Deep investments have been made in the product over the years to migrate Delphi from a Windows-centric product to a multi-device development tool supporting the five most popular operating systems: Windows, macOS, iOS, Android, and Linux.

Global Reach

Delphi developers can be found in virtually every corner of the world, and this is why a city moniker designates each of the 10.x versions to celebrate the diverse global reach and significant contributions that Delphi is making today. Since VCL has been the best object-oriented library Windows API wrapping for over 20 years, Seattle was chosen first (to honor the city near Microsoft headquarters). Next, the Berlin release acknowledged the strong developer community and partner network presence that Delphi has -- not only in Germany, but throughout all of Europe. Most recently, the Tokyo release recognizes the proud and growing community in Japan.

Tokyo Release: Running on Linux

Delphi has long had amazing support for multi-tier and server-side development on Windows. The 10.2 Tokyo release extends all of that support to the Linux operating system. This includes support for WebBroker, WebServices, DataSnap, and the new EMS modules for RAD Server. This means that many of your existing RAD Server/Windows server applications will migrate quite easily over to Linux. Only a few changes are necessary in a typical migration, thanks to the cross-platform FireDAC support. FireDAC works on both Windows and Linux to give you unparalleled access to your favorite databases. 

There's more. Gather up all of your Apache or IIS modules, your REST backend services, your Windows services, or any other server-side or console application, and easily migrate those app components from Windows to Linux.

New features continue to drive strong innovation

If you've not taken a close look lately, it's time to reacquaint yourself with the newer release of Delphi and explore some truly amazing features. These are only a few:

  • Live Preview - Let's say that you're designing an app, and you want to see how it looks on an iOS or Android device. As you work in the Form Designer, simply click a button to see your app in the Live Preview feature of Delphi -- in proper scale and clear definition. There's no need to plug in your device, and you can easily and repeatedly preview the app in either device format as you continue your development work.

  • App Tethering - Maybe you've built a desktop app, and you're also building a mobile companion app. How should these apps talk to each other? App tethering makes it very easy to connect any app on any platform to an app on any other platform -- including Mac-to-Windows, Android-to-Mac, iOS-to-Windows, and so on.

  • Parallel Programming Library - High-level, easy usable, and quick parallelization. It's the holy grail, and it's an integral part of Delphi.

  • Desktop Bridge - Need to get your desktop app into the Windows Store? Simply rebuild, since the Windows Store is available as a build target (just like any other target). No need to mess with the tedium that you may have heard about in other development platforms. We build easy-to-use, straightforward systems. And Delphi is flat-out easy.

Delphi Language Evolution -- Forever Young and Growing

The Delphi language is very powerful. Yet simple, expressive, and easily readable. Excellent for a student and yet solid and robust for the most adept professionals. It is a rich  language that is ready for the future, while retaining its solid roots of the past. The language has a long history, remains dynamic in the present, and we are certain of a brilliant future ahead. Delphi is a multi-faceted language, combining the power of object-oriented programming, advanced support for generic programming, and dynamic constructs-like attributes. And yet, for those who prefer it, full support remains for conventional procedural programming. Delphi is a tool for all trades -- with a variety of compilers and development tools that fully embrace the mobile era.

How broad is the range of the Delphi language? You name it. Desktop apps, client-server applications, massive web server modules, middleware, office automation, apps for the latest phones and tablets, industrial automation systems, and Internet virtual phone networks. These are some of the many real-world uses for Delphi.

The Delphi language, also known as Object Pascal, is a modern type-checked and object-oriented language, featuring single-inheritance and an object reference model (similar to Java and C#). Over the years, the language has grown to include records with methods, operator overloading for records, class data, nested types, sealed classes, final methods, and class helpers.

Beyond the classic OOP features, the Delphi language has gained support for generic data types and collections, anonymous methods (or closures), reflection, and attributes -- along with an extremely rich RTTI and component streaming support architecture. Part of modernizing the language was its transition towards Unicode strings as native types and the use of the ARC (Automatic Reference Counting) memory model on mobile platforms.

In terms of features, the Delphi language has no reason to envy to other more popular programming languages. Delphi is happy retaining its distinctive characteristics, its readability, and its flexibility through such a wide variety of the programming paradigms it supports.

Building a Future Together

Developers are absolutely essential to the future, in which technology will be ever more integral to everything we do. The success of Delphi is largely attributable to its community of passionate developers -- a community that cherishes the elegance and simplicity of the language, but also its ability to create powerful applications with ease and speed.

To learn more about the history of Delphi and today's landscape, read our 55-page booklet at http://online.flowpaper.com/79e6075d/Delphi22Magazine/. Enjoy.

Categories: News, Blogs, and Tips

Pictures from Italian Delphi Day last week

Mon, 06/19/2017 - 09:23

Last week I was at a large Italian conference (with almost 100 Delphi developers attending) in my city. I gave a keynote on the status and future of Delphi, and there were many other sessions given by Italian Delphi developers and some international experts (including Stefan, Dmitry, and Yuriy). See the conference site www.delphiday.it for more information and the program.

I was able to meet and talk with many attendees, several of which I've known for years, but I was also happy to find some very young developers in the audience. Here there are a few pictures (some I took and some shared by Paolo Rossi and Marco Breveglieri on social media):

Nice conference. Now I have a fairly long break, I'll be back speaking in public after the summer.

Categories: News, Blogs, and Tips

The Issue with Delphi Runtime Packages and Windows 10 Creators Update

Mon, 06/12/2017 - 10:01

Since Windows 10 Creators Update was released two months ago, we have started seeing reports of issues with runtime package (for example, https://quality.embarcadero.com/browse/ RSP-17972, where myself, Embarcadero support and R&D have chimed in), mostly while debugging applications. The issue is affecting applications that use runtime packages (BPL), not applications compiled as a single executable. In general terms, the problem affects all applications that use runtime packages, built with any version of Delphi (recent, old, or even the early ones). In most cases, the slowdown for end user application is relatively limited, however applications with runtime packages on network shares are affected. But what is happening?

The Core Issue: Optimized DLL Loading

Let's start with some background information. On the Windows operating system, dynamic linking (DLLs) support both load-time binding and full runtime binding (LoadLibrary). In both cases, when the DLL is generated it is has a table of entry points (export table). Any other library or executable referring to it has an import table referring to functions of that export table. Since the early days, when the Delphi compiler (and linker) generate a DLL or package library (BPL) by assembling multiple units in a single binary file, and do so by making functions and methods available by creating multiple sections in the export/import table. This was likely a minor linker optimization, and never had a real side effect.

Fast forward to Windows 10 Creators Update. Microsoft decided to rewrite the DLL loading code to make it parallel (different threads can load different libraries in parallel) to optimize applications loading. However this change has ended up affecting the loading of libraries with multiple sections in the export tables. Empirically, it looks like a BPL is loaded once for each segment. Now consider that most of the core Delphi BPL (rtl, vcl, fmx) have dozens and dozens of sections, and the result is libraries are loaded (and unloaded) dozens and dozens of times.

Here is a screenshot of the effect in the Event log (this is a single form FMX application):

While in this simple application on my machine it takes a couple of extra seconds, with larger applications having many runtime packages the effect on the debugger can be fairly extreme. Here is the full debugger log, with operations on packages (and other notable ones) marked in bold:

Thread Start: Thread ID: 12052. Process Project13.exe (13088) Process Start: C:\Users\marco\Documents\Embarcadero\Studio\Projects\Win32\Debug\Project13.exe. Base Address: $00400000. Process Project13.exe (13088) Module Load: Project13.exe. Has Debug Info. Base Address: $00400000. Process Project13.exe (13088) Module Load: ntdll.dll. No Debug Info. Base Address: $76F40000. Process Project13.exe (13088) Module Load: KERNEL32.dll. No Debug Info. Base Address: $74520000. Process Project13.exe (13088) Module Unload: KERNEL32.dll. Process Project13.exe (13088) Module Load: KERNEL32.dll. No Debug Info. Base Address: $74520000. Process Project13.exe (13088) Module Load: KERNELBASE.dll. No Debug Info. Base Address: $73B80000. Process Project13.exe (13088) Thread Start: Thread ID: 14596. Process Project13.exe (13088) Thread Start: Thread ID: 2688. Process Project13.exe (13088) Thread Start: Thread ID: 2076. Process Project13.exe (13088) Module Load: rtl250.bpl. Has Debug Info. Base Address: $50050000. Process Project13.exe (13088) Module Load: rtl250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: rtl250.bpl. Has Debug Info. Base Address: $01740000. Process Project13.exe (13088) Module Load: rtl250.bpl. Has Debug Info. Base Address: $02170000. Process Project13.exe (13088) Module Unload: rtl250.bpl. Process Project13.exe (13088) Module Unload: rtl250.bpl. Process Project13.exe (13088) Module Unload: rtl250.bpl. Process Project13.exe (13088) Module Load: OLEAUT32.dll. No Debug Info. Base Address: $74980000. Process Project13.exe (13088) Module Load: msvcp_win.dll. No Debug Info. Base Address: $76130000. Process Project13.exe (13088) Module Load: ucrtbase.dll. No Debug Info. Base Address: $743A0000. Process Project13.exe (13088) Module Load: combase.dll. No Debug Info. Base Address: $75EA0000. Process Project13.exe (13088) Module Load: RPCRT4.dll. No Debug Info. Base Address: $73A30000. Process Project13.exe (13088) Module Load: SspiCli.dll. No Debug Info. Base Address: $73A10000. Process Project13.exe (13088) Module Load: CRYPTBASE.dll. No Debug Info. Base Address: $73A00000. Process Project13.exe (13088) Module Load: bcryptPrimitives.dll. No Debug Info. Base Address: $76810000. Process Project13.exe (13088) Module Load: SECHOST.dll. No Debug Info. Base Address: $763A0000. Process Project13.exe (13088) Module Load: ADVAPI32.dll. No Debug Info. Base Address: $73AF0000. Process Project13.exe (13088) Module Load: msvcrt.dll. No Debug Info. Base Address: $75DE0000. Process Project13.exe (13088) Module Load: USER32.dll. No Debug Info. Base Address: $76870000. Process Project13.exe (13088) Module Load: win32u.dll. No Debug Info. Base Address: $74A20000. Process Project13.exe (13088) Module Load: GDI32.dll. No Debug Info. Base Address: $74A50000. Process Project13.exe (13088) Module Load: gdi32full.dll. No Debug Info. Base Address: $74640000. Process Project13.exe (13088) Module Load: imagehlp.dll. No Debug Info. Base Address: $74060000. Process Project13.exe (13088) Module Load: SHLWAPI.dll. No Debug Info. Base Address: $745F0000. Process Project13.exe (13088) Module Load: ole32.dll. No Debug Info. Base Address: $74080000. Process Project13.exe (13088) Module Load: WS2_32.dll. No Debug Info. Base Address: $73E20000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $031A0000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $031A0000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $031A0000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $031A0000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $01940000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02570000. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Unload: fmx250.bpl. Process Project13.exe (13088) Module Load: VERSION.dll. No Debug Info. Base Address: $73990000. Process Project13.exe (13088) Module Load: NETAPI32.dll. No Debug Info. Base Address: $712F0000. Process Project13.exe (13088) Module Load: MPR.dll. No Debug Info. Base Address: $72BB0000. Process Project13.exe (13088) Module Load: SHFOLDER.dll. No Debug Info. Base Address: $737E0000. Process Project13.exe (13088) Module Load: SHELL32.dll. No Debug Info. Base Address: $74A80000. Process Project13.exe (13088) Module Load: WINHTTP.dll. No Debug Info. Base Address: $72B00000. Process Project13.exe (13088) Module Load: WSOCK32.dll. No Debug Info. Base Address: $72A00000. Process Project13.exe (13088) Module Load: OLEACC.dll. No Debug Info. Base Address: $6F3D0000. Process Project13.exe (13088) Module Load: CFGMGR32.dll. No Debug Info. Base Address: $73D50000. Process Project13.exe (13088) Module Load: OPENGL32.dll. No Debug Info. Base Address: $6F2F0000. Process Project13.exe (13088) Module Load: SHCORE.dll. No Debug Info. Base Address: $73D90000. Process Project13.exe (13088) Module Load: GLU32.dll. No Debug Info. Base Address: $70C90000. Process Project13.exe (13088) Module Load: netutils.dll. No Debug Info. Base Address: $71C70000. Process Project13.exe (13088) Module Load: Windows.Storage.dll. No Debug Info. Base Address: $769B0000. Process Project13.exe (13088) Module Load: AppCore.dll. No Debug Info. Base Address: $73B70000. Process Project13.exe (13088) Module Load: POWRPROF.dll. No Debug Info. Base Address: $760E0000. Process Project13.exe (13088) Module Load: profapi.dll. No Debug Info. Base Address: $74970000. Process Project13.exe (13088) Module Load: fmx250.bpl. Has Debug Info. Base Address: $00D10000. Process Project13.exe (13088) Module Load: COMDLG32.dll. No Debug Info. Base Address: $742A0000. Process Project13.exe (13088) Module Load: COMCTL32.dll. No Debug Info. Base Address: $6F510000. Process Project13.exe (13088) Module Load: urlmon.dll. No Debug Info. Base Address: $6CE50000. Process Project13.exe (13088) Module Load: WINMM.dll. No Debug Info. Base Address: $72F20000. Process Project13.exe (13088) Module Load: d3d9.dll. No Debug Info. Base Address: $68C10000. Process Project13.exe (13088) Module Load: WINSPOOL.DRV. No Debug Info. Base Address: $6F280000. Process Project13.exe (13088) Module Load: iertutil.dll. No Debug Info. Base Address: $6CC30000. Process Project13.exe (13088) Module Load: WINMMBASE.dll. No Debug Info. Base Address: $72A10000. Process Project13.exe (13088) Module Load: WINMMBASE.dll. No Debug Info. Base Address: $001D0000. Process Project13.exe (13088) Module Unload: WINMMBASE.dll. Process Project13.exe (13088) Module Load: WINMMBASE.dll. No Debug Info. Base Address: $001D0000. Process Project13.exe (13088) Module Unload: WINMMBASE.dll. Process Project13.exe (13088) Module Load: dwmapi.dll. No Debug Info. Base Address: $6C320000. Process Project13.exe (13088) Module Load: bcrypt.dll. No Debug Info. Base Address: $729E0000. Process Project13.exe (13088) Module Load: IMM32.dll. No Debug Info. Base Address: $76370000. Process Project13.exe (13088) Module Load: UxTheme.dll. No Debug Info. Base Address: $6C2A0000. Process Project13.exe (13088) Module Load: MSCTF.dll. No Debug Info. Base Address: $761C0000. Process Project13.exe (13088) Module Load: gdiplus.dll. No Debug Info. Base Address: $6BFA0000. Process Project13.exe (13088) Thread Start: Thread ID: 2908. Process Project13.exe (13088) Module Load: TextInputFramework.dll. No Debug Info. Base Address: $6F1E0000. Process Project13.exe (13088) Module Load: CoreMessaging.dll. No Debug Info. Base Address: $6C8A0000. Process Project13.exe (13088) Module Load: CoreUIComponents.dll. No Debug Info. Base Address: $6C930000. Process Project13.exe (13088) Module Load: NTMARTA.dll. No Debug Info. Base Address: $71F60000. Process Project13.exe (13088) Module Load: WinTypes.dll. No Debug Info. Base Address: $70CF0000. Process Project13.exe (13088) Module Load: USERMGRCLI.dll. No Debug Info. Base Address: $70C00000. Process Project13.exe (13088) Thread Start: Thread ID: 14704. Process Project13.exe (13088) Thread Start: Thread ID: 11932. Process Project13.exe (13088) Thread Start: Thread ID: 12476. Process Project13.exe (13088) Module Load: CLBCatQ.DLL. No Debug Info. Base Address: $74210000. Process Project13.exe (13088) Module Load: DataExchange.dll. No Debug Info. Base Address: $5B340000. Process Project13.exe (13088) Module Load: d3d11.dll. No Debug Info. Base Address: $625F0000. Process Project13.exe (13088) Module Load: dcomp.dll. No Debug Info. Base Address: $5B250000. Process Project13.exe (13088) Module Load: dxgi.dll. No Debug Info. Base Address: $62850000. Process Project13.exe (13088) Module Load: twinapi.appcore.dll. No Debug Info. Base Address: $6F790000. Process Project13.exe (13088) Module Load: d3d10_1.dll. No Debug Info. Base Address: $6B4A0000. Process Project13.exe (13088) Module Load: d3d10_1core.dll. No Debug Info. Base Address: $69450000. Process Project13.exe (13088) Module Unload: d3d10_1core.dll. Process Project13.exe (13088) Module Unload: d3d10_1.dll. Process Project13.exe (13088) Module Load: d3d10_1.dll. No Debug Info. Base Address: $6B4A0000. Process Project13.exe (13088) Module Load: d3d10_1core.dll. No Debug Info. Base Address: $69450000. Process Project13.exe (13088) Module Load: ResourcePolicyClient.dll. No Debug Info. Base Address: $6D230000. Process Project13.exe (13088) Module Unload: ResourcePolicyClient.dll. Process Project13.exe (13088) Module Load: igd10iumd32.dll. No Debug Info. Base Address: $5C3A0000. Process Project13.exe (13088) Module Load: ncrypt.dll. No Debug Info. Base Address: $6B860000. Process Project13.exe (13088) Module Load: NTASN1.dll. No Debug Info. Base Address: $6B830000. Process Project13.exe (13088) Module Load: igdusc32.dll. No Debug Info. Base Address: $5ECD0000. Process Project13.exe (13088) Module Unload: igdusc32.dll. Process Project13.exe (13088) Module Unload: NTASN1.dll. Process Project13.exe (13088) Module Unload: ncrypt.dll. Process Project13.exe (13088) Module Unload: igd10iumd32.dll. Process Project13.exe (13088) Module Load: igd10iumd32.dll. No Debug Info. Base Address: $5C3A0000. Process Project13.exe (13088) Module Load: ncrypt.dll. No Debug Info. Base Address: $6B860000. Process Project13.exe (13088) Module Load: NTASN1.dll. No Debug Info. Base Address: $6B830000. Process Project13.exe (13088) Module Load: igdusc32.dll. No Debug Info. Base Address: $5ECD0000. Process Project13.exe (13088) Module Load: d2d1.dll. No Debug Info. Base Address: $51D40000. Process Project13.exe (13088) Module Load: CRYPT32.dll. No Debug Info. Base Address: $73EE0000. Process Project13.exe (13088) Module Load: MSASN1.dll. No Debug Info. Base Address: $74390000. Process Project13.exe (13088) Module Load: DWrite.dll. No Debug Info. Base Address: $51AF0000. Process Project13.exe (13088) Module Load: WindowsCodecs.dll. No Debug Info. Base Address: $699C0000. Process Project13.exe (13088)

Notice, again, this is not specific to Delphi 10.2 Tokyo or Delphi 10.1 Berlin, but the same applies to the XE series and even classic versions of the product. The issue is caused by a change at the operating system level.

If you are a developer using RAD Studio, we recommend holding off moving to Windows 10 Creators Update on your developer machines, but this is clearly not a solution, also also prevents you from experimenting with the latest version of Windows.

First Solution: Embarcadero to Fix the Linker

Given the issue is how runtime packages are managed by the operating system, the ultimate solutions can come only from two player: Embarcadero or Microsoft. In fact, it is coming from both sides.

On the Embarcadero side, our R&D team has worked on changing the linker in 10.2 Tokyo, so that it produces a single import table with all required entries. The problem is if we just release a new linker, all existing package libraries will still misbehave. So we need to update a fairly large portion of the product, something more commonly done in an Update (or new Release) than via a hot fix. This is by no mean a final decision and R&D and PM are weighing in the alternatives. Now, what about older version of Delphi? Given the effect on packages (from us and third parties) all requiring to be recompiled, this is a fairly difficult scenario to address for past versions of RAD Studio.

Second Solution: Microsoft to Fix the Loader

The second solution would be to Microsoft to address the issue wih the loaded, keep the optimized parallel loading but taking into account the scenario of Delphi packages (which, in fact, happens also with a handful of platform libraries, even if to a more limited extent). Now, we are very happy to share the fact that we have engaged with Microsoft on the issue and they have been very fast to tackle it. The latest 16215 "Insider Build" of Windows 10 Fall Creators Update (https://blogs.windows.com/windowsexperience/2017/06/08/announcing-windows-10-insider-preview-build-16215-pc-build-15222-mobile) addresses the issue. As you can see, using the RTM version of 10.2 Tokyo the FMX library is loaded twice. Still not exactly as it used to work, but not really causing any actual problem:

This is the complete event log as you start debugging a Windows FireMonkey application with runtime packages on build 16215. Lines related with Delphi packages are in bold:

Thread Start: Thread ID: 208. Process Project3.exe (6184) Process Start: C:\Users\Marco\Documents\Embarcadero\Studio\Projects\Win32\Debug\Project3.exe. Base Address: $00400000. Process Project3.exe (6184) Module Load: Project3.exe. Has Debug Info. Base Address: $00400000. Process Project3.exe (6184) Module Load: ntdll.dll. No Debug Info. Base Address: $76FA0000. Process Project3.exe (6184) Module Load: KERNEL32.dll. No Debug Info. Base Address: $74360000. Process Project3.exe (6184) Module Unload: KERNEL32.dll. Process Project3.exe (6184) Module Load: KERNEL32.dll. No Debug Info. Base Address: $74360000. Process Project3.exe (6184) Module Load: KERNELBASE.dll. No Debug Info. Base Address: $76DD0000. Process Project3.exe (6184) Module Load: rtl250.bpl. Has Debug Info. Base Address: $50050000. Process Project3.exe (6184) Module Load: OLEAUT32.dll. No Debug Info. Base Address: $74EA0000. Process Project3.exe (6184) Module Load: msvcp_win.dll. No Debug Info. Base Address: $76C20000. Process Project3.exe (6184) Module Load: ucrtbase.dll. No Debug Info. Base Address: $76B00000. Process Project3.exe (6184) Module Load: combase.dll. No Debug Info. Base Address: $76680000. Process Project3.exe (6184) Module Load: RPCRT4.dll. No Debug Info. Base Address: $74F40000. Process Project3.exe (6184) Module Load: SspiCli.dll. No Debug Info. Base Address: $739F0000. Process Project3.exe (6184) Module Load: CRYPTBASE.dll. No Debug Info. Base Address: $739E0000. Process Project3.exe (6184) Module Load: bcryptPrimitives.dll. No Debug Info. Base Address: $74580000. Process Project3.exe (6184) Module Load: SECHOST.dll. No Debug Info. Base Address: $746A0000. Process Project3.exe (6184) Module Load: ADVAPI32.dll. No Debug Info. Base Address: $76D50000. Process Project3.exe (6184) Module Load: msvcrt.dll. No Debug Info. Base Address: $73D00000. Process Project3.exe (6184) Module Load: USER32.dll. No Debug Info. Base Address: $764E0000. Process Project3.exe (6184) Module Load: win32u.dll. No Debug Info. Base Address: $73A10000. Process Project3.exe (6184) Module Load: GDI32.dll. No Debug Info. Base Address: $74660000. Process Project3.exe (6184) Module Load: gdi32full.dll. No Debug Info. Base Address: $73AC0000. Process Project3.exe (6184) Module Load: imagehlp.dll. No Debug Info. Base Address: $745E0000. Process Project3.exe (6184) Module Load: SHLWAPI.dll. No Debug Info. Base Address: $76CF0000. Process Project3.exe (6184) Module Load: ole32.dll. No Debug Info. Base Address: $74480000. Process Project3.exe (6184) Module Load: WS2_32.dll. No Debug Info. Base Address: $73C90000. Process Project3.exe (6184) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02B40000. Process Project3.exe (6184) Module Unload: fmx250.bpl. Process Project3.exe (6184) Module Load: VERSION.dll. No Debug Info. Base Address: $73850000. Process Project3.exe (6184) Module Load: MPR.dll. No Debug Info. Base Address: $6FC30000. Process Project3.exe (6184) Module Load: SHFOLDER.dll. No Debug Info. Base Address: $6FC60000. Process Project3.exe (6184) Module Load: SHELL32.dll. No Debug Info. Base Address: $75100000. Process Project3.exe (6184) Module Load: CFGMGR32.dll. No Debug Info. Base Address: $74CC0000. Process Project3.exe (6184) Module Load: SHCORE.dll. No Debug Info. Base Address: $75010000. Process Project3.exe (6184) Module Load: Windows.Storage.dll. No Debug Info. Base Address: $74700000. Process Project3.exe (6184) Module Load: AppCore.dll. No Debug Info. Base Address: $746F0000. Process Project3.exe (6184) Module Load: POWRPROF.dll. No Debug Info. Base Address: $74430000. Process Project3.exe (6184) Module Load: profapi.dll. No Debug Info. Base Address: $76660000. Process Project3.exe (6184) Module Load: NETAPI32.dll. No Debug Info. Base Address: $6EA80000. Process Project3.exe (6184) Module Load: WINHTTP.dll. No Debug Info. Base Address: $70F70000. Process Project3.exe (6184) Thread Start: Thread ID: 6828. Process Project3.exe (6184) Module Load: WSOCK32.dll. No Debug Info. Base Address: $70D50000. Process Project3.exe (6184) Module Load: OLEACC.dll. No Debug Info. Base Address: $6FB20000. Process Project3.exe (6184) Module Load: OPENGL32.dll. No Debug Info. Base Address: $6C8D0000. Process Project3.exe (6184) Thread Start: Thread ID: 6456. Process Project3.exe (6184) Module Load: GLU32.dll. No Debug Info. Base Address: $6FAC0000. Process Project3.exe (6184) Module Load: netutils.dll. No Debug Info. Base Address: $6E4A0000. Process Project3.exe (6184) Module Load: fmx250.bpl. Has Debug Info. Base Address: $02C40000. Process Project3.exe (6184) Module Load: COMDLG32.dll. No Debug Info. Base Address: $76A10000. Process Project3.exe (6184) Module Load: COMCTL32.dll. No Debug Info. Base Address: $70D60000. Process Project3.exe (6184) Module Load: urlmon.dll. No Debug Info. Base Address: $6FF00000. Process Project3.exe (6184) Module Load: WINMM.dll. No Debug Info. Base Address: $6CEC0000. Process Project3.exe (6184) Module Load: WINSPOOL.DRV. No Debug Info. Base Address: $6C860000. Process Project3.exe (6184) Module Load: d3d9.dll. No Debug Info. Base Address: $6B960000. Process Project3.exe (6184) Module Load: iertutil.dll. No Debug Info. Base Address: $6FCE0000. Process Project3.exe (6184) Thread Start: Thread ID: 7136. Process Project3.exe (6184) Module Load: WINMMBASE.dll. No Debug Info. Base Address: $6CE90000. Process Project3.exe (6184) Module Load: dwmapi.dll. No Debug Info. Base Address: $6F4C0000. Process Project3.exe (6184) Module Load: bcrypt.dll. No Debug Info. Base Address: $71C50000. Process Project3.exe (6184) Module Load: IMM32.dll. No Debug Info. Base Address: $74E70000. Process Project3.exe (6184) Thread Start: Thread ID: 4232. Process Project3.exe (6184) Module Load: UxTheme.dll. No Debug Info. Base Address: $70620000. Process Project3.exe (6184) Module Load: MSCTF.dll. No Debug Info. Base Address: $768C0000. Process Project3.exe (6184) Module Load: gdiplus.dll. No Debug Info. Base Address: $70830000. Process Project3.exe (6184) Thread Start: Thread ID: 3124. Process Project3.exe (6184) Module Load: TextInputFramework.dll. No Debug Info. Base Address: $6C7A0000. Process Project3.exe (6184) Module Load: CoreUIComponents.dll. No Debug Info. Base Address: $6C570000. Process Project3.exe (6184) Module Load: CoreMessaging.dll. No Debug Info. Base Address: $6C4D0000. Process Project3.exe (6184) Module Load: NTMARTA.dll. No Debug Info. Base Address: $705F0000. Process Project3.exe (6184) Module Load: WinTypes.dll. No Debug Info. Base Address: $6C400000. Process Project3.exe (6184) Module Load: WinTypes.dll. No Debug Info. Base Address: $05960000. Process Project3.exe (6184) Module Unload: WinTypes.dll. Process Project3.exe (6184) Thread Start: Thread ID: 3616. Process Project3.exe (6184) Thread Start: Thread ID: 5984. Process Project3.exe (6184) Module Load: CLBCatQ.DLL. No Debug Info. Base Address: $73A30000. Process Project3.exe (6184) Module Load: DataExchange.dll. No Debug Info. Base Address: $69B60000. Process Project3.exe (6184) Module Load: d3d11.dll. No Debug Info. Base Address: $69910000. Process Project3.exe (6184) Module Load: dcomp.dll. No Debug Info. Base Address: $69800000. Process Project3.exe (6184) Module Load: dxgi.dll. No Debug Info. Base Address: $69770000. Process Project3.exe (6184) Module Load: twinapi.appcore.dll. No Debug Info. Base Address: $6CBF0000. Process Project3.exe (6184) Module Load: RMCLIENT.dll. No Debug Info. Base Address: $6CBD0000. Process Project3.exe (6184) Module Load: d3d10_1.dll. No Debug Info. Base Address: $63B40000. Process Project3.exe (6184) Module Load: d3d10_1core.dll. No Debug Info. Base Address: $63AE0000. Process Project3.exe (6184) Module Unload: d3d10_1core.dll. Process Project3.exe (6184) Module Unload: d3d10_1.dll. Process Project3.exe (6184) Module Load: d3d10_1.dll. No Debug Info. Base Address: $63B40000. Process Project3.exe (6184) Module Load: d3d10_1core.dll. No Debug Info. Base Address: $63AE0000. Process Project3.exe (6184) Module Load: ResourcePolicyClient.dll. No Debug Info. Base Address: $63A40000. Process Project3.exe (6184) Module Unload: ResourcePolicyClient.dll. Process Project3.exe (6184) Module Load: vm3dum10.exe. No Debug Info. Base Address: $63AA0000. Process Project3.exe (6184) Module Unload: vm3dum10.exe. Process Project3.exe (6184) Module Load: vm3dum10.exe. No Debug Info. Base Address: $63AA0000. Process Project3.exe (6184) Module Unload: vm3dum10.exe. Process Project3.exe (6184) Module Load: vm3dum10.exe. No Debug Info. Base Address: $63AA0000. Process Project3.exe (6184) Module Unload: vm3dum10.exe. Process Project3.exe (6184) Module Load: vm3dum10.exe. No Debug Info. Base Address: $63AA0000. Process Project3.exe (6184) Module Load: d2d1.dll. No Debug Info. Base Address: $65120000. Process Project3.exe (6184) Module Load: CRYPT32.dll. No Debug Info. Base Address: $73DC0000. Process Project3.exe (6184) Module Load: MSASN1.dll. No Debug Info. Base Address: $75000000. Process Project3.exe (6184) Module Load: DWrite.dll. No Debug Info. Base Address: $64EA0000. Process Project3.exe (6184) Module Load: WindowsCodecs.dll. No Debug Info. Base Address: $6C290000. Process Project3.exe (6184)

Perfect solution, right? Well, it does fix the issue for current and old versions of Delphi, but unfortunately not immediately. It is true Microsoft fixed the problem, but if the solution will show only in the next major release of the operating system, still several months away (Fall Creators Update), what happens to developers and users on Creators Update? We still hope and have been asking Microsoft for a fix also for the current version of Windows, and you can certainly join us in this request.

Some Temporary Workarounds

Given the two solutions above are coming but don't address the issue immediately and for all developers, it is important to focus also on a few available workarounds.

A first one is for debugging. Given the issue happens when loading the application, running it standalone and later attaching the debugger to it seems to work for most developers. Clearly, it is an annoyance, but clearly much better than waiting a lot of time or see the debugger get stuck.

A second workaround (for end users) is to consider one of the tools that fix-up and cleanup PE executables, including reorganizing the import/export tables. There are many such tools. One of them is http://www.ntcore.com/exsuite.php.

There are of course other more extreme options, like staying on Windows 10 Anniversary edition, jumping to the latest Insider release or moving from the use of runtime packages to releasing a single executable.

Conclusion

We are working on releasing our linker solution for the issue, we'll keep pushing Microsoft for a broad and more immediate fix, and we are also evaluating alternative workarounds for the short term. Stay tuned for more information.

Categories: News, Blogs, and Tips

Speaking at the Italian Delphi Day 2017 Conference Next Week

Fri, 06/09/2017 - 02:44

Next Wednesday, June 14th, I'll give a keynote at the Delphi Day conference in Piacenza, Italy, which is also the city where I live (short trip, for sure). This is a conference I used to organize in the past and that Paolo Rossi and Wintech Italia are continuing to put together, with a fairly impressive group of speakers, Embarcadero MVPs, present and former members of Delphi R&D team.

I'll give a keynote, probably not too technical, and I'm likley going to give it in Italian. But I'll be around the entire day, and likley also stop by the day before (some of the pre-conference seminars are very interesting!). For all information and to sign up (the conference cost is nominal, just pays for the food) see:

http://www.delphiday.it/

I hope to see a lot of Italian Delphi developers there, as usual.

Categories: News, Blogs, and Tips

Webinar Tomorrow: Understanding Automatic Reference Counting

Wed, 05/31/2017 - 05:51

Tomorrow, June 1st, I'll give a webinar (at 3 different time slots) focused on automatic reference counting memory model in Delphi.. This is the summary:

Automatic Reference Counting is the memory management system used by Strings & Interfaces on all platforms, and all objects on Linux and Mobile. Unlike Garbage Collection, ARC is purely determisitic and keeps the developer in control. Join Delphi Product Manager Marco Cantu for this deep dive into Automatic Reference Counting.

Yuo can register for any of thr 3 times zones at https://register.gotowebinar.com/rt/65694002494075138

I'll do live Q&A at the end. See you onoline tomorrow.

Categories: News, Blogs, and Tips

Delphi Linux Blogs of the (Week) Month #52

Tue, 05/30/2017 - 02:26

Given I haven't made one of these monthly posts in some time, I have a rather large collection of relevant blogs psots and links, and so I decided to split the blog post in two. This is focused in full on Delphi Linux, a following one will be general in scope.

Blog Posts

Creating a Linux Daemon (service) in Delphi by Craig Chapman: http://chapmanworld.com/2017/04/05/creating-a-linux-daemon-service-in-delphi/

Daemonizing a WebBroker Application on Linux by Craig Chapman: https://community.embarcadero.com/blogs/entry/daemonizing-a-webbroker-application-on-linux

Calling Linux Commands from Delphi by Craig Chapman : https://community.embarcadero.com/blogs/entry/calling-linux-commands-from-delphi

Easy install SQL Server driver in Ubuntu by Luis Navarro: https://community.embarcadero.com/blogs/entry/easy-install-sql-server-driver-in-ubuntu

Importing third-party Linux libraries on Delphi 10.2 Tokyo by Allen Drennan: https://blog.grijjy.com/2017/04/06/importing-third-party-linux-libraries-on-delphi-10-2-tokyo/

Try Delphi on Amazon Linux by Haruyuki Mohri: https://community.embarcadero.com/blogs/entry/try-delphi-on-amazon-linux/

Running Delphi Applications on Linux with Docker by Juan Antonio Ruzafa: https://yeiei.net/en/running-delphi-applications-on-linux-with-docker/

How to make Linux platform available in existent console applications: https://blog.andreamagni.eu/2017/03/how-to-make-linux-platform-available-in-existent-console-applications/

Third Party Tools

Getting Started with FmxLinux: https://www.fmxlinux.com/guide.html

Few more features on FM for Linux: https://plus.google.com/u/0/118397897778295642304/posts/dDn1SREATEN?cfem=1

All for Now

This is all for now... hoping to get back to a more consistent schedule.

Categories: News, Blogs, and Tips

Centennial Bridge: BUILD, Creators Update, Windows 10 S and More

Mon, 05/29/2017 - 07:28

As you probably know, RAD Studio 10.1 Berlin Update 2 last fall was the first IDE to offer native and direct support for the Windows Desktop Bridge (also known as Centennial Bridge). In short, using the bridge you can create Universal Windows Platform (UWP) applications that can be distributed using Microsoft Windows 10 Store. RAD Studio let's you set a few parameters and generate an APPX file ready for the store. Given I already blogged multiple times on the topic, I won't re-iterate all of the details here.

There are some interesting news from Microsoft. The summary is the Desktop Bridge is considered a successful project by the company and they plan to keep pushing it as the best approach to bring existing Windows applications to the Store.

Windows 10 S

The first interesting announcement was "Windows 10 S". See the FAQ at https://support.microsoft.com/en-us/help/4020089/windows-10-s-faq.

This is a "safe" version of Windows 10 aimed to the consumer market and intended to allow running only applications downloaded from the Windows Store, excluding old traditional apps downloaded directly to the PC. This is potentially a huge change, although it has to be seen if Windows user will go for it. In any case, Desktop Bridge applications will be included in the support, so all of your VCL and FireMonkey applications could still be used after doing some fairly minimal migration (in most cases).

Centennial at BUILD

The second interesting announcement came at the BUILD conference, where Microsoft had many sessions covering the Desktop Bridge. The main one (https://developer.microsoft.com/en-us/windows/projects/events/build/2017/ bring-desktop-apps-to-uwp-and-the-windows-store) focused on new features in Creators Update and general status and plans for the Centennial bridge. For example, Microsoft ahs extended the support to shell extensions, but only for out-of-process scenarios. The (Microsoft) speaker listed RAD Studio as one of the tools supporting the bridge:

Notice the in the session they did demonstrate deployment of a bridge application using Visual Studio, but apparently the steps are so complex they decided to skip the actual demo -- compared to a Delphi demo of APPX generation, that takes seconds!

The other part of the session I'm still a bit unclear is why you'd really need to come up with the complex architecture below, when in most cases a native application (like one built in Delphi) can leverage most of the WinRT APIs like notifications in a much more simple way. While having two applications inter-operating makes sense in some cases, in most it seems fairly overkill.

The Business Store

The other relevant initiative related with the Desktop Bridge is the ability for larger companies to create their own "business store", again using APPX applications. In other words, the same binary you could upload to the public store you can also provide to a company for internal distribution. This makes sense for specific applications, includes license tracking, and because a simpler way to install and update an application on a large number of systems. The same applies to education institutions.

More information at https://docs.microsoft.com/en-us/microsoft-store/windows-store-for-business-overview. Again, most Win32 and Win64 applications built with RAD Studio should be ready to be converted to the new format, and our IDE can help in the process.

Categories: News, Blogs, and Tips

My Visit to Australia and ADUG Symposium

Fri, 05/26/2017 - 09:33

Last week I was in Australia for the ADUG Symposium, invited by the ADUG committee. For more information about this user groups, which is one of the largest and best organized in the Delphi community, refer to https://www.adug.org.au/.

The event was nice and well organized, I ended up talking over 3 hours each day, but it was great, and we had a lot of interactions around the status of Delphi and its roadmap. The focus of my sessions was Windows 10 and the Delphi language, plus some product status. Overall there wer about 100 Delphi developers among the two events, which was very nice.

Over the week I spent time in Sydney (to visit a customer and at Code Partners office, the local Embarcadero partner), in Brisbane (another customer and the first conference), and in Melbourne (for the second conference and a meeting with the user group committee). The final weekend I had some free time in Melbourne, I used to see around and meet a couple of friends I had not seen for a long time!

Pictures and Pictures

Here are some pictures taken in the various cities I visited, more or less in chronological order. First is the view from the office of a customer I visited:

Yes, you can see the Opera House in the back. But later in the day I has some time and went there:

Following day, we got to Brisbane, where we had the first conference:

Same day we flew to Melbourne, for the next day (larger) event -- Malcolm is speaking here:

Next day I was invited to a meeting of the user group committee, to offer suggestions for events, topics, and have some chat (and some good food offered by one of the members at this house):

The same day, we got back to the city of Melbourne and over Eureka tower (the tallest tower in the Southern atmosphere). This was the view of the downtown area from the tower:

The last day I still had some fre time and ended up looking for penguins out "in the wild"... and I found some near the city, in a small protected area. It was dark, so not great pictures:

That's all. It was a nice trip... looking forward for more Delphi developers to visit around the world!

Categories: News, Blogs, and Tips

RAD Studio May 2017 Roadmap and Commentary

Thu, 05/18/2017 - 19:20

Over the last week, Embarcadero published a new official RAD Studio roadmap and an additional blog post with Product Manager comments and further information (including a section of mine).

Here are the links, in case you missed one of those:

https://community.embarcadero.com/article/news/16519-rad-studio-roadmap-may-2018

https://community.embarcadero.com/blogs/entry/may-2017-roadmap-commentary-from-product-management

Categories: News, Blogs, and Tips

New FireDAC Database Status Page

Wed, 05/10/2017 - 03:41

Since last year, beside our regular docwiki with the extensive product documentation (it has over a quarter million pages!) Embarcadero has a platforms status wiki indicating with versions of operating systems are supported -- and how that changes over different versions of RAD Studio. The page includes also information on just released operating system updates and fixes or workarounds for those.

Now we have added a new page listing the versions of the RDMBS FireDAC officially supports in different versions of RAD Studio. We plan adding similar workarounds and additional information as it becomes available, although in most cases newer database versions work fine with drivers tested for previous versions. The new page is at:

http://docwiki.embarcadero.com/Status/en/FireDAC_Database_Support

Categories: News, Blogs, and Tips

Speaking at ADUG 2017 Symposium Next Week (and Visiting Australia)

Tue, 05/09/2017 - 00:28

Next week on Thursday and Friday I'll be speaking at the ADUG Symposium in Brisbane and Melbourne. The event information is at http://www.adug.org.au/meetings/symposiums/2017-symposium/. I'll give two sessions, one focused on the Delphi language and one on its Windows support (including WinRT and the Desktop Bridge). I'll also give a keynote on the status of Delphi. There are other sessions for a day packed of content. If you live in the area, you should not miss the event...

Before the events, I'll spend also a couple of days in Sydney with our local partner (and friend) Malcolm Groves, meeting customers and discussing the product plans. If you can come to the events, I'll be happy to have a chat. If you cannot attent and you are in the area, we can still arrange something. Trying to get the most of the long trip!

See you down under...

Categories: News, Blogs, and Tips

Delphi Web Razor Scripting Webinar on Thursday

Tue, 05/02/2017 - 06:20

Thursday May 4th (that is, in 2 days) I'll give a webinar on Razor Scripting with Delphi WebBroker, introducing the open source library I wrote (with help of a few others). The same day is also Star Wars Day.

I already wrote a bit about the project in a recent blog post (http://blog.marcocantu.com/blog/2017-april-delphi-relax-linux.html)

In this webinar I'll cover the foundations of the Delphi Razor scripting language, see how it can be used as a drop-in replacement of PageProducer, see how it can handle complex dynamic website, and showcase a couple of real world examples based on Bootstrap. I'll show demos running on Windows and Linux servers.

Register now for this webinar that is coming on Thursday, May 4, 2017 on https://attendee.gotowebinar.com/rt/3514960935272236290. The weboanr will be given at 3 time zones, 8:00 AM CDT (3PM Europe) - 1:00 PM CDT (8PM Europe) - 8:00 PM CDT (morning of the 5th in APAC region).

Categories: News, Blogs, and Tips

Delphi Relax Web Scripting on Linux

Fri, 04/21/2017 - 02:47

I've finished porting my Delphi Relax web scripting library to RAD Studio 10.2, adding Linux support. I also added a new set of unit tests. The library is available at https://github.com/marcocantu/DelphiRazor/ and we are considering adding it to GetIt as well. In two weeks I'm going to host a webinar covering the library, covering different scenarios of modern web development. Stay tuned for that.

In this blog post I want to focus on a 5 minutes demo showing Linux support. I'll probably expand the demo for the webinar. First of all, what is Delphi Razor? It is a web scripting notation heavily inspired by ASP.NET Razor notation. The Delphi tie in comes form the ability of the application to exposes objects, list of objects and datasets to the web page processing engine, by means of RTTI.

To build a simple database-driven the demo, I've created a console-dames WebBroker application, I've dropped an FDMemTable and an FDStanStorageBinLink component to the web module. This will allow me to load data from a local file (local on the web server). Next I've dropped an RlxRazorProcessor component and associated it with a local HTML file, by setting the InputFilename property to "./table.html".

I've also added a custom action to the web module, and added an event handler for it. You can see the design time components below:

Next, I've create a fairly trivial HTML file for the data. Notice this can be any HTML, based on Bootstrap (like I've done for other Delphi Razor projects) and integrating any JavaScript client library. This one is really a bare bone HTML file:

Employees    
    @foreach (var emp in employee) {  
  • @emp.FirstName @emp.LastName (@emp.PhoneExt)
  • }

What this does is iterate over the element called "employee" (which happens to ba a database table) and replicate the HTML within the curly braces for each record, creating a line item for each entry with the value of three fields. The for loop defines a local loop variable "emp" that is used in the loop to refer to the record. Drop that segment of HTML with script into a nice looking HTML page and you are in business.

The last bit is adding the code to load the database table and associate it with the name "employee" used in the script. Here is the complete code of the web action event handler:

procedure TWebModule2.WebModule2WebActionItem1Action(Sender: TObject; Request: TWebRequest; Response: TWebResponse; var Handled: Boolean); var filename: string; begin filename := './employee.fds'; if not FDMemTable1.Active then begin FDMemTable1.LoadFromFile(filename); FDMemTable1.Open; end; RlxRazorProcessor1.AddToDictionary('employee', FDMemTable1, False); Response.Content := RlxRazorProcessor1.Content; end;

The binding of the internal data with the script happens by adding an entry in the processor dictionary. By copying its content to the output, the last line of the code will trigger the script processor.

Now compile and deploy to Linux, start it (like in the image below):

You'll be able to see the ugly HTML output in your browser:

Stay tuned for more information about the Delphi Razor webinar.

 

Categories: News, Blogs, and Tips

Linux ClientDataSet libmidas.so Now Available

Wed, 04/19/2017 - 01:05

To use the ClientDataSet component on Linux Delphi applications you need to distribute the libmidas.so library, the Linux equivalent of midas.dll. We failed to deliver it as part of the 10.2 Tokyo release, and it has been made separately available at:

http://cc.embarcadero.com/item/30765

The additional file belongs to the redistributable list and you should also copy it to C:\Program Files (x86)\Embarcadero\Studio\19.0\binlinux64 -- ultimately it doesn't matter much.

You can add that file to the application deployment, so that it will be copy to the Linux box via PAServer, or just copy it manually to the Linux box. Of course, you need to do so only if you want to use the ClientDataSet component in a Linux application. While we recommend the FDMemTable component as a replacement, if you have existing code based on ClientDataSet you might want to use that older solution.

Categories: News, Blogs, and Tips

RAD Studio 2017 Themes and Developers Survey

Wed, 04/12/2017 - 01:45

With 10.2 Tokyo shipping last month, we at Embarcadero have renewed our focus to future plans, while R&D is still busy with fixes, updates, and some additional Tokyo features (mostly C++ for Linux).

Themes for 2017/2018

The RAD Studio PM team (that is myself, Sarina, and David)  has published a summary of the themes for this and the next year. You can find the document at https://community.embarcadero.com/blogs/entry/updated-roadmap-coming-soon-annual-developer-survey. There isn't much to add to what's written there. The three key Delphi related items are:

  • Expanded native controls support for multi-device development
  • Enhanced Windows 10 platform features
  • Delphi Language Features
RAD Studio 2017 Developer Survey

We have also opened our yearly developers survey (available until April 25th) to our customers asking input for our future plans (for example asking for details on each of the 3 items above) and validation of some ideas we are exploring (in many existing and new areas). We know that a 97 questions survey can be intimidating (although a few questions are fairly easy and fast to answer) but this survey is the largest we do every year and we spend a lot of time examining the information our customers give us. The direct link is:

https://www.surveymonkey.com/r/2017RADStudioSurvey

So I'm asking you personally to take the survey , but also to invite others (active Delphi or C++Builder developers, but also developers who moved to other tools and could tell us what would make them consider coming back, or just why they are not using RAD Studio any more and what they don't like), and also software developers at large who have never used our tools extensively but are interest to tell us what they like in a developer tools. If you can help us reach more developers, it will help us shape the future of the product for a broader community.

Thanks for your help.

Categories: News, Blogs, and Tips

Windows 10 Creators Update and Delphi 10.2

Thu, 04/06/2017 - 07:03
Creators Update Developers Information

Today Microsoft shipped Windows 10 Creators Update. You can read some of the key developers information in many places, including:

https://docs.microsoft.com/en-us/windows/uwp/whats-new/windows-10-version-1703

https://blogs.windows.com/buildingapps/2017/04/05/windows-10-creators-update-creators-update-sdk-released

https://blogs.windows.com/buildingapps/2017/03/31/desktop-bridge-creators-update/

The most relevant change for VCL developers is the fact that High-DPI support has further changes, something we are still assessing internally. There are some interesting new APIs like "Payment Request API". Also notice the additional options for Windows Desktop Bridge apps, ranging from resource explorer handlers to COM servers, 

Installing Windows 10 Creators Update

I upgraded my main Windows 10 PC to the new release and the installed it and the process was smooth. Notice that if you are not offered an update, you can still download an application to do it sooner. Very smooth process, but not slow.

Delphi On Creators Update

I had RAD Studio 10.2 already installed on the PC, so all I have to do it start it and build some VCL and FireMonkey applications. There is no significant difference, and everything worked fairly smoothly. Including UWP applications installed using the Windows Desktop Bridge. No surprise, also because I had already installed the RTM version and previously some beta versions of Tokyo on a VM with recent builds of Windows.

And Delphi Linux in the Ubuntu / Bash Shell

The last test I did was installing also the Ubuntu Bash shell part of Windows 10 (even if still in beta). This was fairly smooth. In fact I was chatting with Matthias, who also blogged about it earlier today (in German) at https://community.embarcadero.com/blogs/entry/bash-on-ubuntu-on-windows-1703-creators-update-und-delphi.

Given the bash shell has access to your file system, you can easily compile an application in Delphi for Linux and run it on the bash shell right away. This is not a VM, it runs in the native computer. Below you can see an image related with the installation and one with a simple application in the IDE and running in bash on Windows:

The missing element is PAServer (and the version of GDB it uses) still has issues running on the bash shell, something we are loooking forwrd to fix and support. Stay tuned.

Categories: News, Blogs, and Tips

Deploying Files (and PAServer) to Linux via WinSCP

Thu, 04/06/2017 - 00:42

I'm a longtime fan and user of WinSCP (https://winscp.net/eng/index.php). This is a nice free utility to do SCP (Secure Copy via SSH) to Linux boxes, manage files, remotely, and even perform a variety of file system operations on remove Linux boxes. All from a nice and familiar Windows UI, with local folders and remote ones side by side. This is an example:

If you use this tool to deploy PAServer to your Linux box, you can also use it to un-compress and expand the tar.gz file, using a simple command in the popup menu of the remote file:

I've created a video showing these steps, but also the following operations need to connect the IDe to PAServer and import the Linux SDK. It is available on YouTube at https://www.youtube.com/watch?v=l-nnF5o3bhU or below:

 

PS. Just FYI, WinSCP is mostly written in C++, and built with a familair tool (http://winscp.cvs.sourceforge.net/viewvc/winscp/winscp3/readme.txt?view=markup): "To build WinSCP you need: Embarcadero C++ Builder XE6 Professional"

Categories: News, Blogs, and Tips