Changes between Version 25 and Version 26 of DeveloperGuidlines


Ignore:
Timestamp:
Apr 15, 2010, 10:49:31 AM (12 years ago)
Author:
Patrick Vacek
Comment:

small bug fixes in transcription and wikification

Legend:

Unmodified
Added
Removed
Modified
  • DeveloperGuidlines

    v25 v26  
    33
    44
    5 !CrypTool 2.0 is built upon state-of-the-art technologies such as .NET 3.5 and the Windows Presentation Foundation. Before you can start writing code and adding to the development of the project, a few things need to be considered. To make this process easier, please read through this document and follow the instructions closely. This document exists to help get you started by showing you how !CrypTool 2 plugins are built in order to succesfully interact with the application core. We have tried to be very thorough, but if you encouter a problem or error that is not described here, please let us know. Not only do we want to help get you up and running, but we also want to add the appropriate information to this guide for the benefi
    6 t of other future developers.
     5!CrypTool 2.0 is built upon state-of-the-art technologies such as .NET 3.5 and the Windows Presentation Foundation. Before you can start writing code and adding to the development of the project, a few things need to be considered. To make this process easier, please read through this document and follow the instructions closely. This document exists to help get you started by showing you how !CrypTool 2 plugins are built in order to succesfully interact with the application core. We have tried to be very thorough, but if you encouter a problem or error that is not described here, please let us know. Not only do we want to help get you up and running, but we also want to add the appropriate information to this guide for the benefit of other future developers.
    76
    87In this
     
    2019
    2120Since you are reading the developer guidelines, you probably want to develop something. Hence, you will need a development environment. In order to compile our sources you need '''Microsoft Visual Studio 2008 Professional'''. Make sure to always install the latest service packs for Visual Studio.
    22 Unfortunately, our sources do not work smoothly with the freely available Visual C# Express. This is due to the fact that a major part of the application core, !CrypWin, uses a commercial component and is therefore distributed only as a binary. The current version of Visual C# Express does not accept a binary fi
    23 le as a start-up project, and thus debugging is quite cumbersome. We hope to resolve this issue later in 2010 when the project is ported to Visual Studio 2010, but until then, we recommend using the full Visual Studio 2008 Professional version.
     21Unfortunately, our sources do not work smoothly with the freely available Visual C# Express. This is due to the fact that a major part of the application core, !CrypWin, uses a commercial component and is therefore distributed only as a binary. The current version of Visual C# Express does not accept a binary file as a start-up project, and thus debugging is quite cumbersome. We hope to resolve this issue later in 2010 when the project is ported to Visual Studio 2010, but until then, we recommend using the full Visual Studio 2008 Professional version.
    2422
    2523In order to run or compile our source code you will need at least the '''Microsoft .NET 3.5 framework with Service Pack 1 (SP1)'''. Usually the installation of Visual Studio also installs the .NET framework, but if you do not have the latest version, you can get it for free from [http://download.microsoft.com/download/0/6/1/061F001C-8752-4600-A198-53214C69B51F/dotnetfx35setup.exe Microsoft's website]. Once the framework has been installed, your development environment should be ready for our source code.
     
    3331les. Right-click on this directory; now that TortoiseSVN has been installed, you should see a few new items in the context menu.
    3432
    35 Select ''SVN Checkout'' and a window will now appear that will ask you for the URL of the repository that you would like to access. Our code repository is stored at [https://www.cryptool.org/svn/CrypTool2/], and this is what you should enter in the appropriate fi
    36 eld. The ''Checkout directory'' should already be fi
    37 lled in correctly with your new folder, and you shouldn't need to change any other options.
     33Select ''SVN Checkout'' and a window will now appear that will ask you for the URL of the repository that you would like to access. Our code repository is stored at [https://www.cryptool.org/svn/CrypTool2/], and this is what you should enter in the appropriate field. The ''Checkout directory'' should already be filled in correctly with your new folder, and you shouldn't need to change any other options.
    3834
    39 Then just hit ''OK''. You may be asked to accept a certi
    40 cate (which you should accept), and you will certainly be asked for login information. If you are a registered developer, you should have already been given a username and password, and you should enter them here. (These are the same username and password that you can use for this wiki.) If you are a guest and just want to download the source code, you can use "anonymous" as the username and an empty password. Mark the checkbox for saving your credentials if you don't want to enter them every time you work with the repository. Finally, hit ''OK'', and the whole !CrypTool 2 repository will begin downloading into your chosen local directory.
     35Then just hit ''OK''. You may be asked to accept a certificate (which you should accept), and you will certainly be asked for login information. If you are a registered developer, you should have already been given a username and password, and you should enter them here. (These are the same username and password that you can use for this wiki.) If you are a guest and just want to download the source code, you can use "anonymous" as the username and an empty password. Mark the checkbox for saving your credentials if you don't want to enter them every time you work with the repository. Finally, hit ''OK'', and the whole !CrypTool 2 repository will begin downloading into your chosen local directory.
    4136
    4237Since CrypTool 2 is a collaborative project with many developers, changes are made to the repository rather frequently. You should maintain a current working copy of the
     
    5954=== Committing your changes ===
    6055
    61 Once you start writing code and developing your plugin, you should check your work into the project repository. If you are reading this page in sequence, you are probably not ready to do this, but while we are on the topic of SVN we will describe the process. To upload your changes, right-click on a directory within the working fi
    62 les that contains your changes and select ''SVN Commit'' from the context menu.
     56Once you start writing code and developing your plugin, you should check your work into the project repository. If you are reading this page in sequence, you are probably not ready to do this, but while we are on the topic of SVN we will describe the process. To upload your changes, right-click on a directory within the working files that contains your changes and select ''SVN Commit'' from the context menu.
    6357
    6458When you commit your code, you can leave a comment to describe what you have changed. Please always provide ''meaningful descriptions'' of your updates. You can also select exactly which
     
    6761files. For example, do not check in the entire ''bin\'' and ''obj\'' directories that Visual Studio generates. The server will reject your commits if you try to do so. You should commit your sources to our SVN repository as often as you can, but only commit code that successfully compiles and runs!
    6862
    69 You can use the SVN comments to link to your changes to a particular issue or bug ticket in this wiki. (The list of active tickets can be found [https://www.cryptool.org/trac/CrypTool2/report/1 here].) The following commands are supported (note that there are multiple variations of each command that are functionally identical):
     63You can use the SVN comments to link to your changes to a particular issue or bug ticket in this wiki. (The list of active tickets can be found [report:1 here].) The following commands are supported (note that there are multiple variations of each command that are functionally identical):
    7064
    7165 {{{
    7266closes, fixes:
    73 The specifi
    74 ed ticket will be closed and the contents of this commit message will be added to its notes.
     67The specified ticket will be closed and the contents of this commit message will be added to its notes.
    7568
    7669references, refs, addresses, re:
    77 The contents of this commit message will be added to the speci
    78 ed ticket's notes, but the status will be left unaltered.
     70The contents of this commit message will be added to the specified ticket's notes, but the status will be left unaltered.
    7971 }}}
    8072
     
    8880 }}}
    8981
    90 You can also use more than one command in a message if necessary. For example, if you want to close tickets #10 and #12, and add a note to #17, you could type the following:
     82You can also use more than one command in a message if necessary. For example, if you want to close tickets !#10 and !#12, and add a note to !#17, you could type the following:
    9183
    9284 {{{
     
    9991 {{{
    10092This library is required by all developers, so I am adding it explicitly to the repository.
     93
    10194override-bad-extension: someLib.dll
    10295 }}}
     
    108101== Compiling the sources ==
    109102
    110 By this point you should have checked out a copy of the entire !CrypTool 2 repository. Compiling is pretty easy; just go to the ''trunk\'' directory and open the '''''!CrypTool 2.0.sln''''' Visual Studio solution. The Visual Studio IDE should open with all the working plugin components nicely arranged. If you are now starting Visual Studio for the fi
    111 rst time, you will have to choose your settings. Just select either ''most common'' or ''C#'' -- you can change this at any time later. On the right side is the project explorer, where you can see all the subprojects included in the solution. Look for the project '''''!CrypWin.exe''''' there. Once you have found it, right-click on it and select ''Set as StartUp Project'' from the context menu. Next, go to the menu bar and select ''Build -> Build Solution''.
     103By this point you should have checked out a copy of the entire !CrypTool 2 repository. Compiling is pretty easy; just go to the ''trunk\'' directory and open the '''''!CrypTool 2.0.sln''''' Visual Studio solution. The Visual Studio IDE should open with all the working plugin components nicely arranged. If you are now starting Visual Studio for the first time, you will have to choose your settings. Just select either ''most common'' or ''C#'' -- you can change this at any time later. On the right side is the project explorer, where you can see all the subprojects included in the solution. Look for the project '''''!CrypWin.exe''''' there. Once you have found it, right-click on it and select ''Set as StartUp Project'' from the context menu. Next, go to the menu bar and select ''Build -> Build Solution''.
    112104
    113 You may have to wait a while for the program to compile. Once it is fi
    114 nished, select ''Debug -> Start Debugging''. !CrypTool 2 should now start for the
    115 first time with your own compiled code. Presumably you have not changed anything yet, but you now have your own build of all the components (with the exception of !''CrypWin'' and ''AnotherEditor'', since they are available only as binaries). If the program does not compile or start correctly, please consult our [wiki:FAQ F.A.Q.] and let us know if you found a bug.
     105You may have to wait a while for the program to compile. Once it is finished, select ''Debug -> Start Debugging''. !CrypTool 2 should now start for the
     106first time with your own compiled code. Presumably you have not changed anything yet, but you now have your own build of all the components (with the exception of ''!CrypWin'' and ''AnotherEditor'', since they are available only as binaries). If the program does not compile or start correctly, please consult our [wiki:FAQ F.A.Q.] and let us know if you found a bug.
    116107
    117 If you are a '''core developer''', hence somebody who can also compile ''CryWin'' and ''AnotherEditor'', you should use the '''''!CrypTool 2.0.sln''''' solution from the ''trunk\CoreDeveloper\'' directory (which will ''not'' be visible to you if you are not a core developer). As a core developer, be aware that when you compile, you '''change the ''!CryWin.exe''''' that is visible to everybody else. Thus, when committing to the repository, please make sure you really want to check in a new binary. Core developers can also build a new setup and publish it as beta release on the website. This process is explained [BuildSetup here].
     108If you are a '''core developer''', hence somebody who can also compile ''CrypWin'' and ''AnotherEditor'', you should use the '''''!CrypTool 2.0.sln''''' solution from the ''trunk\CoreDeveloper\'' directory (which will ''not'' be visible to you if you are not a core developer). As a core developer, be aware that when you compile, you '''change the ''!CrypWin.exe''''' that is visible to everybody else. Thus, when committing to the repository, please make sure you really want to check in a new binary. Core developers can also build a new setup and publish it as beta release on the website. This process is explained [BuildSetup here].