How to build to a protected folder in xcode on 10.7 - xcode

im trying to build an audio unit synth and I've got it to compile but and it works so far but I want to debug it properly by setting my daw as a debug exexuble. The problem is that the daw only loads plugings that are in the component folder and xcode says it doesn't have permission to build there.

You should set up a build step to copy the plugin from the built products directory to your components folder. Aside from the fact that the internal built products directory is internal, the AU tools on Mac will only look for plugins in the system and user components directories, unlike VST which can be an arbitrary path.
The script would look something like this:
cp -r "$BUILT_PRODUCTS_DIR/$PRODUCT_NAME.component" "$HOME/Library/Audio/Plug-Ins/Components"

Related

Qt5 - Why the .exe don't run anything when make a deployment?

I have a problem with building an application file (*.exe) on windows. I create a simple project and run on QtCreator the result is:
It hasn't any error and warning. After that, I build it with release using kit is Desktop Qt 5.12.1 MSVC2017 64-bit, I got a folder release after rebuild with qmlTest.exe
To continues, I deploy it to follow this link
Deployment Qt apps on Windows
I got some files into the release file of my project
But when I click on qmlTest.exe nothing appears, no error, no missing dll files notifications. I checked process task and no qmlTest was running.
Who can tell me what I was wrong?
Thanks for your kind help!
You are missing some folders & files like QtQml and QtQuick etc..
Qt has a tool called "windeployqt.exe" to do exactly this.
It is used from the Console like this:
windeployqt.exe --dir PATH_TO_DEPLOY --compiler-runtime --release --qmldir PATH_TO_QML MY_EXE
PATH_TO_DEPLOY: an empty folder where you would like the dependencies to be copied
PATH_TO_QML: the folder where you have your qml files
MY_EXE: path to your executable
So in your case, it would look something like this:
C:\Qt\5.12.1\msvc2017_64\bin\windeployqt.exe --dir C:\Users\...\Desktop\deployFolder --compiler-runtime --release --qmldir C:\Users\...\Desktop\QmlTest\qml C:\Users\...\Desktop\build-qmlTest-Desktop_Qt...-Release\release\qmlTest.exe
After running the tool, all the files you need will be in the deployFolder. You just have to copy the executable from the release folder and you're done.
More infos can be found here: https://doc.qt.io/qt-5/windows-deployment.html

Create custom Platform and SDK for Xcode 8.3+

I'm trying to create a custom .platform and SDK in Xcode 8.3 and higher.
I am ultimately attempting to update the old DarwinBuild build system so that I can compile a few of the Apple open source components. DarwinBuild used to use this technique in order to be able to compile against a different set of headers and libraries without having to chroot.
DarwinBuild includes a setup script, installXcode32, that creates a new .platform under Xcode's Developer/Platforms directory, and a new sdk under the platform's Developer/SDKs directory. It also creates an Info.plist and SDKSettings.plist in the right spots. This script needs some updating to work with Xcode 8.3.
I know this is unsupported, but that doesn't matter in this case. After all, Apple published the original script...
I updated the original installXcode32 script to work with the new Xcode paths (/Applications/Xcode.app/Contents/...), and it produces the new .platform, Info.plist, and SDKSettings.plist, and they're all symlinked to the right spots. However, xcodebuild -showsdks now produces this error:
xcodebuild: error: Initialization failed.
Reason: Required content for platform darwin is missing.
I know it's an issue with the Info.plist and SDKSettings.plist files. I have tried copying the entire MacOSX.platform directory, and changing the names in the .plist, and I get the same error.
Does anyone know enough about Xcode and platforms to know what is required to get Xcode 8.3+ to recognize a "new" Platform and sdk?
Many thanks!
I have successfully done this with Xcode 9.4, pretty much like you did. I changed:
CanonicalName
PLATFORM_NAME
DisplayName

Different builds of SQLite in the same Windows Store app bundle

