build google breakpad stackwalk - google-breakpad

I can build the google breakpad client, the stackwalker can convert the dump to human readable txt file. But there is no gyp file to make vs2008 solution. Does anyone know how to build the stackwalker on windows. Thanks

The stackwalker tool doesn't build using Visual C++ currently. You can build it with Cygwin if you install that whole toolchain. If you'd find it useful there's a prebuilt Cygwin minidump_stackwalk binary that Mozilla uses on our build machines.
Along with the matching Cygwin support DLLs:
cygwin1.dll,
cygstdc++-6.dll,
cyggcc_s-1.dll.
It's slightly out-of-date but should work fine.
Also note that you should be able to load Windows minidump files directly into a debugger on Windows, like Visual C++ or WinDBG.

Related

azuresphere real-time applications -- generating .image files from compatible, pre-built ELF (.out) files

i have a separate build-flow that can produce .out files for the MT3620/M4 core using the same gcc-arm compiler.... for reasons beyond the scope of this question, it's not practical for me to migrate this build-flow into cmake....
once i generate the .out file, my thinking was to simply envelop it within a project structure identical to the samples -- with an conforming app_manifest.json file.... from here, i could effectively run just the final step of the cmake build -- which generates the image package....
before i go down this path, is there anything obvious i'm missing here????
As of today you will need to decide to install Azure Sphere SDK Preview for Visual Studio or Azure Sphere SDK Preview for Windows (You cannot install both SDKs on the same PC.)
To develop applications, however, you need to set up your development environment and possibly install additional tools. The Azure Sphere SDK for Windows supports development with the CLI only. If you've installed this version of the SDK, you'll need to install CMake and Ninja on your PC.
If you plan to develop real-time capable applications (RTApps), you might need to install a compiler for the embedded processor and set up hardware to display output from the app.
Both Quickstarts "Build an RTapp on cmd" and "Build an RTApp with Visual Studio" require that you use CMake at some stage and those are the supported methods.
Update: New documentation improvements will be done soon to address the option of using a different build system to cmake and "yes" it should work as you suggest.

How to build TensorFlow C++ library on Windows XP 32-bit

I'm attempting to build TensorFlow's C++ library for Windows XP. While I've been able to build and use it on Windows 10, 32-bit XP isn't working. The background: I'm working on a COM module that calls fuctions from tensorflow.dll. My build environment:
Visual Studio 2017 15.7
CMake 3.11.1
TensorFlow 1.8
Windows 10
The sequence I use to build tensorflow.dll is:
Open "x64_x86 Cross Tools Command Prompt for VS 2017"
Try to force the use of functions availablbe in Win XP: set CXXFLAGS=/D_WINVER=0x0501 /D_WIN32_WINNT=0x0501
Add Git to path: set PATH=%PATH%;C:\Program Files (x86)\Git\bin
Fix CMake file for converting *.proto files to *.pb.h files as described here.
Configure CMake: cmake .. -A Win32 -T v141_xp,host=x64 -DCMAKE_SYSTEM_VERSION=7.0 -DCMAKE_BUILD_TYPE=Release -DPYTHON_EXECUTABLE=C:\Users\williams\AppData\Local\Continuum\Anaconda3\envs\tensorflow\python.exe -Dtensorflow_BUILD_SHARED_LIB=ON -Dtensorflow_BUILD_PYTHON_BINDINGS=OFF -Dtensorflow_WIN_CPU_SIMD_OPTIONS="/arch:IA32"
Build: cmake --build . --target tensorflow --config Release -- /fileLogger /m:1 /p:CL_MPCount=1
The last step also involves some manual labour as the build process doesn't copy .lib files from the 3rd part dependencies to where they are needed. For whatever reason, a bunch of INSTALL projects never get run so I had to do that manually each time the build would fail while looking for a missing lib file. Once that was done, the build completed successfully.
Next I copy my COM module (a DLL) and the TensorFlow DLL over to a Windows XP virtual machine for testing and try to register the COM module, but get an error LoadLibrary("MyDLL.dll") - The specified procedure could not be found. I don't know what procedure it is looking for, so the best I can offer is that Dependency Walker highlights WS2_32.DLL and tells me it can't find inet_ntop and inet_pton.
Any suggestions on how to build TensorFlow so that it doesn't use these two functions?
P.S. suggestions of "Stop using XP, its old and no longer supported" don't help here. Upgrading to Windows 10 is an absolute last resort because of the disruption it would cause at the facility where this software will be tested.
Edit 1:
These two functions inet_pton and inet_ntop were only used in one file that forms part of Google Cloud Storage support in TensorFlow. The build process generated a tensorflow_static.lib in addition to tensorflow.dll. Linking against the static version and adding a few dependencies that aren't included in tensorflow_static.lib got rid of the code using inet_* functions.
My COM module still isn't working on Windows XP though because the file tensorflow\core\platform\windows\env.cc uses functions like CloseThreadpoolWork, submit SubmitThreadpoolWork, etc. that were only introduced in Windows Vista. It looks like I'll have to replace them with something else, as I don't see an alternative implementation in TensorFlow.
Additionally, I found that tensorflow\contrib\cmake\CMakeLists.txt forces _WIN32_WINNT=0x0A00 and that CXXFLAGS is the wrong environment variable to use. Changing it to CMAKE_CXX_FLAGS at least gets my macro definitions included, FWIW.
It is almost impossible to port tensorflow to windows xp, because:
TF's platform depedent code requires some Windows APIs later than winxp such as Thread Pool API. This would possibly bypassed by using third party thread pool libs.
The nsync, protobuf and eigen, which are core parts of TF, use C++11 thread_local, which makes them unable to run-time load as dll, see https://learn.microsoft.com/en-us/cpp/parallel/thread-local-storage-tls?view=vs-2017 for details. This later feature can theoretically be replaced by old windows TLS API, which requires many modifications on TF's core framework.
Anyway, if you really need the xp support, good luck with that.
In the end I gave up on this as simply being impossible. Even replacing the thread pool functions with something from Boost didn't help. If someone else manages to get this working, I'll gladly accept that as the answer, but so far this looks impossible.

