Tree [b3ff08] master /
History



File Date Author Commit
SDL 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
libbz2 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
libconio 2015-06-07 Lawrence Sebald Lawrence Sebald [ed4929] Add metadata for libconio, libdcplib, libkosh, ...
libdcplib 2015-06-07 Lawrence Sebald Lawrence Sebald [2424f0] Might help if I hit save on that file.
libgl 2015-06-04 Lawrence Sebald Lawrence Sebald [08c6ae] Add metadata to libgl.
libimageload 2015-06-06 Lawrence Sebald Lawrence Sebald [c0f624] Add pkg-descr files to libimageload, libpcx, an...
libjpeg 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
libkmg 2015-06-04 Lawrence Sebald Lawrence Sebald [8f9ac6] Add metadata to libimageload, libkmg, libpcx, a...
libkosh 2015-06-07 Lawrence Sebald Lawrence Sebald [ed4929] Add metadata for libconio, libdcplib, libkosh, ...
libmodplug 2015-06-07 Lawrence Sebald Lawrence Sebald [ed4929] Add metadata for libconio, libdcplib, libkosh, ...
libmp3 2015-06-06 Lawrence Sebald Lawrence Sebald [369448] Add metadata for libmp3.
libogg 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
liboggvorbisplay 2015-06-04 Lawrence Sebald Lawrence Sebald [a03fa9] Add metadata to libogg, libvorbis, liboggvorbis...
libparallax 2015-06-07 Lawrence Sebald Lawrence Sebald [4ac791] Add metadata to libparallax, libtsunami, and lua.
libpcx 2015-06-06 Lawrence Sebald Lawrence Sebald [c0f624] Add pkg-descr files to libimageload, libpcx, an...
libpng 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
libtga 2015-06-06 Lawrence Sebald Lawrence Sebald [c0f624] Add pkg-descr files to libimageload, libpcx, an...
libtremor 2015-06-04 Lawrence Sebald Lawrence Sebald [a03fa9] Add metadata to libogg, libvorbis, liboggvorbis...
libtsunami 2015-06-07 Lawrence Sebald Lawrence Sebald [4ac791] Add metadata to libparallax, libtsunami, and lua.
libvorbis 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
lua 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
scripts 2015-06-11 Lawrence Sebald Lawrence Sebald [b3ff08] Fix stupid typo.
utils 2015-06-09 Lawrence Sebald Lawrence Sebald [39d39e] Add a validate-dist target to the ports collect...
zlib 2015-06-09 Lawrence Sebald Lawrence Sebald [28ee94] Add distinfo files for all packages that downlo...
.gitignore 2015-05-10 Lawrence Sebald Lawrence Sebald [fe7c0b] Create installation directories automatically, ...
COPYING 2015-05-04 Lawrence Sebald Lawrence Sebald [8cbb70] First commit of new kos-ports.
README 2015-06-09 Lawrence Sebald Lawrence Sebald [39d39e] Add a validate-dist target to the ports collect...
config.mk 2015-06-09 Lawrence Sebald Lawrence Sebald [39d39e] Add a validate-dist target to the ports collect...

Read Me

README for kos-ports
Copyright (C) 2015 Lawrence Sebald
--------------------------------------------------------------------------------

Introduction
------------
Welcome to the newest iteration of the kos-ports system. As I'm sure you already
know, kos-ports is a repository of various useful libraries that have been
ported to KOS over the years. These libraries provide various tools such as
image reading support, archive file reading and writing, and even a OpenGL-like
environment. Each port is meant to be as self-contained as possible (which does
not mean it can't have dependent ports, of course) and should build on the
current version of KallistiOS with minimal fuss.

For those of you familiar with FreeBSD at all, this works a lot like their
ports collection (indeed, that's what I modeled it after). To build a port, it
should be as easy as going into that port's directory in a terminal and typing
    make install clean
into the terminal. If all goes well, the port will be built and installed inside
the ports tree, ready to be used.

This new version of the kos-ports tree sprung into being in May of 2015 and will
be included with the next version of KOS to be released after that point.


Dependencies
------------
kos-ports has very few external dependencies beyond a normally functioning KOS
toolchain. Here's the list:

1. Some way of downloading files from the terminal. The ports collection uses
   curl by default, but there's a configuration option to use whatever tool you
   might happen to have (and an example of using wget).
2. Git and SVN are required for some of the ports in the ports collection.
3. In order to validate downloaded source packages, Python is needed. Python
   2.7.x has been tested and found working. If you don't have Python, please
   edit the config.mk file to disable source package validation (or, better yet,
   install Python).
4. A relatively sane *nix shell and make program are also required. Everything's
   been tested with Bash and GNU Make.


Differences from the old ports tree
-----------------------------------
Unlike the old ports tree, this new ports tree is meant to not keep all of the
source code of each port in our own private copies. Basically, it's designed to
make sure we try to at least keep mostly up-to-date with the upstream versions
of libraries. In the past, we'd pretty much settle on one version of a library
for a very long time, never updating it until we had to. ;-)

In addition, this new version of the ports tree can enforce things like
dependencies between libraries. That is to say, for a library like libpng that
requires another library (zlib), the new ports tree will make sure you've
satisfied the dependencies at build time to avoid any surprises later.


Using the ports tree
--------------------
There are a few targets that can be built in each port's directory that are
available. Here's a brief rundown of each make target that you might be
interested in:

- install: Perform all steps to download, patch, build, and install the port in
           question. Generally this is the one target you want (along with the
           next one).
- clean: Clean up any dist files and intermediate build results.
- uninstall: Uninstall the port. This does not make sure dependencies are still
             fulfilled, so keep that in mind.
- portinfo: Print to the terminal a description and various metadata about the
            port in question.

Lesser used targets (mainly for internal use):
- clean-dist: Clean up any dist files. Does not clean build files.
- clean-build: Cleans up build files, leaving dist files in place.
- fetch: Download dist files from upstream.
- build-stamp: Build the port, but do not install it.
- version-check: Check the version of the port that is currently installed.
- depends-check: Check if all dependencies of the port are installed.
- unpack: Unpack any fetched packages for the port.
- validate-dist: Check downloaded distfiles for validity (if enabled).


Porting a new library
---------------------
Porting a new library is meant to be a relatively simple task. I recommend
looking at an existing port to get the idea (libpng is a good one to look at).
Describing the whole process would probably take a lot of work, so I'll leave it
as an exercise for the reader here. ;-)