{"id":61,"date":"2008-10-07T08:55:50","date_gmt":"2008-10-07T07:55:50","guid":{"rendered":"http:\/\/www.miscdebris.net\/blog\/?p=61"},"modified":"2008-10-07T09:18:31","modified_gmt":"2008-10-07T08:18:31","slug":"instructions-on-how-to-create-devpak-packages","status":"publish","type":"post","link":"http:\/\/www.miscdebris.net\/blog\/2008\/10\/07\/instructions-on-how-to-create-devpak-packages\/","title":{"rendered":"Instructions on how to create DevPak packages"},"content":{"rendered":"<p>I&#8217;m in the process of writing a DevPak for the <a href=\"http:\/\/www.libharu.org\" target=\"_blank\">libharu<\/a> libary. These are actually tar.bz2 packages of whatever you think is a good idea to install into the <a href=\"http:\/\/www.bloodshed.net\/dev\/\" target=\"_blank\">Dev-C++<\/a>, <a href=\"http:\/\/www.codeblocks.org\/\" target=\"_blank\">Code::Blocks<\/a> or <a href=\"http:\/\/wxdsgn.sourceforge.net\/\" target=\"_blank\">wxDev-C++<\/a> IDEs. E.g. precompiled libraries and necessary header files. In addition one adds a so called DevPackage file, which tells the IDEs where to put all the files. Since you are also allowed to install files into the windows directory, these packages are also quite dangerous &#8211; you should check the package content first (rename xxx.DevPak to xxx.tar.bz2). The DevPackage file format is more or less straight forward, but first I couldn&#8217;t find a documentation for that. In the cvs repository of Dev-C++ there was actually a documentation (<a href=\"http:\/\/dev-cpp.cvs.sourceforge.net\/viewvc\/dev-cpp\/V5\/source\/packman\/File%20Format.txt?view=log\" target=\"_blank\">File Format.txt<\/a>), but it contained some errors. So I updated the file and make it available in this post.<!--more--><\/p>\n<pre>                           Dev-C++ Package File Format\r\n                         Version 1 - March the 15th, 2002\r\n                           Update October the 7th, 2008\r\n\r\nGeneral Information\r\n-------------------\r\nThe content of a DevPak package is described using a package description file,\r\nwhich has the extension .DevPackage. The file is really a simple INI file.\r\nThis is an updated version of the original \"File Format.txt\" file found\r\nin the cvs repository of Dev C++:\r\nhttp:\/\/dev-cpp.cvs.sourceforge.net\/viewvc\/dev-cpp\/V5\/source\/packman\/File%20Format.txt?view=log\r\nor in the svn repository of wxDev-C++ (or wxDesigner)\r\nhttp:\/\/wxdsgn.svn.sourceforge.net\/viewvc\/wxdsgn\/trunk\/packman\/File%20Format.txt?view=log\r\n\r\nSections\r\n--------\r\nThe .DevPackage file contains three sections:\r\n[Setup]\r\nThis section contains information about the package, such as package name,\r\nversion, description, readme, license, etc.\r\n\r\n[Files]\r\nThis section contains information about files, and where they should be\r\ninstalled to.\r\n\r\n[Icons]\r\nThis section contains information about links to documentation or webpages\r\nwhich are added to the Dev-C++ start menu.\r\n\r\nThe [Setup] section\r\n-------------------\r\nThis section *must* contain at least the following keys:\r\nVersion     The package format's version number. A higher version number means\r\n            that this package is not compatible with older package managers.\r\nAppName     A name for the package. Example: MyApp\r\nAppVerName  The package's name and the version together.\r\n            Example: MyApp Version 1.0\r\nAppVersion  The package's version number. Example: 1.0\r\nMenuName    A name for a menu group for this package.\r\n\r\nThe following keys are optional:\r\nUrl           An URL to the library's website.\r\nPicture       A filename to a logo\/picture\/whatever that will be displayed.\r\nDescription   A desription for the package.\r\nReadme        A filename to the Readme file, relative to the .DevPackage file.\r\n              Example: README.TXT\r\nLicense       A filename to the license file, relative to the .DevPackage file.\r\n              Example: COPYING.TXT\r\nReboot        Wether the package requires a reboot or not in order to function\r\n              properly. The value can be either 1 (true) or 0 (false).\r\nDependencies  A comma-seperated list of package names that this package\r\n              depends on.\r\n\r\nThe [Files] section\r\n-------------------\r\nKeys in the Files section are composed in the following format:\r\n\r\nSource=Destdir\\[FileName][;Flags]\r\n\r\nSource (required):\r\nThe name of the source file, relative to the .DevPackage file.\r\nThis can be a directory, in which case all files inside that directory will be\r\ncopied.\r\n\r\nDestdir (required):\r\nThe destination directory. Please note that Destdir must *always* end with a\r\nbackslash (\\). Otherwise it will be interpreted as FileName.\r\n\r\nFileName (optional):\r\nIf this is specified, the copied file will be renamed to the specified filename.\r\n\r\nFlags (optional):\r\nAn extra set of options.\r\nrecursive   If Source is a directory, the installer will recurse into any\r\n            subdirectories and copy the files inside those subdirectories too.\r\n            This doesn't work in Dev-C++, since one one hand the directories\r\n            are copied recursively by default and on the other hand the \";\"\r\n            is used in DestDir corrupting the destination filename.\r\n\r\nConstants:\r\nSourcedir and Destdir can contain constants. A constant will be replaced to\r\ntheir literal value, depending on the user's configuration. The constants'\r\nnames are not case sensitive.\r\n&lt;app&gt;  Dev-C++'s root directory (usually C:\\Dev-C++).\r\n&lt;src&gt;  The source directory (the directory where the .DevPackage file is\r\n       located).\r\n&lt;win&gt;  The system's Windows directory (usually C:\\WINDOWS).\r\n&lt;sys&gt;  The system's Windows System directory (usually C:\\WINDOWS\\SYSTEM).\r\n\r\nExamples:\r\nFoo.txt=&lt;app&gt;\\                         Installs to C:\\Dev-C++\\Foo.txt\r\nBar.h=&lt;app&gt;\\include\\FooBar.h           Installs to C:\\Dev-C++\\include\\FooBar.h\r\nL33t.dll=&lt;sys&gt;\\                        Installs to C:\\WINDOWS\\System\\L33t.dll\r\nWindowsSucks.exe=&lt;win&gt;\\Explorer.exe    Installs to C:\\WINDOWS\\Explorer.exe\r\nBigFolder=C:\\;recursive                Installs all files in BigFolder,\r\n                                       including all files inside any\r\n                                       subfolders, to C:\\\r\n\r\nThe [Icons] section\r\n-------------------\r\nThis section is ignored if MenuName (in the Setup section) is not given.\r\n\r\nEntries in this section describe what menu items should be created.\r\nEach entry has the following format:\r\n\r\nName=Target[,Icon Filename]\r\n\r\nTarget can contain constants as described in the Files section.\r\n\r\nExamples:\r\n[Setup]\r\nMenuName=GTK\r\n[Icons]\r\nWebsite=http:\/\/www.gtk.org\/\r\n\r\nThis will create the menu group \"Start-&gt;Programs-&gt;Bloodshed Dev-C++-&gt;GTK\",\r\nwith 1 menu item, called Website, which points to http:\/\/www.gtk.org\/\r\n\r\n[Setup]\r\nMenuName=FLTK\r\n[Icons]\r\nUI Designer=&lt;app&gt;\\bin\\Fluid.exe,&lt;app&gt;\\Icons\\Fluid.ico\r\nWebsite=http:\/\/www.fltk.org\/\r\n\r\nLet's assume that Dev-C++ is installed in C:\\Dev-C++. This will create the\r\nmenu group \"Start-&gt;Programs-&gt;Bloodshed Dev-C++-&gt;FLTK\", with 2 menu items:\r\n- Website, which points to http:\/\/www.gtk.org\/\r\n- UI Designer, which points to C:\\Dev-C++\\bin\\fluid.exe, and use the icon\r\n  file C:\\Dev-C++\\Icons\\Fluid.ico<\/pre>\n<p>The file can also be downloaded: <a href=\"http:\/\/www.miscdebris.net\/blog\/wp-content\/uploads\/2008\/10\/devpak-format.txt\">devpak-format<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;m in the process of writing a DevPak for the libharu libary. These are actually tar.bz2 packages of whatever you think is a good idea to install into the Dev-C++, Code::Blocks or wxDev-C++ IDEs. E.g. precompiled libraries and necessary header files. In addition one adds a so called DevPackage file, which tells the IDEs where &hellip; <a href=\"http:\/\/www.miscdebris.net\/blog\/2008\/10\/07\/instructions-on-how-to-create-devpak-packages\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Instructions on how to create DevPak packages<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false},"version":2}},"categories":[6],"tags":[],"class_list":["post-61","post","type-post","status-publish","format-standard","hentry","category-miscellaneous-debris"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p6pnj-Z","_links":{"self":[{"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/posts\/61"}],"collection":[{"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/comments?post=61"}],"version-history":[{"count":10,"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/posts\/61\/revisions"}],"predecessor-version":[{"id":66,"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/posts\/61\/revisions\/66"}],"wp:attachment":[{"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/media?parent=61"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/categories?post=61"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.miscdebris.net\/blog\/wp-json\/wp\/v2\/tags?post=61"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}