2008年3月29日 星期六

Flickr

This is a test post from flickr, a fancy photo sharing thing.

2007年4月25日 星期三

Java3d howto on FreeBSD box

I . STEPS
  1. Install JDK and JRE from ports or package
  2. You can fetch the source/package here:
    http://www.FreeBSDFoundation.org/downloads/java.shtml

    cd $PORTS_DIR/java/diablo-jdk15; make install clean
    cd $PORTS_DIR/java/diablo-jre15; make install clean
    or use pkg_add(1)

  3. Install Java3d from ports/packages


  4. cd $PORTS_DIR/java/java3d; make install clean

  5. Set CLASS_PATH and LD_LIBRARY_PATH in your $HOME/.bashrc or $HOME/.cshrc

  6. (in csh/tcsh, you should use setenv instead of export, for example:
    setenv VARIABLE value, ie.: setenv CLASSPATH /usr/local/diablo-jdk15/lib/tools.jar)

    following is example of my .bashrc:

    export JDK_PKG_NAME=diablo-jdk1.5.0

    export JRE_PKG_NAME=diablo-jre1.5.0

    export JAVA_HOME=/usr/local/${JDK_PKG_NAME}/
    export JRE_HOME=/usr/local/${JRE_PKG_NAME}/

    export CLASSPATH=/usr/local/${JDK_PKG_NAME}/lib/tools.jar:\
    /usr/local/share/java/classes/:\
    /usr/local/share/java/java3d/jar/:./

    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:\
    /usr/local/share/java/java3d/lib/:\
    /usr/local/${JDK_PKG_NAME}/jre/lib/i386/xawt


II. Testing
go http://www.java3d.org for testing!

2007年3月22日 星期四

check expat part of config.log in om source


