Snapcraft and Java - experimental

Mark Shuttleworth mark at ubuntu.com
Tue Aug 4 01:45:22 UTC 2015


The two core ideas for snapcraft are:

First, a universal meta-build system that allows you to pull together
wildly different types of source code and build your app together with
all its dependencies. So for example you might download and build the
javascript runtime you want, together with the JRE and various Java
files, adding in a bunch of python for a sub-command and Go for another.
snapcraft lets you define handlers for classes of content, and it comes
with handlers for common project types like "github automake projects"
or "go projects" or "apache maven projects". Each of these can have
completely different build systems or make files; the handler takes care
of all that.

We know that most cool stuff is moving far faster than the packaging
system, so snapcraft is designed to work directly from source wherever
you need, handling every type of source project from github or
elsewhere, and then mix in debs where that makes sense. We took a lot of
inspiration from the catkin tools in the ROS project, and we're keen for
feedback from the widest audience. Just yesterday we had a good bug
report asking for a cleanroom build as well as cross-build support,
which is very useful insight.

Second, in order to enable people to go faster, we want to have a
library of pre-defined upstream source "parts". In snapcraft you
describe each of these parts, defining which handler to use and any
parameters like the version control URL and tag to use. We figure it
would be most useful to have many of those defined in a shared space, as
parts that you can just invoke by name. So "libreadline" as a named part
in your snap would be the source equivalent of "apt-get install
libreadline-dev". This idea of an apt-like system for commonly shared
source parts is particularly cool.

Happy snappying,
Mark

On 03/08/15 10:12, Maarten Ectors wrote:
> Many developers are surprised to see how easy it is to create a hello world
> Snappy App. However when you go and create a complex application, packaging
> it as a Snap becomes harder. This is why we launched Snapcraft
> <https://launchpad.net/snapcraft>. Snapcraft allows anybody to create
> plugins to support their favourite programming language, platform,
> packaging solution, etc. Snapcraft is still experimental but with your help
> we can make it super easy for anybody to create snaps in any language and
> for any platform.
>
> As a preview here you can see how easy it is to package a JDK, Tomcat and
> your favourite war:
> https://insights.ubuntu.com/2015/08/03/java-on-snappy/
>
> If you like Snapcraft, please upvote the blog post on Hacker News:
> https://news.ycombinator.com/item?id=9994563
>





More information about the snappy-app-devel mailing list