Winebot Package Maintainer's Tutorial

Requirements

  • Decent knowledge of XML/DTD (it's a bit similar to HTML).
  • sh/BASH basics for writing .sh installer/uninstaller scripts
  • willingness to learn AutoHotkey scripting language for automated installations
  • understand package maintainer responsibilities stated in Winebot Manifest

Winebot package is a bzipped tarball consisting of several mandatory and optional files. Bare package contains pack.xml, resources/license.txt and install/uninstall scripts.

resources/license.txt
scripts/uninstall.ahk
scripts/install.ahk
pack.xml

Basic steps overview

  1. Create a package directory named shortname-version_language
    ex: mkdir firefox-1.5.0.6_en_US
    
  2. Place pack.xml into the package directory.
  3. Create scripts and resources subdirectories in the package directory.
    mkdir shortname-version_language/scripts shortname-version_language/resources
    
  4. Place install/uninstall scripts into the scripts/ subdirectory.
  5. Place license.txt into resources/ subdirectory.
  6. Create a tarball/WDI from the package directory
    cd shortname-version_language/
    tar cjvf ../shortname-version_language.wdi *
    

You've got bare WDI package.

Package release for general availability

  1. Create a trac ticket to add the package to repository, use type 'task', component 'application-pack' and Milestone 'Game packages' or 'Base packages' or 'Global packages', and version set to empty
  2. Checkout the winebot-repositories repository
  3. Add the package directory to the global, games or base repository
    1. Base repository is used for generic tools like installers, extractors, libraries
  4. Describe the package test cases for
    1. Installation
    2. Uninstallation
    3. Upgrade (optional)
    4. Other behaviour (optional)
  5. Submit the ticket
  6. Commit the new directory to svn and update the ticket with commit #
  7. Assign the ticket to package repository maintainer (currently Hark)
  8. Package repository maintainer will take the ticket, verify the license, run the tests and if happy, updates the package repository with the new package and close the ticket.

WDI package details

pack.xml [mandatory]

DTD
Winebot package can contain whole installer when copyright owner allows such distribution. This is called complete application pack.

<ApplicationPack type="complete" version="0.1">

Otherwise Winebot downloads application payload from defined set of URIs. This is called skeleton application pack.

<ApplicationPack type="skeleton" version="0.1">

resources/license.txt [mandatory]

Bare text file containing the package vendor license.

uninstall scripts

It's not recommended to remove a dll that was provided by a "Microsoft package" that doesn't have a Wine equivalent. After all, another application's installer could add say mfc42.dll. This application doesn't need to depend on mfc-4.2 because it provides the dll, but it would be adversely affected if/when that package is removed. So the solution is to add dependency for mfc-4.2 and don't erase the provided files.

package naming convention

Package naming convention is actually implemented using application pack information (pack.xml):

  • <shortname></shortname> short package name, using underscores '_' as word separators
  • <version></version> any string identifying program version by manufacturer
  • <pkg-version></pkg-version> number starting from 1, similar to Debian revision

Actual state is:

  • shortname-version.wdi
  • Ex: autohotkey-1.0.46.10.wdi

Near future state will be:

  • shortname-version-pkg-version.wdi
  • Ex: autohotkey-1.0.46.10-1.wdi

In case package is dependent on exact Wine version, this information should be embedded in version tag.

  • Ex: worms_armageddon_us-3.256.23.4_wine0.9.31.wdi

<pkg-version> will allow package upgrades when upgrade script is available.

However, package name is intended for ease of human work, winebot itself does not depend on file name, it uses pack.xml and packlist.xml files for data mining.

DLL packages

DLL List - provides a list of Wine provided and Windows provided DLLs.