I'm having a problem deploying an update of my app to the store.
The app runs SQLite, and I've recently discovered it throws an error on certain x64 architectures.
BadImageFormatException: An attempt was made to load a program with an
incorrect format.
I understand what this means. The x64 version of the app is using the x86 compiled version of sqlite3.dll. I can get around this issue and build an x64 version by the following method.
Open Project > Properties, and set Platform and Platform Target to x64.
Save
Open Build > Configuration Manager and set Active Platform and Platform (Release) to x64.
Build the project
Open Project > Store > Create App Packages and generate my package
This creates a correct x64 app package with the x64 version of sqlite3.dll
Following this for all three architectures (x86, x64 and ARM) gives me three separate appxbundle files. When I go to upload a new package to the store through the developer dashboard, I can only upload one of these.
If I open "Create App Packages" and choose all three architectures for my bundle, it generates a single appxbundle for all three. However when I unzip this appxbundle I can see that the x64 build is using the x86 compiled sqlite3.dll and not the x64 version.
I tried opening the appxbundle in 7zip and replacing the files, but 7zip could not write to the file, only read it.
I then tried unzipping the appxbundle and replacing each of the three builds with the correct builds from the singular appxbundles. I then zipped the lot together using no compression and renamed .zip to .appxbundle, but the store rejected this as an invalid file.
I'm guessing there's some kind of signing going on or a proprietary compression. To be honest I didn't expect that to work but it was worth a try.
How do I build the correct version of my app for each architecture and include it in a single appxbundle? Can I manually create my own appxbundle from separate builds?
SOLUTION
I have accepted crea7or's answer below, but I just wanted to expand on it a little
Using the MakeAppX.exe command line tool I was able to unbundle and rebundle my appxbundle file correctly, using the following command
// to unbundle
MakeAppX.exe unbundle /p MyPackage.appxbundle /d MyPackage
// to bundle
MakeAppX.exe bundle /d MyPackage /p MyPackage.appxbundle
A couple of handy pointers. Make sure you use the 8.1 version of MakeAppX, as the 8.0 version cannot bundle or unbundle.
C:\Program Files (x86)\Windows Kits\8.1\bin\x86\makeappx.exe
You'll save yourself a lot of hassle and typing if you simply add this path to your PATH Environment Variables in Advanced system settings. That way you can run MakeAppX from any location. This might seem obvious to people of my generation but not everyone is so familiar with DOS. =)
Visual Studio creates .appxupload packages, which according to this question, are zip files renamed as .appxupload. MakeAppX cannot create or unbundle .appxupload packages - you have to use a zip app.
However, any .appxupload package I created with 7zip did not validate when uploaded. Luckily it seems that the store will accept the .appxbundle directly, so I didn't need to zip it up at all, only bundle it. I've submitted this to the store. I'll report back if it gets approved.
update
the above appxbundle file was not approved, failed technical tests. I tried the zip approach again and it was accepted this time, again I'll report back if this passes.
To sum up:
c:\MyApp.appxupload -> [unzip] -> c:\MyApp\
c:\MyApp\MyApp.appxbundle -> [makeappx unbundle] -> c:\MyApp\MyApp\
c:\MyApp\MyApp\MyApp.appx -> [do whatever you need to here]
c:\MyApp\MyApp\ -> [makeappx bundle] -> c:\MyApp\MyApp.appxbundle
c:\MyApp\ -> [zip] -> c:\MyApp.zip
c:\MyApp.zip -> [rename] -> c:\MyApp.appxupload
You should use MakeAppx tool to create valid appx package bundle, because they are signed. Here is the tutorial about creating bundles.

Native plugin with Unity3d Mac OSX Dll notfoundexception

I am trying to integrate a 3rd party native plugin with unity3D. In order to use it i made a c# plugin as a wrapper dll. The plugin works fine with PC standalone when i copy the plugin binaries manually to build folder along with my EXE file.I have used debug configuration for the plugin build process.
Problem is :
when i make a mac OS X build, i am getting DllNotFoundException. My c# plugin file is in the app located at "\Contents\Data\Managed" along with other unity related plugins which means unity is recognizing my wrapper plugin but not copying the native plugins.
Things already tried :
I copied the native plugins also in the Assets/Plugins/ folder so as they are also included in build, but unity didn't include them in build.
I tried putting my native plugin in "\Contents\Data\Managed" folder and also in other folders in the app,still it was not able to find the dll.
I tried putting the dylib file which came with the native plugin, also along with my wrapper plugin but it didn't work.
I tried to do a dllmap in the config file at "\Contents\Data\Managed\etc\mono" using
also, but it didn't work.
I am out of ideas. Any help is appreciated.
It worked for me to add a dll map to the mono config file found here:
Your.app/Contents/Data/Managed/etc/mono/config
I added the following :
<dllmap dll="phidget21.dll" target="/Library/Frameworks/Phidget21.framework/Versions/Current/Phidget21" />
Make sure that the Phidget21.framework exists in /Library/Frameworks..

Deploy / build application for OSX

I have created my first XE2 FM HD application.
I have my OSX machine connected and running debug builds on OSX works fine, but I don't have a way to create a release version and copy it to another computer.
I tried just copying over the Package made by the debug but that's missing files.
Inside XE2 I went to Project -> Deployment.
For the OSX Debug deployment I have a green button, but under OSX Release deployment I don't.
Clues?
Here's step-by-step instructions for building the App bundle and putting in the required dynamic link library:
Create a folder called MyApp.app
Create a subfolder in Myapp.app called Contents
Create a subfolder in Contents called MacOS
Create a subfolder in Contents called Resources
From your build, copy Info.plist into Contents
From your build, copy the Mac binary to MacOS
From your build, copy the icon to Resources
Copy libcgunwind.1.0.dylib to MacOS
Copy the .app folder to your Mac and double-click it to run
You will find libcunwind.1.0.dylib on your Mac where you installed the platform assistant, most likely:
/Users/username/Applications/Embarcadero/PAServer/
Here's a video tutorial on how to create the manual install Disk Image installer on the Mac.

Resources