Difference between revisions of "Wah!Cade:Development"

From Wah!ki
Jump to navigation Jump to search
(One intermediate revision by the same user not shown)
Line 14: Line 14:
 
==== Required (Common) ====
 
==== Required (Common) ====
 
* a VERSION file in the wahcade directory
 
* a VERSION file in the wahcade directory
* ''' Directories '''
+
* Modified make_tarball bash script, creates required directories
Modified make_tarball bash script
+
<pre>
: <pre>
 
 
#!/bin/sh
 
#!/bin/sh
 
#make a tarball for the project
 
#make a tarball for the project
Line 62: Line 61:
 
                 self.version = line.rstrip('\n')
 
                 self.version = line.rstrip('\n')
  
 +
</pre>
 +
 +
* Clean up after packaging complete, add the text below to the bottom of build_deb_package
 +
<pre>
 +
rm -rf $SOURCE/dist
 
</pre>
 
</pre>
  

Revision as of 09:17, 1 May 2011

Layouts

Source Code

Packaging

Required (Common)

  • a VERSION file in the wahcade directory
  • Modified make_tarball bash script, creates required directories
#!/bin/sh
#make a tarball for the project

PROJECTS=~/projects
COMMON=$PROJECTS/common
NAME=wahcade
LNSOURCE=~/wahcade
SOURCE=$PROJECTS/$NAME
WWW=$PROJECTS/anti-particle.com

#make directories
mkdir -p $PROJECTS
mkdir -p $COMMON
#mkdir -p $SOURCE
ln -s $LNSOURCE $SOURCE
mkdir -p $WWW
mkdir -p $SOURCE/dist/tarballs/
mkdir -p $SOURCE/dist/rpms/
mkdir -p $SOURCE/dist/debs/
mkdir -p $PROJECTS/windows_data/downloads/temp
mkdir -p $WWW/projects/$NAME/

#set vars requiring directories
VERSION=$(cat $PROJECTS/$NAME/VERSION)
PYVER=$NAME-$VERSION
TARBALL=$SOURCE/dist/tarballs/$PYVER.tar.gz

#make the tarball
cd $PROJECTS
tar -zhcf $TARBALL -T $NAME/wahcade_files

#copy stuff to antiparticle dir
cp -f $TARBALL $PROJECTS/windows_data/downloads/temp
cp -f $TARBALL $WWW/projects/$NAME
cp -f $SOURCE/doc/[A-Z]* $WWW/projects/$NAME/
cp -f $SOURCE/doc/xmame/xmamerc $WWW/projects/$NAME/
cp -f $SOURCE/doc/xmame/xmame-x11rc $WWW/projects/$NAME/
  • Edit line 87 of the bdist_debian.py and have it read from the VERSION file
        #self.version=self.distribution.get_version()
        for line in open ('VERSION','r'):
                self.version = line.rstrip('\n')

  • Clean up after packaging complete, add the text below to the bottom of build_deb_package
rm -rf $SOURCE/dist

Required (Ubuntu)

  • Alien (sudo apt-get install alien)

How to Package

  • Run ./make_all from the wahcade project folder.

Packages will be available in ~/projects/anti-particle.com/projects/wahcade/