Cmake to generate solution file machine independent

I tried to generate a solution file of GSL library for visual studio 2012 using cmake gui. I did that successfully and I build the library for my own computer. But when I tried to build the same solution file in my different computer, it gives me errors saying "C:/my other computer directory/xxx.vcxproj does not exist" . Is there any way that I can generate sln file which is machine independent.
CMake is not designed to be used in this way, and it is highly unlikely you will be able to use it in this way. CMake performs system introspection, storing this in the CMake cache, and uses full paths to most things. I would advise you to run CMake on each system, and prefer offering simple instructions to run CMake/cmake-gui on each machine.

How to build gstreamer-sharp with monodevelop/xamarin?

i'm developer of AudioCuesheetEditor, an application for editing audio cuesheets. The new Version should be able to play back sound, so I would like to use gstreamer as backend. I investigated a bit in gstreamer and found out, that I need to use version 1.x with gstreamer-sharp 0.99.x binding. No problem, downloaded gstreamer-sharp 0.99.0, opened the solution with monodevelop (on linux) or xamarin (on windows) and tried to build the dll, but that didn't work. I get the error "namespace Gst.GLib" not found.
I'm developing with xamarin/monodevelop and need to have a portable app (working with mono/.net).
Can anyone help me, get gstreamer-sharp build?
Thanks in advance!
gstreamer-sharp is currently not supported on Windows, however you can compile the managed parts on linux and compile the glue on Windows using Visual Studio:
Install gtk-sharp 3.0 from https://github.com/mono/gtk-sharp
Compile gstreamer-sharp using ./autogen.sh && make
Take the compiled glib-sharp and gstreamer-sharp binary and all .c files from sources/glue/
Download and install gstreamer binaries from http://gstreamer.freedesktop.org/data/pkg/windows/1.2.2/ and install the development and binary packages for the architecture you want to compile for. You can use gstreamer 1.0 or 1.2.
Use the Visual Studio template from the gstreamer-devel package and change the project type to library. Add the c files taken from the sources/glue folder and compile the glue library. The library should be called libgstreamersharpglue-1.0.0.dll
Put the managed parts together with the native symbols.
EDIT:
Compiling the glue is now easier on Windows! Someone set up a project which can compile the glue using Visual Studio on Windows. I have a fork which has binaries at https://github.com/xDarkice/libgstreamersharpglue
gstreamer-sharp uses autotools for its build system, you cannot build it with an IDE. Please do the autotools dance:
./autogen.sh --prefix=/the/prefix/where/you/want/to/install
make
sudo make install

How can I install MPFI library in Windows?

there!
I'd like to execute example program, Surface_reconstruction_points_3.
I think the program needs additionally 3rd library, MPFI.
So I downloaded the library from http://mpfi.gforge.inria.fr/.
And I unzipped it at proper folder and linked it to the system path.
After configurating the example program using cmake-gui,
I found some error message, 'Could NOT find MPFI (missing: MPFI_LIBRARIES)'.
How can I install MPFI library in Window using visual studio 2008?
Since MPFI is a GNU library, it is completely supported on Windows.
CGAL provides this third-party libraries inside its installation, but Windows has its own replacement.
I installed this correctly with Visual Studio, but you need to uncheck those third-party libraries so CGAL won't mess with the own windows replacements.
Maybe doing this kind of installation isn't working well for all the sample codes inside the installation, but it works fine for development. I used CGAL without those third-libraries for Voronoi and 2D and 3D triangulation and it works fine.
For a clean installation, delete all you installed previously, make sure the new installation isn't messing with the bad previous installation.
EDIT:
About not using those optional libraries for Windows, I just received a similar mail through the CGAL mailing list and these could be the steps for newer versions of CGAL (>4.2):
You have to comment 3 lines in the CMake machinery:
In CGAL-4.1/CMakeList.txt you have to comment:
#list (INSERT CGAL_ESSENTIAL_3RD_PARTY_LIBRARIES 0 GMP MPFR)
#hide_variable(CGAL_ESSENTIAL_3RD_PARTY_LIBRARIES)
In CGAL-4.1/cmake/modules/UseCGAL.cmake you have to comment:
#use_essential_libs()
On the other hand, you can search on internet for precompiled versions of MPFI. For instance, you can find precompiled GMP, MPFR and MPFI for Windows on http://vegas.loria.fr/rs/ .