ts-7000
[Top] [All Lists]

[ts-7000] Re: Java Step-by-Step

To:
Subject: [ts-7000] Re: Java Step-by-Step
From: "ticrus00" <>
Date: Mon, 23 Jul 2007 15:51:34 -0000
Chris,

Yes I have libpthread.so, jamvm works fine with your modified
glibj.zip, but not with the full one.  I don't get it.  I'm going to
try and build it, thanks for you help.

Justin

--- In  Christopher Friedt <> wrote:
>
> Hi Justin,
> 
> Do you know if the libpthread.so library was available on your system?
> 
> Here are the steps to build it from scratch if that helps:
> 
> 1) download zlib source, jamvm source, gnu classpath source
> 
> 2) extract to folders:
> 
> 
> jamvm/jamvm-${j_ver}/
> jamvm/jamvm-${j_ver}/
> zlib/zlib-${ver}
> classpath/classpath-${cp_ver}
> 
> for zlib configure,
> CC=arm-linux-gcc ./configure --prefix=/usr --shared
> 
> for zlib make,
> make
> make install prefix=$PWD/../zlib-install
> 
> for classpath configure,
> CFLAGS="-Os" ./configure --target=arm-linux --host=arm-linux 
> --prefix=/usr/local/jamvm --with-jikes --enable-collections 
> --enable-default-preferences-peer=file --without-gcj --without-x 
> --disable-gtk-peer --disable-gconf-peer --disable-plugin
> 
> for classpath make,
> make && make install DESTDIR=$PWD/../classpath-install
> 
> for jamvm configure,
> CFLAGS="-Os -I$PWD/../zlib/zlib-install/usr/include 
> -L$PWD/../zlib/zlib-install/usr/lib" ./configure 
> --prefix=/usr/local/jamvm --with-classpath-install-dir=/usr/local/jamvm 
> --host=arm-linux --target=arm-linux
> 
> for jamvm make,
> make && make install DESTDIR=$PWD/../jamvm-install
> 
> A few notes:
> 
> You should always strip shared libs and binaries before copying them to 
> your board, i.e. arm-linux-strip --strip-unneeded -vv <bin_or_soname>
> 
> Copy only binaries and shared libs, get rid of all other directories & 
> files, except for glibj.zip and the security file for jamvm.
> 
> 
> Before copying glibj.zip, as it was build per default, from your 
> workstation to your board, you will definitely need to remove some of 
> the parts. I wrote a script to do this, in the jamvm dir outside of the 
> compile / install dirs.
> 
> Note that there is a reference to a file ./__LOCALEINFO_NOT_NEEDED__ in 
> this script. My entries in that file follow below.
> 
> =====================================================================
> #!/bin/sh
> 
> RETVAL=0
> ORIG_DIR=$PWD
> INSTALL_DIR=classpath-install
> GLIBJ_ZIP=$INSTALL_DIR/usr/local/jamvm/share/classpath/glibj.zip
> 
> if [ ! -d $INSTALL_DIR ]; then
>    echo "'$INSTALL_DIR': no such file or directory"
>    exit 1
> else
> rm -Rf $INSTALL_DIR/usr/local/jamvm/info \
>   $INSTALL_DIR/usr/local/jamvm/bin \
>   $INSTALL_DIR/usr/local/jamvm/share/classpath/tools.zip \
>   $INSTALL_DIR/usr/local/jamvm/share/classpath/examples
> RETVAL=$(($RETVAL|$?))
> if [ $RETVAL -ne 0 ]; then
>    echo "warning: failed to remove exmples, tools, scripts, and info
files"
> fi
> 
> if [ ! -e $GLIBJ_ZIP ]; then
>    echo "'$GLIBJ_ZIP': no such file or directory"
>    exit 2
> else
> LOCALES_TO_REMOVE="`cat __LOCALEINFO_NOT_NEEDED__`"
> TMP="org/omg/* javax/swing/* javax/print/* javax/sound/*"
> TMP="$TMP java/rmi/* gnu/java/awt gnu/java/awt/* gnu/java/rmi/*
gnu/CORBA/*"
> TMP="$TMP gnu/javax/print/* gnu/javax/sound/* gnu/javax/swing/*"
> TMP="$TMP gnu/javax/rmi/CORBA/* java/awt/* javax/rmi/*"
> TMP="$TMP $LOCALES_TO_REMOVE"
> 
> zip -d $GLIBJ_ZIP $TMP > /dev/null 2>&1
> RETVAL=$(($RETVAL|$?))
> exit $RETVAL
> fi
> fi
> ========================================================
> 
> __LOCALEINFO_NOT_NEEDED__:
> gnu/java/locale/
> gnu/java/locale/LocaleInformation_ml_IN.properties
> gnu/java/locale/LocaleInformation_en_AU.properties
> gnu/java/locale/LocaleInformation_sid_ET.properties
> gnu/java/locale/LocaleInformation_ar.properties
> gnu/java/locale/LocaleInformation_sr_BA_Cyrl.properties
> gnu/java/locale/LocaleInformation_bg_BG.properties
> gnu/java/locale/LocaleInformation_da_DK.properties
> gnu/java/locale/LocaleInformation_zh_CN_Hans.properties
> gnu/java/locale/LocaleInformation_ti_ER.properties
> gnu/java/locale/LocaleInformation_kl_GL.properties
> gnu/java/locale/LocaleInformation_es_BO.properties
> gnu/java/locale/LocaleInformation_mt_MT.properties
> gnu/java/locale/LocaleInformation_aa.properties
> gnu/java/locale/LocaleInformation_ms.properties
> gnu/java/locale/LocaleInformation_es_PY.properties
> gnu/java/locale/LocaleInformation_byn_ER.properties
> gnu/java/locale/LocaleInformation_mt.properties
> gnu/java/locale/LocaleInformation_ar_YE.properties
> gnu/java/locale/LocaleInformation_de_LI.properties
> gnu/java/locale/LocaleInformation_en_VI.properties
> gnu/java/locale/LocaleInformation_fa_IR.properties
> gnu/java/locale/LocaleInformation_uz.properties
> gnu/java/locale/LocaleInformation_so_ET.properties
> gnu/java/locale/LocaleInformation_wal_ET.properties
> gnu/java/locale/LocaleInformation_sq_AL.properties
> gnu/java/locale/LocaleInformation_az.properties
> gnu/java/locale/LocaleInformation_fr_BE.properties
> gnu/java/locale/LocaleInformation_fr_CA.properties
> gnu/java/locale/LocaleInformation_dv.properties
> gnu/java/locale/LocaleInformation_sw_TZ.properties
> gnu/java/locale/LocaleInformation_pa_IN.properties
> gnu/java/locale/LocaleInformation_tt_RU.properties
> gnu/java/locale/LocaleInformation_fo_FO.properties
> gnu/java/locale/LocaleInformation_so.properties
> gnu/java/locale/LocaleInformation_uk.properties
> gnu/java/locale/LocaleInformation_en_BE.properties
> gnu/java/locale/LocaleInformation_km.properties
> gnu/java/locale/LocaleInformation_es_ES.properties
> gnu/java/locale/LocaleInformation_el.properties
> gnu/java/locale/LocaleInformation_ro.properties
> gnu/java/locale/LocaleInformation_cy.properties
> gnu/java/locale/LocaleInformation_it_IT.properties
> gnu/java/locale/LocaleInformation_id.properties
> gnu/java/locale/LocaleInformation_en_ZW.properties
> gnu/java/locale/LocaleInformation_es_SV.properties
> gnu/java/locale/LocaleInformation_nb_NO.properties
> gnu/java/locale/LocaleInformation_sa.properties
> gnu/java/locale/LocaleInformation_as.properties
> gnu/java/locale/LocaleInformation_es_US.properties
> gnu/java/locale/LocaleInformation_nn_NO.properties
> gnu/java/locale/LocaleInformation_lo_LA.properties
> gnu/java/locale/LocaleInformation_ky.properties
> gnu/java/locale/LocaleInformation_be_BY.properties
> gnu/java/locale/LocaleInformation_sr_Latn.properties
> gnu/java/locale/LocaleInformation_hy_AM.properties
> gnu/java/locale/LocaleInformation_kn.properties
> gnu/java/locale/LocaleInformation_uz_Latn.properties
> gnu/java/locale/LocaleInformation_eu.properties
> gnu/java/locale/LocaleInformation_es_EC.properties
> gnu/java/locale/LocaleInformation_bn_IN.properties
> gnu/java/locale/LocaleInformation_ka.properties
> gnu/java/locale/LocaleInformation_ru.properties
> gnu/java/locale/LocaleInformation_es_PA.properties
> gnu/java/locale/LocaleInformation_iu.properties
> gnu/java/locale/LocaleInformation_fa.properties
> gnu/java/locale/LocaleInformation_en_GB.properties
> gnu/java/locale/LocaleInformation_nn.properties
> gnu/java/locale/LocaleInformation_de_AT.properties
> gnu/java/locale/LocaleInformation_ur.properties
> gnu/java/locale/LocaleInformation_he_IL.properties
> gnu/java/locale/LocaleInformation_eu_ES.properties
> gnu/java/locale/LocaleInformation_uz_Arab.properties
> gnu/java/locale/LocaleInformation_zh_SG_Hans.properties
> gnu/java/locale/LocaleInformation_lv_LV.properties
> gnu/java/locale/LocaleInformation_de_CH.properties
> gnu/java/locale/LocaleInformation_sk.properties
> gnu/java/locale/LocaleInformation_ja.properties
> gnu/java/locale/LocaleInformation_ja_JP.properties
> gnu/java/locale/LocaleInformation_es_VE.properties
> gnu/java/locale/LocaleInformation_kn_IN.properties
> gnu/java/locale/LocaleInformation_mn.properties
> gnu/java/locale/LocaleInformation_fo.properties
> gnu/java/locale/LocaleInformation_ml.properties
> gnu/java/locale/LocaleInformation_zh_MO_Hant.properties
> gnu/java/locale/LocaleInformation_tig_ER.properties
> gnu/java/locale/LocaleInformation_fa_AF.properties
> gnu/java/locale/LocaleInformation_sr.properties
> gnu/java/locale/LocaleInformation_nb.properties
> gnu/java/locale/LocaleInformation_as_IN.properties
> gnu/java/locale/LocaleInformation_om.properties
> gnu/java/locale/LocaleInformation_el_GR.properties
> gnu/java/locale/LocaleInformation_ca.properties
> gnu/java/locale/LocaleInformation_aa_DJ.properties
> gnu/java/locale/LocaleInformation_en_BZ.properties
> gnu/java/locale/LocaleInformation_es_AR.properties
> gnu/java/locale/LocaleInformation_fi_FI.properties
> gnu/java/locale/LocaleInformation_es.properties
> gnu/java/locale/LocaleInformation_sv_FI.properties
> gnu/java/locale/LocaleInformation_hr.properties
> gnu/java/locale/LocaleInformation_nl_NL.properties
> gnu/java/locale/LocaleInformation_te.properties
> gnu/java/locale/LocaleInformation_en_UM.properties
> gnu/java/locale/LocaleInformation_es_CL.properties
> gnu/java/locale/LocaleInformation_en_GU.properties
> gnu/java/locale/LocaleInformation_af_ZA.properties
> gnu/java/locale/LocaleInformation_is.properties
> gnu/java/locale/LocaleInformation_mr.properties
> gnu/java/locale/LocaleInformation_so_DJ.properties
> gnu/java/locale/LocaleInformation_en_BW.properties
> gnu/java/locale/LocaleInformation_es_MX.properties
> gnu/java/locale/LocaleInformation_en_MT.properties
> gnu/java/locale/LocaleInformation_uk_UA.properties
> gnu/java/locale/LocaleInformation_bs.properties
> gnu/java/locale/LocaleInformation_tr_TR.properties
> gnu/java/locale/LocaleInformation_hu.properties
> gnu/java/locale/LocaleInformation_byn.properties
> gnu/java/locale/LocaleInformation_ti.properties
> gnu/java/locale/LocaleInformation_ar_QA.properties
> gnu/java/locale/LocaleInformation_syr.properties
> gnu/java/locale/LocaleInformation_el_CY.properties
> gnu/java/locale/LocaleInformation_sw_KE.properties
> gnu/java/locale/LocaleInformation_en_PH.properties
> gnu/java/locale/LocaleInformation_ar_SA.properties
> gnu/java/locale/LocaleInformation_da.properties
> gnu/java/locale/LocaleInformation_sk_SK.properties
> gnu/java/locale/LocaleInformation_en_ZA.properties
> gnu/java/locale/LocaleInformation_et_EE.properties
> gnu/java/locale/LocaleInformation_aa_ER_SAAHO.properties
> gnu/java/locale/LocaleInformation_kok_IN.properties
> gnu/java/locale/LocaleInformation_pl.properties
> gnu/java/locale/LocaleInformation_pt_PT.properties
> gnu/java/locale/LocaleInformation_es_DO.properties
> gnu/java/locale/LocaleInformation_lv.properties
> gnu/java/locale/LocaleInformation_gu.properties
> gnu/java/locale/LocaleInformation_tig.properties
> gnu/java/locale/LocaleInformation_sv.properties
> gnu/java/locale/LocaleInformation_ga.properties
> gnu/java/locale/LocaleInformation_lo.properties
> gnu/java/locale/LocaleInformation_ar_MA.properties
> gnu/java/locale/LocaleInformation_aa_ET.properties
> gnu/java/locale/LocaleInformation_km_KH.properties
> gnu/java/locale/LocaleInformation_te_IN.properties
> gnu/java/locale/LocaleInformation_es_PE.properties
> gnu/java/locale/LocaleInformation_haw_US.properties
> gnu/java/locale/LocaleInformation_zh_Hant.properties
> gnu/java/locale/LocaleInformation_dv_MV.properties
> gnu/java/locale/LocaleInformation_en_SG.properties
> gnu/java/locale/LocaleInformation_kw.properties
> gnu/java/locale/LocaleInformation_th.properties
> gnu/java/locale/LocaleInformation_ps_AF.properties
> gnu/java/locale/LocaleInformation_mk.properties
> gnu/java/locale/LocaleInformation_kk_KZ.properties
> gnu/java/locale/LocaleInformation_cs_CZ.properties
> gnu/java/locale/LocaleInformation_ru_RU.properties
> gnu/java/locale/LocaleInformation_ro_RO.properties
> gnu/java/locale/LocaleInformation_haw.properties
> gnu/java/locale/LocaleInformation_kk.properties
> gnu/java/locale/LocaleInformation_bn.properties
> gnu/java/locale/LocaleInformation_it.properties
> gnu/java/locale/LocaleInformation_tr.properties
> gnu/java/locale/LocaleInformation_es_CR.properties
> gnu/java/locale/LocaleInformation_ms_MY.properties
> gnu/java/locale/LocaleInformation_sa_IN.properties
> gnu/java/locale/LocaleInformation_sid.properties
> gnu/java/locale/LocaleInformation_kok.properties
> gnu/java/locale/LocaleInformation_ar_SY.properties
> gnu/java/locale/LocaleInformation_pl_PL.properties
> gnu/java/locale/LocaleInformation_de.properties
> gnu/java/locale/LocaleInformation_dz_BT.properties
> gnu/java/locale/LocaleInformation_fi.properties
> gnu/java/locale/LocaleInformation_es_CO.properties
> gnu/java/locale/LocaleInformation_ms_BN.properties
> gnu/java/locale/LocaleInformation_az_Cyrl.properties
> gnu/java/locale/LocaleInformation_om_KE.properties
> gnu/java/locale/LocaleInformation_dz.properties
> gnu/java/locale/LocaleInformation_sq.properties
> gnu/java/locale/LocaleInformation_gl.properties
> gnu/java/locale/LocaleInformation_de_LU.properties
> gnu/java/locale/LocaleInformation_ar_TN.properties
> gnu/java/locale/LocaleInformation_lt.properties
> gnu/java/locale/LocaleInformation_ga_IE.properties
> gnu/java/locale/LocaleInformation_zh_TW_Hant.properties
> gnu/java/locale/LocaleInformation_kl.properties
> gnu/java/locale/LocaleInformation_ar_JO.properties
> gnu/java/locale/LocaleInformation_tt.properties
> gnu/java/locale/LocaleInformation_gez_ER.properties
> gnu/java/locale/LocaleInformation_en_IN.properties
> gnu/java/locale/LocaleInformation_en_IE.properties
> gnu/java/locale/LocaleInformation_sl_SI.properties
> gnu/java/locale/LocaleInformation_hy.properties
> gnu/java/locale/LocaleInformation_ar_DZ.properties
> gnu/java/locale/LocaleInformation_es_UY.properties
> gnu/java/locale/LocaleInformation_fr_LU.properties
> gnu/java/locale/LocaleInformation_or.properties
> gnu/java/locale/LocaleInformation_de_DE.properties
> gnu/java/locale/LocaleInformation_th_TH.properties
> gnu/java/locale/LocaleInformation_ta.properties
> gnu/java/locale/LocaleInformation_bg.properties
> gnu/java/locale/LocaleInformation_ko.properties
> gnu/java/locale/LocaleInformation_zh.properties
> gnu/java/locale/LocaleInformation_es_GT.properties
> gnu/java/locale/LocaleInformation_sr_BA_Latn.properties
> gnu/java/locale/LocaleInformation_uz_AF_Arab.properties
> gnu/java/locale/LocaleInformation_ru_UA.properties
> gnu/java/locale/LocaleInformation_nl.properties
> gnu/java/locale/LocaleInformation_he.properties
> gnu/java/locale/LocaleInformation_es_PR.properties
> gnu/java/locale/LocaleInformation_ti_ET.properties
> gnu/java/locale/LocaleInformation_sl.properties
> gnu/java/locale/LocaleInformation_vi.properties
> gnu/java/locale/LocaleInformation_en_PK.properties
> gnu/java/locale/LocaleInformation_gv_GB.properties
> gnu/java/locale/LocaleInformation_so_SO.properties
> gnu/java/locale/LocaleInformation_pa.properties
> gnu/java/locale/LocaleInformation_or_IN.properties
> gnu/java/locale/LocaleInformation_gez_ET.properties
> gnu/java/locale/LocaleInformation_ta_IN.properties
> gnu/java/locale/LocaleInformation_ca_ES.properties
> gnu/java/locale/LocaleInformation_am.properties
> gnu/java/locale/LocaleInformation_is_IS.properties
> gnu/java/locale/LocaleInformation.properties
> gnu/java/locale/LocaleInformation_en_HK.properties
> gnu/java/locale/LocaleInformation_de_BE.properties
> gnu/java/locale/LocaleInformation_gez.properties
> gnu/java/locale/LocaleInformation_ar_LB.properties
> gnu/java/locale/LocaleInformation_en_NZ.properties
> gnu/java/locale/LocaleInformation_es_HN.properties
> gnu/java/locale/LocaleInformation_hu_HU.properties
> gnu/java/locale/LocaleInformation_zh_HK_Hant.properties
> gnu/java/locale/LocaleInformation_be.properties
> gnu/java/locale/LocaleInformation_en.properties
> gnu/java/locale/LocaleInformation_kw_GB.properties
> gnu/java/locale/LocaleInformation_it_CH.properties
> gnu/java/locale/LocaleInformation_hy_AM_REVISED.properties
> gnu/java/locale/LocaleInformation_aa_ER.properties
> gnu/java/locale/LocaleInformation_es_NI.properties
> gnu/java/locale/LocaleInformation_mr_IN.properties
> gnu/java/locale/LocaleInformation_en_CA.properties
> gnu/java/locale/LocaleInformation_sr_Cyrl.properties
> gnu/java/locale/LocaleInformation_lt_LT.properties
> gnu/java/locale/LocaleInformation_nl_BE.properties
> gnu/java/locale/LocaleInformation_gl_ES.properties
> gnu/java/locale/LocaleInformation_pt_BR.properties
> gnu/java/locale/LocaleInformation_am_ET.properties
> gnu/java/locale/LocaleInformation_so_KE.properties
> gnu/java/locale/LocaleInformation_cy_GB.properties
> gnu/java/locale/LocaleInformation_sv_SE.properties
> gnu/java/locale/LocaleInformation_af.properties
> gnu/java/locale/LocaleInformation_syr_SY.properties
> gnu/java/locale/LocaleInformation_gu_IN.properties
> gnu/java/locale/LocaleInformation_fr.properties
> gnu/java/locale/LocaleInformation_et.properties
> gnu/java/locale/LocaleInformation_ps.properties
> gnu/java/locale/LocaleInformation_hi_IN.properties
> gnu/java/locale/LocaleInformation_fr_CH.properties
> gnu/java/locale/LocaleInformation_cs.properties
> gnu/java/locale/LocaleInformation_id_ID.properties
> gnu/java/locale/LocaleInformation_wal.properties
> gnu/java/locale/LocaleInformation_hi.properties
> gnu/java/locale/LocaleInformation_en_MH.properties
> gnu/java/locale/LocaleInformation_pt.properties
> gnu/java/locale/LocaleInformation_eo.properties
> gnu/java/locale/LocaleInformation_en_MP.properties
> gnu/java/locale/LocaleInformation_en_AS.properties
> gnu/java/locale/LocaleInformation_om_ET.properties
> gnu/java/locale/LocaleInformation_ko_KR.properties
> gnu/java/locale/LocaleInformation_sw.properties
> gnu/java/locale/LocaleInformation_gv.properties
> 
> 
> 
> ticrus00 wrote:
> > I tried replacing your modified zip file with the original, and I
get a:
> > 
> >  Exception occurred while VM initialising.
> > java/lang/NoClassDefFoundError: java/lang/Thread
> > 
> > error.  When I put the modified one back it works just fine.  But I
> > need some things you cut out, Any ideas?
> > 
> > 
> > Justin
> > --- In  Christopher Friedt <cfriedt@> wrote:
> >> Along with the pre-packaged jamvm that I've already posted,
> >>
> >>
> >
http://vaiprime.visibleassets.com/~cfriedt/classpath-0.93_jamvm-1.4.5-20070412.tar.gz
> >> I've also posted the original glibj.zip file as well, just in case 
> >> anyone would like to decide for themselves which classes are
> > stripped out.
> >> You can pick it up here:
> >>
> >> http://vaiprime.visibleassets.com/~cfriedt/glibj_original.zip
> >>
> >> ~/Chris
> >>
> >>
> >> Taj Morton wrote:
> >>> On 4/10/07, Christopher Friedt <cfriedt@> wrote:
> >>>> Does anyone know how to change all of the static paths that are
> > placed
> >>>> into libraries & exutable files during compile?
> >>>>
> >>>> For instance, i would like the --prefix stored in a library or
> >>>> executable to be /usr/local, but when I'm cross-compiling the
> > package, i
> >>>> do not actually want it installed to /usr/local but
> >>>> $PWD/../package-install/usr/local, so that I can easily create a
> > tarball
> >>>> of the installation files.
> >>> You can usually use make install DESTDIR=/path/to/package-install
> >>>
> >>> That will dump all the stuff into
/path/to/package-install/usr/local,
> >>> which you can then tar up.
> >>> For the binaries to actually work, though, you probably need to
> >>> install them into /usr/local.
> >>>
> >>> Alternatively,  if I miss understood your question, and you were
> >>> wondering about how to compile so you can install and run into any
> >>> prefix, check out binreloc from the Autopackage project:
> >>> http://trac.autopackage.org/browser/binreloc/trunk/fdbr.c
> >>>
> >>> Cheers,
> >>> - Taj
> >>>
> >>>
> > 
> > 
> >
>




 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ts-7000/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/ts-7000/join
    (Yahoo! ID required)

<*> To change settings via email:
     
    

<*> To unsubscribe from this group, send an email to:
    

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 

<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU