ActionsAPI

Autotools

Author:

Semen Cirit

Date:

October 26, 2011

Version:

0.1

configure

configure(parameters)

Configures the package according to the parameters given by the user and PISI’s default parameters.

The default parameters: (You can see the these defaults from http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py and http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py)

--prefix
--build
--mandir
--infodir
--datadir
--sysconfdir
--localstatedir
--libexecdir

Examples:

autotools.configure()
autotools.configure("--with-libusb")

rawConfigure

rawConfigure(parameters)

Configures the package according to the parameters given by the user.

Examples:

autotools.rawConfigure()
autotools.rawConfigure("--prefix=/usr --libdir=/usr/lib --with-doxywizard")
autotools.rawConfigure("--enable-nls --enable-freetype --disable-xmltest)

compile

compile(parameters)

Compile the package with default GCC binutils, C flags and the parameters given by the user.

Example:

autotools.compile("-I/usr/include/dvdread -o dvdbackup src/dvdbackup.c -ldvdread")

make

make(parameters)

Builds the package according to the parameters given by the user.

Examples:

autotools
.
make
()
autotools
.
make
(
"local-all"
)
autotools
.
make
(
"LIBS=
%s
"
%
get
.
LDFLAGS
())
autotools
.
make
(
"-j1"
)

install

install
(
parameters
)

Install the package according to the parameters given by the user and PISI’s default parameters.

Examples:

autotools
.
install
()
autotools
.
install
(
"libdir=
%s
/usr/lib"
%
get
.
installDIR
())

rawInstall

rawInstall
(
parameters
)

Install the package according to the parameters given by the user.

Exmples:

autotools
.
rawInstall
(
"DESTDIR=
%s
"
%
get
.
installDIR
())
autotools
.
rawInstall
(
"DESTDIR=
\"
%s
\"
 docdir=/usr/share/doc/
%s
/html"
%
(
get
.
installDIR
(),
get
.
srcTAG
()))

aclocal

aclocal
(
parameters
)

Creates an aclocal.m4 file according to the configure.in file.

Examples:

autotools
.
aclocal
(
"-I cmulocal -I config"
)
autotools
.
aclocal
(
"-I m4"
)
autotools
.
aclocal
()

autoconf

autoconf
(
parameters
)

Creates the configure script, with given parameters.

Example:

autotools
.
autoconf
()

autoreconf

autoreconf
(
parameters
)

Recreates the configure script with given parameters.

Example:

autotools
.
autoreconf
()

automake

automake
(
parameters
)

Creates the makefile with given parameters.

Examples:

autotools
.
automake
(
"-afc"
)
autotools
.
automake
(
"--add-missing"
)
autotools
.
automake
()

autoheader

autoheader
(
parameters
)

Creates the header file for the configure script.

Examples:

autotools
.
autoheader
()

Cmaketools

Author:

Semen Cirit

Date:

October 26, 2011

Version:

0.1

configure

configure
(
parameters
,
sourceDir
,
installPrefix
=
'
%s
'
%
get
.
defaultprefixDIR
())

Configures the source with the given cmake parameters.

Examples:

cmaketools
.
configure
()
cmaketools
.
configure
(
installPrefix
=
"
%s
"
%
(
get
.
kdeDIR
()))
cmaketools
.
configure
(
"-DCMAKE_BUILD_TYPE=None -DKDEDIR=
%s
"
%
get
.
kdeDIR
(),
sourceDir
=
".."
)

make

make
(
parameters
)

Builds the source with the given parameters.

Example:

cmaketools
.
make
()
cmaketools
.
make
(
"LIBS=
%s
"
%
get
.
LDFLAGS
())
cmaketools
.
make
(
"-j1"
)

install

install
(
parameters
,
argument
=
'install'
)

Installs the source with the parameters given by the user and PISI’s default parameters.

Example:

cmaketools
.
install
()
cmaketools
.
install
(
"libdir=
%s
/usr/lib"
%
get
.
installDIR
())

rawInstall

rawInstall
(
parameters
,
argument
=
'install'
)

Installs the source with the parameters given by the user.

Example:

cmaketools
.
rawInstall
(
"PREFIX=
%s
"
%
get
.
installDIR
())

Get

Author:

Semen Cirit

Date:

October 26, 2011

Version:

0.1

Global Functions

curDIR

get
.
curDIR
()

Returns current work directory’s path.

curKERNEL

get
.
curKERNEL
()

Returns currently running kernel’s version.

curPYTHON

get
.
curPYTHON
()

Returns currently used python’s version.

curPERL

get
.
curPERL
()

Returns currently used perl’s version.

ENV

get
.
ENV
(
environ
)

Returns any given environ variable.

Example:

get
.
ENV
(
"MAKE_DOC"
)
get
.
ENV
(
"LD_LIBRARY_PATH"
)

pkgDIR

get
.
pkgDIR
()

Returns the path of binary packages. Default is”/var/cache/pisi/packages”.

workDIR

get
.
workDIR
()

Returns the path of package work directory. For example it can return a path like “/var/pisi/texlive-core-0.0_20091107-4/work”.

installDIR

get
.
installDIR
()

Returns the package install directory. For example it can return a path like “/var/pisi/texlive-core-0.0_20091107-4/install”

lsbINFO

get
.
lsbINFO
()

Returns a dictionary filled through /etc/lsb-release.

srcNAME

get
.
srcNAME
()

Returns the name of source package. (i.e. flashplugin)

srcVERSION

get
.
srcVERSION
()

Returns the version of source package. (i.e. 5.2_p1, 10.1.82.76)

srcRELEASE

get
.
srcRELEASE
()

Returns the release number of source package. (i.e. 28)

srcTAG

get
.
srcTAG
()

Returns the name, version and release number of source package. (i.e. 5.2_p1-28)

srcDIR

get
.
srcDIR
()

Returns the directory name of the package source under “/var/pisi/”. (i.e. teeworlds-0.5.2)

ARCH

get
.
ARCH
()

Returns the default arch value written at “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class GeneralDefaults. (i.e i686)

HOST

get
.
HOST
()

Returns the default host value written at “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class BuildDefaults. (i.e i686-pc-linux-gnu)

CFLAGS

get
.
CFLAGS
()

Return the default cflags used for Pardus. You can see them from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class BuildDefaults.

CXXFLAGS

get
.
CXXFLAGS
()

Return the default cxxflags used for Pardus. You can see them from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class BuildDefaults.

LDFLAGS

get
.
LDFLAGS
()

Return the default ldflags used for pardus. You can see them from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class BuildDefaults.

makeJOBS

get
.
makeJOBS
()

Return the default jobs value used for pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class BuildDefaults.

buildTYPE

get
.
buildTYPE
()

Return the current build type included in pspec.xml with <BuildType> tag.

docDIR

get
.
docDIR
()

Returns the default doc files directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

sbinDIR

get
.
sbinDIR
()

Returns the default sbin directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

infoDIR

get
.
infoDIR
()

Returns the default info files directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

manDIR

get
.
manDIR
()

Returns the default man files directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

dataDIR

get
.
dataDIR
()

Returns the default data files directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

confDIR

get
.
confDIR
()

Returns the default configure files directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

localstateDIR

get
.
localstateDIR
()

Returns the default locale files directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

libexecDIR

get
.
libexecDIR
()

Returns the default library executable directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in

defaultprefixDIR

get
.
defaultprefixDIR
()

Returns the default prefix directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py” in class Dirs.

kdeDIR

get
.
kdeDIR
()

Returns the default kde directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class DirectoriesDefaults.

qtDIR

get
.
qtDIR
()

Returns the default qt directory used for Pardus. You can see it from “http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py” in class DirectoriesDefaults.

AR

get
.
AR
()

Return GNU ar binutil executable variable of the system where the package being compiled. (i.e. ar)

AS

get
.
AS
()

Return GNU assembler binutil executable variable of the system where the package being compiled. (i.e. as)

CC

get
.
CC
()

Return gcc binutil executable variable of the system where the package being compiled. (i.e. i686-pc-linux-gnu-gcc)

CXX

get
.
CXX
()

Return gcc C++ binutil executable variable of the system where the package being compiled. (i.e. i686-pc-linux-gnu-g++)

LD

get
.
LD
()

Return GNU linker binutil executable variable of the system where the package being compiled. (i.e. ld)

NM

get
.
NM
()

Return GNU nm binutil executable variable of the system where the package being compiled. (i.e. nm)

RANLIB

get
.
RANLIB
()

Return ranlib binutil executable variable of the system where the package being compiled. (i.e. ranlib)

F77

get
.
F77
()

Return GNU fortran compiler binutil executable variable of the system where the package being compiled. (i.e. g77)

GCJ

get
.
GCJ
()

Return GNU java compiler binutil executable variable of the system where the package being compiled. (i.e. gcj)

KDE

Author:

Semen Cirit

Date:

October 26, 2011

Version:

0.1

configure

configure
(
parameters
)

Configures the kde packages according to the parameters given by the user and PISI’s

default parameters.

The default parameters: (You can see the these defaults from http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/configfile.py and http://svn.pardus.org.tr/uludag/trunk/pisi/pisi/actionsapi/variables.py)

--prefix
--build
--with-x
--enable-mitshm
--with-xinerama
--with-qt-dir
--enable-mt
--with-qt-libraries
--disable-dependency-tracking
--disable-debug

Example:

kde.configure("--without-included-sqlite")
kde.configure("--with-libsamplerate")
kde.configure()

make

make(parameters)

Builds the kde packages according to the parameters given by the user.

Example::

kde.make("-f admin/Makefile.common")
kde.make()

install

install(parameters='install')

Install the package according to the parameters given by the user and PISI’s default parameters.

Example:

kde.install()

Kerneltools

Author:

Semen Cirit

Date:

October 26, 2011

Version:

0.1

Configuration Part

getKernelVersion

getKernelVersion(flavour=None)

Returns the kernel version information to use with external module compilation This is something like 2.6.30_rc7-119 which will be appended to /lib/modules. If flavour==None, it will return the kernel version in the /etc/kernel/kernel file, else /etc/kernel/<flavour>. If it fails, it will return the running kernel version.

Configure

configure()

It first cleans the system form .orig files, then starts kernel configuration.

updateKConfig()

updateKConfig()

Call this to set newly added symbols to their defaults after sedding some Kernel Configuration parameters.

Building and Installing Part

dumpVersion

dumpVersion()

Writes the specific kernel version into /etc/kernel.

build

build(debugSymbols=False)

Builds the kernel with given debug symbols, the default debugSymbols is False.

install

install(installFirmwares=True)

It first controls whether loadable module support is available, then it installs the kernel image.

If installFirmwares==False it removes firmwares.

installHeaders

installHeaders(extra=[])

Installs the additional kernel headers needed to build out-of-tree kernel modules.

Example:

kerneltools.installHeaders(extra=["drivers/media/dvb/dvb-core"
,"drivers/media/dvb/frontends","drivers/media/video"])

installLibcHeaders

installLibcHeaders(excludes=[]):

Installs the Linux-Libc-Headers exculuding the givens.

Example:

kerneltools.installLibcHeaders(excludes=["scsi"])

installSource

installSource()

Installs the kernel source files.

cleanModuleFiles

cleanModuleFiles()

Cleans module.* files generated by depmod.

mkinitramfs

mkinitramfs()

Create and install the initramfs image into the package.

Libtools

Author:

Semen Cirit

Date:

October 26, 2011

Version:

0.1

preplib

prelib
(
sourceDirectory
)

Executes ldconfig command in the sourceDirectory.

Example:

libtools
.
preplib
()

gnuconfig_update

gnuconfig_update
()

Copies the newest config.sub and config.guess files to the source.

Example:

libtools
.
gnuconfig_update
()

libtoolize

libtoolize
(
parameters
)

Makes it possible to execute libtoolize with given parameters on the source.

Examples:

libtools
.
libtoolize
()
libtools
.
libtoolize
(
"--force --copy"
)
libtools
.
libtoolize
(
"--force --install"
)

gen_usr_ldscript

gen_usr_ldscript
(
dynamicLib
)

Since Pardus has critical dynamic libraries in /lib, and the static versions in /usr/lib, we need to have a dynamic lib in /usr/lib, otherwise we run into linking problems.

Examples:

libtools
.
gen_usr_ldscript
(
"libhandle.so"
)
libtools
.
gen_usr_ldscript
(
"libhandle.so"
)
libtools
.
gen_usr_ldscript
(
"libdevmapper.so"
)

Last updated