soc.2009.penguin.visualstudio: 19bf05f1: Penguin now builds, compiles, runs, and ...
wade at soc.pidgin.im
wade at soc.pidgin.im
Fri Aug 14 07:31:53 EDT 2009
-----------------------------------------------------------------
Revision: 19bf05f15f6ac493f4b3de4e04775c497b396cbb
Ancestor: 10b3f93df6357cf0329e0bcb06af1c25c9624228
Author: wade at soc.pidgin.im
Date: 2009-08-14T11:27:35
Branch: im.pidgin.soc.2009.penguin.visualstudio
URL: http://d.pidgin.im/viewmtn/revision/info/19bf05f15f6ac493f4b3de4e04775c497b396cbb
Modified files:
libpurple/win32/vs9/libpurple.vcproj
libpurple/wrapper/PurpleWrapper.csproj
libpurple/wrapper/generator/Program.cs
libpurple/wrapper/generator/Scripts.suo
libpurple/wrapper/generator/WrapperGenerator.cs
penguin/Penguin/Penguin.csproj
penguin/Penguin/WelcomeForm.Designer.cs
penguin/Penguin/WelcomeForm.cs penguin/Penguin.sln
penguin/README.txt
ChangeLog:
Penguin now builds, compiles, runs, and makes call to libpurple all natively in C#! Yayyy!
-------------- next part --------------
============================================================
--- libpurple/win32/vs9/libpurple.vcproj 83822b240c47011e2d2be43ca39ff2105eb58396
+++ libpurple/win32/vs9/libpurple.vcproj 7972a5647a0f99ccbed2ec6438cff5afd702aa63
@@ -40,7 +40,7 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
- AdditionalIncludeDirectories=""$(IntDir)\..\..\include\glib-2.0";"$(IntDir)\..\..\lib\glib-2.0\include";"$(ProjectDir)..\..";"$(ProjectDir)..\..\win32";"$(SolutionDir)""
+ AdditionalIncludeDirectories=""$(IntDir)\..\..\include\glib-2.0";"$(IntDir)\..\..\lib\glib-2.0\include";"$(ProjectDir)..\..";"$(ProjectDir)..\..\win32";"$(SolutionDir)libxml2\include";"$(SolutionDir)libiconv\include""
PreprocessorDefinitions="HAVE_CONFIG_H"
MinimalRebuild="true"
BasicRuntimeChecks="3"
@@ -59,9 +59,9 @@
/>
<Tool
Name="VCLinkerTool"
- AdditionalDependencies="Ws2_32.lib"
+ AdditionalDependencies="Ws2_32.lib $(SolutionDir)libxml2\lib\libxml2.lib $(SolutionDir)libiconv\lib\libiconv.lib"
OutputFile="$(OutDir)\bin\$(ProjectName).dll"
- ModuleDefinitionFile=""
+ ModuleDefinitionFile="$(SolutionDir)..\libpurple\win32\libpurple.def"
GenerateDebugInformation="true"
TargetMachine="1"
/>
============================================================
--- libpurple/wrapper/PurpleWrapper.csproj cda9988892e23cf62f44eefee6f20ef427533252
+++ libpurple/wrapper/PurpleWrapper.csproj c1118c55e62bdbf5aa1e94f09202efea55da4ddf
@@ -31,20 +31,6 @@
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
- <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
- <PlatformTarget>x86</PlatformTarget>
- <OutputPath>bin\x86\Debug\</OutputPath>
- </PropertyGroup>
- <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
- <PlatformTarget>x86</PlatformTarget>
- <OutputPath>bin\x86\Release\</OutputPath>
- </PropertyGroup>
- <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug %28Win32%29|AnyCPU' ">
- <OutputPath>bin\Debug %28Win32%29\</OutputPath>
- </PropertyGroup>
- <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug %28Win32%29|x86' ">
- <OutputPath>bin\x86\Debug %28Win32%29\</OutputPath>
- </PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core">
============================================================
--- libpurple/wrapper/generator/Program.cs 1caca457292635694d04720b3eac64635a2f4617
+++ libpurple/wrapper/generator/Program.cs e3954f4fe4b0450ad52ee35297789f0dd33e1e5e
@@ -21,6 +21,7 @@ namespace Scripts
Console.WriteLine("Writing base classes and visual studio project file...");
wrapperGen.WriteVisualStudioProjectFile();
wrapperGen.WriteBaseClasses();
+ wrapperGen.WriteDefFile();
/*
Console.WriteLine();
============================================================
# libpurple/wrapper/generator/Scripts.suo is binary
============================================================
--- libpurple/wrapper/generator/WrapperGenerator.cs 99351e693a69508e9259eb9a82eda5230ad0a07c
+++ libpurple/wrapper/generator/WrapperGenerator.cs 42012aa75acc9cee264d7162ddbdd345c2ea6d50
@@ -407,7 +407,33 @@ namespace Scripts
writer.Close();
}
+ public void WriteDefFile()
+ {
+ StreamWriter writer = new StreamWriter(path + "../win32/libpurple.def");
+ writer.WriteLine("EXPORTS");
+
+ foreach (CFile file in CFile.FileCollection)
+ {
+ foreach (CFunction function in file.Functions)
+ {
+ if (function.Name.StartsWith("purple_desktop") ||
+ function.Name == "purple_init" ||
+ function.Name == "purple_oscar_convert" ||
+ function.Name == "purple_upnp_get_control_info" ||
+ function.Name == "static_proto_init")
+ {
+ /* skip */
+ }
+ else
+ writer.WriteLine(" " + function.Name);
+ }
+ }
+
+ writer.Close();
+ }
+
+
private String GetCommentHeader()
{
StringBuilder sb = new StringBuilder();
============================================================
--- penguin/Penguin/Penguin.csproj 40a0501066650f3742f3874722aa5e22fe699788
+++ penguin/Penguin/Penguin.csproj 78018ef03aac3e110b4bf7b90c3fe44be96d532f
@@ -17,7 +17,7 @@
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
- <OutputPath>bin\Debug\</OutputPath>
+ <OutputPath>..\Win32\Debug\bin\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
@@ -62,6 +62,9 @@
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
<SubType>Designer</SubType>
</EmbeddedResource>
+ <EmbeddedResource Include="WelcomeForm.resx">
+ <DependentUpon>WelcomeForm.cs</DependentUpon>
+ </EmbeddedResource>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
============================================================
--- penguin/Penguin/WelcomeForm.Designer.cs aec5a69a2b4eec54f275603c65c3128f1cc006c8
+++ penguin/Penguin/WelcomeForm.Designer.cs 5c45483b523eaee09076157b022f95225e150de3
@@ -28,12 +28,57 @@
/// </summary>
private void InitializeComponent()
{
- this.components = new System.ComponentModel.Container();
+ this.label1 = new System.Windows.Forms.Label();
+ this.labelPurpleVersion = new System.Windows.Forms.Label();
+ this.listBoxDebugText = new System.Windows.Forms.ListBox();
+ this.SuspendLayout();
+ //
+ // label1
+ //
+ this.label1.AutoSize = true;
+ this.label1.Location = new System.Drawing.Point(12, 9);
+ this.label1.Name = "label1";
+ this.label1.Size = new System.Drawing.Size(49, 13);
+ this.label1.TabIndex = 0;
+ this.label1.Text = "libpurple:";
+ //
+ // labelPurpleVersion
+ //
+ this.labelPurpleVersion.AutoSize = true;
+ this.labelPurpleVersion.Location = new System.Drawing.Point(67, 9);
+ this.labelPurpleVersion.Name = "labelPurpleVersion";
+ this.labelPurpleVersion.Size = new System.Drawing.Size(57, 13);
+ this.labelPurpleVersion.TabIndex = 1;
+ this.labelPurpleVersion.Text = "(unknown)";
+ //
+ // listBoxDebugText
+ //
+ this.listBoxDebugText.FormattingEnabled = true;
+ this.listBoxDebugText.Location = new System.Drawing.Point(12, 35);
+ this.listBoxDebugText.Name = "listBoxDebugText";
+ this.listBoxDebugText.Size = new System.Drawing.Size(260, 212);
+ this.listBoxDebugText.TabIndex = 2;
+ //
+ // WelcomeForm
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Text = "Form1";
+ this.ClientSize = new System.Drawing.Size(284, 264);
+ this.Controls.Add(this.listBoxDebugText);
+ this.Controls.Add(this.labelPurpleVersion);
+ this.Controls.Add(this.label1);
+ this.Name = "WelcomeForm";
+ this.Text = "Penguin";
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
}
#endregion
+
+ private System.Windows.Forms.Label label1;
+ private System.Windows.Forms.Label labelPurpleVersion;
+ private System.Windows.Forms.ListBox listBoxDebugText;
}
}
============================================================
--- penguin/Penguin/WelcomeForm.cs ca69f47ffbf925b6519b59459318e58eadb27533
+++ penguin/Penguin/WelcomeForm.cs dfca8b4834ee5356942aa967728b8db6cebaa884
@@ -13,7 +13,14 @@ namespace Penguin
{
public WelcomeForm()
{
+ /* */
InitializeComponent();
+
+
+ /* libpurple init */
+ PurpleWrapper.Debug.SetEnabled(true);
+ PurpleWrapper.Plugin.PluginsAddSearchPath(System.IO.Directory.GetCurrentDirectory());
+ labelPurpleVersion.Text = PurpleWrapper.Core.GetVersion();
}
}
}
============================================================
--- penguin/Penguin.sln 48071dd688cea2c873c7ef1379bdd51673a8dd4f
+++ penguin/Penguin.sln 281cfc07aa6f7ba2bf7517ad2b31dcc7d8653201
@@ -119,37 +119,35 @@ Global
ReleaseWdkCrt|x86 = ReleaseWdkCrt|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Any CPU.ActiveCfg = Debug (Win32)|Any CPU
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Any CPU.Build.0 = Debug (Win32)|Any CPU
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Mixed Platforms.ActiveCfg = Debug (Win32)|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Mixed Platforms.Build.0 = Debug (Win32)|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Win32.ActiveCfg = Debug (Win32)|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Win32.Build.0 = Debug (Win32)|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|x64.ActiveCfg = Debug (Win32)|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|x86.ActiveCfg = Debug (Win32)|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|x86.Build.0 = Debug (Win32)|x86
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Any CPU.ActiveCfg = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Any CPU.Build.0 = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Mixed Platforms.ActiveCfg = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Mixed Platforms.Build.0 = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|Win32.ActiveCfg = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|x64.ActiveCfg = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug (Win32)|x86.ActiveCfg = Debug|Any CPU
{8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Mixed Platforms.ActiveCfg = Debug|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Mixed Platforms.Build.0 = Debug|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Win32.ActiveCfg = Debug|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Win32.Build.0 = Debug|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|x64.ActiveCfg = Debug|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|x86.ActiveCfg = Debug|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|x86.Build.0 = Debug|x86
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Win32.ActiveCfg = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|Win32.Build.0 = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Debug|x86.ActiveCfg = Debug|Any CPU
{8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Any CPU.Build.0 = Release|Any CPU
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Mixed Platforms.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Mixed Platforms.Build.0 = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Win32.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|x64.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|x86.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|x86.Build.0 = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Any CPU.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Mixed Platforms.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Win32.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|x64.ActiveCfg = Release|x86
- {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|x86.ActiveCfg = Release|x86
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Mixed Platforms.Build.0 = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|Win32.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|x64.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.Release|x86.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Any CPU.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Any CPU.Build.0 = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Mixed Platforms.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Mixed Platforms.Build.0 = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|Win32.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|x64.ActiveCfg = Release|Any CPU
+ {8034DEA9-30CC-DEA0-3903-80210CE809FA}.ReleaseWdkCrt|x86.ActiveCfg = Release|Any CPU
{16F97E97-B16F-49B2-A8E0-049E57963361}.Debug (Win32)|Any CPU.ActiveCfg = Debug (Win32)|Any CPU
{16F97E97-B16F-49B2-A8E0-049E57963361}.Debug (Win32)|Any CPU.Build.0 = Debug (Win32)|Any CPU
{16F97E97-B16F-49B2-A8E0-049E57963361}.Debug (Win32)|Mixed Platforms.ActiveCfg = Debug (Win32)|Any CPU
============================================================
--- penguin/README.txt 163f33ca824fe8f0c675f25ce7467e1ce6100ed5
+++ penguin/README.txt 08ce2bc574a7773648b01af168a4688c8f6eeb88
@@ -1,13 +1,22 @@
To sucessfully build this project, you must download some external sources.
-[Step 1]
+[Step 1]:
You must have a full checkout of the /penguin/ directory and the /libpurple/ directory.
These are the only sources needed within pidgin that are required.
+
[Step 2]:
- Follow instructions in GLib/README.txt
+ Compile and run the Visual Studio solution located at:
+ ..\libpurple\wrapper\generator\Scripts.sln
+ This will generate the PurpleWrapper classes needed to make libpurple calls.
+
+
[Step 3]:
+ Follow instructions in GLib/README.txt
+
+
+[Step 4]:
Copy the following folders and files into this directory from GLib/build:
/builddeps/
/scripts/
@@ -16,9 +25,51 @@
msvc-pragmas.h
OABuild.rules
-[Step 4]:
- (TBA): Getting libxml2.dll to link correctly.
[Step 5]:
- Open Penguin.sln inside Visual Studio and compile/run.
+ Obtain some win32 build of libxml2. This package is tested using the
+ win32 port at:
+ http://www.zlatkovic.com/pub/libxml/
+ This package should contain, at least:
+ /bin/libxml2.dll
+ /lib/libxml2.lib
+ and various .h files in /include/
+
+ Place these directories and files inside the libxml2 directory.
+
+
+[Step 6]:
+ Obtain some win32 build of libiconv. This package is tested with the
+ win32 port at:
+ http://gnuwin32.sourceforge.net/packages/libiconv.htm
+
+ The developer files package should contain, at least:
+ /lib/libiconv.lib
+ and various .h files in /include/
+
+ Place these directories and files inside the libxml2 directory.
+
+
+[Step 7]:
+ Open Penguin.sln inside Visual Studio and build (but don't run) the solution.
+
+
+[Step 8]:
+ Once Visual Studio builds the project, you need to add two DLLs to the build
+ directory. Namely:
+ libxml2.dll
+ iconv.dll
+
+ By default, it is built in:
+ Win32/Debug/bin/
+
+
+[Step 9]:
+ Run the project!
+
+
+
+
+
+
More information about the Commits
mailing list