NativeLinuxPackages Former
NOTE: The current document regarding Linux packaging is located here: http://wiki.netbeans.org/NativeLinuxPackages
Table of Contents
Configuration
This is stripped NetBeans IDE 6.0.1 configuration to limit number of external dependencies.
Remarks
- Basically Java IDE which does not include: DB, JPA, WebServices and XSL.
- The patch is a plain module config change.
- Removing VCS (CVS, Subversion) would probably remove three more libs (jsch, ini4j and svnClientAdapter )
- List of hardy packages obtained from http://packages.ubuntu.com/hardy/allpackages.en.txt.gz
- Would be nice to get rid of resolver.jar too, but all freeform modules seem to depend on it (see bottom of the page).
Mandriva
Press Release April 17, 2008
NetBeans team and Mandriva, the publisher of Mandriva Linux are proud to announce the immediate availability of award winning NetBeans IDE as part of the Mandriva 2008.1 Linux distribution.
Based on the open source NetBeans IDE 6.0 release, and the open source version of Java, as developed by Sun Microsystems, the Mandriva's contrib repository now contains a full Open Source stack to write, run, debug and test Swing based Java applications. Just open your favorite package management tool and install "netbeans-ide" package:
urpmi netbeans-ide
Enjoy! If you find any bugs, please report them to linux-packaging@installer.netbeans.org mailing list.
Technical info about Packaging
Latest source RPMs are published as part of Mandriva's Cooker, for example at ftp.proxad.net and [ftp.proxad.net| ftp://ftp.proxad.net/pub/Distributions_Linux/MandrivaLinux/devel/cooker/SRPMS/contrib/release] start with netbeans-ide and libnb-* packages.
List of packages:
- libnb-platform7 package contains cluster platform7
- libnb-ide8 ide8
- libnb-java1 java1
- libnb-apisupport1 apisupport1
- libnb-platform7-devel harness
- libnb-javaparser contains NetBeans java parser infrastructure
- libnb-svnClientAdapter contains NetBeans version of SVN adapter
- netbeans-ide nb6.0, launcher, netbeans.conf, netbeans.clusters, ....
Other packages may be added in future, as soon as they are cleaned up from 3rd party libraries. However even right now they are available through NetBeans internal Autoupdate.
List of necessary Libraries (Ubuntu)
External
| Library | Ubuntu Hardy Package | Status |
|---|---|---|
| ./platform7/modules/ext/swing-layout-1.0.3.jar | libswing-layout-java (1.0.3-1) universe | EXISTS |
| ./platform7/modules/ext/script-api.jar | we have dummy module icedtea contains this code already | N/A |
| ./platform7/modules/ext/jh-2.0_05.jar | javahelp2 (2.0.05-3) universe | EXISTS |
| ./ide8/modules/ext/xerces-2.8.0.jar | libxerces2-java (2.9.0-1) main | EXISTS |
| ./ide8/modules/ext/lucene-core-2.1.0.jar | liblucene2-java (2.2.0-2ubuntu1) universe | EXISTS |
| ./ide8/modules/ext/resolver-1.2.jar | libxml-commons-resolver1.1-java (1.2-1) | EXISTS 1 |
| ./ide8/modules/ext/freemarker-2.3.8.jar | libfreemarker-java (2.3.10) | EXISTS |
| ./ide8/modules/ext/commons-logging-1.0.4.jar | libcommons-logging-java (1.1-1ubuntu1) main | EXISTS |
| ./ide8/modules/ext/ini4j-0.2.6.jar | our own libini4j-java (0.2.6) | ACCEPTED 2 185943 |
| ./ide8/modules/ext/svnClientAdapter-0.9.23.jar | our own libnb-svnclientadapter-java (6.0) | ACCEPTED 185991 |
| ./ide8/modules/ext/jsch-0.1.24.jar | libjsch-java (0.1.34ds1-1) main | EXISTS |
| ./java1/ant/* | ant (1.7.0-3) main | EXISTS Needs to test whether all parts are available in the package |
| ./java1/modules/ext/junit-3.8.2.jar | junit (3.8.1.1-7) main | EXISTS |
| ./java1/modules/ext/junit-4.1.jar | junit4 (4.3.1-2) universe | EXISTS |
| ./java1/modules/ext/swing-worker-1.1.jar | our own libswingworker-java (1.1) | ACCEPTED 185960 |
| ./java1/modules/ext/appframework-1.0.3.jar | our own libappframework-java (1.0.3) | ACCEPTED 185969 |
| ./java1/modules/ext/beansbinding-1.2.1.jar | our own libbeansbinding-java (1.2.1) | ACCEPTED 185975 |
| ./java1/modules/ext/javac-api.jar AND javac-impl.jar | our own libnb-javaparser-java (6.0) | ACCEPTED 185982 |
NetBeans (don't care)
| ./java1/modules/ext/org-netbeans-modules-java-j2seplatform-probe.jar |
|---|
| ./java1/modules/ext/AbsoluteLayout.jar |
| ./platform7/modules/ext/updater.jar |
| ./ide8/modules/ext/org-netbeans-tax.jar |
| ./nb6.0/modules/ext/locale/updater_nb.jar |
Modules depending on resolver-1.2.jar
grep -r --include "*.xml" "xml\.resolver" .
./java/freeform/nbproject/project.xml: org.apache.xml.resolver
./logger/uihandlerlib/test/unit/src/org/netbeans/lib/uihandlerserver/wrongutfchar.xml: <param>org.apache.xml.resolver</param>
./logger/uihandlerlib/test/unit/src/org/netbeans/lib/uihandlerserver/baduser.xml: <param>org.apache.xml.resolver</param>
./libs/resolver/nbproject/project.xml: org.apache.xml.resolver
./libs/resolver/nbproject/project.xml: <subpackages>org.apache.xml.resolver</subpackages>
./apisupport/project/nbproject/project.xml: org.apache.xml.resolver
./xml/retriever/nbproject/project.xml: org.apache.xml.resolver
./xml/catalog/nbproject/project.xml: org.apache.xml.resolver
./ant/freeform/nbproject/project.xml: org.apache.xml.resolver
Build of the Small IDE
Zipped build of the small IDE is available here for convenience. Unfortunately this link only works inside of Sun. If you are outside you will still need to check out 6.0 version of NetBeans, apply the patch and build it with ant -Dcluster.config=basic build-nozip.
Packages
List of packages:
Binary packages generated from source package libnb-platform7-java:
- libnb-platform7-java package contains cluster platform7
- libnb-platform7-java-doc package contains javadoc for NetBeans Platform
- libnb-platform7-devel-java harness
Binary packages generated from source package netbeans:
- libnb-ide8-java ide8
- libnb-java1-java java1
- libnb-apisupport1-java apisupport1
- netbeans nb6.0, launcher, netbeans.conf, netbeans.clusters, ....
Our own separate packages:
- libnb-javaparser-java contains NetBeans java parser infrastructure
- libnb-svnClientAdapter-java contains NetBeans version of SVN adapter
These are also listed above in table of external libraries
Ubuntu
Disc layout
Disc layout is designed to allow to install more versions of NetBeans (and its clusters) into one system. This allows other applications which might depend on older NetBeans version (e.g. platform7 cluster) to still use this cluster even NetBeans IDE with cluster platform8 is installed.
Packages listed above, the ones which contain real modules and files will be installed as follows:
- e.g. package libnb-platform7-java ==> /usr/share/netbeans/platform7 folder.
- or libnb-ide8-java ==> /usr/share/netbeans/ide8 folder.
From these folders we will create symlinks to 3rd party libraries installed aside e.g. to ini4j.jar which is installed as extra lib. External libraries are installed mostly to /usr/share/java.
The top level package for NetBeans 6.0.1 IDE will be installed as follows:
- package netbeans ==> /usr/share/netbeans/6.0.1/nb6.0/
- then symlinks to all clusters physically installed above will be created in /usr/share/netbeans/6.0.1/platform7 will be symlink to /usr/share/netbeans/platform7 folder
- /etc/netbeans.clusters file will contain list of all known clusters. /usr/share/netbeans/6.0.1/etc/netbeans.clusters is symlink to /etc/netbeans.clusters
- IDE launcher /usr/bin/netbeans will be created. The launcher script will be "one fits all" kind, it will not be customized for particular system configuration.
- Files /etc/netbeans.conf and /etc/netbeans.clusters will be actual files and /usr/share/netbeans/6.0.1/etc/netbeans.conf and /usr/share/netbeans/6.0.1/etc/netbeans.clusters will be symlinks to them.
- Launcher is created in /usr/bin/netbeans. It is patched to be able to locate /etc/netbeans.conf and /usr/share/netbeans/6.0.1/etc/netbeans.clusters
- Man page /usr/share/man/man1/netbeans.1.gz is created.
- Desktop file /usr/share/applications/netbeans.desktop (adds menu item to start menu Applications -> Programming for NetBeans IDE.
NetBeans 6.0.1
| Package | Status | Link |
|---|---|---|
| libnb-platform7-java | ACCEPTED | 187301 |
| netbeans | ACCEPTED | 187708 |
#1 It contains original resolver1.2 without NetBeans patches. XML team should handle this. API change should go to upstream. Second NPE issue should be handled somehow on NetBeans side. Current status breaks SOA functionality #127132 . We are investigating if there is any workaround.
#2 Source package is UPLOADED to REVU and must pass through review by at least 2 reviewers. If it passes review it goes to NEW queue . It must be ACCEPTED by archive admin to go to repository and become available. These packages already passed review from Emmet Hikory - our Ubuntu technical contact.
lucene2 issues:
Notes
appframework upstream has AppFramework-1.03.jar but in IDE framework-1.0.3.jar is used.
Upstream sources for NetBeans 6.0.1 Ubuntu packages
We use reference archive for platform and ide to create upstream source archives necessary to build Ubuntu packages. As these archives contain binaries we must clean them. Shell scripts clean-platform_NativeLinuxPackages_Former.sh and clean-ide_NativeLinuxPackages_Former.sh for cleaning original sources are attached below. Unneeded sources are deleted from ide sources. Resulting source archives in tar.gz format used as upstream source for building packages are published as platform upstream and ide upstream. Root folder with name of source netbeans-platform-6.0.1 and netbeans-6.0.1 containing sources is created and file LICENSE.txt containing license is added to this folder.
HowTo Build Packages Quickstart
To build packages it is necessary to have either development version of Ubuntu or use pbuilder. Some additional packages must be installed. System tells you what to install on console when uninstalled program is used. Following packages must be installed to build our packages:
- build-essential
- debhelper
- devscripts
- ant and eventually ant-optional
- cdbs
- gnupg
- and of course any build dependency of built package
First you must have GPGKey to be able to sign built packages. Without it you will not be able to upload new packages or contribute updates for existing packages. Simply all contributions MUST be signed.
I will use libini4j-java package as example to show how to build existing package.
Get source package:
apt-get source libini4j-java
You will get:
libini4j-java-0.2.6 libini4j-java_0.2.6-0ubuntu2.diff.gz libini4j-java_0.2.6-0ubuntu2.dsc libini4j-java_0.2.6.orig.tar.gz
Directory libini4j-java-0.2.6 contains directory debian and uncompressed sources. Archive libini4j-java_0.2.6.orig.tar.gz contains upstream sources. Note name structure. If you create new package you must create this content manually.
To build binary package from source package go to directory libini4j-java-0.2.6 and use
debuild
in the end you will be asked to sign packages ie. enter passphrase.
To build source package for upload:
debuild -S -sa
To perform clean:
debuild clean
More info:
For uploading new packages see: REVU
For updating existing packages see: Contributing
For more info about debian packaging see: Debian New Maintainers' Guide and Debian Policy Manual
Debian
Daniel Baumann, a Debian developer, did the packaging work and put NB 6.0 into <contrib>
NetBeans 6.1 for Debian and Ubuntu
List of packages:
Binary packages generated from source package libnb-platform-java:
- libnb-platform8-java package contains cluster platform8
- libnb-platform8-java-doc package contains javadoc for NetBeans Platform
- libnb-platform8-devel-java harness
Binary packages generated from source package netbeans:
- libnb-ide9-java ide9
- libnb-java2-java java2
- libnb-apisupport1-java apisupport1
- netbeans nb6.1, launcher, netbeans.conf, netbeans.clusters, etc
Our own separate packages are listed below in the tables of external libraries
List of necessary Libraries (Debian)
External(Exist in 6.0.1)
| Library | Debian Package | Status |
|---|---|---|
| ./platform8/modules/ext/swing-layout-1.0.3.jar | libswing-layout-java (1.0.3-1) sid/main | EXISTS |
| ./platform8/modules/ext/script-api.jar | we have dummy module icedtea contains this code already | N/A (?) |
| ./platform8/modules/ext/jh-2.0_05.jar | javahelp2 (2.0.05-3) sid/main | EXISTS |
| ./ide9/modules/ext/xerces-2.8.0.jar | libxerces2-java (2.9.1-2) sid/main | EXISTS |
| ./ide9/modules/ext/lucene-core-2.2.0.jar | liblucene2-java (2.3.1+ds1-1) sid/contrib | EXISTS 3 (waits for openjdk-6 to move to main) |
| ./ide9/modules/ext/resolver-1.2.jar | libxml-commons-resolver1.1-java (1.2-2) sid/main | EXISTS 4 |
| ./ide9/modules/ext/freemarker-2.3.8.jar | libfreemarker-java (2.3.13-1) sid/contrib | EXISTS 3 (waits for libservlet2.5-java to move to main) |
| ./ide9/modules/ext/commons-logging-1.0.4.jar | libcommons-logging-java (1.1.1-1) sid/main | EXISTS |
| ./ide9/modules/ext/ini4j-0.2.6.jar | our own libini4j-java (0.2.6) | DONE(for Debian only) |
| ./ide9/modules/ext/svnClientAdapter-0.9.23.jar | our own libnb-svnclientadapter-java (6.1) | DONE(for Debian only) |
| ./ide9/modules/ext/jsch-0.1.24.jar | libjsch-java (0.1.37-3) sid/main | EXISTS |
| ./java2/ant/* | ant (1.7.0-6) sid/main | EXISTS |
| ./java2/modules/ext/junit-3.8.2.jar | junit (3.8.2-1) sid/main | EXISTS |
| ./java2/modules/ext/junit-4.1.jar | junit4 (4.3.1-4) sid/main | EXISTS |
| ./java2/modules/ext/swing-worker-1.1.jar | our own libswingworker-java (1.1) | DONE(for Debian only) |
| ./java2/modules/ext/appframework-1.0.3.jar | our own libappframework-java (1.0.3) | DONE(for Debian only) |
| ./java2/modules/ext/beansbinding-1.2.1.jar | our own libbeansbinding-java (1.2.1) | DONE(for Debian only) |
| ./java2/modules/ext/javac-api-nb-7.0-b07.jar AND javac-impl-nb-7.0-b07.jar | our own libnb-javaparser-java (6.1) | DONE(updated in Intrepid) |
External(New for 6.1)
| Library | Evaluation |
|---|---|
| ./java2/modules/ext/spring/commons-logging-1.1.jar | don't care |
| ./java2/modules/ext/spring/spring-2.5.jar | don't care |
| ./platform8/modules/ext/jna-3.0.2.jar | seems to be used by core.nativeaccess; New package is DONE. |
TODO
- #3 wait for packages to move to main(for Debian only)
- #4 resolve issue with forked resolver1.2 for NB6.1. #128678
- check what packages really require openjdk to build and what are ok to build with java-gcj-compat-dev and runtime java-gcj-compat | java1-runtime | java2-runtime (for Debian only)
- prepare licences for platform and IDE
- ML packages (?)
- create infrastructure for daily(?) builds
Release schedule (lenny)
Early of June 2008 : Freeze of the non-essential toolchain
The "non-essential toolchain" means things like debhelper, cdbs and a big chunk of other things usually needed to produce binary packages.
End of June 2008 : Freeze of all library packages
This will affect all packages that produce library packages used
by other packaged software. Packages without r-deps won't be
frozen at this point.
Mid of July 2008 : Full freeze
September 2008 : Release lenny
NetBeans 6.5 for Debian and Ubuntu
Stripped IDE configuration
Cluster nb.cluster.websvccommon is removed from clusters.config.basic.list. So all webcvs.* modules are removed
Modules removed from basic cluster by patch
| Module's name | Cluster name | List of broken dependencies | List of missing binaries |
|---|---|---|---|
| db | ide10 | derby-10.2.2.0.jar | |
| db.core | ide10 | db | |
| db.dataview | ide10 | db | |
| db.drivers | ide10 | mysql-connector-java-5.1.6-bin.jar, postgresql-8.3-603.jdbc3.jar | |
| db.kit | ide10 | all db* | |
| db.metadata.model | ide10 | db | |
| db.mysql | ide10 | db | |
| db.sql.editor | ide10 | db | |
| db.sql.visualeditor | ide10 | javacc-3.2.jar | |
| dbapi | ide10 | db | |
| httpserver | ide10 | tomcat-webserver-3.2.jar | |
| libs.jaxb | ide10 | activation.jar, jaxb-api.jar, jaxb-impl.jar, jaxb-xjc.jar | |
| servletapi | ide10 | servlet-2.2.jar | |
| web.flyingsaucer | ide10 | core-renderer-R7final.jar | |
| xsl | ide10 | servletapi | |
| dbschema | java2 | db | |
| derby | java2 | db | |
| form.j2ee | java2 | db, j2ee.persistence | |
| hibernate | java2 | db, dbschema, hibernatelib | |
| hibernatelib | java2 | hibernate-3.2.5-lib.zip | |
| j2ee.jpa.refactoring | java2 | j2ee.persistence | |
| j2ee.jpa.verification | java2 | dbapi, j2ee.persistence | |
| j2ee.persistence | java2 | db, dbapi, dbschema | |
| j2ee.persistence.kit | java2 | db, dbapi, dbschema, derby | |
| j2ee.toplinklib | java2 | glassfish-persistence-v2-build-58g.jar, glassfish-persistence-v2ur1-build-09d.jar | |
| libs.cglib | java2 | cglib-2.2.jar | |
| libs.springframework | java2 | spring-2.5.jar | |
| spring.beans | java2 | libs.springframework | |
| websvc.jaxws21 | java2 | jaxws-2.1.zip, jaxws-2_1-api-doc.zip | |
| websvc.jaxws21api | java2 | jaxws-2.1.zip | |
| websvc.saas.codegen.java | java2 | libs.jaxb, websvc.jaxws21api dep. (also depends on websvccommon cluster) | |
| xml.jaxb | java2 | websvc.jaxws21 | |
Fedora
See a separate page NetBeans & Fedora about the NetBeans distribution for Fedora.
Gentoo
- Netbeans 6.5 package on Gentoo contains every standard module/cluster except support for ruby (will be added later). Here are the modules/clusters: NETBEANS_MODULES="apisupport cnd groovy gsf harness ide identity j2ee java mobility nb php profiler soa visualweb webcommon websvccommon xml"
- We also have localization support in the package: LINGUAS="de es fr it ja pl pt_BR ru sq tr zh_CN zh_TW"
- Users can choose which modules they want to have built in, the same for locales
- We support x86 and amd64 archs
- Info about native linux packages of Netbeans 6.5 can be found in the ebuild (DEPEND is for compilation time dependencies, RDEPEND for runtime dependencies), more info about the packages can be found at Gentoo Online Package Database (please note that Gentoo is from-source distribution so we have to solve also compilation time JARs)
3rd party libraries
NetBeans IDE contains a lot of foreign JAR files, under various licenses. We should eliminate those that are not under OSI-approved ones (should be done by opensourcing JDK). For those that are under OSI, but under different license we need to find appropriate package or create it by ourselves. Indeed locations of JAR files in such packages are going to be at wrong places, so we need to create a symlink from usual NetBeans location to the actual JAR location. Also the NetBeans package that depends on the existence and validity of the symlink needs to have dependency on the package providing the symlink's original. Dependency is generally ok to specify just >= min.version.needed.by.netbeans, in most of the cases it should not matter that the actual version is a bit higher (e.g. ok to use jsch 1.30 even NetBeans does include jsch 1.28).
References
- heroic but not enough FOSS work on UbuntuPackagesForRelease55
- Small IDE experiment

