I want to publish package about sdl_mixer, it's a native package. I did as tutorial said. I put .dll
.h
and .lib
files into package content, but the final package didn't work. So what is right way to create c++ nuget package?
Another question: I found in nuget, most native c++ package are published in two packages, for example:
sdl2_ttf.v140
sdl2_ttf.v140.redist
What is difference between those two files? And how can I publish my packages like that?
Update:
I followed the tutorial on how to publish native packages. I have written the following autopkg file
nuget{
nuspec {
id = MySdl_mixer;
version :2.0.0.0;
title: sdl mixer;
authors: { Sam Lantinga, Stephane Peter, Ryan Gordon};
owners: {spartawhy117};
licenseUrl: "http://libsdl.org/license.php";
projectUrl: "http://libsdl.org/index.php";
iconUrl:"";
requireLicenseAcceptance:false;
summary:Nothing;
description: @"SDL_mixer is a sample multi-channel audio mixer library....
";
releaseNotes: "Release of C++ ";
copyright:Copyright 2015;
tags: {v140 ,sdl_mixer , native, CoApp };
};
files {
#defines {
Include = include\;
Bin = bin64\;
Lib = lib64\;
}
include:{"${Include}*"};
[x64,v140,debug,desktop]{
lib: ${Lib}SDL2_mixer.lib;
bin: ${Bin}SDL2_mixer.dll;
}
[x64,v140,release,desktop]{
lib: ${Lib}SDL2_mixer.lib;
bin: ${Bin}SDL2_mixer.dll;
}
};
targets {
Defines += HAS_SDLMIXER;
};
}
Running the command Write-NuGetPackage .\sdl_mixer.autopkg
returns an error unexpected input of the end. What is the problem here?
Defines += HAS_SDLMIXER;HAS_B