797 | #include <expat.h>
798 configure:19523: result: no
799 configure:19551: checking for expat.h
800 configure:19559: result: no
801 configure:19605: checking for X
802 configure:19840: result: libraries /usr/X11R6/lib, headers /usr/X11R6/include
803 configure:19868: checking for GDAL
804 configure:19877: result: yes
805 configure:19896: checking for OGR in GDAL
806 configure:19903: result: yes
807 configure:19946: looking for expat.h in /usr/local/include
808 configure:19950: checking for /usr/local/include/expat.h
809 configure:19971: c++ -c -O2 -fno-strict-aliasing -pipe -march=pentium-m conftest.cpp >&5
810 In file included from /usr/include/sys/_types.h:33,
811 from /usr/include/stdlib.h:42,
812 from /usr/local/include/expat.h:17,
813 from conftest.cpp:24:
814 /usr/include/machine/_types.h:51: error: expected unqualified-id before string constant
815 /usr/include/machine/_types.h:88: error: `__int8_t' does not name a type
816 configure:19977: $? = 1
817 configure: failed program was:
818 | /* confdefs.h. */
819 | #define PACKAGE_NAME ""
820 | #define PACKAGE_TARNAME ""
821 | #define PACKAGE_VERSION ""
822 | #define PACKAGE_STRING ""
823 | #define PACKAGE_BUGREPORT ""
824 | #define PACKAGE "libopenmodeller"
825 | #define VERSION "0.4.1"
826 | #define STDC_HEADERS 1</expat.h>

2007年3月21日 星期三

om build log

The structure of om port is as below:

Makefile distinfo pkg-descr pkg-plist


When I use #make configure, the log is as following:

===> Extracting for libopenmodeller-0.4.1
=> MD5 Checksum OK for libopenmodeller-0.4.1.tar.gz.
=> SHA256 Checksum OK for libopenmodeller-0.4.1.tar.gz.
===> Patching for libopenmodeller-0.4.1
===> libopenmodeller-0.4.1 depends on executable in : proj - found
===> libopenmodeller-0.4.1 depends on executable in : gdal-config - found
===> libopenmodeller-0.4.1 depends on executable in : gmake - found
===> libopenmodeller-0.4.1 depends on shared library: expat.6 - found
===> Configuring for libopenmodeller-0.4.1
checking for a BSD-compatible install... /usr/bin/install -c -o root -g wheel
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether gmake sets $(MAKE)... yes
checking for i386-portbld-freebsd6.2-g++... c++
checking for C++ compiler default output file name... a.out
checking whether the C++ compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether c++ accepts -g... yes
checking for style of include used by gmake... GNU
checking dependency style of c++... gcc3
checking whether ln -s works... yes
checking whether gmake sets $(MAKE)... (cached) yes
checking for a BSD-compatible install... /usr/bin/install -c -o root -g wheel
checking build system type... i386-portbld-freebsd6.2
checking host system type... i386-portbld-freebsd6.2
checking for i386-portbld-freebsd6.2-gcc... cc
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ANSI C... none needed
checking dependency style of cc... gcc3
checking for a sed that does not truncate output... /usr/local/bin/gsed
checking for egrep... grep -E
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for /usr/bin/ld option to reload object files... -r
checking for BSD-compatible nm... nm
checking how to recognise dependent libraries... pass_all
checking how to run the C preprocessor... cc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking how to run the C++ preprocessor... c++ -E
checking for i386-portbld-freebsd6.2-g77... no
checking for i386-portbld-freebsd6.2-f77... no
checking for i386-portbld-freebsd6.2-xlf... no
checking for i386-portbld-freebsd6.2-frt... no
checking for i386-portbld-freebsd6.2-pgf77... no
checking for i386-portbld-freebsd6.2-fort77... no
checking for i386-portbld-freebsd6.2-fl32... no
checking for i386-portbld-freebsd6.2-af77... no
checking for i386-portbld-freebsd6.2-f90... no
checking for i386-portbld-freebsd6.2-xlf90... no
checking for i386-portbld-freebsd6.2-pgf90... no
checking for i386-portbld-freebsd6.2-epcf90... no
checking for i386-portbld-freebsd6.2-f95... no
checking for i386-portbld-freebsd6.2-fort... no
checking for i386-portbld-freebsd6.2-xlf95... no
checking for i386-portbld-freebsd6.2-ifc... no
checking for i386-portbld-freebsd6.2-efc... no
checking for i386-portbld-freebsd6.2-pgf95... no
checking for i386-portbld-freebsd6.2-lf95... no
checking for i386-portbld-freebsd6.2-gfortran... no
checking for g77... no
checking for f77... f77
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether f77 accepts -g... yes
checking the maximum length of command line arguments... (cached) 262144
checking command to parse nm output from cc object... ok
checking for objdir... .libs
checking for i386-portbld-freebsd6.2-ar... no
checking for ar... ar
checking for i386-portbld-freebsd6.2-ranlib... no
checking for ranlib... ranlib
checking for i386-portbld-freebsd6.2-strip... no
checking for strip... strip
checking if cc static flag works... yes
checking if cc supports -fno-rtti -fno-exceptions... no
checking for cc option to produce PIC... -fPIC
checking if cc PIC flag -fPIC works... yes
checking if cc supports -c -o file.o... yes
checking whether the cc linker (/usr/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking dynamic linker characteristics... freebsd6.2 ld.so
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
configure: creating libtool
appending configuration tag "CXX" to libtool
checking for ld used by c++... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking whether the c++ linker (/usr/bin/ld) supports shared libraries... yes
checking for c++ option to produce PIC... -fPIC
checking if c++ PIC flag -fPIC works... yes
checking if c++ supports -c -o file.o... yes
checking whether the c++ linker (/usr/bin/ld) supports shared libraries... yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking dynamic linker characteristics... freebsd6.2 ld.so
appending configuration tag "F77" to libtool
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for f77 option to produce PIC... -fPIC
checking if f77 PIC flag -fPIC works... yes
checking if f77 supports -c -o file.o... yes
checking whether the f77 linker (/usr/bin/ld) supports shared libraries... yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking dynamic linker characteristics... freebsd6.2 ld.so
checking float.h usability... yes
checking float.h presence... yes
checking for float.h... yes
checking values.h usability... no
checking values.h presence... no
checking for values.h... no
checking jni.h usability... no
checking jni.h presence... no
checking for jni.h... no
checking for X... libraries /usr/X11R6/lib, headers /usr/X11R6/include
checking for GDAL... yes
checking for OGR in GDAL... yes
configure: looking for expat.h in /usr/local/include
checking expat.h usability... no
checking expat.h presence... no
checking for expat.h... no
configure: looking for expat.h in /usr/local/include/expat
checking for expat.h... (cached) no
configure: looking for expat.h in /usr/include
checking for expat.h... (cached) no
configure: looking for expat.h in /usr/include/expat
checking for expat.h... (cached) no
configure: looking for expat.h in /usr/local/include
checking for expat.h... (cached) no
configure: looking for expat.h in /usr/local/include/expat
checking for expat.h... (cached) no
checking whether linking with expat-1 works... checking whether linking with expat works... checking for Proj4 library in /us
r/local... "/usr/local exists"
checking proj_api.h usability... yes
checking proj_api.h presence... yes
checking for proj_api.h... yes
checking for pj_is_latlong in -lproj... no
===> Script "configure" failed unexpectedly.

port openmodeller to freebsd log(1)


# New ports collection makefile for: openmodeller
# Date created: Sat Mar 17 19:02:13 CST 2007
# Whom: Lin, Cheng-Tao <b89605222@ntu.edu.tw>
#
# $FreeBSD$
#

PORTNAME= libopenmodeller
PORTVERSION= 0.4.1
CATEGORIES= biology
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}

MAINTAINER= b89605222@ntu.edu.tw
COMMENT= openModeller is a fundamental niche modelling library

GNU_CONFIGURE= yes
USE_GMAKE= yes
CONFIGURE_ARGS+= --with-expat=/usr/local \
--with-proj=${PREFIX} \
--with-projlib=${PREFIX}

BUILD_DEPENDS= proj:${PORTSDIR}/graphics/proj \
gdal-config:${PORTSDIR}/graphics/gdal

LIB_DEPENDS= expat.6:${PORTSDIR}/textproc/expat2


.if defined(WITH_PYTHON)
RUN_DEPENDS+= python:${PORTSDIR}/lang/python
.endif

.if defined(WITH_GSL)
RUN_DEPENDS+= gsl>=1.4:${PORTSDIR}/math/gsl
.endif

.if defined(WITH_SWIG)
RUN_DEPENDS+= swig:${PORTSDIR}/devel/swig13
.endif

.if defined(WITH_JAVA)
RUN_DEPENDS+= java:${PORTSDIR}/java/javavmwrapper
USE_JAVA= yes
JAVA_VERSION= 1.4+
.endif

.if defined(WITH_SQLITE3)
RUN_DEPENDS+= sqlite3.8:${PORTSDIR}/databases/sqlite3
.endif

.if defined(WITH_X)
RUN_DEPENDS+= X
.endif

.include <bsd.port.mk>

2006年12月25日 星期一

call me test

this is only the test!