How to compile a DirectX 11 app in MinGW - directx

I've looked, and I can't find any material relating to using Direct3d 10 or 11 with MinGW. What do I have to do to get things working? I'm getting errors in the header files supplied by the DX SDK.
And don't anyone even think of suggesting Visual Studio.

It seems that here it is explained how to get DX headers from SDK work with MinGW: http://d.hatena.ne.jp/tbk/20110115/1295080728
Use Google Translate to translate page to english.
Alternatively try using DirectX headers from mingw64 project from here: http://sourceforge.net/projects/mingw-w64/files/
You'll need "Download headers and CRT source v2.0.1 (r4623) (7.0 MB)". Or you can check out them directly from svn: https://mingw-w64.svn.sourceforge.net/svnroot/mingw-w64/trunk/mingw-w64-headers/

May be this is answer.
http://www.gamedev.net/topic/619239-directx-11-mingw-w64/page_view_findpost_p_4908066

Related

Where to get OpenCL SDK?

I tried to download OpenCL SDK. But no way. I have an AMD GPU so I searched on Google for AMD SDK but all the links from google and some tutorials are broken and there is no possibility to find the sdk through AMD developpers site.
Well I tried then Intel OpenCL SDK ... but there is no direct link. I tried to register and apply for the sdk but I don't see any download links in my mail box :(
Is it that difficult to get hands on OpenCL SDKs? Something I am missing?
UPDATE:
Finally as for OpenGL SDK is only needed for headers and libs. And tools ...
Looks like the SDK is deprecated and we should just use OpenCL SDK Lite that only contains headers and library files:
https://github.com/GPUOpen-LibrariesAndSDKs/OCL-SDK/releases Pretty disappointing.
There are still tools related to ROCm for linux but not much for Windows. CodeXL should work on windows thow.
For Intel SDK I finally received a confirmation mail and could download it. It took a couple of days.
Full Installers:
32-bit: http://amd-dev.wpengine.netdna-cdn.com/app-sdk/installers/APPSDKInstaller/3.0.130.135-GA/full/AMD-APP-SDKInstaller-v3.0.130.135-GA-windows-F-x86.exe
64-bit: http://amd-dev.wpengine.netdna-cdn.com/app-sdk/installers/APPSDKInstaller/3.0.130.135-GA/full/AMD-APP-SDKInstaller-v3.0.130.135-GA-windows-F-x64.exe
On Win64, you can build the SDK yourself. Get the OpenCL headers from Khronos, and build the import library from the OpenCL.dll using the VC++ tools. See csidev.net.

Finding boost framework with Cmake for iOS

I have Boost built as a framework for iOS. This is currently installed in Applications/Xcode.app/Contents/Developer/Library/Frameworks/.
When I create a "hand-generated" XCode project, I have no problems using this framework.
I'm now trying to use CMake to generate an XCode project. I found this helpful, cross-compiling toolchain (https://github.com/cristeab/ios-cmake). This works as long as I do not include
find_package( Boost )
But when the above line is added to my CMakeLists.txt file, I get a "Boost_INCLUDE_DIR-NOTFOUND"
So question is: has anyone had success in using CMake with Boost for iOS? If so, any help on how to go about it is greatly appreciated.
I found another SO user trying to do something similar here: How to find a iOS/mac OS X framework via Cmake
But it does not offer much details other than using "CMAKE_FRAMEWORK_PATH".
So any help is much appreciated.
Thanks...
find_package cannot find boost built for ios (tested on cmake 3.13 and 3.14)
Was able to solve it in following way.
Build boost using https://github.com/faithfracture/Apple-Boost-BuildScript
set BOOST_ROOT to Apple-Boost-BuildScript/src/boost_x_xx_x
for iOS:
set(Boost_INCLUDE_DIRS "${BOOST_ROOT}")
set(Boost_LIBRARIES "${BOOST_ROOT}/iphone-build/stage/lib/libboost_date_time.a")
set(Boost_LIBRARIES "${Boost_LIBRARIES};${BOOST_ROOT}/iphone-build/stage/lib/libboost_regex.a")
set(Boost_LIBRARIES "${Boost_LIBRARIES};${BOOST_ROOT}/iphone-build/stage/lib/libboost_system.a")
iOS simulator:
set(Boost_INCLUDE_DIRS "${BOOST_ROOT}")
set(Boost_LIBRARIES "${BOOST_ROOT}/iphonesim-build/stage/lib/libboost_date_time.a")
set(Boost_LIBRARIES "${Boost_LIBRARIES};${BOOST_ROOT}/iphonesim-build/stage/lib/libboost_regex.a")
set(Boost_LIBRARIES "${Boost_LIBRARIES};${BOOST_ROOT}/iphonesim-build/stage/lib/libboost_system.a")
I hope it's not too late:)
I came across almost same issue, find_package always complain that can not find the lib, even the search path is correct, notice that the similar issue also exist for Android NDK
For the ios I suggest:
Enable boost debug by set(Boost_DEBUG ON), then check the path specified is correct or not, ref to this link for more info
How can I get CMake to find my alternative Boost installation?
Try find_host_package instead of find_package, I found some clue in ios.cmake which may lead to the issue:
# only search the iOS sdks, not the remainder of the host filesystem
set (CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY)
set (CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set (CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)

how to compile and use objc runtime from apple's source code?

As is know to us all, objc's runtime is open source and can be downloaded from: http://www.opensource.apple.com/tarballs/objc4/
After I download the tarball an extract it. I open objc.xcodeproj using xcode. However, when I build it, there are many erros, such as, can not find some headers. I googled all the missing headers, download them, put them in /tmp/objc.dst/usr/include. But without luck, still errors.
I searched the internet, but I can find few documents or instructions about:
how to compile apple's objc runtime from source code?
After compile it , I should get libobjc.A.dylib, how to use it (as a replace of the system's libobjc.A.dylib) ?
I really appreciate any help you can provide.
Compile with no error under 10.10.2(14C1514), Xcode 6.2 (6C131e).
You need OSX 10.8 SDK, which you can get from early Xcode install dmg or this repository https://github.com/phracker/MacOSX-SDKs (If you download sdk from this repo, you may need to fix the soft links using this script http://blog.jeswang.org/blog/2014/10/26/fix-slash-soft-slash-links-slash-in-slash-an-slash-archived-slash-file/, you may need to run the script two times for the recursion of references)
More the 10.8 sdk to /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
Clone this repository https://github.com/Jeswang/objc4-532.2
Compile and Run the debug-objc scheme
You can set any breakpoint in the source and debug the whole runtime.

Corona sdk build v2013.2076 having error loading my game

I am having this error after upgrading to v2013.2076. I didn't had this error message when working with pre version of corona sdk.
Why do I get this error message?
It looks like you are trying to import a module which can not be found. The proper way to import a modules is to use:
local sprite_module = require("modules.sprite")
where modules is a folder relative the main.lua and sprite is a .lua-file.
I have the same problem. I had to switch my system to Windows 8 64 bit and installed everything new (corona and zerobrane) and now corona no more finds the sprite.lua file.
I think I found the solution here:
http://docs.coronalabs.com/api/library/sprite/index.html
sprite.* is no more supported...
You can/have to use display.newSprite() to do this now.
Edit:
Now I found the definitive proof, its because the new grafic v2.0.
http://docs.coronalabs.com/guide/graphics/migration_v1.html
(scrole to removed libraries...)
I also have problems with my joystick now... prob. this is related, too...
I am very unhappy about this, corona!

Can't find directx library

I recently installed windows 8 and installed directx sdk jun 2010 on it. However when I try to start a program on it gives me an error:
Error:
"couldnt find d3dx9.lib" or "couldnt find d3dx11.h"
This error was in directx own sample projects also. I found an article on the internet that said these kind of libraries(every thing with x in it :d) are not supported any more. I commented all code that needed these libraries, it worked and my program ran.
Question:
What is it and how should I work with it? Are all these libraries are not supported? I found vs 2012 added a new framework:
direct 3d app and direct 2d app. I made a project in it but I hardly could understand the code and how it works. Is it a new way of working with directx or is the best to make an empty project?
You will need to include the libraries you need into your projects settings.
Right click the project -> Properties -> Linker -> Input -> Additional Dependence -> Add the libraries your compiler is asking for

Resources