http://wiki.amule.org/t/api.php?action=feedcontributions&user=212.242.54.121&feedformat=atomAMule Project FAQ - User contributions [en]2024-03-29T01:41:40ZUser contributionsMediaWiki 1.23.3http://wiki.amule.org/t/index.php?title=Changelog_2.1_seriesChangelog 2.1 series2006-03-18T09:59:10Z<p>212.242.54.121: </p>
<hr />
<div>This are the [[aMule]] 2.1.x release changelogs available:<br />
<br />
[[Changelog_2.1.0|aMule 2.1.0]]<br />
<br />
[[Changelog_2.1.1|aMule 2.1.1]]</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Changelog_2.1_seriesChangelog 2.1 series2006-03-18T09:58:56Z<p>212.242.54.121: Adding entry for 2.1.1</p>
<hr />
<div>This are the [[aMule]] 2.1.x release changelogs available:<br />
<br />
[[Changelog_2.1.0|aMule 2.1.0]]<br />
[[Changelog_2.1.1|aMule 2.1.1]]</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Getting_StartedGetting Started2006-02-26T21:35:26Z<p>212.242.54.121: </p>
<hr />
<div><center><br />
'''English''' | [[Getting_Started-fr|Français]] | [[Getting_Started-nl|Nederlands]] | [[Getting_Started-es|Español]] | [[Getting_Started-de|Deutsch]] | [[Getting_Started-hu|Magyar]] | [[Getting Started-ru|Russian]] | [[Getting Started-da|Dansk]]<br />
</center><br />
<br />
== What is [[aMule]] ==<br />
<br />
[[aMule]] is a [[P2P|p2p]], or peer-to-peer, client for the [[FAQ_eD2k-Kademlia|eD2k]] network, commonly known as [[FAQ_eD2k-Kademlia|eDonkey network]] or eD2k network ([[eDonkey2000]]). This guide does not require you to be familiar with these networks (but it does help), however it does require that you have [[aMule]] installed on your computer.<br />
If you haven't installed [[aMule]] yet, please refer to the proper installation guide for your system. Links to these guides can be found on the [[Main_Page|main page]].<br />
<br />
--[[User:Xaignar|Xaignar]] 01:12, 10 Jul 2004 (CEST)<br />
<br />
== Running [[aMule]] for the first time ==<br />
First, launch [[aMule]]. This can be done by executing the command ''amule'' in a console window or by whatever method might be provided by your distro and/or windows manager in terms of icons, etc.<br />
<br />
Once started, if you are using the [http://www.gnu.org/software/cvs CVS] build, [[aMule]] will display a notification telling you that you are running it for the first time. Read this to learn what you are getting yourself into ;)<br />
<br />
Please note that aMule makes extensive use of right-click menus, so if you can't find a function, try right-clicking on the item you wish to manipulate.<br />
<br />
=== Configuring [[aMule]] ===<br />
Before you begin file sharing, you will need to properly configure [[aMule]]. This includes connection speeds and limits, directories to be used, proxies, port settings and other settings.<br />
You can access [[aMule]] preferences by clicking on the ''Preferences'' icon at the top of the [[aMule]] window.<br />
<br />
==== Connection Speed ====<br />
You should know that the eDonkey clients enforce upload. This means that in order to download, you'll have to share files yourself (don't worry if you don't have anything to share). This is enforced in two ways:<br />
* Your download speed depends on how fast you upload. If your upload speed is set to anything below 10kb/s then your maximum download speed will be 3 or 4 times your uploadspeed (read [[FAQ_eD2k-Kademlia#Are_there_any_limitations_on_the_ED2K_network?|this]] to know more about it), so if you limit your upload speed to 5kb/s, you'll only be able to download with 20kb/s.<br />
* Partially downloaded files are shared as well. You automatically start sharing a file after you've received at least one [[FAQ_eD2k-Kademlia#What_is_a_chunk?|chunk]] (a [[FAQ_eD2k-Kademlia#What_is_a_chunk?|chunk]] is a 9.28Mb piece of a file).<br />
<br />
Note: If you ever enter the [http://forum.amule.org aMule forum] or [[IRC|IRC channel]] to complain about this or demand that we change the ratio, I will hunt you down and eat your spleen. -- [[User:Xaignar|Xaignar]]<br />
<br />
When you first open the Preferences dialog, the page shown will be "General", which contains some general settings, like the [[nickname]] other people will see when they download from or upload to you. <br />
To proceed, click on the tab named "Connection":<br />
<br />
http://www.amule.org/dev-up/Limits.png<br />
<br />
The only settings relevant to this guide are the settings under "Bandwidth Limits" marked "Upload" and "Download". You don't need to enter a max download speed, but it is recommended that you set the upload speed to around 80% of your actual speed, since it can cause slower downloads otherwise.<br />
<br />
Once you have entered the proper values, you can explore the rest of the settings. To save the changes, simply click the "OK" button.<br />
<br />
=== ED2K and Kademlia ===<br />
<br />
As of v2.1.0, aMule is also capable of connecting to the serverless network dubbed [[Kademlia]]. This allows aMule and other eDonkey2000 clients to function without having to rely on generous souls running servers. Both [[Kademlia]] and the server-based [[ED2K]] network are enabled by default, but you can disable either of the two networks on the lower part prefences page titled 'Connection'. Users with slow upload speeds should consider enabling only one of the two networks, due to the added overhead. <br />
<br />
=== Connecting to a Server ===<br />
<br />
You should now be looking at the servers dialog:<br />
<br />
http://www.amule.org/dev-up/ServerDlg.png<br />
<br />
The empty list normally contains the servers you know about, but since this is the first time you're running [[aMule]], you don't have any. To remedy this situation, simply click in the text-field containing the text ''http://www.srv1000.com/azz/server.met'' and press enter.<br />
A dialog will pop up and close again once the download has completed.<br />
<br />
You should now have a full list of servers, if not search google for ''server.met'', replace the url mentioned above and press enter to initiate the download.<br />
<br />
http://www.amule.org/dev-up/ServerList.png<br />
<br />
Next you need to connect to a [[server]]. Normally it's a good idea to select one with as many users as possible, but for now, lets just click the large "Connect" button near the top-left of the window. This will connect you to a random server. Please wait while [[aMule]] contacts servers and tries to establish an connection. Once this happens, proceed on to the next section.<br />
<br />
=== Connecting to the Kademlia Network ===<br />
<br />
To connect to the [[Kademlia]] network, provided that it is enabled in the preferences, all you need to do is to do is press the "Connect" button on the top toolbar. Note that manually connecting to a server (by double-clicking or right-clicking and selecting the 'Connect to server' item) wont connect you to the [[Kademlia]] network. Another way to connect to the [[Kademlia]] network is to enter the 'Kad' sub-page on the 'Networks' page, and press the 'Bootstrap from known clients' button. In case this is the first time you use Kad, you may want to updates your nodes.dat file, by clicking in the Url textfield and pressing enter, or by clicking the "blue play button" http://forum.amule.org/images/bunfirlite/lastpost.gif by that bar. It is not necessary to do this again later, as the nodes list is kept up to date when aMule is running.<br />
<br />
<br />
=== [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|High and Low ID]] ===<br />
Because [[P2P|p2p]] networks work by [[Client|clients]] directly connecting to each other, being behind a firewalls, or routers that do not/cannot pass traffic on specific ports, can really cause problems. If you don't know whenever or not you are behind a firewall, simply look at the globe icon in the bottom-right of the window. If its arrows are green, then you have [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|High ID]] and can proceed, but if they are yellow, then you need to take a look at the page on [[Firewall|Firewalls]] and/or [[AMule_problems#aMule_connects_to_server,_but_it_is_always_given_LowID._Why?_and,_can_I_do_something_about_it?|common problems]], since having a [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|Low ID]] greatly reduces [[P2P|p2p]] experiences.<br />
<br />
== Basic Usage ==<br />
This will cover some basic usage of [[aMule]].<br />
<br />
=== Searching and Downloading ===<br />
OK, this is what [[P2P|p2p]]'ing is about: Downloading files.<br />
For the sake of this guide, I'll presume that you are really keen on downloading the latest [http://www.knoppix.org Knoppix] CD (who isn't?). To download this, first ensure that you are connected to a server, or the [[Kademlia]] network, and then click on the "Searches" button.<br />
<br />
This will bring up the search dialog:<br />
<br />
http://www.amule.org/dev-up/SearchDlg.png<br />
<br />
Since we only care about CD images, we click on "Extended Options" and select the option "CD-Images" from the "File Type" dropdown menu. If you are connected to an [[ED2K]] server, select the "[[Search#Local_search|Local]] [[Search]]" setting, since we don't really need to search anything other than the currently connected [[server]]. Otherwise, if you are connected to the [[Kademlia]] network, select the 'Kad' search-type. Then we enter ''Knoppix'' in the top "Name" field and hit enter or the "Search" button. You should now have a listful of results:<br />
<br />
http://www.amule.org/dev-up/SearchResults.png<br />
<br />
Lets sort the list by [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]], by clicking twice on the field marked "Sources", this makes it easier to find popular files. The second one looks interesting, so we double-click on it (or click on it and then on the "Download" button). This will queue the file for download.<br />
<br />
Results can be displayed in a number of colors, which signify the following:<br />
* Blue represents the number of sources, the more sources the darker the blue.<br />
* Red represents files that you are currently downloading.<br />
* Green is for files you have downloaded or shared before, in other words files you already have.<br />
<br />
=== Search Types ===<br />
I only mentioned 'Local' and 'Kad' searching above. <br />
<br />
A local search only asks the server you are connected to, and is enough in most cases. However, if this does not return any results, you can ask all servers in your serverlist, by doing a 'Global' search. This however takes a lot longer (0.75s per server). <br />
<br />
Lastly, you can search on the 'Kademlia' network via the 'Kad' search-type. Note that on the 'Kad' network, results signify complete sources, unlike 'ED2K' searches, where the source-count contains both complete and incomplete sources.<br />
<br />
=== The Download Queue ===<br />
Click on the "Transfers" button to bring forth a list of files you have queued for download:<br />
<br />
http://www.amule.org/dev-up/DownloadQueue.png<br />
<br />
If you're lucky, the progress bar will turn a nice dark shade of blue, which means that a lot of people have that file (read [[FAQ_aMule#What_do_those_colors_in_the_progress_bar_mean?|this]] to know more about it). Beware of files that have parts marked in red, since it means that no-one has that part of the file and you most likely wont be able to complete the download.<br />
<br />
If you double-click on any of the files, you can see the [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] you have found for that file.<br />
<br />
==== Of Rows and Columns ====<br />
These are the columns of the Download Queue:<br />
<br />
; ''Filename'' : The name of the file.<br />
; ''Size'' : The size of the file. The eDonkey2000 network supports files up to 4GB in size (read [[FAQ_eD2k-Kademlia#Are_there_any_limitations_on_the_ED2K_network?|more]] about this).<br />
; ''Transferred'' : Shows the amount downloaded.<br />
; ''Completed'' : This column displays how much of the file you have actually completed. Please note that this can differ from the Transferred column because of corruptions or gains made by the compression *Mule [[Client|clients]] use (read [[FAQ_aMule#What_is_the_difference_between_Transfered_and_Completed_in_the_Transfers_window?|more]] about this difference).<br />
; ''Progress'' : This bar displays the current progress of the file, the colours signifying the following (alternative [[FAQ_aMule#What_do_those_colors_in_the_progress_bar_mean?|resource]]):<br />
* Blue: How many sources provide this part, the darker the colour, the more sources provide it.<br />
* Red: There are no known [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] that provide this part.<br />
* Black: You have already downloaded this part.<br />
* Yellow: You are currently downloading this part.<br />
: The green bar on top of the larger bar gives an indication of the actual progress.<br />
; ''Sources'' : There are 3 fields in this column, though mostly only 2 are shown (alternative [[FAQ_aMule#What_do_all_those_numbers_in_the_sources_column_in_the_transfers_window_mean?|resource]]):<br />
: <Asked [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]>[/<All [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]>] [+ <[[FAQ_aMule#What_is_A4AF?|A4AF]] [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]> ] [(<Transferring [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]]>)]<br />
: 'Asked [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]' are those that have been asked for the file.<br />
: 'All [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]' are all [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] of that file, asked and unasked.<br />
: '[[FAQ_aMule#What_is_A4AF?|A4AF (Asked For Another File)]] [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]' are [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] that provide that file, but have been asked for anther one.<br />
: 'Transferring [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]]' are [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] which are uploading that file to you at this very moment.<br />
; ''Priority'' : The priority of the file. Files are set to auto-priority by default, which means that [[aMule]] will manage it by itself. Priorities affect how [[aMule]] allocates [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] that are known to provide multiple files and thus means that high-priority files get more [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]]. Read [[FAQ_aMule#What_do_all_those_numbers_in_the_priority_column_in_the_extended_transfers_window_mean?|more]] about this.<br />
; ''Status'' : The current status of the file. Waiting means that you are waiting for [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] to start uploading to you.<br />
; ''Time Remaining'' : An guess at how fast the file will be completed. Only shows something when you are currently receiving the file.<br />
; ''Last Seen Complete'' : This shows the last time you've seen the entire file provided by the [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] you've asked.<br />
; ''Last Reception'' : This shows the last time you were downloading parts of this file.<br />
<br />
=== The Upload Queue ===<br />
The upload queue can be found just beneath the download queue, and shows who are downloading files from you (you might want to read [[FAQ_aMule#Why_are_there_two_transfer_rates_in_the_uploading_transfer_list?|this]]). In case you are wondering, no, you cannot stop uploads. If you click on the blue icon next to the "Uploads" label, you can see who are queued for downloading from you, rather than the people who are actually downloading from you right now.<br />
<br />
=== Icons and What They Signify ===<br />
These are the icons that can be found on the Transfers page.<br />
<br />
* '''Source Status''' <br />
** http://www.amule.org/dev-up/Source_1.png - [[Client]] is sending you either a file or a hashset.<br />
** http://www.amule.org/dev-up/Source_2.png - You are either on this [[Client|clients]] queue or currently asking it for a file.<br />
** http://www.amule.org/dev-up/Source_3.png - You are currently connecting to this [[Client|client]].<br />
** http://www.amule.org/dev-up/Source_4.png - [[Client]] has been asked for another file, has no needed parts or is unable to connect because of a [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|Low ID]].<br />
** http://www.amule.org/dev-up/Source_5.png - Status is unknown.<br />
<br />
* '''eDonkey Clients'''<br />
** http://www.amule.org/dev-up/Client_aMule.png - [[aMule]]<br />
** http://www.amule.org/dev-up/Client_eDonkey.png - [[eDonkey2000]]<br />
** http://www.amule.org/dev-up/Client_eMule.png - [[eMule]]<br />
** http://www.amule.org/dev-up/Client_Friend.png - [[Client]] is a [[Friend]]<br />
** http://www.amule.org/dev-up/Client_Lphant.png - [[lphant]]<br />
** http://www.amule.org/dev-up/Client_MLDonkey.png - [[mlDonkey]]<br />
** http://www.amule.org/dev-up/Client_Shareaza.png - [[Shareaza]]<br />
** http://www.amule.org/dev-up/Client_Unknown.png - Unknown [[Client]]<br />
** http://www.amule.org/dev-up/Client_xMule.png - [[xMule]]<br />
<br />
* '''Modifiers'''<br />
** http://www.amule.org/dev-up/Client_Mod_eMuleProt.png - [[Client]] supports the extended [[eMule]] protocols. Source-sharing and such.<br />
** http://www.amule.org/dev-up/Client_Mod_GoodCredit.png - [[Client]] has a good [[FAQ_eD2k-Kademlia#What_is_all_this_talk_about_credits,_ratings_and_scoring_about?|credit-rating]].<br />
** http://www.amule.org/dev-up/Client_Mod_NormCredit.png - [[Client]] has a normal [[FAQ_eD2k-Kademlia#What_is_all_this_talk_about_credits,_ratings_and_scoring_about?|credit-rating]].<br />
** http://www.amule.org/dev-up/Client_Mod_SecId_Good.png - [[Client]] has been [[Secure_User_Identification|securely identified]].<br />
** http://www.amule.org/dev-up/Client_Mod_SecId_Bad.png - [[Client]] has been identified for some reason as a [[bad guy]].<br />
<br />
* '''File [[comment]]s''' icons are explained in the [[comment icon]]s article.<br />
<br />
=== Categories for Downloads ===<br />
<br />
It is possible to assign downloads to a category, which can have a unique color on the download listctrl, and can be saved to a different folder than the default one. <br />
<br />
To add a new category, right-click (and hold) on the tab titled 'All', which is located next to the green tick, just below the toolbar on the Transfers page. Then select 'Add Category' and fill in the desired details. A random color is selected by default, but this can be changed.<br />
<br />
To add a file to a category, right-click on it in the download listctrl, and select the desired category in the "Assign to Category" submenu. The item 'Unassigned' will assign it to the default category.<br />
<br />
When categories are added, a matching tab is added next to the original 'All' tab. Left-clicking on these will change the display to only display files assigned to this category. As a final note, the default view, the 'All' tab, allows for various forms of filtering. These can be accessed by right-clicking on the tab and selecting from the 'Select view filter' submenu.<br />
<br />
<br />
=== Where Are The Files? ===<br />
Once [[aMule]] starts downloading a file, it will create a number of files to keep track of that specific download. These files can be found in the subdir ''.aMule/Temp'' in your homedir (''~/.aMule/Temp''), but should not be touched in most cases. <br />
<br />
If you have incompleted downloads from [[eMule]], you can simply place the temp files in the ''~/.aMule/Temp'' directory if you wish for [[aMule]] to continue downloading them.<br />
<br />
However, once a file has been completed, it will be moved away from ''~/.aMule/Temp'' and to ''~/.aMule/Incoming'', where all completed files are placed by default. You can change both of these paths in the preferences should you wish to do so.<br />
<br />
Also, please note that the ''.aMule'' directory is a hidden directory, so you might have to enable showing of hidden files in your file-mananger, should you use one such.<br />
<br />
=== [[Share|Sharing]] [[File]]s ===<br />
First off, note the [[FAQ_ed2k|eDonkey2000 network]] is not meant to [[share]] small [[file]]s such as audio clips, but instead is optimized for distribution of larger [[file]]s. Also note that its your own responsibility to ensure that you do not violate any local laws regarding material shared.<br />
<br />
You can share files in two ways in [[aMule]]: <br />
<br />
The first method is to place the [[file]]s in the "Incoming" directory (''~/.aMule/Incoming'' on [http://www.unix.org Unix] like systems). After this has been done, you must either restart [[aMule]] or press the "Reload" button on the SharedFiles page.<br />
<br />
http://www.amule.org/reload_button.png<br />
<br />
The second method is to explicitly add [[shared directory|shared directories]] in which [[aMule]] will look for [[file]]s to [[share]]. This is done by clicking on the "Preferences" button and selecting the "Directories" page.<br />
<br />
http://www.amule.org/images/screenshots/prefs7.png<br />
<br />
From there, you can browse to the directory you wish to [[share]] via the directory-tree. Double-clicking on the folder icon will [[share]] the given directory and right-clicking on the folder icon will [[share]] the directory recursively.<br />
<br />
== Conclusion == <br />
Hopefully this brief introduction has given you an idea of how [[aMule]] works. If you feel that something is missing from this guide, please let us know or add it yourself.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=ReleaseRelease2005-07-01T23:07:00Z<p>212.242.54.121: </p>
<hr />
<div>Files that have PowerShare priority will be uploaded a 100% of the time if there are [[client]]s trying to download them. It doesn't matter how many other files you share or download.<br />
<br />
This makes it possible for you to release files efficiently and still download files normally.<br />
<br />
If the files with PowerShare priority don't use all of the bandwidth, shared files with non-PowerShare priority are uploaded. This means that you won't have to unshare everything that you are not shareing with PowerShare priorty.<br />
<br />
This gives more [[FAQ_eD2k-Kademlia#What_is_a_source?|source]]s for files on the [[FAQ_eD2k-Kademlia|network]] and makes sure the allotted upload bandwidth are always used a 100% efficiently to release your files.<br />
<br />
In [[aMule]] this corresponds to the "Release" priority for shared files.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=HowTo_compile_on_Win32_with_MinGWHowTo compile on Win32 with MinGW2005-05-02T13:38:48Z<p>212.242.54.121: </p>
<hr />
<div><center><h2>Originally by '''Madcat'''</h2></center><br />
<br />
This wiki page only supports the lastest [[aMule_CVS|CVS]] version of [[aMule]].<br />
<br />
== List of things you need to compile [[aMule]] ==<br />
<br />
'''Note:''' Some of these require manually moving includes/libs into the right directories.<br />
<br />
[http://www.microsoft.com/windows Windows] port of [http://gcc.gnu.org GNU C compiler] -> [http://prdownloads.sf.net/mingw/MinGW-3.1.0-1.exe?download Download]<br />
<br />
Minimal [http://www.gnu.org GNU] shell for [http://www.microsoft.com/windows Windows] -> [http://prdownloads.sf.net/mingw/MSYS-1.0.10.exe?download Download]<br />
<br />
Developer toolkit for [http://www.mingw.org/msys.shtml MSys] (for [http://www.gnu.org/software/cvs CVS] & co) -> [http://prdownloads.sf.net/mingw/msysDTK-1.0.1.exe?download Download]<br />
<br />
[http://www.gnu.org/software/libiconv LibIConv] (required by [http://www.gnu.org/software/gettext gettext]) -><br />
[http://prdownloads.sf.net/mingw/libiconv-1.8.0-2003.02.01-1.exe?download Download]<br />
<br />
[http://www.gnu.org/software/gettext GetText] (for [http://www.gnu.org/software/gettext po files], [http://www.gnu.org/software/automake/automake.html autogen.sh], etc) -><br />
[http://prdownloads.sf.net/mingw/gettext-0.11.5-2003.02.01-1.exe?download Download]<br />
<br />
[http://www.zlib.org zlib] compression library -><br />
[http://www.zlib.net/zlib-1.2.2.tar.gz Download]<br />
<br />
[http://www.microsoft.com/windows Windows] port of [[wxWidgets]] library -><br />
[http://prdownloads.sourceforge.net/wxwindows/wxMSW-2.6.0.zip Download]<br />
<br />
<br />
== Common guidelines, issues, solutions ==<br />
<br />
When compiling wxWidgets, you should make use of the following configure flags:<br />
''--disable-shared --without-checklistbox''<br />
<br />
Link statically against ''[http://www.zlib.org zlib]'' to avoid distributing extranous DLLs (and generally make life simpler). <br />
<br />
== Compilation ==<br />
<br />
The compilation itself it's actually just a matter of following the usual compilation way: ''./configure && make''<br />
<br />
However, [http://www.zlib.org zlib] detection might fail. If that's the case, you need to add ''--with-zlib=/local/'' to yout configure flags.<br />
<br />
== Compiling with [http://www.parinya.ca/mingwstudio.html MinGW Studio] ==<br />
<br />
'''NOTE:''' The compilation with [http://www.parinya.ca/mingwstudio.html MinGW Studio] is deprecated right now and generally doesn't work at the moment. Might work again in the future.<br />
<br />
Since the 2004/07/17, you can find in [http://www.gnu.org/software/cvs CVS] the file ''amule.msp'' which is the project file relative to the [http://www.parinya.ca/mingwstudio.html MinGW Studio] IDE ([http://www.gnu.org/philosophy/free-sw.html Free] and under [http://www.gnu.org/copyleft/gpl.html GPL] at http://www.parinya.ca/ and shipped with precompiled [[wxWidgets|wxMSW]]). <br />
<br />
Install [http://www.parinya.ca/mingwstudio.html MinGW Studio], add [http://www.zlib.org Zlib] and [http://curl.haxx.se Curl] compiled libs in The [http://www.parinya.ca/mingwstudio.html MinGW Studio] tree.<br />
<br />
Then, open ''amule.msp'' with [http://www.parinya.ca/mingwstudio.html MinGW Studio], press '''F7''', and [[aMule]] "should" be compiled :)<br />
<br />
Yes, I know, "compile" is not the same as "work" ... But it is a great begining</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Using_another_wxinstallUsing another wxinstall2005-03-21T18:46:21Z<p>212.242.54.121: --prefix needs full path</p>
<hr />
<div><center><br />
'''English''' | [[Using another wxinstall-de|Deutsch]]<br />
</center><br />
<br />
If there's already a version of [[wxWidgets]] installed, but you want [[aMule]] to use another (probably newer) one, here are the steps to follow:<br />
<br />
First, create the target directory (in this article, as an example, ''~/aMule/'' will be used), where [[wxWidgets]] and [[aMule]] will reside (they don't need to be in the same dir, but it makes life easier). Then configure [[wxWidgets]] and [[aMule]] accordingly (assuming [[wxWidgets]] 2.4.2 and current (=>rc8) aMule).<br />
<br />
It is recommended that you read the article about [[Compilation_Installation#Step_1:_wxGTK|how to compile wxGTK]] and (optionally, only if installing a [[wxWidgets]] version prior to 2.5) [[Compilation_Installation#Step_2:_wxBase|how to compile wxBase]]<br />
<br />
In [[aMule]] source dir:<br><br />
''./configure --prefix=/home/'''user'''/aMule/ --enable-debug --disable-optimize --with-wx-config=/home/'''user'''/aMule/bin/wx-config --with-wxbase-config=/home/'''user'''/aMule/bin/wxbase-2.4-config''<br><br />
''make && make install''<br />
<br />
'''NOTE:''' On some distros, instead of ''--with-wx-config=/home/'''user'''/aMule/bin/wx-config'' you might need to use ''--with-wx-config=/home/'''user'''/aMule/bin/wxgtk-2.4-config''<br />
<br />
'''NOTE 2:''' Sometimes [[wxBase]] will overwrite ''wx-config''. You can know if it has done so by running ''wx-config --basename''. It should show ''wx_gtk''. If it doesn't, please reinstall [[wxGTK]] so it will overwritte ''wx-config'' to link it to the [[wxGTK]] file.<br />
<br />
On the above example, [[aMule]] binary will be installed in ''~/aMule/bin/'' directory.<br />
<br />
Also note that ''--with-wxbase-config=...'' should only be used with [[wxWidgets]] versions prior to 2.5.<br />
<br />
To start [[aMule]], you need to explicitely specifiy the LD path each time you run it:<br />
<br />
''export LD_LIBRARY_PATH=~/aMule/lib:$LD_LIBRARY_PATH''<br><br />
''export LC_ALL=en_EN.UTF-8''<br />
<br />
'''NOTE 3:''' On some systems the above export command does not work, you have instead to run<br><br />
''export LD_LIBRARY_PATH=~/aMule/lib/:$LD_LIBRARY_PATH''<br><br />
This has been observed on [[Debian]] and [http://www.gentoo.org Gentoo Linux].<br />
<br />
Please remember to create [[Backtraces]] and provide them to the [[AMule_devs|aMule development team]].</div>212.242.54.121http://wiki.amule.org/t/index.php?title=HowTo_Compile_aMuledHowTo Compile aMuled2005-03-21T12:33:44Z<p>212.242.54.121: </p>
<hr />
<div>== 1st ==<br />
<br />
'''NOTE:''' If you have already installed [[wxWidgets|wxGTK]] 2.5.4 or higher, jump directly into the [[#2nd|second step]], since [[wxGTK]] 2.5.4 includes [[wxBase]] 2.5.4. Note that amuled will not compile with earlier versions of wxWidgets, such as version 2.4.2!<br />
<br />
Download [[wxBase]] 2.5.4 or higher from http://www.wxWidgets.org<br />
unpack it, and do as user<br />
*''./configure --prefix=/usr/''<br />
*''make''<br />
as root <br />
*''make install''<br />
*''ldconfig''<br />
<br />
<br />
== 2nd ==<br />
<br />
*Download [[aMule CVS|amule-cvs]] from http://amule.hirnriss.net <br />
Don't use version 2.0.0-rc8, there was a severe bug in it concerning [[aMuled]]!<br />
<br />
Unpack it, and do as user<br />
*''./configure --enable-amulecmd --enable-webserver --disable-monolithic --enable-amule-daemon''<br />
*''make''<br />
as root <br />
*''make install''<br />
<br />
Edit( I had to copy all wx lib files, libwx_base-2.5.so.4.0.0 and symlinks, from /usr/local/lib to /usr/lib then it worked) <br />
<br />
That's it. You now have a working [[aMuled|aMule-daemon]] in ''/usr/local/bin''<br><br />
Now you need to configure it. To create the ''~/.eMule'' file, which is the preferences file, run [[aMuled]] once. <br><br />
The ''~/.eMule'' file and the ''~/.aMule'' directory will be creted in the home directory of the user that ran [[aMuled]]. <br><br />
You probably want [[aMuleWeb]] to control your [[aMuled|daemon]]. To be able to use that you need to enable [[External Connections]]. Check [[Webserver-1.2.x|this article]].<br><br />
I know it's for 1.2.x but since you dont have a GUI to setup everything this is what you want.<br><br />
<br />
== Where to report problems and questions? ==<br />
<br />
For Problems or Questions just report on [http://forum.amule.org aMule forum] or join [[IRC]] channel [irc://irc.freenode.net/amule #amule] at [irc://irc.freenode.net irc.freenode.net]<br />
<br />
[[User:Stefanero|Stefanero]]</div>212.242.54.121http://wiki.amule.org/t/index.php?title=HowTo_Compile_aMuledHowTo Compile aMuled2005-03-21T12:32:45Z<p>212.242.54.121: </p>
<hr />
<div>== 1st ==<br />
<br />
'''NOTE:''' If you have already installed [[wxWidgets|wxGTK]] 2.5.4 or higher, jump directly into the [[#2nd|second step]], since [[wxGTK]] 2.5.4 includes [[wxBase]] 2.5.4. Note that the aMule daemon will not compile with earlier versions of wxGTK, such as wxGTK-2.4.2!<br />
<br />
Download [[wxBase]] 2.5.4 or higher from http://www.wxWidgets.org<br />
unpack it, and do as user<br />
*''./configure --prefix=/usr/''<br />
*''make''<br />
as root <br />
*''make install''<br />
*''ldconfig''<br />
<br />
<br />
== 2nd ==<br />
<br />
*Download [[aMule CVS|amule-cvs]] from http://amule.hirnriss.net <br />
Don't use version 2.0.0-rc8, there was a severe bug in it concerning [[aMuled]]!<br />
<br />
Unpack it, and do as user<br />
*''./configure --enable-amulecmd --enable-webserver --disable-monolithic --enable-amule-daemon''<br />
*''make''<br />
as root <br />
*''make install''<br />
<br />
Edit( I had to copy all wx lib files, libwx_base-2.5.so.4.0.0 and symlinks, from /usr/local/lib to /usr/lib then it worked) <br />
<br />
That's it. You now have a working [[aMuled|aMule-daemon]] in ''/usr/local/bin''<br><br />
Now you need to configure it. To create the ''~/.eMule'' file, which is the preferences file, run [[aMuled]] once. <br><br />
The ''~/.eMule'' file and the ''~/.aMule'' directory will be creted in the home directory of the user that ran [[aMuled]]. <br><br />
You probably want [[aMuleWeb]] to control your [[aMuled|daemon]]. To be able to use that you need to enable [[External Connections]]. Check [[Webserver-1.2.x|this article]].<br><br />
I know it's for 1.2.x but since you dont have a GUI to setup everything this is what you want.<br><br />
<br />
== Where to report problems and questions? ==<br />
<br />
For Problems or Questions just report on [http://forum.amule.org aMule forum] or join [[IRC]] channel [irc://irc.freenode.net/amule #amule] at [irc://irc.freenode.net irc.freenode.net]<br />
<br />
[[User:Stefanero|Stefanero]]</div>212.242.54.121http://wiki.amule.org/t/index.php?title=AMule_is_slowAMule is slow2005-03-21T12:22:56Z<p>212.242.54.121: Added comment about the effect of long queues.</p>
<hr />
<div><center>'''English''' | [[AMule_is_slow-it|Italiano]] | [[AMule_is_slow-nl|Nederlands]]</center><br />
<br />
== [[aMule]] is slow ==<br />
<br />
So [[aMule]] is slow? This can be due to:<br />
<br />
*[[#Your fault|Your fault]]<br />
*[[#The network's fault|The network's fault]]<br />
<br />
== Your fault ==<br />
<br />
This is a list of issues which can be the reason for slow download speeds:<br />
<br />
*A low value in "Preferences"->"Download limit".<br />
*A low value in "Preferences"->"Upload limit". Upload limits under 4 kbps limit your download speed to 3 times your upload speed. Upload limits under 10 kbps limit your download speed to 4 times your upload speed. Upload limits above or equal to 10 kbps give you unlimited download speed, limited only by the "Download limit" preference value (read [[FAQ_eD2k-Kademlia#Are_there_any_limitations_on_the_ED2K_network?|this link]] to know more about it).<br />
*A too high value in "Preferences"->"Upload limit". Your line may get congested! (depends on your line-speed)<br />
*A too low value in "Preferences"->"Max Connections". There are not enough connections available.<br />
*A too high value in "Preferences"->"Max Connections". Too many connections are congesting your line.<br />
*A too low value in "Core Tweaks"->"Max New Connections". It takes very long to aquire sources.<br />
*A too high value in "Core Tweaks"->"Max New Connections". Your line gets congested, many new connections produce much overhead-bandwidth.<br />
*Having [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|Low ID]].<br />
*Some [http://en.wikipedia.org/wiki/ISP ISP]s block or limit connections to the standard [[FAQ_eD2k-Kademlia#What_is_ED2K?|eD2k]] [[FAQ_eD2k-Kademlia#Which_ports_do_I_have_to_configure_in_a_firewall_or_router_to_run_aMule?|ports]]. Try changing the port in "Preferences"->"Connections" to some other values.<br />
*Your firewall may be blocking some ports/protocols used by [[aMule]] and/or you did not forward these ports in your router (again, see [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|Low ID]]).<br />
<br />
== The network's fault ==<br />
<br />
We're sorry to tell you that sometimes, the low speeds aren't due to a bad [[aMule]] code or a bad configuration, but due to other facts. This is a list:<br />
<br />
*The [[FAQ_eD2k-Kademlia#What_is_ED2K?|eD2k]] is a slow network. In some other [[P2P]] networks you can easily download faster. The [[FAQ_eD2k-Kademlia#What_is_ED2K?|eD2k]] network is one of the fastest [[P2P]] networks existing, but its main goal is availability. While on other popular networks you'll be able to download very fast, you'll quickly find out that in the [[FAQ_eD2k-Kademlia#What_is_ED2K?|eD2k]] network there are millions of files you'll be unable to find in any other network.<br />
*[[FAQ_eD2k-Kademlia#What_is_all_that_credits,_rate_and_score_stuff_about?|Credits]]. If you are running [[aMule]] for the first time or if you deleted some files in the ''~/.aMule'' directory, you'll have no [[FAQ_eD2k-Kademlia#What_is_all_that_credits,_rate_and_score_stuff_about?|credits]]. [[FAQ_eD2k-Kademlia#What_is_all_that_credits,_rate_and_score_stuff_about?|Credits]] grant fast downloads. If you don't know what they are, read [[FAQ_eD2k-Kademlia#What_is_all_that_credits,_rate_and_score_stuff_about?|this]].<br />
*The file's availability. Rare files, old files, extremly new files... this kind of files have very few [[FAQ_eD2k-Kademlia#What_is_a_source?|source]]s, so it takes quite some time for [[aMule]] to connect to some other [[client]] sharing it.<br />
*Long queues: eMule and most of its variants use long queues, the default maximum size being 5.000. While this means that one cannot jump ahead of other clients by rapidly re-asking a source (a problem seen before the time of eMule), it also means that one must be willing to wait in line and that can for a new client with no credits modifiers take a while. <br />
*Check the [[FAQ network|network FAQ]].</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-03-04T18:30:18Z<p>212.242.54.121: </p>
<hr />
<div>This article details the coding style that should be adopted when writing changes to the [[aMule]] codebase. Various useful information for [[aMule]] (new and old) [[aMule_devs|developers]] can also be found here.<br />
<br />
== Formatting ==<br />
<br />
=== Indenting ===<br />
<br />
==== Use tabs ====<br />
<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
=== Whitespace ===<br />
<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
=== Brackets ===<br />
<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of ''if''/''while''/etc blocks.<br />
<br />
=== Misc ===<br />
<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the ''//'' chars when writing comments.<br />
<br />
== Documenting comments ==<br />
<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in ''CMD4Hash.h'', ''BarShader.*'', ''ServerListCtrl.*'' and others. More information on the usage and syntax of [http://www.stack.nl/~dimitri/doxygen doxygen] can be found in the [http://www.stack.nl/~dimitri/doxygen/manual.html doxygen documentation].<br />
<br />
Use the following format, which is [http://www.stack.nl/~dimitri/doxygen doxygen] compatible.<br />
<br />
=== Functions, classes, structs, etc === <br />
<br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc ===<br />
<br />
//! <Description><br />
<br />
== Coding ==<br />
<br />
=== Naming Style ===<br />
<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (''it'', ''i'', ''x'', ''y'', etc).<br />
<br />
===== Functions =====<br />
<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles described below<br />
<br />
===== Variables =====<br />
<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with ''g_''<br />
* Prefix static variables with ''s_''<br />
* Prefix member variables with ''m_''<br />
<br />
===== Classes =====<br />
<br />
* Prefix classnames with ''C''<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
===== Constants =====<br />
<br />
* Use ALLUPPERCASE names<br />
<br />
* Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
===== Filenames =====<br />
<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
=== Const correctness ===<br />
<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This increases the ability for us to write safer code and is a good thing.<br />
<br />
===== References =====<br />
<br />
Always use references where passing large datatypes suchs as [http://www.wxwidgets.org/manuals/2.4.2/wx368.htm ''wxString''] and ''CMD4Hash'' and only use non-const references if we are going to change the passed variables.<br />
<br />
<br />
=== Lists/etc ===<br />
<br />
Only use raw arrays when absolutely nessesary, in ALL other cases use:<br />
1) STL containers, or<br />
2) wxWidgets containers<br />
<br />
However, for consistency STL containers should always be used unless there is a major reason for doing otherwise. Using STL containers gives us the advantage of making it possible to use the many algorithms in the STL library and they are usually faster than the corresponding wxWidgets container.<br />
<br />
=== Deleting ===<br />
<br />
Deleting a NULL pointer is a valid operation, so checks against NULL only clutter the code needlesly. <br />
<br />
=== Hacks ===<br />
<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
<br />
Helper functions which can have use across the app should be placed in ''otherfunctions.h''.<br />
<br />
Whenever possible, prefer [[wxWidgets]] functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.<br />
<br />
== IMPORTANT: What to avoid (The special 'I kill you' section!) ==<br />
<br />
Do NEVER NEVER use unicode2char and char2unicode functions at all. Same for unicode2UTF8 and UTF82unicode, and anything related to converting unicode wxStrings into char or wchar buffers. This is specially true with functions dealing with interface, where we should ALWAYS use wxStrings, and never use string conversion to construct that wxString.<br />
<br />
''The only places this is allowed is on printf() calls for debug. And if you REALLY need to use them in other scenario, like network communication or file handling use them VERY carefully. There are comments about the proper use at the beggining of StringFunctions.h. If you don't know if it's right or what to use, just ask, probably Kry is the best one to reply to that questions. Make someone review the code if you're not experienced and want to use that.''<br />
<br />
<br />
Do NEVER use wxFile or wxFFile - use CFile instead. It has several bugfixes over wxFile, and it will work perfectly for handling UTF8 filenames on unicode aMule, such as anything non-ascii.<br />
<br />
''There should be no problem using wxFile and wxFFile for amule-related files, like server.met and others, that are never unicoded, but the use of CFile is advisable to keep coherence over the system and easier replacement when a valid wxFile is released from wxWidgets devs.''<br />
<br />
Do NEVER use wxFind{First,Next}File. Use the CDirIterator class found in CFile.*. Reasons for this are the same as for wxFile and wxFFile: they don't handle unicode filenames properly.<br />
<br />
''No, there's not exception for this. Just never use it.''<br />
<br />
Avoid wxDateTime::Now().Format{Time, Date} as if it was Satan itself. Mainly, it asserts and breaks on several locale, mainly chinese and other asian languages. Use wxDateTime::Now().FormatISO{Time, Date}. People will have to live with english formated date and time strings.<br />
<br />
''No excuses for this either. It will have to go like this till wx fixes it.''<br />
<br />
When you use a string to build a wxString, like "aMule", you MUST use wxT("aMule") if you want it not to be translated and _("aMule") if you want it to be translated. Failure to do so will result in aMule not being compilable in unicode mode, and the coder responsive will be killed and buried alive, not neccesarily in that order.<br />
<br />
''As a side note, debug messages should be ALWAYS in english, and messages meant to be for the user should be translated. This is so we can read debug info without translating it.''<br />
<br />
Do NEVER use CList/CTypedPtrList. This classes were a implementation of a MFC-compatible CList, and they are hand-made lists. they're known to be buggy and had to be fixed several times in the past. Instead, use stl containers or wxWidgets containers, as said on Lists/etc section. As a matter of fact, if you see a CList or CTypedPtrList on the code, clean it.<br />
<br />
''There are places in the code still using those classes, mainly the part about averages that Emilio wrote for the stats. The reason for this is aminly some special functions for recycle nodes as head/tail he added to the CList class. While this improved performance, it breaks the rules, and we should consider cleaning it. Other than that, there's no excuse to use CList classes.''<br />
<br />
Probably more things I should remember, so I'll make this list bigger later.<br />
<br />
=== Malloc ===<br />
<br />
Only use malloc when it is absolutely necessary, for instance when dealing with C-libs, in all other cases it should be avoided!<br />
<br />
<br />
== Usefull information ==<br />
* [http://www.joelonsoftware.com/articles/Unicode.html Basic Introduction to Unicode].<br />
* [http://www.sgi.com/tech/stl/table_of_contents.html An excellent reference to the STL implementation that GCC also uses].<br />
* [http://www.acmqueue.com/modules.php?name=Content&pa=showpage&pid=271 How Not to Write FORTRAN in Any Language].<br />
* [http://emuleplus.info/forum/index.php?showforum=23&hyperlink=/Developers/KB/Diagrams ED2K/eMule protocol flow-diagrams].</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-03-04T18:28:43Z<p>212.242.54.121: </p>
<hr />
<div>This article details the coding style that should be adopted when writing changes to the [[aMule]] codebase. Various useful information for [[aMule]] (new and old) [[aMule_devs|developers]] can also be found here.<br />
<br />
== Formatting ==<br />
<br />
=== Indenting ===<br />
<br />
==== Use tabs ====<br />
<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
=== Whitespace ===<br />
<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
=== Brackets ===<br />
<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of ''if''/''while''/etc blocks.<br />
<br />
=== Misc ===<br />
<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the ''//'' chars when writing comments.<br />
<br />
== Documenting comments ==<br />
<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in ''CMD4Hash.h'', ''BarShader.*'', ''ServerListCtrl.*'' and others. More information on the usage and syntax of [http://www.stack.nl/~dimitri/doxygen doxygen] can be found in the [http://www.stack.nl/~dimitri/doxygen/manual.html doxygen documentation].<br />
<br />
Use the following format, which is [http://www.stack.nl/~dimitri/doxygen doxygen] compatible.<br />
<br />
=== Functions, classes, structs, etc === <br />
<br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc ===<br />
<br />
//! <Description><br />
<br />
== Coding ==<br />
<br />
=== Naming Style ===<br />
<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (''it'', ''i'', ''x'', ''y'', etc).<br />
<br />
===== Functions =====<br />
<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles described below<br />
<br />
===== Variables =====<br />
<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with ''g_''<br />
* Prefix static variables with ''s_''<br />
* Prefix member variables with ''m_''<br />
<br />
===== Classes =====<br />
<br />
* Prefix classnames with ''C''<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
===== Constants =====<br />
<br />
* Use ALLUPPERCASE names<br />
<br />
* Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
===== Filenames =====<br />
<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
=== Const correctness ===<br />
<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This increases the ability for us to write safer code and is a good thing.<br />
<br />
===== References =====<br />
<br />
Always use references where passing large datatypes suchs as [http://www.wxwidgets.org/manuals/2.4.2/wx368.htm ''wxString''] and ''CMD4Hash'' and only use non-const references if we are going to change the passed variables.<br />
<br />
<br />
=== Lists/etc ===<br />
<br />
Only use raw arrays when absolutely nessesary, in ALL other cases use:<br />
1) STL containers, or<br />
2) wxWidgets containers<br />
<br />
However, for consistency STL containers should always be used unless there is a major reason for doing otherwise. Using STL containers gives us the advantage of making it possible to use the many algorithms in the STL library and they are usually faster than the corresponding wxWidgets container.<br />
<br />
=== Deleting ===<br />
<br />
Deleting a NULL pointer is a valid operation, so checks against NULL only clutter the code needlesly. <br />
<br />
=== Hacks ===<br />
<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
<br />
Helper functions which can have use across the app should be placed in ''otherfunctions.h''.<br />
<br />
Whenever possible, prefer [[wxWidgets]] functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.<br />
<br />
== IMPORTANT: What to avoid (The special 'I kill you' section!) ==<br />
<br />
Do NEVER NEVER use unicode2char and char2unicode functions at all. Same for unicode2UTF8 and UTF82unicode, and anything related to converting unicode wxStrings into char or wchar buffers. This is specially true with functions dealing with interface, where we should ALWAYS use wxStrings, and never use string conversion to construct that wxString.<br />
<br />
''The only places this is allowed is on printf() calls for debug. And if you REALLY need to use them in other scenario, like network communication or file handling use them VERY carefully. There are comments about the proper use at the beggining of StringFunctions.h. If you don't know if it's right or what to use, just ask, probably Kry is the best one to reply to that questions. Make someone review the code if you're not experienced and want to use that.''<br />
<br />
<br />
Do NEVER use wxFile or wxFFile - use CFile instead. It has several bugfixes over wxFile, and it will work perfectly for handling UTF8 filenames on unicode aMule, such as anything non-ascii.<br />
<br />
''There should be no problem using wxFile and wxFFile for amule-related files, like server.met and others, that are never unicoded, but the use of CFile is advisable to keep coherence over the system and easier replacement when a valid wxFile is released from wxWidgets devs.''<br />
<br />
Do NEVER use wxFind{First,Next}File. Use the CDirIterator class found in CFile.*. Reasons for this are the same as for wxFile and wxFFile: they don't handle unicode filenames properly.<br />
<br />
''No, there's not exception for this. Just never use it.''<br />
<br />
Avoid wxDateTime::Now().Format{Time, Date} as if it was Satan itself. Mainly, it asserts and breaks on several locale, mainly chinese and other asian languages. Use wxDateTime::Now().FormatISO{Time, Date}. People will have to live with english formated date and time strings.<br />
<br />
''No excuses for this either. It will have to go like this till wx fixes it.''<br />
<br />
When you use a string to build a wxString, like "aMule", you MUST use wxT("aMule") if you want it not to be translated and _("aMule") if you want it to be translated. Failure to do so will result in aMule not being compilable in unicode mode, and the coder responsive will be killed and buried alive, not neccesarily in that order.<br />
<br />
''As a side note, debug messages should be ALWAYS in english, and messages meant to be for the user should be translated. This is so we can read debug info without translating it.''<br />
<br />
Do NEVER use CList/CTypedPtrList. This classes were a implementation of a MFC-compatible CList, and they are hand-made lists. they're known to be buggy and had to be fixed several times in the past. Instead, use stl containers or wxWidgets containers, as said on Lists/etc section. As a matter of fact, if you see a CList or CTypedPtrList on the code, clean it.<br />
<br />
''There are places in the code still using those classes, mainly the part about averages that Emilio wrote for the stats. The reason for this is aminly some special functions for recycle nodes as head/tail he added to the CList class. While this improved performance, it breaks the rules, and we should consider cleaning it. Other than that, there's no excuse to use CList classes.''<br />
<br />
Probably more things I should remember, so I'll make this list bigger later.<br />
<br />
=== Malloc ===<br />
<br />
Only use malloc when it is absolutely necessary, for instance when dealing with C-libs, in all other cases it should be avoided!<br />
<br />
<br />
== Usefull information ==<br />
* [http://www.joelonsoftware.com/articles/Unicode.html Basic Introduction to Unicode].<br />
* [http://www.sgi.com/tech/stl/table_of_contents.html An excellent reference to the STL implementation that GCC also uses].<br />
* [http://www.acmqueue.com/modules.php?name=Content&pa=showpage&pid=271 How Not to Write FORTRAN in Any Language].</div>212.242.54.121http://wiki.amule.org/t/index.php?title=FAQ_networkFAQ network2005-02-28T16:36:48Z<p>212.242.54.121: Reformatting, fixed some bad grammer and the expansion past the window-width.</p>
<hr />
<div>= Network speed: what you should know before asking questions =<br />
by Froenchenko Leonid, lfroen@gmail.com<br />
<br />
<br />
== Preface ==<br />
The purpose of this document is to clarify different issues regarding network <br />
speed that pops up from time to time in amule forum. Generally speaking, there're several reasons for questions about "amule network":<br />
<br />
* Speed reported by amule doesn't match provider given rate<br />
* Poor performance of amule itself or another network application on the same computer<br />
* What are key factors influencing network performance while amule is running<br />
<br />
Intended audience for this document are users who want to get better understanding of network functionality in general and in practical implication to amule functionality.<br />
<br />
This page, however, is not to be seen as comprehensive general purpose "Network <br />
FAQ".<br />
<br />
== Network speed - how much is it? ==<br />
While talking about network speed, people are using "bps" units, which mean <br />
"bits per second". The reason for ''bit'' rather that ''byte'' is pretty <br />
much historical, but also have engineering motivation behind. <br />
<br />
This motivation comes from the fact, that not all networks in the world are transferring bytes.<br />
<br />
There's also convention to use capital "B" in "Bps" when speed is marked <br />
in "bytes per second". However, this convention is not widely accepted. Particularly, organizations like IETF and IEEE are stick to original "bps".<br />
<br />
== Prefixes ==<br />
Since their invention, networks made quite a progress, and now we have networks <br />
that transfers thousands and millions bits and more bits per second. For marking those speeds, prefixes ''"kilo"'', ''"mega"'', ''"giga"'', ''"tera"'' etc. are used. <br />
<br />
It is a <u>common mistake</u> to think that values with those prefixes are the same as in computer science, i.e. powers of 2. The truth is that, for historical reasons, prefixes in networking have a decimal base, and not a binary one.<br />
<br />
<table cellpadding="2" cellspacing="2" border="1" width="100%"<br />
title="Table 1"><br />
<tr><br />
<th valign="middle" title="Table 1" align="center"<br />
bgcolor="#33ff33">Prefix</th><br />
<th valign="middle" align="center" bgcolor="#33ff33">meaning in computers</th><br />
<th valign="middle" title="Table 1" align="center"<br />
bgcolor="#33ff33">meaning in networks</th><br />
<th valign="middle" align="center" bgcolor="#33ff33">difference, %%</th><br />
</tr><br />
<tr><br />
<td valign="top">K (kilo)</td><br />
<td valign="top">2^10 = 1024</td><br />
<td valign="top">10^3 = 1000</td><br />
<td valign="top">2%</td><br />
</tr><br />
<tr><br />
<td valign="top">M (mega)</td><br />
<td valign="top">2^20 = 1,048,576</td><br />
<td valign="top">10^6 = 1,000,000</td><br />
<td valign="top">5%</td><br />
</tr><br />
<tr><br />
<td valign="top">G (giga)</td><br />
<td valign="top">2^30 = 1,073,741,624</td><br />
<td valign="top">10^9 = 1,000,000,000</td><br />
<td valign="top">7%</td><br />
</tr><br />
<tr><br />
<td valign="top">T (tera)</td><br />
<td valign="top">2^40 = 1,099,511,627,776</td><br />
<td valign="top">10^12 = 1,000,000,000,000</td><br />
<td valign="top">9%</td><br />
</tr> <br />
</table><br />
<br />
As you can see from the table above the error in calculation is about 5% when the prefix is incorrectly interpreted. Please note that the speed your provider tells you is "speed in network", i.e. calculated on decimal base.<br />
<br />
For example when your provider tells you that your link is "ADSL 256/128" you <br />
should understand that he means 256000/128000 bps. Which means, that the speed of your connection is 32000/16000 bps.<br />
<br />
== Protocol overhead - what is it about ==<br />
When amule is running, it constantly "talks" with other clients and servers. <br />
This data exchange is needed to identify itself, request information about <br />
available sources and files, perform searches and so on. <br />
<br />
Since this information has no use for the user itself, it's called "overhead" i.e. inevitable addition to the data you actually want to upload or download. <br />
<br />
aMule calls this "''connection overhead''". However, the number amule presents, includes only the size of the actual data that amule itself is sending to the network stack. Later, this data is sent down to the net with more overhead - now of network protocols. How much is it - lets see that in the next section.<br />
<br />
== Network overhead ==<br />
First of all - we're talking about IPv4 network. Once upon a time, there <br />
was only one type of IP network. Now there are two - IP version 4, the old<br />
we all know; and IP version 6 - the new protocol made to fix the limitations of IPv4. <br />
<br />
ED2K protocol by design, is unable to talk over IPv6 network, so users who have it (in Japan and China for example) will not be able to connect "as is". Using IPv4 means, that each packet (TCP, UDP, ICMP) will have IPv4 header.<br />
<br />
The minimum size of this header is 20 bytes. Header can have optional parts (each 4 bytes) and it's up to your provider - for example my adds 1 option dword. <-- WTF?<br />
<br />
When talking to other thing on ed2k network, amule uses the widely known TCP protocol. UDP is also used, but on a much smaller scale. As the reader might know, TCP is a reliable protocol, i.e. it's guaranteed that data which sent from one side will arrive on the other or an error will be reported.<br />
<br />
In order to achieve this, TCP send its own data in addition to the actual transfer. This data includes TCP client initial negotiation, checksums, sequence numbers and acknowledgments. All this is in the ''TCP header'' which is added to each packet sent. The size of this header is 20 bytes minimum.<br />
<br />
While being small overhead for large bulk transfer, it can take significant part of bandwidth when small amounts of data are being exchanged. <u>This is exactly what happens on source discovery part of amule</u>.<br />
<br />
Our client is trying to establish a connection and negotiate with a large number of other clients. Doing this, amule opens new TCP connections <u>''all the time''</u>. The amount of those connections is controlled by the ''"Maximum number of connections in 5 seconds"'' setting in the preferences. <br />
<br />
A typical number is about 100. Each TCP connection results in at least 3 packets traveling the net - one is a SYN packet, i.e. connection request, and one an ACK or a RST when the connection is accepted or refused, and SYN+ACK to establish the session. <br />
<br />
There's more overhead of DNS queries when an address is resolved, retries when a host doesn't reply and so on.<br />
<br />
=== On low level ===<br />
After passing TCP and IP layers packets go down to the network interface <br />
driver. The kind of this driver depends on the way your computer is connected to the internet. For simplicity sake we will assume that this computer is connected to the ISP directly, i.e. you have no LAN (or switch or router) between. <br />
<br />
Common setups that I'm aware of:<br />
<br />
* Analog modem, connected to telephone line (ISDN modem falls in this category too)<br />
* Cable modem, connected through ethernet, ISP gives you an IP address through DHCP<br />
* Cable modem, connected through ethernet, ISP requires you to configure PPPoE or PPTP tunnel<br />
* ADSL modem, connected through ethernet. You must have a PPPoE or PPTP tunnel<br />
* Variation of above - modem connected to PC by USB.<br />
<br />
In each of above setups there are different protocols in use, and different headers added to transmitted packets. But there's one important thing to note: <u>''ethernet frames traveling between cable/ADSL modem and PC, and don't reach the ISP''</u>. <br />
<br />
And consequently they are not counted in rate calculations. PPPoE and <br />
PPTP headers, on the contrary <u>''do reach the ISP''</u>. Whether or not <br />
your particular provider includes them in rate calculations I obviously have <br />
no idea about. For this reason I will exclude those headers from my calculations. <br />
<br />
If you think that your ISP includes it, add 4 bytes to the size of each packet.<br />
<br />
=== Example ===<br />
Let's see how much network overhead we have on a typical network. Our connection is a cable modem connected via an ethernet link to a PC directly (no router between them). <br />
<br />
In this setup we have IPv4 packets sent over ethernet. <br />
<br />
Lets say we have 10 new connections opened each second, and all are being accepted (successfully established TCP session). This alone sums up to (I'm counting data going up - from my computer to the net):<br />
<br />
''10 connection * 2 packets * (20 bytes of TCP + 20 bytes of IPv4) = 800 bytes of overhead.''<br />
<br />
This means that we are starting with 1.16*8 Kbps of "''invisible"''<br />
overhead caused by the very way the network works. Now, let's assume that<br />
after each connection is established our amule sends something to the other side and waits to receive an answer.<br />
<br />
''Total of 800 bytes + 800 bytes = 1600 bytes per second = 6400 bps = 6.4 Kbps''<br />
<br />
What we have here is 6.4 Kbps of network overhead alone. Taking into account <br />
that amule has other data to send (uploads) and it is not the only network <br />
application running we will have the following picture: <br />
<br />
Most likely the link to your provider is not that fast. aMule will <u>''try''</u> to open 10 connections per second and will <u>''try''</u> to upload on the specified speed. <br />
<br />
Your operating system will share all available bandwidth between those and between amule and other network applications (browser for example). Actual results will vary depending on specific OS settings.<br />
<br />
== ACK bottleneck ==<br />
In all calculations above there was one assumption - zero download. But downloading is what amule was built for. So let's examine how the overhead <br />
above affects your downloading speed. The answer is in TCP protocol. <br />
<br />
When TCP is sending data, it requires that the other side acknowledge the reception. So if client A is sending data to client B by TCP, B has to send a special ACK packets to A which tells B "ok, I got it". If, however, A doesn't receive the ACK packets in time, he will assume that either packet is lost. <br />
<br />
So, without going deeply into TCP specification: <u>''if B fails to send ACK to A, as a result A will transmit slower''</u>.<br />
<br />
Now let's see the situation in aMule. We saw in the previous chapter, that the uplink stream is congested by connection requests and uploads. As a result, there's a good chance that ACK packets for a file we are downloading <u>''will not be sent on time''</u>.<br />
<br />
The remote party will notice this and slow down. This is one more reason why the upstream should better not be too congested.<br />
<br />
== Is there anything I can do? ==<br />
OK, now that you understood why your network is so slow while amule is <br />
running you will maybe look for a way to fix this. The answer in 2 words: "rate limit".<br />
<br />
The first thing you should do is to assign realistic rate limits in amule <br />
itself. If you have a uplink rate of 128 Kbps don't set amules upload limit to <br />
16 (kilobytes per second) just because 128/8 = 16.<br />
<br />
A better, but far more complicated solution is to use the QoS and packet scheduling services of your OS. For example, you can give a higher priority to ACK packets to solve the above mentioned "ACK bottleneck" problem. <br />
<br />
The QoS topic, however, is beyond scope of this article.<br />
<br />
<br />
== Router (switch, home network): is there any difference? ==<br />
When the cable coming from your ISP is connected to some switching or routing <br />
device, which in turn is connected to several PC's, bandwidth is shared between <br />
them. <br />
<br />
So, having N computers connected, an ideal device would simply provide <br />
each one of them with 1/N of the total bandwidth. The situation may vary in real life, and your particular device may have different idea about fairness. <br />
<br />
Since you're not going to have the hardware specs of your router chipset the only advice here is "try and see yourself".</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-02-18T22:36:01Z<p>212.242.54.121: Adding useful links to the CS page.</p>
<hr />
<div>This article details the coding style that should be adopted when writing changes to the [[aMule]] codebase. Various useful information for aMule (new and old) developers can also be found here.<br />
<br />
== Formatting ==<br />
<br />
=== Indenting ===<br />
<br />
==== Use tabs ====<br />
<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
=== Whitespace ===<br />
<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
=== Brackets ===<br />
<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of ''if''/''while''/etc blocks.<br />
<br />
=== Misc ===<br />
<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the ''//'' chars when writing comments.<br />
<br />
== Documenting comments ==<br />
<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in ''CMD4Hash.h'', ''BarShader.*'', ''ServerListCtrl.*'' and others. More information on the usage and syntax of [http://www.stack.nl/~dimitri/doxygen doxygen] can be found in the [http://www.stack.nl/~dimitri/doxygen/manual.html doxygen documentation].<br />
<br />
Use the following format, which is [http://www.stack.nl/~dimitri/doxygen doxygen] compatible.<br />
<br />
=== Functions, classes, structs, etc === <br />
<br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc ===<br />
<br />
//! <Description><br />
<br />
== Coding ==<br />
<br />
=== Naming Style ===<br />
<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (''it'', ''i'', ''x'', ''y'', etc).<br />
<br />
===== Functions =====<br />
<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles described below<br />
<br />
===== Variables =====<br />
<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with ''g_''<br />
* Prefix static variables with ''s_''<br />
* Prefix member variables with ''m_''<br />
<br />
===== Classes =====<br />
<br />
* Prefix classnames with ''C''<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
===== Constants =====<br />
<br />
* Use ALLUPPERCASE names<br />
<br />
* Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
===== Filenames =====<br />
<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
=== Const correctness ===<br />
<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This increases the ability for us to write safer code and is a good thing.<br />
<br />
===== References =====<br />
<br />
Always use references where passing large datatypes suchs as [http://www.wxwidgets.org/manuals/2.4.2/wx368.htm ''wxString''] and ''CMD4Hash'' and only use non-const references if we are going to change the passed variables.<br />
<br />
<br />
=== Lists/etc ===<br />
<br />
Only use raw arrays when absolutely nessesary, in ALL other cases use:<br />
1) STL containers, or<br />
2) wxWidgets containers<br />
<br />
However, for consistency STL containers should always be used unless there is a major reason for doing otherwise. Using STL containers gives us the advantage of making it possible to use the many algorithms in the STL library and they are usually faster than the corresponding wxWidgets container.<br />
<br />
=== Deleting ===<br />
<br />
Deleting a NULL pointer is a valid operation, so checks against NULL only clutter the code needlesly. <br />
<br />
=== Hacks ===<br />
<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
<br />
Helper functions which can have use across the app should be placed in ''otherfunctions.h''.<br />
<br />
Whenever possible, prefer [[wxWidgets]] functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.<br />
<br />
== IMPORTANT: What to avoid (The special 'I kill you' section!) ==<br />
<br />
Do NEVER NEVER use unicode2char and char2unicode functions at all. Same for unicode2UTF8 and UTF82unicode, and anything related to converting unicode wxStrings into char or wchar buffers. This is specially true with functions dealing with interface, where we should ALWAYS use wxStrings, and never use string conversion to construct that wxString.<br />
<br />
''The only places this is allowed is on printf() calls for debug. And if you REALLY need to use them in other scenario, like network communication or file handling use them VERY carefully. There are comments about the proper use at the beggining of StringFunctions.h. If you don't know if it's right or what to use, just ask, probably Kry is the best one to reply to that questions. Make someone review the code if you're not experienced and want to use that.''<br />
<br />
<br />
Do NEVER use wxFile or wxFFile - use CFile instead. It has several bugfixes over wxFile, and it will work perfectly for handling UTF8 filenames on unicode aMule, such as anything non-ascii.<br />
<br />
''There should be no problem using wxFile and wxFFile for amule-related files, like server.met and others, that are never unicoded, but the use of CFile is advisable to keep coherence over the system and easier replacement when a valid wxFile is released from wxWidgets devs.''<br />
<br />
Do NEVER use wxFind{First,Next}File. Use the CDirIterator class found in CFile.*. Reasons for this are the same as for wxFile and wxFFile: they don't handle unicode filenames properly.<br />
<br />
''No, there's not exception for this. Just never use it.''<br />
<br />
Avoid wxDateTime::Now().Format{Time, Date} as if it was Satan itself. Mainly, it asserts and breaks on several locale, mainly chinese and other asian languages. Use wxDateTime::Now().FormatISO{Time, Date}. People will have to live with english formated date and time strings.<br />
<br />
''No excuses for this either. It will have to go like this till wx fixes it.''<br />
<br />
When you use a string to build a wxString, like "aMule", you MUST use wxT("aMule") if you want it not to be translated and _("aMule") if you want it to be translated. Failure to do so will result in aMule not being compilable in unicode mode, and the coder responsive will be killed and buried alive, not neccesarily in that order.<br />
<br />
''As a side note, debug messages should be ALWAYS in english, and messages meant to be for the user should be translated. This is so we can read debug info without translating it.''<br />
<br />
Do NEVER use CList/CTypedPtrList. This classes were a implementation of a MFC-compatible CList, and they are hand-made lists. they're known to be buggy and had to be fixed several times in the past. Instead, use stl containers or wxWidgets containers, as said on Lists/etc section. As a matter of fact, if you see a CList or CTypedPtrList on the code, clean it.<br />
<br />
''There are places in the code still using those classes, mainly the part about averages that Emilio wrote for the stats. The reason for this is aminly some special functions for recycle nodes as head/tail he added to the CList class. While this improved performance, it breaks the rules, and we should consider cleaning it. Other than that, there's no excuse to use CList classes.''<br />
<br />
Probably more things I should remember, so I'll make this list bigger later.<br />
<br />
=== Malloc ===<br />
<br />
Only use malloc when it is absolutely necessary, for instance when dealing with C-libs, in all other cases it should be avoided!<br />
<br />
<br />
== Usefull information ==<br />
* [http://www.joelonsoftware.com/articles/Unicode.html Basic Introduction to Unicode].<br />
* [http://www.sgi.com/tech/stl/table_of_contents.html An excellent reference to the STL implementation that GCC also uses].</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-02-17T22:28:19Z<p>212.242.54.121: </p>
<hr />
<div>This article details the coding style that should be adopted when writing changes to the [[aMule]] codebase.<br />
<br />
== Formatting ==<br />
<br />
=== Indenting ===<br />
<br />
==== Use tabs ====<br />
<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
=== Whitespace ===<br />
<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
=== Brackets ===<br />
<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of ''if''/''while''/etc blocks.<br />
<br />
=== Misc ===<br />
<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the ''//'' chars when writing comments.<br />
<br />
== Documenting comments ==<br />
<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in ''CMD4Hash.h'', ''BarShader.*'', ''ServerListCtrl.*'' and others. More information on the usage and syntax of [http://www.stack.nl/~dimitri/doxygen doxygen] can be found in the [http://www.stack.nl/~dimitri/doxygen/manual.html doxygen documentation].<br />
<br />
Use the following format, which is [http://www.stack.nl/~dimitri/doxygen doxygen] compatible.<br />
<br />
=== Functions, classes, structs, etc === <br />
<br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc ===<br />
<br />
//! <Description><br />
<br />
== Coding ==<br />
<br />
=== Naming Style ===<br />
<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (''it'', ''i'', ''x'', ''y'', etc).<br />
<br />
===== Functions =====<br />
<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles described below<br />
<br />
===== Variables =====<br />
<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with ''g_''<br />
* Prefix static variables with ''s_''<br />
* Prefix member variables with ''m_''<br />
<br />
===== Classes =====<br />
<br />
* Prefix classnames with ''C''<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
===== Constants =====<br />
<br />
* Use ALLUPPERCASE names<br />
<br />
* Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
===== Filenames =====<br />
<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
=== Const correctness ===<br />
<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This increases the ability for us to write safer code and is a good thing.<br />
<br />
===== References =====<br />
<br />
Always use references where passing large datatypes suchs as [http://www.wxwidgets.org/manuals/2.4.2/wx368.htm ''wxString''] and ''CMD4Hash'' and only use non-const references if we are going to change the passed variables.<br />
<br />
<br />
=== Lists/etc ===<br />
<br />
Only use raw arrays when absolutely nessesary, in ALL other cases use:<br />
1) STL containers, or<br />
2) wxWidgets containers<br />
<br />
However, for consistency STL containers should always be used unless there is a major reason for doing otherwise. Using STL containers gives us the advantage of making it possible to use the many algorithms in the STL library and they are usually faster than the corresponding wxWidgets container.<br />
<br />
=== Deleting ===<br />
<br />
Deleting a NULL pointer is a valid operation, so checks against NULL only clutter the code needlesly. <br />
<br />
=== Hacks ===<br />
<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
<br />
Helper functions which can have use across the app should be placed in ''otherfunctions.h''.<br />
<br />
Whenever possible, prefer [[wxWidgets]] functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.<br />
<br />
== IMPORTANT: What to avoid (The special 'I kill you' section!) ==<br />
<br />
Do NEVER NEVER use unicode2char and char2unicode functions at all. Same for unicode2UTF8 and UTF82unicode, and anything related to converting unicode wxStrings into char or wchar buffers. This is specially true with functions dealing with interface, where we should ALWAYS use wxStrings, and never use string conversion to construct that wxString.<br />
<br />
''The only places this is allowed is on printf() calls for debug. And if you REALLY need to use them in other scenario, like network communication or file handling use them VERY carefully. There are comments about the proper use at the beggining of StringFunctions.h. If you don't know if it's right or what to use, just ask, probably Kry is the best one to reply to that questions. Make someone review the code if you're not experienced and want to use that.''<br />
<br />
<br />
Do NEVER use wxFile or wxFFile - use CFile instead. It has several bugfixes over wxFile, and it will work perfectly for handling UTF8 filenames on unicode aMule, such as anything non-ascii.<br />
<br />
''There should be no problem using wxFile and wxFFile for amule-related files, like server.met and others, that are never unicoded, but the use of CFile is advisable to keep coherence over the system and easier replacement when a valid wxFile is released from wxWidgets devs.''<br />
<br />
Do NEVER use wxFind{First,Next}File. Use the CDirIterator class found in CFile.*. Reasons for this are the same as for wxFile and wxFFile: they don't handle unicode filenames properly.<br />
<br />
''No, there's not exception for this. Just never use it.''<br />
<br />
Avoid wxDateTime::Now().Format{Time, Date} as if it was Satan itself. Mainly, it asserts and breaks on several locale, mainly chinese and other asian languages. Use wxDateTime::Now().FormatISO{Time, Date}. People will have to live with english formated date and time strings.<br />
<br />
''No excuses for this either. It will have to go like this till wx fixes it.''<br />
<br />
When you use a string to build a wxString, like "aMule", you MUST use wxT("aMule") if you want it not to be translated and _("aMule") if you want it to be translated. Failure to do so will result in aMule not being compilable in unicode mode, and the coder responsive will be killed and buried alive, not neccesarily in that order.<br />
<br />
''As a side note, debug messages should be ALWAYS in english, and messages meant to be for the user should be translated. This is so we can read debug info without translating it.''<br />
<br />
Do NEVER use CList/CTypedPtrList. This classes were a implementation of a MFC-compatible CList, and they are hand-made lists. they're known to be buggy and had to be fixed several times in the past. Instead, use stl containers or wxWidgets containers, as said on Lists/etc section. As a matter of fact, if you see a CList or CTypedPtrList on the code, clean it.<br />
<br />
''There are places in the code still using those classes, mainly the part about averages that Emilio wrote for the stats. The reason for this is aminly some special functions for recycle nodes as head/tail he added to the CList class. While this improved performance, it breaks the rules, and we should consider cleaning it. Other than that, there's no excuse to use CList classes.''<br />
<br />
Probably more things I should remember, so I'll make this list bigger later.<br />
<br />
=== Malloc ===<br />
<br />
Only use malloc when it is absolutely necessary, for instance when dealing with C-libs, in all other cases it should be avoided!</div>212.242.54.121http://wiki.amule.org/t/index.php?title=AMule_devsAMule devs2005-02-12T00:04:00Z<p>212.242.54.121: Adding ken to devs and sorting the list ... pardon the pun. :P</p>
<hr />
<div>== The [[aMule]] Project ==<br />
The aMule project is led by a bunch in people who toil away in front of their computers, so that you can enjoy a stable and featureful P2P client.<br />
This page is about us.<br />
<br />
== The Team ==<br />
These are the people who work on aMule:<br />
<br />
=== Developers ===<br />
* [[User:deltaHF|deltaHF]]: Webmaster, Admin and from-time-to-time-coder ;)<br />
* [[User:falso|falso]]: [[CAS]] coder.<br />
* [[User:GonoszTopi|GonoszTopi]]: [[External Connections]] developer.<br />
* [[User:Hetfield|Hetfield]]: Admin, pretty-no-free-time coder.<br />
* [[User:Jacobo221|Jacobo221]]: Our man-for-all<br />
* [[User:ken|Ken]]: The big Mac guy.<br />
* [[User:Kry|Kry]]: Main developer and Admin<br />
* [[User:lfroen|lfroen]]: Core/GUI dedicated guy.<br />
* [[User:Phoenix|Phoenix]]: Code janitor junior.<br />
* [[User:thepolish|thepolish]]: [[aMule]] [[FAQ_utils|tools]] coder.<br />
* [[User:Unleashed|Unleashed]]: Sometimes around ;)<br />
* [[User:Xaignar|Xaignar]]: Code janitor extraordinaire!<br />
<br />
=== Testers ===<br />
* [[User:Citroklar|Citroklar]]: Tester, slave-work-coder (sometimes)<br />
* ender`: Tester<br />
* nachbarnebenan: Tester, and life-complicator by using large&strange nicks ;-P<br />
* nich: Tester<br />
* [[User:Stefanero|Stefanero]]: Supporter, Tester, and [[aMuleWeb]] Guru<br />
<br />
=== Special Gold Guest Members ===<br />
* [[User:Bigbob|Bigbob]]: Also known as ''[[User:Bigbob|Creteil]]''; [[aMule]] project creator.<br />
* [[User:Madcat|Madcat]]: The one and only kitty dev.<br />
* [[User:Tiku|Tiku]]: And God said: Let there be [[lMule]]!<br />
<br />
=== Others ===<br />
* [[User:Bootstrap|bootstrap]]: [[IRC]] bot (''bootbox'') and [[aMule CVS]] hoster<br />
* [[User:uberpenguin|uberpenguin]]: uberpenguin is extremely difficult to classify... Let us call him the 'official bystander to *mule'.<br />
* niet: [http://www.dns.net/dnsrd DNS] stuff, [[XAS]], tester.<br />
<br />
=== Former Team-members ===<br />
These are people who have worked on [[aMule]] in the past.<br />
Please note that this list doesn't include the people from before [[aMule]] forked off from [[xMule]], nor does it include people from the [[LMule]] days. If you wish to learn more about those, please visit the websites of those projects.<br />
<br />
==== Developers ====<br />
* shakraw: [[aMuleWeb]] mantainer.<br />
<br />
==== Testers ====<br />
<br />
== Helping ==<br />
We can always use another helping hand, and if you are interested, then I'd encourage you to contact us and see if you can help us. Currently, what we need the most is developers and testers, though also translators and others.<br />
<br />
=== Becoming a Developer ===<br />
To become a [[aMule]] Developer (tm), you'll need at the very least a working knowledge of C++, since that is the language in which [[aMule]] is written. You'll also need to learn about the GUI toolkit used by [[aMule]]: [[wxWidgets]]. Of course, you will have to follow our [[Coding Style]] rules or we will beat you to death with a brick in a sock.<br />
<br />
However, we do not require that you are an expert, only that you are willing to help and willing to learn.<br />
<br />
If you are interested, then simply drop by on [[IRC]] and let us know. Currently we use a private [http://www.gnu.org/software/cvs CVS] server, but after you've submitted a patch or two you can easily get r/w access to it. You can also post patches on the [http://www.amule-project.net/amule/board.php?boardid=47 Development] forum, however, virtually all discussions regarding development happens on [[IRC]], so learning about that is a good idea as well.<br />
<br />
We can use your skills if you are using one of the platforms where we aim at being usable on: Unix, *BSD, [http://www.sun.com/solaris Solaris], [http://www.apple.com Macs] and [http://www.microsoft.com/windows Windows].<br />
And if your operating system of choice isn't on that list, then maybe you can help add it.<br />
<br />
=== Becoming a Tester ===<br />
We need people who are willing to create complete bug-reports, as the standard is pretty low regarding user reports. This is rather simple, but takes patience. Please contact us on [[IRC]] for more information and read [[Backtraces|this guide on creating useful backtraces]].<br />
<br />
=== Becoming a Translator ===<br />
[[aMule]] already includes translations for a number of languages, however, we'll always welcome more, and even if your language of choice has been done already, then perhaps you can help improve it. Please see the [http://forum.amule.org/board.php?boardid=40 Translations forum] for more information on current translations, or contact us on [[IRC]]. Also, take a deep look into the [[Translations|aMule translation howto]].<br />
<br />
Of course, you can also work on [[Translating_Wiki|translating this wiki]]'s articles. There's still a lot of work to do!</div>212.242.54.121http://wiki.amule.org/t/index.php?title=WebserverWebserver2005-02-07T09:43:00Z<p>212.242.54.121: </p>
<hr />
<div>== Setting up [[aMuleWeb|Webserver]] with [[aMule]] ==<br />
<br />
=== [[Webserver-1.2.x|Webserver with aMule 1.2.8 or earlier]] ===<br />
<br />
=== Webserver with [[aMule]] 2.0.0-rc1 or later ===<br />
<br />
*[http://www.gnu.org/software/tar/tar.html Untar] the sources and copy '''''src/aMule.tmpl''''' and '''''src/webserver/''''' into your '''''~/.aMule/''''' directory. The following (run from the sources directory), should do so:<br />
:''$ cp -r src/aMule.tmpl src/webserver/ ~/.aMule/''<br />
<br />
* If you installed [[aMule]] from rpm, then you can do:<br />
:''$ cp /usr/share/amuleweb/aMule.tmpl ~/.aMule/''<br />
:''$ cp -r /usr/share/amuleweb/webserver/ ~/.aMule/''<br />
<br />
*Go to "Preferences"->"Remote Controls" (in [[aMule]]) and...<br />
**Enable "Accept External Connections".<br />
**Enable "Use TCP ports instead of unix local sockets".<br />
**Enter a password for external connections. If you don't do this, amuleweb will not communicate with amule.<br />
<br />
:'''NOTE:''' On some early [[aMule]] 2.0.0-rcX versions the above options weren't available (or didn't work). If you are using such [[aMule]] version and you don't wish to upgrade, then do the following:<br />
<br />
:Shutdown [[aMule]] if it is still running.<br />
:Edit your ''~/.eMule'' file, locate the ''[ExternalConnect]'' section and change:<br />
::''AcceptExternalConnections=1'' <-- To enable [[aMule]] listening for [[External Connections]].<br />
::''ECUseTCPPort=1'' <-- To use the [http://www.faqs.org/faqs/internet/tcp-ip/resource-list TCP] port. Very important since [http://www.unix.org Unix] sockets are disabled.<br />
::''ECPassword=ca3c365274907c6fd527068788e14639'' <-- To find the MD5 string for your password, do:<br />
:::''$ echo -n yourpasswordhere | md5sum | cut -d ' ' -f 1''<br />
:::''ca3c365274907c6fd527068788e14639''<br />
<br />
*Restart [[aMule]]<br />
<br />
*Go to your "Preferences"->"Remote Controls" (in [[aMule]]) and setup your passwords here for [[External Connections]] and [[aMuleWeb|webserver]] login.<br />
::'''NOTE:''' When you change your [[aMuleWeb|webserver]] and [[External Connections]] ports here, make sure to restart [[aMule]].<br />
::'''NOTE:''' that ''"Enable [[aMuleWeb|Webserver]]"'' has no effect and will be renamed in 2.0.0rc8. [[aMuleWeb|Webserver]] is always enabled as long as you have [[External Connections]] enabled.<br />
::'''NOTE:''' For users running [[aMuled|aMule Daemon]] you have to edit the ''.eMule'' file like shown above. For a way to setup a password check the [[Webserver-1.2.x|1.2.8 aMule HowTo]]. You can still do it in the same way.<br />
<br />
*Now you're done! You are ready to run [[aMuleWeb|amuleweb]] and connect to it.<br />
<br />
'''[[User:Stefanero|Stefanero]]'''<br />
<br />
== Connecting to [[aMuleWeb|amuleweb]] ==<br />
<br />
To run [[aMuleWeb]] run '''''amuleweb''''' on a terminal. For more information about running [[aMuleWeb]] check the [[aMuleWeb|aMuleWeb document]].<br />
<br />
Once [[aMuleWeb]] is running, open a web browser and connect to:<br />
<br />
''http://host:port''<br />
<br />
where ''host'' stands for your host's name (try with ''localhost'') and port stands for the [[aMuleWeb]] port ('''NOT''' the [[External Connections]] port).<br />
<br />
For example: ''http://localhost:4711''<br />
<br />
== Standard ports ==<br />
<br />
The ports can be set to anything, but this are the most used (the standard ones):<br />
<br />
*[[External Connections]]: 4712<br />
*[[aMuleWeb|amuleweb]]: 4711<br />
<br />
Make sure you do not confuse with what each of them is.<br />
<br />
== Where to report problems and questions? ==<br />
<br />
For Problems or Questions just report on http://forum.amule.org forum or join [[IRC]] channel [irc://irc.freenode.net/amule #amule] at [irc://irc.freenode.net irc.freenode.net]</div>212.242.54.121http://wiki.amule.org/t/index.php?title=AMule_devsAMule devs2005-02-07T09:37:08Z<p>212.242.54.121: </p>
<hr />
<div>== The [[aMule]] Project ==<br />
The aMule project is led by a bunch in people who toil away in front of their computers, so that you can enjoy a stable and featureful P2P client.<br />
This page is about us.<br />
<br />
== The Team ==<br />
These are the people who work on aMule:<br />
<br />
=== Developers ===<br />
<br />
* [[User:deltaHF|deltaHF]]: Webmaster, Admin and from-time-to-time-coder ;)<br />
* [[User:Jacobo221|Jacobo221]]: Our man-for-all<br />
* [[User:Kry|Kry]]: Main developer and Admin<br />
* [[User:lfroen|lfroen]]: Core/GUI dedicated guy.<br />
* [[User:Phoenix|Phoenix]]: Code janitor junior.<br />
* [[User:thepolish|thepolish]]: [[aMule]] [[FAQ_utils|tools]] coder.<br />
* [[User:Unleashed|Unleashed]]: Sometimes around ;)<br />
* [[User:Xaignar|Xaignar]]: Code janitor extraordinaire!<br />
* [[User:GonoszTopi|GonoszTopi]]: [[External Connections]] developer.<br />
* [[User:falso|falso]]: [[CAS]] coder.<br />
* [[User:Hetfield|Hetfield]]: Admin, pretty-no-free-time coder.<br />
<br />
=== Testers ===<br />
* [[User:Citroklar|Citroklar]]: Tester, slave-work-coder (sometimes)<br />
* ender`: Tester<br />
* nachbarnebenan: Tester, and life-complicator by using large&strange nicks ;-P<br />
* nich: Tester<br />
* [[User:Stefanero|Stefanero]]: Supporter, Tester, and [[aMuleWeb]] Guru<br />
<br />
=== Special Gold Guest Members ===<br />
* [[User:Bigbob|Bigbob]]: Also known as ''[[User:Bigbob|Creteil]]''; [[aMule]] project creator.<br />
* [[User:Madcat|Madcat]]: The one and only kitty dev.<br />
* [[User:Tiku|Tiku]]: And God said: Let there be [[lMule]]!<br />
<br />
=== Others ===<br />
* [[User:Bootstrap|bootstrap]]: [[IRC]] bot (''bootbox'') and [[aMule CVS]] hoster<br />
* [[User:uberpenguin|uberpenguin]]: uberpenguin is extremely difficult to classify... Let us call him the 'official bystander to *mule'.<br />
* niet: [http://www.dns.net/dnsrd DNS] stuff, [[XAS]], tester.<br />
<br />
=== Former Team-members ===<br />
These are people who have worked on [[aMule]] in the past.<br />
Please note that this list doesn't include the people from before [[aMule]] forked off from [[xMule]], nor does it include people from the [[LMule]] days. If you wish to learn more about those, please visit the websites of those projects.<br />
<br />
==== Developers ====<br />
* shakraw: [[aMuleWeb]] mantainer.<br />
<br />
==== Testers ====<br />
<br />
== Helping ==<br />
We can always use another helping hand, and if you are interested, then I'd encourage you to contact us and see if you can help us. Currently, what we need the most is developers and testers, though also translators and others.<br />
<br />
=== Becoming a Developer ===<br />
To become a [[aMule]] Developer (tm), you'll need at the very least a working knowledge of C++, since that is the language in which [[aMule]] is written. You'll also need to learn about the GUI toolkit used by [[aMule]]: [[wxWidgets]]. Of course, you will have to follow our [[Coding Style]] rules or we will beat you to death with a brick in a sock.<br />
<br />
However, we do not require that you are an expert, only that you are willing to help and willing to learn.<br />
<br />
If you are interested, then simply drop by on [[IRC]] and let us know. Currently we use a private [http://www.gnu.org/software/cvs CVS] server, but after you've submitted a patch or two you can easily get r/w access to it. You can also post patches on the [http://www.amule-project.net/amule/board.php?boardid=47 Development] forum, however, virtually all discussions regarding development happens on [[IRC]], so learning about that is a good idea as well.<br />
<br />
We can use your skills if you are using one of the platforms where we aim at being usable on: Unix, [http://www.sun.com/solaris Solaris], [http://www.apple.com Macs] and [http://www.microsoft.com/windows Windows].<br />
And if your operating system of choice isn't on that list, then maybe you can help add it.<br />
<br />
=== Becoming a Tester ===<br />
We need people who are willing to create complete bug-reports, as the standard is pretty low regarding user reports. This is rather simple, but takes patience. Please contact us on [[IRC]] for more information and read [[Backtraces|this guide on creating useful backtraces]].<br />
<br />
=== Becoming a Translator ===<br />
[[aMule]] already includes translations for a number of languages, however, we'll always welcome more, and even if your language of choice has been done already, then perhaps you can help improve it. Please see the [http://forum.amule.org/board.php?boardid=40 Translations forum] for more information on current translations, or contact us on [[IRC]]. Also, take a deep look into the [[Translations|aMule translation howto]].<br />
<br />
Of course, you can also work on [[Translating_Wiki|translating this wiki]]'s articles. There's still a lot of work to do!</div>212.242.54.121http://wiki.amule.org/t/index.php?title=AMule_devsAMule devs2005-02-07T09:36:35Z<p>212.242.54.121: </p>
<hr />
<div>== The [[aMule]] Project ==<br />
The aMule project is led by a bunch in people who toil away in front of their computers, so that you can enjoy a stable and featureful P2P client.<br />
This page is about us.<br />
<br />
== The Team ==<br />
These are the people who work on aMule:<br />
<br />
=== Developers ===<br />
<br />
* [[User:deltaHF|deltaHF]]: Webmaster, Admin and from-time-to-time-coder ;)<br />
* [[User:Jacobo221|Jacobo221]]: Our man-for-all<br />
* [[User:Kry|Kry]]: Main developer and Admin<br />
* [[User:lfroen|lfroen]]: Core/GUI dedicated guy.<br />
* [[User:Phoenix|Phoenix]]: Code janitor junior.<br />
* [[User:thepolish|thepolish]]: [[aMule]] [[FAQ_utils|tools]] coder.<br />
* [[User:Unleashed|Unleashed]]: Sometimes around ;)<br />
* [[User:Xaignar|Xaignar]]: Code janitor extraordinaire!<br />
* [[User:GonoszTopi|GonoszTopi]]: [[External Connections]] developer.<br />
* [[User:falso|falso]]: [[CAS]] coder.<br />
* [[User:Hetfield|Hetfield]]: Admin, pretty-no-free-time coder.<br />
<br />
=== Testers ===<br />
* [[User:Citroklar|Citroklar]]: Tester, slave-work-coder (sometimes)<br />
* ender`: Tester<br />
* nachbarnebenan: Tester, and life-complicator by using large&strange nicks ;-P<br />
* nich: Tester<br />
* [[User:Stefanero|Stefanero]]: Supporter, Tester, and [[aMuleWeb]] Guru<br />
<br />
=== Special Gold Guest Members ===<br />
* [[User:Bigbob|Bigbob]]: Also known as ''[[User:Bigbob|Creteil]]''; [[aMule]] project creator.<br />
* [[User:Madcat|Madcat]]: The one and only kitty dev.<br />
* [[User:Tiku|Tiku]]: And God said: Let there be [[lMule]]!<br />
<br />
=== Others ===<br />
* [[User:Bootstrap|bootstrap]]: [[IRC]] bot (''bootbox'') and [[aMule CVS]] hoster<br />
* [[User:uberpenguin|uberpenguin]]: uberpenguin is extremely difficult to classify... Let us call him the 'official bystander to *mule'.<br />
* niet: [http://www.dns.net/dnsrd DNS] stuff, [[XAS]], tester.<br />
<br />
=== Former Team-members ===<br />
These are people who have worked on [[aMule]] in the past.<br />
Please note that this list doesn't include the people from before [[aMule]] forked off from [[xMule]], nor does it include people from the [[LMule]] days. If you wish to learn more about those, please visit the websites of those projects.<br />
<br />
==== Developers ====<br />
* shakraw: [[aMuleWeb]] mantainer.<br />
<br />
==== Testers ====<br />
<br />
== Helping ==<br />
We can always use another helping hand, and if you are interested, then I'd encourage you to contact us and see if you can help us. Currently, what we need the most is developers and testers, though also translators and others.<br />
<br />
=== Becoming a Developer ===<br />
To become a [[aMule]] Developer (tm), you'll need at the very least a working knowledge of C++, since that is the language in which [[aMule]] is written. You'll also need to learn about the GUI toolkit used by [[aMule]]: [[wxWidgets]]. Of course, you'll will have to follow our [[Coding Style]] rules or we will beat you to death with a brick in a sock.<br />
<br />
However, we do not require that you are an expert, only that you are willing to help and willing to learn.<br />
<br />
If you are interested, then simply drop by on [[IRC]] and let us know. Currently we use a private [http://www.gnu.org/software/cvs CVS] server, but after you've submitted a patch or two you can easily get r/w access to it. You can also post patches on the [http://www.amule-project.net/amule/board.php?boardid=47 Development] forum, however, virtually all discussions regarding development happens on [[IRC]], so learning about that is a good idea as well.<br />
<br />
We can use your skills if you are using one of the platforms where we aim at being usable on: Unix, [http://www.sun.com/solaris Solaris], [http://www.apple.com Macs] and [http://www.microsoft.com/windows Windows].<br />
And if your operating system of choice isn't on that list, then maybe you can help add it.<br />
<br />
=== Becoming a Tester ===<br />
We need people who are willing to create complete bug-reports, as the standard is pretty low regarding user reports. This is rather simple, but takes patience. Please contact us on [[IRC]] for more information and read [[Backtraces|this guide on creating useful backtraces]].<br />
<br />
=== Becoming a Translator ===<br />
[[aMule]] already includes translations for a number of languages, however, we'll always welcome more, and even if your language of choice has been done already, then perhaps you can help improve it. Please see the [http://forum.amule.org/board.php?boardid=40 Translations forum] for more information on current translations, or contact us on [[IRC]]. Also, take a deep look into the [[Translations|aMule translation howto]].<br />
<br />
Of course, you can also work on [[Translating_Wiki|translating this wiki]]'s articles. There's still a lot of work to do!</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-02-06T20:19:53Z<p>212.242.54.121: </p>
<hr />
<div>This article details the coding style that should be adopted when writing changes to the [[aMule]] codebase.<br />
<br />
== Formatting ==<br />
<br />
=== Indenting ===<br />
<br />
==== Use tabs ====<br />
<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
=== Whitespace ===<br />
<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
=== Brackets ===<br />
<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of ''if''/''while''/etc blocks.<br />
<br />
=== Misc ===<br />
<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the ''//'' chars when writing comments.<br />
<br />
== Documenting comments ==<br />
<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in ''CMD4Hash.h'', ''BarShader.*'', ''ServerListCtrl.*'' and others. More information on the usage and syntax of [http://www.stack.nl/~dimitri/doxygen doxygen] can be found in the [http://www.stack.nl/~dimitri/doxygen/manual.html doxygen documentation].<br />
<br />
Use the following format, which is [http://www.stack.nl/~dimitri/doxygen doxygen] compatible.<br />
<br />
=== Functions, classes, structs, etc === <br />
<br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc ===<br />
<br />
//! <Description><br />
<br />
== Coding ==<br />
<br />
=== Naming Style ===<br />
<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (''it'', ''i'', ''x'', ''y'', etc).<br />
<br />
===== Functions =====<br />
<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles described below<br />
<br />
===== Variables =====<br />
<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with ''g_''<br />
* Prefix static variables with ''s_''<br />
* Prefix member variables with ''m_''<br />
<br />
===== Classes =====<br />
<br />
* Prefix classnames with ''C''<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
===== Constants =====<br />
<br />
* Use ALLUPPERCASE names<br />
<br />
* Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
===== Filenames =====<br />
<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
=== Const correctness ===<br />
<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This increases the ability for us to write safer code and is a good thing.<br />
<br />
===== References =====<br />
<br />
Always use references where passing large datatypes suchs as [http://www.wxwidgets.org/manuals/2.4.2/wx368.htm ''wxString''] and ''CMD4Hash'' and only use non-const references if we are going to change the passed variables.<br />
<br />
<br />
=== Lists/etc ===<br />
<br />
Only use raw arrays when absolutely nessesary, in ALL other cases use:<br />
1) STL containers, or<br />
2) CList/CTypedPtrList, or<br />
3) wxWidgets containers<br />
<br />
However, for consistency STL containers should always be used unless there is a major reason for doing otherwise. Using STL containers gives us the advantage of making it possible to use the many algorithms in the STL library and they are usually faster than the corresponding wxWidgets container.<br />
<br />
=== Deleting ===<br />
<br />
Delting a NULL pointer is a valid operation, so checks against NULL only clutter the code needlesly. <br />
<br />
=== Hacks ===<br />
<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
<br />
Helper functions which can have use across the app should be placed in ''otherfunctions.h''.<br />
<br />
Whenever possible, prefer [[wxWidgets]] functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.<br />
<br />
== IMPORTANT: What to avoid (The special 'I kill you' section!) ==<br />
<br />
Do NEVER NEVER use unicode2char and char2unicode functions at all. Same for unicode2UTF8 and UTF82unicode, and anything related to converting unicode wxStrings into char or wchar buffers. This is specially true with functions dealing with interface, where we should ALWAYS use wxStrings, and never use string conversion to construct that wxString.<br />
<br />
''The only places this is allowed is on printf() calls for debug. And if you REALLY need to use them in other scenario, like network communication or file handling use them VERY carefully. There are comments about the proper use at the beggining of StringFunctions.h. If you don't know if it's right or what to use, just ask, probably Kry is the best one to reply to that questions. Make someone review the code if you're not experienced and want to use that.''<br />
<br />
<br />
Do NEVER use wxFile or wxFFile - use CFile instead. It has several bugfixes over wxFile, and it will work perfectly for handling UTF8 filenames on unicode aMule, such as anything non-ascii.<br />
<br />
''There should be no problem using wxFile and wxFFile for amule-related files, like server.met and others, that are never unicoded, but the use of CFile is advisable to keep coherence over the system and easier replacement when a valid wxFile is released from wxWidgets devs.''<br />
<br />
Do NEVER use wxFind{First,Next}File. Use the CDirIterator class found in CFile.*. Reasons for this are the same as for wxFile and wxFFile: they don't handle unicode filenames properly.<br />
<br />
''No, there's not exception for this. Just never use it.''<br />
<br />
Avoid wxDateTime::Now().Format{Time, Date} as if it was Satan itself. Mainly, it asserts and breaks on several locale, mainly chinese and other asian languages. Use wxDateTime::Now().FormatISO{Time, Date}. People will have to live with english formated date and time strings.<br />
<br />
''No excuses for this either. It will have to go like this till wx fixes it.''<br />
<br />
When you use a string to build a wxString, like "aMule", you MUST use wxT("aMule") if you want it not to be translated and _("aMule") if you want it to be translated. Failure to do so will result in aMule not being compilable in unicode mode, and the coder responsive will be killed and buried alive, not neccesarily in that order.<br />
<br />
''As a side note, debug messages should be ALWAYS in english, and messages meant to be for the user should be translated. This is so we can read debug info without translating it.''<br />
<br />
Probably more things I should remember, so I'll make this list bigger later.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-02-06T20:15:06Z<p>212.242.54.121: </p>
<hr />
<div>This article details the coding style that should be adopted when writing changes to the [[aMule]] codebase.<br />
<br />
== Formatting ==<br />
<br />
=== Indenting ===<br />
<br />
==== Use tabs ====<br />
<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
=== Whitespace ===<br />
<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
=== Brackets ===<br />
<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of ''if''/''while''/etc blocks.<br />
<br />
=== Misc ===<br />
<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the ''//'' chars when writing comments.<br />
<br />
== Documenting comments ==<br />
<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in ''CMD4Hash.h'', ''BarShader.*'', ''ServerListCtrl.*'' and others. More information on the usage and syntax of [http://www.stack.nl/~dimitri/doxygen doxygen] can be found in the [http://www.stack.nl/~dimitri/doxygen/manual.html doxygen documentation].<br />
<br />
Use the following format, which is [http://www.stack.nl/~dimitri/doxygen doxygen] compatible.<br />
<br />
=== Functions, classes, structs, etc === <br />
<br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc ===<br />
<br />
//! <Description><br />
<br />
== Coding ==<br />
<br />
=== Naming Style ===<br />
<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (''it'', ''i'', ''x'', ''y'', etc).<br />
<br />
===== Functions =====<br />
<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles described below<br />
<br />
===== Variables =====<br />
<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with ''g_''<br />
* Prefix static variables with ''s_''<br />
* Prefix member variables with ''m_''<br />
<br />
===== Classes =====<br />
<br />
* Prefix classnames with ''C''<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
===== Constants =====<br />
<br />
* Use ALLUPPERCASE names<br />
<br />
* Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
===== Filenames =====<br />
<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
=== Const correctness ===<br />
<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This increases the ability for us to write safer code and is a good thing.<br />
<br />
===== References =====<br />
<br />
Always use references where passing large datatypes suchs as [http://www.wxwidgets.org/manuals/2.4.2/wx368.htm ''wxString''] and ''CMD4Hash'' and only use non-const references if we are going to change the passed variables.<br />
<br />
<br />
=== Lists/etc ===<br />
<br />
Only use raw arrays when absolutely nessesary, in ALL other cases use:<br />
1) STL containers, or<br />
2) CList/CTypedPtrList, or<br />
3) wxWidgets containers<br />
<br />
However, for consistency STL containers should always be used unless there is a major reasons for doing otherwise. Using STL containers also gives us the advantage of making possible to use the many algorithms in the STL library and STL containers are usually faster than the corresponding wxWidgets container.<br />
<br />
=== Deleting ===<br />
<br />
It is not needed to check pointers before deleting them, so checks against NULL only clutter the code needlesly. Such checks should only be used in cases where there is an need, as for instance in the Packet destructor.<br />
<br />
=== Hacks ===<br />
<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
<br />
Helper functions which can have use across the app should be placed in ''otherfunctions.h''.<br />
<br />
Whenever possible, prefer [[wxWidgets]] functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.<br />
<br />
== IMPORTANT: What to avoid (The special 'I kill you' section!) ==<br />
<br />
Do NEVER NEVER use unicode2char and char2unicode functions at all. Same for unicode2UTF8 and UTF82unicode, and anything related to converting unicode wxStrings into char or wchar buffers. This is specially true with functions dealing with interface, where we should ALWAYS use wxStrings, and never use string conversion to construct that wxString.<br />
<br />
''The only places this is allowed is on printf() calls for debug. And if you REALLY need to use them in other scenario, like network communication or file handling use them VERY carefully. There are comments about the proper use at the beggining of StringFunctions.h. If you don't know if it's right or what to use, just ask, probably Kry is the best one to reply to that questions. Make someone review the code if you're not experienced and want to use that.''<br />
<br />
<br />
Do NEVER use wxFile or wxFFile - use CFile instead. It has several bugfixes over wxFile, and it will work perfectly for handling UTF8 filenames on unicode aMule, such as anything non-ascii.<br />
<br />
''There should be no problem using wxFile and wxFFile for amule-related files, like server.met and others, that are never unicoded, but the use of CFile is advisable to keep coherence over the system and easier replacement when a valid wxFile is released from wxWidgets devs.''<br />
<br />
Do NEVER use wxFind{First,Next}File. Use the CDirIterator class found in CFile.*. Reasons for this are the same as for wxFile and wxFFile: they don't handle unicode filenames properly.<br />
<br />
''No, there's not exception for this. Just never use it.''<br />
<br />
Avoid wxDateTime::Now().Format{Time, Date} as if it was Satan itself. Mainly, it asserts and breaks on several locale, mainly chinese and other asian languages. Use wxDateTime::Now().FormatISO{Time, Date}. People will have to live with english formated date and time strings.<br />
<br />
''No excuses for this either. It will have to go like this till wx fixes it.''<br />
<br />
When you use a string to build a wxString, like "aMule", you MUST use wxT("aMule") if you want it not to be translated and _("aMule") if you want it to be translated. Failure to do so will result in aMule not being compilable in unicode mode, and the coder responsive will be killed and buried alive, not neccesarily in that order.<br />
<br />
''As a side note, debug messages should be ALWAYS in english, and messages meant to be for the user should be translated. This is so we can read debug info without translating it.''<br />
<br />
Probably more things I should remember, so I'll make this list bigger later.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-01-30T20:15:40Z<p>212.242.54.121: </p>
<hr />
<div>This page details the coding stile that should be addopted when writing changes to the aMule codebase.<br />
<br />
== Formatting ==<br />
=== Indenting ===<br />
==== Use tabs ====<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
<br />
=== Whitespace ===<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
<br />
<br />
=== Brackets ===<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of if/while/etc blocks.<br />
<br />
<br />
=== Misc ===<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the "//" chars when writing comments.<br />
<br />
<br />
== Documenting comments ==<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in CMD4Hash.h, BarShader.*, ServerListCtrl.* and others. More information on the usage and syntax of doxygen can be found in the doxygen documentation.<br />
<br />
Use the following format, which is doxygen compatible.<br />
<br />
=== Functions, classes, structs, etc. === <br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc. ===<br />
//! <Description><br />
<br />
<br />
== Coding ==<br />
=== Naming Style ===<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (it, i, x, y, etc).<br />
<br />
Functions:<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles<br />
described below<br />
<br />
Variables:<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with g_<br />
* Prefix static variables with s_<br />
* Prefix member variables with m_<br />
<br />
Classes:<br />
* Prefix classnames with "C"<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
Constants:<br />
* Use ALLUPPERCASE names<br />
<br />
Filenames:<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
<br />
=== Const Correctness ===<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This increases the ability for us to write safer code and is a good thing.<br />
<br />
==== Consts vs. Defines ====<br />
Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
==== References ====<br />
Always use references where passing large datatypes suchs as wxString and CMD4Hash and only use non-const references if we are going to change the passed variables<br />
<br />
=== Hacks ===<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
Helper functions which can have use across the app should be placed in otherfunctions.h<br />
<br />
Whenever possible, prefer wxWidgets functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Coding_StyleCoding Style2005-01-30T19:06:21Z<p>212.242.54.121: </p>
<hr />
<div>This page details the coding stile that should be addopted when writing changes to the aMule codebase.<br />
<br />
== Formatting ==<br />
=== Indenting ===<br />
==== Use tabs ====<br />
Always use tabs for indenting, do not use spaces. The size of each tab should be equal to 4 spaces.<br />
<br />
==== Scopes ====<br />
Indent inside new scopes, including classes, structs, functions, etc. <br />
<br />
Examples:<br />
if ( false ) {<br />
...<br />
} else {<br />
...<br />
}<br />
<br />
class foo<br />
{<br />
foo() {<br />
...<br />
}<br />
}<br />
<br />
<br />
=== Whitespace ===<br />
Place whitespace between brackets and keywords, and between operators and variables:<br />
<br />
if (something == true);<br />
<br />
rather than<br />
<br />
if(something==true);<br />
<br />
<br />
<br />
=== Brackets ===<br />
Brackets are placed on the same line as the construct with the exception of non-inlined functions, structs and classes. Perfer the usage of brackets, even when optional, as in the case of if/while/etc blocks.<br />
<br />
<br />
=== Misc ===<br />
* When using the trinary operator, place brackets to promote readability.<br />
* Add a space after the "//" chars when writing comments.<br />
<br />
<br />
== Documenting comments ==<br />
Always remember to documment new functions and classes! Examples of documented classes can be found in can be found in CMD4Hash.h, BarShader.*, ServerListCtrl.* and others. More information on the usage and syntax of doxygen can be found in the doxygen documentation.<br />
<br />
Use the following format, which is doxygen compatible.<br />
<br />
=== Functions, classes, structs, etc. === <br />
/**<br />
* <Short description><br />
*<br />
* [@param <Param_1 description>]<br />
* [@param <Param_n description>]<br />
* [@return <return value description>]<br />
*<br />
* [Long description]<br />
* [@see <reference to other relevant function>]<br />
*/<br />
<br />
=== Variables, typedefs, constants, etc. ===<br />
//! <Description><br />
<br />
<br />
== Coding ==<br />
=== Naming Style ===<br />
Always try to use descriptive names, except when it adds nothing to the readability, such as iterator varibles and counters (it, i, x, y, etc).<br />
<br />
Functions:<br />
* Function names should follow the AllWordsAreUppercase convention<br />
* Function arguments should follow the conventions for local varibles<br />
described below<br />
<br />
Variables:<br />
* Names should follow the firstWordLowerCaseRestUpperCase convention <br />
* Prefix global variables with g_<br />
* Prefix static variables with s_<br />
* Prefix member variables with m_<br />
<br />
Classes:<br />
* Prefix classnames with "C"<br />
* Names should follow the AllWordsAreUppercase convention<br />
<br />
Constants:<br />
* Use ALLUPPERCASE names<br />
<br />
Filenames:<br />
* For classes, use the classname without the "C" prefix.<br />
<br />
<br />
=== Const Correctness ===<br />
Remember to mark functions and arguments (pointers, references) as const where possible. This not increases the ability for us to write safer code and is a good thing.<br />
<br />
==== Consts vs. Defines ====<br />
Whenever possible, prefer const variables to pre-compiler defines. We've already had problems with nameclashing caused by defines, so me might as well not increase the chances of it happening again. Actual constants also has the major advantage that we gain proper type-safety.<br />
<br />
==== References ====<br />
Always use references where passing large datatypes suchs as wxString and CMD4Hash and only use non-const references if we are going to change the passed variables<br />
<br />
=== Hacks ===<br />
Always try to avoid odd hacks and in general try to avoid abnormal stuff, assignments in if constructs and the like for instance should be avoided when possible. Also try to avoid the usage of void pointers as they result in a almost total loss of type-safety.<br />
<br />
=== Helper-functions ===<br />
Helper functions which can have use across the app should be placed in otherfunctions.h<br />
<br />
Whenever possible, prefer wxWidgets functions to system calls, as this reduces the dependencies on specific function-calls that may or may not be available on other platforms.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=FAQ_aMuleFAQ aMule2005-01-11T19:55:27Z<p>212.242.54.121: Slight change, xMule not being dead and all. :P</p>
<hr />
<div><center><br />
<u><h4>F.A.Q on [[aMule_Project_FAQ:About|aMule]]</h4></u><br />
<br />
<h2>by ''[[User:Jacobo221|Jacobo221]]''</h2><br />
<br />
'''English''' | [[FAQ_aMule-es|Español]] | [[FAQ_aMule-it|Italiano]] | [[FAQ_aMule-pt_BR|Portuguese]] | [[FAQ_aMule-fr|Français]] | [[FAQ_aMule-de|Deutsche]]<br />
</center><br />
<br />
== What is [[aMule_Project_FAQ:About|aMule]]? ==<br />
'''''[[aMule]] is a multi-platform client for the [[FAQ_eD2k-Kademlia|ED2K file sharing network]] based on the windows client [[eMule]].'''''<br><br />
aMule started in August 2003 as a fork of [[xMule]], which is a fork of [[lMule]].<br />
<br />
It currently supports Linux, FreeBSD, OpenBSD, Windows, MacOS X and X-Box on both 32 bits and 64 bits computers. It should be noted that the Windows port isn't ready for general usage yet.<br />
<br />
[[aMule]] is intended to be as user-friendly and feature-plenty as [[eMule]] and to remain faithful to the look of [[eMule]], so users familiar with either [[aMule_Project_FAQ:About|aMule]] or [[eMule]] will be able switch between the two easily.<br />
<br />
Since [[aMule_Project_FAQ:About|aMule]] is based upon the [[eMule]] codebase, new features in [[eMule]] tend to find their way to [[aMule]] soon after their inclusion in [[eMule]], so users of [[aMule_Project_FAQ:About|aMule]] can expect to ride the cutting-edge of [[FAQ_eD2k-Kademlia|ED2k]] clients.<br />
<br />
The best part is, that it's developed by a great team which is even more user-friendly than [[aMule_Project_FAQ:About|aMule]] itself (if possible), so please join #amule on irc.freenode.net or visit the [http://www.amule.org/amule forums], if you have any suggestions, questions, problems, bugs, patches or what else you might think of.<br />
<br />
If you are interested in joining the development team, please contact us either through the [http://www.amule.org/amule forums] or in the IRC channel.<br />
<br />
== How do I view a client's credits? ==<br />
You can see any client's credits (the credits you owe him) by right clicking on it's name and selecting Show Details. There is no specific value shown so you can either view the total amount of data that client has sent you or the Credits Modifier (which is called DL/UL Modifier). On that same dialog window, if that client is on your upload queue, you'll be able to view it's rate and score on you.<br />
<br />
== What do those colors in the progress bar mean? ==<br />
<u>On the downloading transfers list:</u><br><br />
<b>Red:</b> Chunks in red are chunks with no sources on current session found.<br><br />
<b>Blue:</b> Chunks in blue are chunks with at least one available source. The more solid blue it is, the more sources available have been found.<br><br />
<b>Yellow:</b> Chunks in yellow are chunks which are being downloaded at this very moment.<br><br />
<b>Black:</b> Chunks in black are chunks which have been already downloaded and verified.<br><br />
<b>Green:</b> When a file is in green it means that it's been completely downloaded and successfully verified (so, it'll be in the Incoming folder).<br><br />
<u>On the expanded transfers list (can be viewed by double-clicking a transfer):</u><br><br />
<b>Black:</b> Chunks which that client has and you don't have.<br><br />
<b>White:</b> Chunks which that client doesn't have.<br><br />
<b>Green:</b> Chunks which that client has and you have, too.<br><br />
<b>Yellow:</b>Chunks which that client is currently uploading to you.<br><br />
<u>On the uploading transfers list:</u><br><br />
<b>Black:</b> That client has completed and verified that chunk.<br><br />
<b>Grey:</b> That client doesn't have that chunk.<br><br />
Have in mind that not all clients support telling other clients which parts they have already completed when uploading, so some clients might have no bar at all.<br><br />
<u>On the shared files window:</u><br><br />
<b>Red:</b> When there's no source found to have that same chunk (apart from you, of course).<br><br />
<b>Blue:</b> The more solid the blue is, the more spread that chunk is.<br><br />
<u>On the search windows:</u><br><br />
<b>Black:</b> Files in black are those which only a client has been found to have.<br><br />
<b>Blue:</b> Files in blue are those which two or more clients have been found to have. The more solid the blue is, the more clients have been found to have it.<br><br />
<b>Red:</b> Files in red are those which are already in the downloading queue.<br><br />
<b>Green:</b> Files in green are those which you are already sharing (you completely downloaded it).<br />
<br />
== What are all these icons? ==<br />
See section "Icons and what they signify" in the [[Getting Started]] guide.<br />
<br />
== What do those numbers in brackets in the search window mean? ==<br />
Those are the clients who are known to have the complete file. Even if the number in brackets is 0, it doesn't mean that no one has the complete file, it juts means that no client has marked the shared file as "completed" (lots of clients don't do so). So, it's a way to have an idea of how many people have the complete file, but not the definitive way.<br />
<br />
== What do all those numbers in the sources column in the transfers window mean? ==<br />
The sources format is XX/YY + ZZ (WW) where<br><br />
<b>XX</b> stands for the amount of available sources (the amount of sources found you can download from).<br><br />
<b>YY</b> stands for the amount of found sources (the total amount of sources found)<br><br />
<b>ZZ</b> stands for the number of "Asked for another file" sources<br><br />
<b>WW</b> stands for the amount of sources from who you are currently downloading some chunk of that file.<br />
<br />
== What do all those numbers in the priority column in the extended transfers window mean? ==<br />
That's the queue position you have on that client for that specific file. Not all clients provide such information, so in some cases, nothing is displayed.<br><br />
The number in brackets is the amount of positions you have "moved" through that client's upload queue. '''Negative''' numbers stand for positions you have '''won''' in the queue since you were added while '''positive''' numbers mean positions you've '''lost''' since since you were added. Notice that when that number is negative, it is displayed blue, while when it's positive, it's displayed red.<br />
<br />
== Why are there two transfer rates in the uploading transfer list? ==<br />
When you are uploading some file to some client, the uploading transfer list will show the transfer rate (speed in KBps) in which you are uploading to that client. If, at the same time, that client is uploading to you some file (or files), then the transfer rate's format will change to XX/YY where XX stands for the speed in which you are uploading to that client and YY will stand for the speed in which that client is uploading to you. If you search in the downloading transfers list you'll find that client.<br><br />
This is useful if you are trying to get a rare file, since you can which file that client is uploading to you and, if it's the rare file, you can set him a friend slot so that you upload to that client faster and gain more credits on that clients (and consequently, download faster from the client).<br />
<br />
== What is A4AF? ==<br />
A4AF stands for ''Ask For Another File''. It is a way to optimize the resources on a specific download.<br><br />
When you try to download a file, aMule gets a list of clients who are sharing that file. Some of this clients might also share some other file which you are also trying to download and, so, you might have that client in two separate download queues.<br><br />
A4AF tries to avoid this situations. Why? Because you can't download two chunks at the same time from the same client. So, by setting A4AF in a specific download, you are telling aMule to search for any client in that file's download queue who is also in some other file's download queue and remove it from that other download queue. This way, you'll get more sources on that file.<br><br />
You can also set a specific download to apply A4AF in the opposite way, that is, to give sources to the other downloads. This should be done on downloads which are not to be downloaded with too much hurry or which should be downloaded after some other similar file has been downloaded (in a series of files, for example).<br><br />
This also can be seen as a way of establishing preferences in downloads.<br />
<br />
When the request swapping is done, the Queue Rank will be maintained.<br />
<br />
'''NOTE:''' A source with a QR lower than 50 in the download with the higher priority will never be swapped. This is done this way to ensure it starts downloading from it.<br />
<br />
== What is the difference between Transfered and Completed in the Transfers window? ==<br />
Transfered shows the amount of data you have received concerning that file. This data is downloaded in a compressed format. Once the data gets to your machine, aMule processes it and decompresses it. The total useful data that can be taken from that received data (that is, the parts of that data which are actually real parts of the file you are trying to download and not headers or such stuff) is the amount that can be viewed in the Completed column.<br />
<br />
== What is the difference between pausing and stopping a transfer? ==<br />
When a transfer is paused, all connections related to the paused transfer are broken with the other clients so that no data is transfered, but sources aren't dropped, so that when the transfer is resumed, [[aMule_Project_FAQ:About|aMule]] will try to connect to those sources it was transferring from.<br />
Instead, when a transfer is stopped, all sources are dropped so, when it's resumed, [[aMule_Project_FAQ:About|aMule]] will start searching for clients who are sharing that file.<br />
<br />
== What are all those files [[aMule_Project_FAQ:About|aMule]] creates the first time it is run? ==<br />
<br />
Most them are the same as [[eMule|eMule]]'s.<br />
<br />
Detailed information about each and a list of all of [[aMule]]'s files can be found [[aMule files|here]].<br />
<br />
== Can I use [[eMule|eMule]]'s files and settings and vice-versa? ==<br />
Most of them yes. The only ones you can't share between [[aMule_Project_FAQ:About|aMule]] and [[eMule]] are the program configuration (that is, preferences.ini in [[eMule]] and ''~/.eMule'' in [[aMule_Project_FAQ:About|aMule]]). All the [[FAQ_eD2k-Kademlia|ED2K network]] related files can be successfully shared between the two applications with no more effort than copying the files in ''~/.aMule'' to the [[eMule]]'s directory and vice-versa. But have in mind that some files in ''~/.aMule'' are [[aMule_Project_FAQ:About|aMule]] specific, such as ''amulesig.dat'' or ''aMule.tmpl'', so it's better to only move those files that are in both the [[aMule_Project_FAQ:About|aMule]] and the [[eMule]] directory.<br />
<br />
Moving the half downloaded files is easy: just place them from your [[eMule]] temp directory (by default ''C:\Program files\eMule\Temp'') into ''~/.aMule/Temp'' or whatever your temp directory is in your [[aMule]] configuration.<br />
<br />
== What is all that stuff in amulesig.dat and onlinesig.dat? ==<br />
<br />
I guess you already read what [[amulesig.dat_file|''amulesig.dat'']] and [[onlinesig.dat_file|''onlinesig.dat'']] are for [[FAQ_aMule#What_are_all_those_files_aMule_creates_the_first_time_it_is_run?|above]].<br />
<br />
So, this files contain the current [[signature]] (the current [[aMule]] status, if enabled, of course).<br />
<br />
Detailed information about each of thee files can be found in the [[amulesig.dat_file|''amulesig.dat'' article]] and the [[onlinesig.dat_file|''onlinesig.dat'' article]].<br />
<br />
== I just installed [[aMule_Project_FAQ:About|aMule]] for the first time. How do I set it up? ==<br />
Setting up aMule properly is just a matter of tastes and depends on many factors. If you just wish a quick startup configuration, then continue reading.<br><br />
Open [[aMule_Project_FAQ:About|aMule]] and click on the Preferences button. Set a nickname and the language in which you wish to have [[aMule_Project_FAQ:About|aMule]]. Then switch to the Connection tab and input your Line Capacities. Then input the Bandwidth Limits according to the maximum amount of bandwidth you want [[aMule_Project_FAQ:About|aMule]] to use. Then switch to the Directories tab and set a directory for both the temporary files (where files will be stored until they are completely downloaded) and the completed files. Finally, select the directories which you want to share. It is not recommended to share too much files. Read bellow "What are the best settings I can set to have a nice download rate". To select recursively all directories inside a certain directory read [[aMule_problems#Is there any way to recursively select a whole directory and its contents?|Is there any way to recursively select a whole directory and its contents?]].<br />
<br />
== Will [[aMule_Project_FAQ:About|aMule]] handle my [[xMule]] and [[lMule]] files? What should I do? ==<br />
[[aMule_Project_FAQ:About|aMule]] automatically handles both [[lMule]] and [[xMule]]'s configuration files, but in different ways:<br><br />
[[lMule]] has been discontinued for several years now, so [[aMule_Project_FAQ:About|aMule]] understands that you are replacing [[lMule]] with [[aMule_Project_FAQ:About|aMule]], so it renames ~/.lMule folder to ~/.aMule. If you used ~/.lMule/Temp and ~/.lMule/Incoming as your temporal and downloading directories respectively, you should change the paths in Preferences to ~/.aMule/Temp and ~/.aMule/Incoming respectively.<br><br />
<br />
If a ~/.xMule directory is found, it will be kept unchanged and [[aMule]] will just copy the configuration files found in it. That means that the files you were downloading will remain in the ~/.xMule directory if they were downloading there, but since [[aMule_Project_FAQ:About|aMule]] has handled [[xMule]]'s configuration files, it will use still use it. You can either live with that, or move directories ~/.xMule/Temp and ~/.xMule/Incoming into ~/.aMule and change directories in Preferences.<br />
<br />
== How do I start my [[aMule_Project_FAQ:About|aMule]] experience? ==<br />
Just click on the Connect button. You should have some servers listed on the Servers window, though. If you have no servers listed, then click on the little button below the Connect button in the Servers window before clicking the Connect button. After some time, [[aMule_Project_FAQ:About|aMule]] will be connected to some server (you'll know because in the lower right corner the "Not connected" message will disappear). When connected, switch to the Search window and search for the file you want and once you find the file you want, double-click on it.<br><br />
For general [[aMule_Project_FAQ:About|aMule]] usage, join [[aMule_Project_FAQ:About|aMule]] #amule in irc.freenode.net or ask in forums at [http://www.amule.org/amule http://www.amule.org/amule]<br />
<br />
<br />
== What are the best settings I can set to have a nice download rate? ==<br />
If you understood "Is there any limit on the [[FAQ_eD2k-Kademlia|ED2K]] network?" then you might have seen that, if your provider allows you, the best is to have the upload limit set to a minimum of 10 KBps. Also, if you understood "What is all that credits, rate and score stuff about?", you might also understand that the more you upload, the more you download, so take the upload limit up as much as you can, share well known and popular files (don't share too much (not more than approximately 200 files) or you'll get banned from some servers for giving too much traffic) and try to share small-sized popular files since some [[FAQ_eD2k-Kademlia|ED2K]] clients give extra credits for providing them a whole small-sized files. A good tip (thanks to kaouete) when you are trying to download some rare or "never completing" file, is, whenever you see someone uploading to you some chunk of that file, give that client a friend slot so that, if it tries to download something from you, it gets preference and you gain credits on that client.<br />
<br />
== Is there a way to open a text file and load all the ed2k links from the file? ==<br />
Yes, there is. Just place all the ed2k links you want to download in a text file, each ed2k link in a separate line. Name that file ''ED2KLinks'' then place it in ''~/.aMule'' and aMule will automatically detect it, add all those ed2k links to download and remove the file.<br><br />
You might want to read [[ED2KLinks_file|this]] to know more about this file.<br />
<br />
== Can I manage [[aMule_Project_FAQ:About|aMule]] remotely through telnet in the same way I do with [[eDonkey2000|eDonkey]]? ==<br />
Yes you can, but not exactly in the same way as you do with [[eDonkey2000|eDonkey]]. Just start a normal telnet (or ssh) session with the host computer (the one running [[aMule_Project_FAQ:About|aMule]]) and, once in, use amulecmd to take control over [[aMule_Project_FAQ:About|aMule]]. To start new downloads just use the [[ed2k_command|ed2k command]]. Remember [[aMuleCMD]] must be configured.<br><br />
Another aMule utility that might be of your interest is [[CAS]] (which's command is <code>cas</code>) which will show basic [[aMule_Project_FAQ:About|aMule]] statistics.<br><br />
Also, [[amuleweb|aMule WebServer]] might be what you are looking for if you can and don't mind using a web browser on the client computer. Have in mind that aMule WebBrowser must also be configured.<br />
<br />
== Is there any way to start [[aMule_Project_FAQ:About|aMule]] with no graphical interface? ==<br />
<br />
Yes. Since aMule 2.0.0-rc6, you can use aMule Daemon, which can be executed on the command line by typing ''amuled''. To control it, use either aMuleWeb, aMuleCMD or any other such application for remotely controlling aMule.<br />
<br />
Anyway, up to aMule 2.0.0-rc6, [[aMule_Project_FAQ:About|aMule]] was a monolithic application. This means that core and GUI were whole inseparable block. <br />
<br />
So, for those using an old aMule version or who refuse to use aMuled (aMule Daemon), there are still two walkarounds to run [[aMule_Project_FAQ:About|aMule]] on command line but they're not direct ways:<br />
*Through ''[http://xfree.org/4.4.0/Xvfb.1.html Xvfb]''<br />
*Through ''[http://www.realvnc.com VNC]''<br />
<br />
'''Through ''[http://xfree.org/4.4.0/Xvfb.1.html Xvfb]:'''<br><br />
You should run <code>[http://xfree.org/4.4.0/Xvfb.1.html Xvfb]</code> and then run aMule in it. Afterwards you can take control over [[aMule_Project_FAQ:About|aMule]] using [[aMuleCMD]] and [[ed2k_command|ed2k]] in the same way as you would if you were accessing [[aMule_Project_FAQ:About|aMule]] remotely over telnet (see above).<br />
<br />
<u>Short example:</u><br /><br />
Run [http://xfree.org/4.4.0/Xvfb.1.html Xvfb]:<br><br />
<code>Xvfb :1 -screen 0 640x480x16 &</code><br /><br />
Set display to use for amule:<br><br />
<code>export DISPLAY=:1</code><br /><br />
Then run [[aMule_Project_FAQ:About|aMule]]:<br><br />
<code>amule &</code><br /><br />
<b>Note:</b> After running <code>export DISPLAY=:1</code>, all graphical applications launched from that shell will be opened in [http://xfree.org/4.4.0/Xvfb.1.html Xvfb]'s display. To avoid this, you can run [[aMule_Project_FAQ:About|aMule]] with the following command, so that only [[aMule_Project_FAQ:About|aMule]] runs there:<br><br />
<code>DISPLAY=:1 amule &</code><br><br />
'''INFO:''' See the [[Screen]] page to know more about the [[Screen]] command<br />
<br />
'''Through ''[http://www.realvnc.com VNC]:'''<br><br />
It's also possible to use ''vncserver'' instead of [http://xfree.org/4.4.0/Xvfb.1.html Xvfb] to achieve something similar. Just install ''vncserver'' and execute ''vncserver :0 -geometry 1024x768'' followed by ''export DISPLAY=:0''. This will create a hidden [http://xfree.org X] server, accessible only remotely using a [http://www.realvnc.com VNC] client. Once the [http://xfree.org X] server is running, you will need a window manager to manage [[aMule]] window (well, it's not really needed, but it's useful if you want to be able to close [[aMule]] without simply killing it), I recommend [http://fluxbox.sourceforge.net FluxBox] due to its low CPU and memory requirements. Just start it with ''fluxbox &'' and then run [[aMule]] with ''amule &''. Now you can connect to the [http://www.realvnc.com VNC] server and see the [[aMule]] window.<br />
<br />
Keep in mind that if [[aMule]] shows any dialog that requires user input (like the one showed the first time [[aMule]] is executed), it will get stuck there until someone connects to the [http://www.realvnc.com VNC] server and clicks ok in the dialog. Usually, this should only need to be done once (and this connection may be used to update the serverlist and set the preferences), from then on [[aMule]] will start without user interaction, showing only some informational messages at startup.<br />
<br />
If you need help on this issue, search [[aMule_Project_FAQ:About|aMule]]'s [http://www.amule.org/amule forums] or join #amule [[IRC]] channel at irc.freenode.net and ask.<br />
<br />
== Can I run two [[aMule_Project_FAQ:About|aMule]] instances at the same time? ==<br />
Yes you can, although it is not recommended. [[aMule_Project_FAQ:About|aMule]] will only check if the concurrent user is running some [[aMule_Project_FAQ:About|aMule]] instance, so you can run as many [[aMule_Project_FAQ:About|aMule]] instances as user accounts you have access to. To do this, just run <code>xhost +</code> and then <code>su</code> as another user and run aMule from that shell.<br><br />
Be aware, since [[aMule_Project_FAQ:About|aMule]] can't check if a user is running [[aMule_Project_FAQ:About|aMule]] on another X display. So, if your account is already running some [[aMule_Project_FAQ:About|aMule]] instance in some other X display, do not run another [[aMule_Project_FAQ:About|aMule]] instance on another X display or you might end up with lost configuration settings and corrupt chunks.<br />
<br />
== How can I get those nice [[aMule_Project_FAQ:About|aMule]] statics some people post on the IRC channels? ==<br />
You can either copy and paste [[CAS]]'s (C [[aMule_Project_FAQ:About|aMule]] Statics) output (to execute [[CAS]], run <code>cas</code>) or, if you use xChat as your IRC client and have the Perl module installed, you could use [[XAS]] (xChat [[aMule_Project_FAQ:About|aMule]] Statics).<br />
<br />
== What is slot allocation? ==<br />
Each upload is a slot, so, if you are uploading to five clients at the same time, you have five upload slots established. So, the amount of slot allocation is the bandwidth which each slot will be given.<br><br />
As an example, if your upload limit is 20KBps, you can set slot allocation to 2KBps which means 10 clients will be able to download from you at the same time, each of them at a maximum transfer rate of 2KBps.<br><br />
See section "Why is aMule ignoring the bandwidth I set per slot?" in [[AMule_problems|aMule common problem's FAQ]].<br />
<br />
== What is a friend slot? ==<br />
A friend slot is just a slot which is assigned to a client in the friends list. Only one friend can have a slot at the same time. Whenever that friend (who has the friend slot enabled) tries to download a file from you, it will be given highest priority in the uploads queue, since it has that slot always assigned. While that friend isn't downloading, that assigned slot will be given to the client with the highest priority in the upload queue, as expected.<br />
<br />
== What is the real point on setting up Line Capacities in Preferences? Shouldn't [[aMule_Project_FAQ:About|aMule]] only care for the Bandwidth Limits? ==<br />
aMule really only cares for the Bandwidth Limits. Line Capacities are only set for the Statics display. Let's see: Imagine you have a 100KBps connection, imagine you want to set the Limit at 40KBps because you have a web server which needs a minimum of 60KBps to serve all the petitions. Now imagine you download rare indonesian free songs. You most surely never download at more than 3KBps ever. So, you could set Line Capacities at 5KBps so that the graph at Statics has some meaning, since if you set it up as a 100KBps connection, the graph will show an horizontal line with no meaning at all.<br />
<br />
== aMule is crashing quite often here. Can I set it to restart every time it crashes? ==<br />
No, you can't. But you can have scripts to do so. Some of these scripts even work if aMule '''hangs''' but doesn't '''crash'''.<br><br />
The following scripts might suit your needs:<br><br />
[http://www.amule.org/amule/thread.php?threadid=1232 http://www.amule.org/amule/thread.php?threadid=1232]<br><br />
[http://www.amule.org/amule/thread.php?threadid=542 http://www.amule.org/amule/thread.php?threadid=542]<br><br />
[http://deepthought.ena.si/mulerunner http://deepthought.ena.si/mulerunner]<br />
<br />
== Can I have aMule get data from the standard input to pass it to GDB or Valgrind? ==<br />
Yes, you can. Up to aMule 2.0.0-rc3 this wasn't allowed, but as of version 2.0.0-rc4 you can with the parameter ''-i'' or ''--enable-stdin''.<br><br />
Anyway, people with aMule versions previous to 2.0.0-rc4 can use [http://www.amule.org/amule/thread.php?threadid=2474 phoenix's aMule stdin patch].<br />
<br />
== How can I switch to aMule from eMule without losing my credits? ==<br />
If you already read [[FAQ_aMule#What_are_all_those_files_aMule_creates_the_first_time_it_is_run?|about the meaning of aMule's files]], you might already know what you have to do:<br><br />
Get ''cryptkey.dat'', ''clients.met'' and ''preferences.dat'' files from eMule's config directory (usually, under Windows, something like ''C:\Program files\eMule\config'') and copy them into ''~/.aMule''. Now start aMule so it reads those files. You're done!<br />
<br />
== What is all this [[rabbit]] story about? ==<br />
Ah, yeah, this all began... ehm... well... I mean... follow the white [[rabbit]] ;-)</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Getting_StartedGetting Started2004-09-15T16:37:09Z<p>212.242.54.121: Adding Where Are The Files section.</p>
<hr />
<div>== What is [[aMule]] ==<br />
[[aMule]] is a client for the [[P2P|peer-to-peer]] [[FAQ_eD2k-Kademlia|eD2k]] network commonly called the [[FAQ_eD2k-Kademlia|eDonkey network]], or the ed2k network ([[eDonkey2000]]). This guide does not require that you are familiar with another network (but it helps), however it does require that you have gotten [[aMule]] installed on your computer.<br />
If you haven't installed [[aMule]] yet, then please refer to the installation guide appropriate for your system. Links to these can be found on the [[Main_Page|main page]].<br />
<br />
--[[User:Xaignar|Xaignar]] 01:12, 10 Jul 2004 (CEST)<br />
<br />
== Running [[aMule]] for the first time ==<br />
Start by running [[aMule]]. Usually this can be done by executing the command ''amule'' in a console window or by whatever method might be provided by your distro and windows manager.<br />
<br />
Once started, if you are using a [http://www.gnu.org/software/cvs CVS] build, [[aMule]] will display a notification telling you that you are running it for the first time. Read this to learn what you are getting yourself into ;)<br />
<br />
=== Configuring [[aMule]] ===<br />
On the top of the [[aMule]] window, there is a row of labelled icons. Click the one marked preferences to enter the configuration dialog. Before you start downloading files, you'll need to properly set your connection speed and possibly other settings.<br />
<br />
==== Connection Speed ====<br />
You should know that the eDonkey clients enforce upload, which means that in order to download, you'll have to share files yourself (don't worry if you don't have anything to share). This is enforced in two ways:<br />
* Your download speed depends on how fast you upload. If your upload speed is set to anything below 10kb/s, your maximum download speed will be 3 or 4 times your uploadspeed (read [[FAQ_eD2k-Kademlia#Are_there_any_limitations_on_the_ED2K_network?|this]] to know more about it), so if you limit your upload speed to 5kb/s, you'll only be able to download with 20kb/s.<br />
* Partially downloaded files are shared as well. You automatically start sharing a file after you've received at least one [[FAQ_eD2k-Kademlia#What_is_a_chunk?|chunk]] (a [[FAQ_eD2k-Kademlia#What_is_a_chunk?|chunk]] is a 9.28Mb piece of a file).<br />
<br />
Note: If you ever enter the [http://forum.amule.org aMule forum] or [[IRC|IRC channel]] to complain about this or demand that we change the ratio, then I will hunt you down and eat your spleen. -- [[User:Xaignar|Xaignar]]<br />
<br />
When you first open the Preferences dialog, the page shown will be "General", which contains some general settings, like the [[nickname]] other people will see when they download from or upload to you. <br />
To proceed, click on the tab named "Connection":<br />
<br><center>http://www.amule.org/dev-up/Limits.png</center><br />
<br />
The only settings relevant to this guide are the settings under "Bandwidth Limits" marked "Upload" and "Download". You don't need to enter a max download speed, but it is recommended that you set the upload speed to around 80% of your actual speed, since it can cause slower downloads otherwise.<br />
<br />
Once you have entered the proper values, you can explore the rest of the settings. To save the changes, simply click the "OK" button.<br />
<br />
=== Connecting to a Server ===<br />
<br />
You should now be looking at the servers dialog:<br />
http://www.amule.org/dev-up/ServerDlg.png<br />
<br />
The empty list normally contains the servers you know about, but since this is the first time you're running [[aMule]], you don't have any. To remedy this situation, simply click in the text-field containing the text ''http://www.srv1000.com/azz/server.met'' and press enter.<br />
A dialog will pop up and close again once the download has completed.<br />
<br />
You should now have a full list of servers, if not search google for ''server.met'' and place the file in the folder ''.aMule'' on your home dir. The list should look like this:<br />
http://www.amule.org/dev-up/ServerList.png<br />
<br />
Next you need to connect to a [[server]]. Normally it's a good idea to select one with as many users as possible, but for now, lets just click the large "Connect" button near the top-left of the window. This will connect you to a random server. Please wait while [[aMule]] contacts servers and tries to establish an connection. Once this happens, proceed on to the next section.<br />
<br />
=== [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|High and Low ID]] ===<br />
Because [[P2P|p2p]] networks works by [[Client|clients]] directly contact each other, being behind a firewall or router can really cause problems. If you don't know whenever or not you are behind a firewall, simply look at the icon in the bottom-right of the window. If it is green, then you have [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|High ID]] and can proceed, but if it is yellow, then you need to take a look at the page on [[Firewall|Firewalls]] and/or [[AMule_problems#aMule_connects_to_server,_but_it_is_always_given_LowID._Why?_and,_can_I_do_something_about_it?|common problems]], since having [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|Low ID]] means greatly reduced capabilities.<br />
<br />
== Basic Usage ==<br />
This will cover some basic usage of [[aMule]].<br />
<br />
=== Searching and Downloading ===<br />
OK, this is what [[P2P|p2p]]'ing is about: Downloading files.<br />
For the sake of this guide, I'll presume that you are really keen on downloading the latest [http://www.knoppix.org Knoppix] CD (who isn't?). To download this, first ensure that you are connected to a server and then click on the "Searches" button.<br />
<br />
This will bring up the search dialog:<br />
http://www.amule.org/dev-up/SearchDlg.png<br />
<br />
Since we only care about CD images, we select the option "CD-Images" from the "Type" dropdown menu. Also untick the "Global Search" setting, since we don't really need to search anything other than the currently connected [[server]]. Then we enter ''Knoppix'' in the top "Name" field and hit enter or the "Search" button. You should now have a listful of results:<br />
http://www.amule.org/dev-up/SearchResults.png<br />
<br />
Lets sort the list by [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]], by clicking twice on the field marked "Sources", this makes it easier to find popular files. The second one looks interesting, so we double-click on it (or click on it and then on the "Download" button). This will queue the file for download.<br />
<br />
=== The Download Queue ===<br />
Click on the "Transfers" button to bring forth a list of files you have queued for download:<br />
http://www.amule.org/dev-up/DownloadQueue.png<br />
<br />
If you're lucky, the progress bar will turn a nice dark shade of blue, which means that a lot of people have that file (read [[FAQ_aMule#What_do_those_colors_in_the_progress_bar_mean?|this]] to know more about it). Beware of files that have parts marked in red, since it means that no-one has that part of the file and you most likely wont be able to complete the download.<br />
<br />
If you double-click on any of the files, you can see the [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] you have found for that file.<br />
<br />
==== Of Rows and Columns ====<br />
These are the columns of the Download Queue:<br />
<br />
; ''Filename'' : The name of the file.<br />
; ''Size'' : The size of the file. The eDonkey2000 network supports files up to 4GB in size (read [[FAQ_eD2k-Kademlia#Are_there_any_limitations_on_the_ED2K_network?|more]] about this).<br />
; ''Transferred'' : Shows the amount downloaded.<br />
; ''Completed'' : This column displays how much of the file you have actually completed. Please note that this can differ from the Transferred column because of corruptions or gains made by the compression *Mule [[Client|clients]] use (read [[FAQ_aMule#What_is_the_difference_between_Transfered_and_Completed_in_the_Tranfers_window?|more]] about this difference).<br />
; ''Progress'' : This bar displays the current progress of the file, the colours signifying the following (alternative [[FAQ_aMule#What_do_those_colors_in_the_progress_bar_mean?|resource]]):<br />
* Blue: How many sources provide this part, the darker the colour, the more sources provide it.<br />
* Red: There are no known [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] that provide this part.<br />
* Black: You have already downloaded this part.<br />
* Yellow: You are currently downloading this part.<br />
: The green bar on top of the larger bar gives an indication of the actual progress.<br />
; ''Sources'' : There are 3 fields in this column, though mostly only 2 are shown (alternative [[FAQ_aMule#What_do_all_those_numbers_in_the_sources_column_in_the_transfers_window_mean?|resource]]):<br />
: <Asked [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]>[/<All [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]>] [+ <[[FAQ_aMule#What_is_A4AF?|A4AF]] [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]> ] [(<Transferring [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]]>)]<br />
: 'Asked [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]' are those that have been asked for the file.<br />
: 'All [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]' are all [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] of that file, asked and unasked.<br />
: '[[FAQ_aMule#What_is_A4AF?|A4AF (Asked For Another File)]] [[FAQ_eD2k-Kademlia#What_is_a_source?|Sources]]' are [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] that provide that file, but have been asked for anther one.<br />
: 'Transferring [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]]' are [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] which are uploading that file to you at this very moment.<br />
; ''Priority'' : The priority of the file. Files are set to auto-priority by default, which means that [[aMule]] will manage it by itself. Priorities affect how [[aMule]] allocates [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] that are known to provide multiple files and thus means that high-priority files get more [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]]. Read [[FAQ_aMule#What_do_all_those_numbers_in_the_priority_column_in_the_extended_transfers_window_mean?|more]] about this.<br />
; ''Status'' : The current status of the file. Waiting means that you are waiting for sources to start uploading to you.<br />
; ''Time Remaining'' : An guess at how fast the file will be completed. Only shows something when you are currently receiving the file.<br />
; ''Last Seen Complete'' : This shows the last time you've seen the entire file provided by the [[FAQ_eD2k-Kademlia#What_is_a_source?|sources]] you've asked.<br />
; ''Last Reception'' : This shows the last time you were downloading parts of this file.<br />
<br />
=== The Upload Queue ===<br />
The upload queue can be found just beneath the download queue, and shows who are downloading files from you (you might want to read [[FAQ_aMule#Why_are_there_two_transfer_rates_in_the_uploading_transfer_list?|this]]). In case you are wondering, no, you cannot stop uploads. If you click on the blue icon next to the "Uploads" label, you can see who are queued for downloading from you, rather than the people who are actually downloading from you right now.<br />
<br />
=== Icons and What They Signify ===<br />
These are the icons that can be found on the Transfers page.<br />
<br />
* '''Source Status''' <br />
** http://www.amule.org/dev-up/Source_1.png - [[Client]] is sending you either a file or a hashset.<br />
** http://www.amule.org/dev-up/Source_2.png - You are either on this [[Client|clients]] queue or currently asking it for a file.<br />
** http://www.amule.org/dev-up/Source_3.png - You are currently connecting to this [[Client|client]].<br />
** http://www.amule.org/dev-up/Source_4.png - [[Client]] has been asked for another file, has no needed parts or is unable to connect because of a [[FAQ_eD2k-Kademlia#What_is_LowID_and_HighID?|Low ID]].<br />
** http://www.amule.org/dev-up/Source_5.png - Status is unknown.<br />
<br />
* '''eDonkey Clients'''<br />
** http://www.amule.org/dev-up/Client_aMule.png - [[aMule]]<br />
** http://www.amule.org/dev-up/Client_eDonkey.png - [[eDonkey2000]]<br />
** http://www.amule.org/dev-up/Client_eMule.png - [[eMule]]<br />
** http://www.amule.org/dev-up/Client_Friend.png - [[Client]] is a [[Friend]]<br />
** http://www.amule.org/dev-up/Client_Lphant.png - [[lphant]]<br />
** http://www.amule.org/dev-up/Client_MLDonkey.png - [[mlDonkey]]<br />
** http://www.amule.org/dev-up/Client_Shareaza.png - [[Shareaza]]<br />
** http://www.amule.org/dev-up/Client_Unknown.png - Unknown [[Client]]<br />
** http://www.amule.org/dev-up/Client_xMule.png - [[xMule]]<br />
<br />
* '''Modifiers'''<br />
** http://www.amule.org/dev-up/Client_Mod_eMuleProt.png - [[Client]] supports the extended [[eMule]] protocols. Source-sharing and such.<br />
** http://www.amule.org/dev-up/Client_Mod_GoodCredit.png - [[Client]] has a good [[FAQ_eD2k-Kademlia#What_is_all_that_credits,_rate_and_score_stuff_about?|credit-rating]].<br />
** http://www.amule.org/dev-up/Client_Mod_NormCredit.png - [[Client]] has a normal [[FAQ_eD2k-Kademlia#What_is_all_that_credits,_rate_and_score_stuff_about?|credit-rating]].<br />
** http://www.amule.org/dev-up/Client_Mod_SecId_Good.png - [[Client]] has been [[Secure_User_Identification|securely identified]].<br />
** http://www.amule.org/dev-up/Client_Mod_SecId_Bad.png - [[Client]] has been for some reason been identified as a [[bad guy]].<br />
<br />
* '''File [[comment]]s'''<br />
** http://www.amule.org/dev-up/File_Comment.png - This file has either been rated or someone has added a [[comment]].<br />
** http://www.amule.org/dev-up/File_Comment_Bad.png - This file has been rated as [[Fake]] by at least one person.<br />
<br />
=== Where Are The Files? ===<br />
Once [[aMule]] starts downloading a file, it will create a number of files to keep track of that specific download. These files can be found in the subdir .aMule/Temp in your homedir (~/.aMule/Temp), but should not be touched in most cases. <br />
<br />
If you have incompleted downloads from eMule, you can simply place the temp files in the ~/.aMule/Temp folder if you wish for aMule to continue downloading them.<br />
<br />
However, once a file has been completed, it will be moved away from ~/.aMule/Temp and to ~/.aMule/Incomming, where all completed files are placed by default. You can change both of these paths in the preferences should you wish to do so.<br />
<br />
Also, please note that the .aMule dir is a hidden folder, so you might have to enable showing of hidden files in your file-mananger, should you use one such.<br />
<br />
<br />
== Conclusion == <br />
Hopefully this brief introduction has given you an idea of how [[aMule]] works. If you feel that something is missing from this guide, please let us know or add it yourself.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=XMuleXMule2004-07-18T22:42:10Z<p>212.242.54.121: </p>
<hr />
<div>== [http://www.xmule.ws xMule] ==<br />
<br />
xMule is a fork of [[LMule]], and was the defacto [[eMule]] client for linux until aMule appeared and challenged that position. However, xMule is still under active development, primarily by HopeSeekr, the person who originally forked lMule.<br />
<br />
As of version 1.8.4, the xMule client is banning [[aMule|aMules]] (all versions) and [[eMule|eMules]] (version 0.43 and up). This is due to the developers of xMule being of the opinion that those clients are [[leech|leeches]]. Please refer to the [http://www.xmule.ws xMule website] for more information on its current progress.<br />
<br />
[[aMule]] is a fork of [http://www.xmule.ws xMule], though both projects have moved further and further apart since then. Diplomatic relations between the two projects are sadly in a rather sorry state.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=Getting_StartedGetting Started2004-07-09T22:58:41Z<p>212.242.54.121: </p>
<hr />
<div>== What is aMule ==<br />
aMule is a client for the peer-to-peer networked commenly called the eDonkey network, or the ed2k network (eDonkey 2000). This guide does not require that you are familiar with another network (but it helps), however it does require that you have gotten aMule installed on your computer.<br />
If you haven't installed aMule yet, then please refer to the installation guide appropriate for your system. Links to these can be found on the [Main_Page main page].<br />
<br />
== Running aMule for the first time ==<br />
Start by running aMule. Usually this can be done by executing the command "amule" in a console window or by whatever method might be provided by your distro and windows manager.<br />
<br />
Once started, if you are using a CVS build, aMule will display a notification telling you that you are running it for the first time. Read this to learn what you are getting yourself into. ;)<br />
<br />
=== Configuring aMule ===<br />
On the top of the aMule window, there is a row of labeled icons. Click the one marked preferences to enter the configuarion dialog. Before you start downloading files, you'll need to properly set your connection speed and possibly other settings.<br />
<br />
==== Connection speed ====<br />
You should know that the eDonkey clients enforce upload, which means that in order to download, you'll have to share files yourself (dont worry if you dont have anything to share). This is enforced in two ways:<br />
* Your download speed depends on how fast you upload. If your upload speed is set to anything below 10kb/s, your maximum download speed will be 3 times your uploadspeed, so if you limit your upload speed to 5kb/s, you'll only be able to download with 15kb/s.<br />
* Partially downloaded files are shared as well. You automatically start sharing a file after you've recieved at least one chunk (a chunk is a 9.28Mb piece of a file).<br />
<br />
Note: If you ever enter the aMule forum or IRC channel to complain about this or demand that we change the ratio, then I will hunt you down and eat your spleen. -- Xaignar<br />
<br />
When you first open the Preferences dialog, the page shown will be "General", which contains some general settings, like the nickname other people will see when they download from or upload to you. <br />
To proceed, click on the tab named "Connection":<br />
[image:Limits.gif]<br />
<br />
The only settings releveant to this guide are the settings under "Bandwidth Limits" marked "Upload" and "Download". You dont need to enter a max download speed, but it is recommended that you set the upload speed to around 80% of your actual speed, since it can cause slower downloads otherwise.<br />
<br />
Once you have entered the proper values, you can explore the rest of the settings. To save the changes, simply click the "Ok" button.<br />
<br />
=== Connecting to a server ===<br />
<br />
You should now be looking at the servers dialog:<br />
[image:ServerDlg.png]<br />
<br />
The empty list normally contains the servers you know about, but since this is the first time you're running aMule, you dont have any. To remidy this situation, simply click in the text-field containing the text "http://www.srv1000.com/azz/server.met" and press enter.<br />
A dialog will pop up and close again once the download has completed.<br />
<br />
You should now have a full list of servers, if not search google for "server.met" and place the file in the folder .aMule on your home dir. The list should look like this:<br />
[image:ServerList.gif]<br />
<br />
Next you need to connect to a server. Normally it's a good idea to select one with as many users as possible, but for now, lets just click the large "Connect" button near the top-left of the window. This will connect you to a random server. Please wait while aMule contacts servers and tries to establish an connection. Once this happens, proceed on to the next section.<br />
<br />
<br />
=== High and Low ID ===<br />
Because p2p networks works by clients directly contact each other, being behind a firewall or router can really cause problems. If you dont know whenever or not you are behind a firewall, simply look at the icon in the bottom-right of the window. If it is green, then you have High ID and can proceed, but if it is yellow, then you need to take a look at the page on [Firewalls Firewall], since having Low ID means greatly reduced capabilities.<br />
<br />
<br />
== Basic Usage ==<br />
This will cover some basic usage of aMule.<br />
<br />
<br />
=== Searching and Downloading ===<br />
Ok, this is what p2p'ing is about: Downloading files.<br />
For the sake of this guide, I'll presume that you are really keen on downloading the latest Knoppix CD (who isn't?). To download this, first ensure that you are connected to a server and then click on the "Searches" button.<br />
<br />
This will bring up the search dialog:<br />
[image:SearchDlg.gif]<br />
<br />
Since we only care about CD images, we select the option "CD-Images" from the "Type" dropdown menu. Also untick the "Global Search" setting, since we dont really need to search anything other than the currently connected server. Then we enter "Knoppix" in the top "Name" field and hit enter or the "Search" button. You should now have a listful of results:<br />
[image:SearchResults.gif]<br />
<br />
Lets sort the list by sources, by clicking twice on the field marked "Sources", this makes it easier to find popular files. The second one looks interesting, so we double-click on it (or click on it and then on the "Download" button). This will queue the file for download.<br />
<br />
<br />
=== The Download Queue ===<br />
Click on the "Transfers" button to bring forth a list of files you have queued for download:<br />
[image:DownloadQueue.gif]<br />
<br />
If you're lucky, the prgress bar will turn a nice dark shade of blue, which means that a lot of people have that file. Beware of files that have parts marked in red, since it means that no-one has that part of the file and you most likely wont be able to complete the download.<br />
<br />
If you double-click on any of the files, you can see the sources you have found for that file.<br />
<br />
==== Icons and What They Signify ====<br />
Todo, hopefully by tomorrow. -- Xaignar<br />
<br />
=== The Upload Queue ===<br />
The upload queue can be found just beneth the download queue, and shows who are downloading files from you. In case you are wondering, no, you cannot stop uploads. Should you click on the blue icon next to the "Uploads" label, you can see who are queued for downloading from you, rather than the people who are actually downloading from you right now.<br />
<br />
<br />
== Conclusion ==<br />
Hopefully this brief introduction have given you an idea of how aMule works. If you feel that something is missing from this guide, please let us know or add it yourself.</div>212.242.54.121http://wiki.amule.org/t/index.php?title=XMuleXMule2004-07-04T09:17:35Z<p>212.242.54.121: </p>
<hr />
<div>== [http://www.xmule.ws xMule] ==<br />
<br />
is an easy to use multi-platform synchronizing fork of the popular eMule client. Based upon the wxWidgets libary and GNU C++, xMule aims to support the GNU/Linux, *BSD, and maybe in the future Windows, and MacOS X operating systems.</div>212.242.54.121