Linker problem compiling static binary

Hi,
I am trying to produce a statically linked binary of an app. I have written, but I get the following error message when I use -static in CFLAGS:
/usr/bin/ld: cannot find -lgtk-x11-2.0
collect2: ld returned 1 exit status
make: *** [xnec2c] Error 1
The library seems to be there:
5b4az src # locate gtk-x11-2.0
/usr/lib/libgtk-x11-2.0.so.0
/usr/lib/libgtk-x11-2.0.so
/usr/lib/libgtk-x11-2.0.so.0.800.6
This is using arch 0.7. I installed arch 0.7.1 on my second hard disk but have the same problem. The app. compiles and runs if -static is not used in CFLAGS.
My thanks in advance for any hints!

phrakture wrote:Umm in order to statically linked, you need a static library - not a "so" which stands for "shared object" - you're looking for libgtk-x11-2.0.a
Thanks! How did I ever manage to write Linux software  :oops:
I will see what I can do to fix this...

Similar Messages

  • Linker problem compiling OCI8 on PHP 5.2.5

    System:
    Red Hat Enterprise Linux Server release 5.1 (Tikanga)
    GNU ld version 2.17.50.0.6-5.el5 20061020
    gcc version 4.1.2 20070626 (Red Hat 4.1.2-14)
    Problem:
    I've downloaded and extracted the basic and sdk into:
    /opt/oracle/instantclient_11_1
    Configure works fine:
    ./configure build=i686-redhat-linux-gnu host=i686-redhat-linux-gnu target=i386-redhat-linux-gnu program-prefix= prefix=/usr exec-prefix=/usr bindir=/usr/bin sbindir=/usr/sbin sysconfdir=/etc datadir=/usr/share includedir=/usr/include libdir=/usr/lib libexecdir=/usr/libexec localstatedir=/var sharedstatedir=/usr/com mandir=/usr/share/man infodir=/usr/share/info cache-file=../config.cache with-libdir=lib with-config-file-path=/etc with-config-file-scan-dir=/etc/php.d disable-debug with-pic disable-rpath without-pear with-bz2 with-curl with-exec-dir=/usr/bin with-freetype-dir=/usr with-png-dir=/usr enable-gd-native-ttf without-gdbm with-gettext with-gmp with-iconv with-jpeg-dir=/usr with-openssl with-png with-pspell with-expat-dir=/usr with-pcre-regex=/usr with-zlib with-layout=GNU enable-exif enable-ftp enable-magic-quotes enable-sockets enable-sysvsem enable-sysvshm enable-sysvmsg enable-track-vars enable-trans-sid enable-yp enable-wddx with-kerberos enable-ucd-snmp-hack with-unixODBC=shared,/usr enable-memory-limit enable-shmop enable-calendar enable-dbx enable-dio with-mime-magic=/etc/httpd/conf/magic without-sqlite with-libxml-dir=/usr with-xml with-apxs2=/usr/sbin/apxs with-mysql=/usr/lib/mysql without-gd without-odbc disable-dom disable-dba without-unixODBC disable-pdo disable-xmlreader disable-xmlwriter --with-oci8=instantclient,/opt/oracle/instantclient_11_1
    Bellow is the error that comes up when i try to compile:
    # make
    /bin/sh /root/sources/php-5.2.5/libtool silent preserve-dup-deps --mode=link gcc -export-dynamic -I/usr/include -g -O2  -L/usr/kerberos/lib -L/usr/lib/mysql -L/opt/oracle/instantclient_11_1   ext/libxml/libxml.lo ext/openssl/openssl.lo ext/openssl/xp_ssl.lo ext/pcre/php_pcre.lo ext/zlib/zlib.lo ext/zlib/zlib_fopen_wrapper.lo ext/zlib/zlib_filter.lo ext/bz2/bz2.lo ext/bz2/bz2_filter.lo ext/calendar/calendar.lo ext/calendar/dow.lo ext/calendar/french.lo ext/calendar/gregor.lo ext/calendar/jewish.lo ext/calendar/julian.lo ext/calendar/easter.lo ext/calendar/cal_unix.lo ext/ctype/ctype.lo ext/curl/interface.lo ext/curl/multi.lo ext/curl/streams.lo ext/date/php_date.lo ext/date/lib/astro.lo ext/date/lib/dow.lo ext/date/lib/parse_date.lo ext/date/lib/parse_tz.lo ext/date/lib/timelib.lo ext/date/lib/tm2unixtime.lo ext/date/lib/unixtime2tm.lo ext/exif/exif.lo ext/filter/filter.lo ext/filter/sanitizing_filters.lo ext/filter/logical_filters.lo ext/filter/callback_filter.lo ext/ftp/php_ftp.lo ext/ftp/ftp.lo ext/gettext/gettext.lo ext/gmp/gmp.lo ext/hash/hash.lo ext/hash/hash_md.lo ext/hash/hash_sha.lo ext/hash/hash_ripemd.lo ext/hash/hash_haval.lo ext/hash/hash_tiger.lo ext/hash/hash_gost.lo ext/hash/hash_snefru.lo ext/hash/hash_whirlpool.lo ext/hash/hash_adler32.lo ext/hash/hash_crc32.lo ext/iconv/iconv.lo ext/json/json.lo ext/json/utf8_to_utf16.lo ext/json/utf8_decode.lo ext/json/JSON_parser.lo ext/mime_magic/mime_magic.lo ext/mysql/php_mysql.lo ext/oci8/oci8.lo ext/oci8/oci8_lob.lo ext/oci8/oci8_statement.lo ext/oci8/oci8_collection.lo ext/oci8/oci8_interface.lo ext/posix/posix.lo ext/pspell/pspell.lo ext/reflection/php_reflection.lo ext/session/session.lo ext/session/mod_files.lo ext/session/mod_mm.lo ext/session/mod_user.lo ext/shmop/shmop.lo ext/simplexml/simplexml.lo ext/sockets/sockets.lo ext/spl/php_spl.lo ext/spl/spl_functions.lo ext/spl/spl_engine.lo ext/spl/spl_iterators.lo ext/spl/spl_array.lo ext/spl/spl_directory.lo ext/spl/spl_sxe.lo ext/spl/spl_exceptions.lo ext/spl/spl_observer.lo regex/regcomp.lo regex/regexec.lo regex/regerror.lo regex/regfree.lo ext/standard/array.lo ext/standard/base64.lo ext/standard/basic_functions.lo ext/standard/browscap.lo ext/standard/crc32.lo ext/standard/crypt.lo ext/standard/cyr_convert.lo ext/standard/datetime.lo ext/standard/dir.lo ext/standard/dl.lo ext/standard/dns.lo ext/standard/exec.lo ext/standard/file.lo ext/standard/filestat.lo ext/standard/flock_compat.lo ext/standard/formatted_print.lo ext/standard/fsock.lo ext/standard/head.lo ext/standard/html.lo ext/standard/image.lo ext/standard/info.lo ext/standard/iptc.lo ext/standard/lcg.lo ext/standard/link.lo ext/standard/mail.lo ext/standard/math.lo ext/standard/md5.lo ext/standard/metaphone.lo ext/standard/microtime.lo ext/standard/pack.lo ext/standard/pageinfo.lo ext/standard/quot_print.lo ext/standard/rand.lo ext/standard/reg.lo ext/standard/soundex.lo ext/standard/string.lo ext/standard/scanf.lo ext/standard/syslog.lo ext/standard/type.lo ext/standard/uniqid.lo ext/standard/url.lo ext/standard/url_scanner.lo ext/standard/var.lo ext/standard/versioning.lo ext/standard/assert.lo ext/standard/strnatcmp.lo ext/standard/levenshtein.lo ext/standard/incomplete_class.lo ext/standard/url_scanner_ex.lo ext/standard/ftp_fopen_wrapper.lo ext/standard/http_fopen_wrapper.lo ext/standard/php_fopen_wrapper.lo ext/standard/credits.lo ext/standard/css.lo ext/standard/var_unserializer.lo ext/standard/ftok.lo ext/standard/sha1.lo ext/standard/user_filters.lo ext/standard/uuencode.lo ext/standard/filters.lo ext/standard/proc_open.lo ext/standard/streamsfuncs.lo ext/standard/http.lo ext/sysvmsg/sysvmsg.lo ext/sysvsem/sysvsem.lo ext/sysvshm/sysvshm.lo ext/tokenizer/tokenizer.lo ext/tokenizer/tokenizer_data.lo ext/wddx/wddx.lo ext/xml/xml.lo ext/xml/compat.lo TSRM/TSRM.lo TSRM/tsrm_strtok_r.lo TSRM/tsrm_virtual_cwd.lo main/main.lo main/snprintf.lo main/spprintf.lo main/php_sprintf.lo main/safe_mode.lo main/fopen_wrappers.lo main/alloca.lo main/php_scandir.lo main/php_ini.lo main/SAPI.lo main/rfc1867.lo main/php_content_types.lo main/strlcpy.lo main/strlcat.lo main/mergesort.lo main/reentrancy.lo main/php_variables.lo main/php_ticks.lo main/network.lo main/php_open_temporary_file.lo main/php_logos.lo main/output.lo main/streams/streams.lo main/streams/cast.lo main/streams/memory.lo main/streams/filter.lo main/streams/plain_wrapper.lo main/streams/userspace.lo main/streams/transports.lo main/streams/xp_socket.lo main/streams/mmap.lo Zend/zend_language_parser.lo Zend/zend_language_scanner.lo Zend/zend_ini_parser.lo Zend/zend_ini_scanner.lo Zend/zend_alloc.lo Zend/zend_compile.lo Zend/zend_constants.lo Zend/zend_dynamic_array.lo Zend/zend_execute_API.lo Zend/zend_highlight.lo Zend/zend_llist.lo Zend/zend_opcode.lo Zend/zend_operators.lo Zend/zend_ptr_stack.lo Zend/zend_stack.lo Zend/zend_variables.lo Zend/zend.lo Zend/zend_API.lo Zend/zend_extensions.lo Zend/zend_hash.lo Zend/zend_list.lo Zend/zend_indent.lo Zend/zend_builtin_functions.lo Zend/zend_sprintf.lo Zend/zend_ini.lo Zend/zend_qsort.lo Zend/zend_multibyte.lo Zend/zend_ts_hash.lo Zend/zend_stream.lo Zend/zend_iterators.lo Zend/zend_interfaces.lo Zend/zend_exceptions.lo Zend/zend_strtod.lo Zend/zend_objects.lo Zend/zend_object_handlers.lo Zend/zend_objects_API.lo Zend/zend_default_classes.lo Zend/zend_execute.lo sapi/cli/php_cli.lo sapi/cli/php_cli_readline.lo sapi/cli/getopt.lo main/internal_functions_cli.lo -laspell -lpspell -lmysqlclient -lgmp -lcurl -lbz2 -lz -lpcre -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lssl -lcrypto -ldl -lz -lcurl -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lresolv -ldl -lidn -lssl -lcrypto -lz -lssl -lcrypto -ldl -lz -lclntsh -lxml2 -lz -lm -lxml2 -lz -lm -lxml2 -lz -lm  -o sapi/cli/php
    /usr/bin/ld: warning: libnnz11.so, needed by /opt/oracle/instantclient_11_1/libclntsh.so, not found (try using -rpath or -rpath-link)
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_ModifyCipherSuites'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosCipherSpecToStr'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Initialize'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosgpc_GetProtocolVer'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztwOpenWallet'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `A_X931RandomInit'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_SetSqlnetFunc'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosGetSupportedCipher'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_ServiceWriteQueue'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_DisableClientAuthentication'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztiGetSecInfo'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Write'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzduui2_destroy_ui'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztGetSubjectName'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzgbllsm_location_shared_memory'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_setThrUse'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzteMyCert'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzteDestroyPersona'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_RetrievePersonaCopy'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosSCCS_SetCRLCacheSize'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztnGCL_Get_Certificate_List'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzumfree'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_setCRLFile'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `A_X931RandomContextDestroy'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_OToolkitContext'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_setOIDConnInfo'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosaccrb_aysnCheckRecbuf'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzhdcgldn_getldapdn'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_SetFuncvec'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzustralloc'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzstrfc_free_content'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Read'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Destroy_Ctx'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzssGEBV_GetEntryByValue'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `snzdafn_assemble_filename'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Configure'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosSetCredential'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzdst_terminate'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosSetCipherSuite'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzumalloc'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztiGCC_Get_CertCtx'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztiFIL_Free_Identity_List'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Handshake'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztwRetrievePersonaCopy'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosGetPeerCredential'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzdcgui_get_userinfo'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Deinitialize'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `A_X931RandomGenerateBytes'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzuexid_initdl'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_setCRLPath'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztwCloseWallet'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzteOpenPersona'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_OpenWallet'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Close'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzstr_alloc'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_enableHWAcc'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzssGSL_GetSecretLength'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosgnc_GetNegotiatedCipher'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_setCertValProtocol'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzssGS_GetSecret'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Create_Ctx'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztiee_IsEncrEnabled'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `A_X931RandomUpdate'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzdsi_initialize'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzosDestroyCredential'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_setCertValPolicy'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_CompareDN'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztSetAppDefaultLocation'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzos_Get_Ctx'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzdcfcx_free_cert_ctx'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nzduui6_get_name'
    /opt/oracle/instantclient_11_1/libclntsh.so: undefined reference to `nztSearchNZDefault'
    collect2: ld returned 1 exit status
    make: *** [sapi/cli/php] Error 1
    I see that library in there, it is there, but something is not linking right!
    Message was edited by:
    user619189
    Message was edited by:
    user619189

    /app/devtools/gcc-4.2.3-64/bin/g++ -L/home/john/sdc/lib/Linux_2.6.5-7.308.PTF.352368.0-smp.gcc-4.2.3-64 -L/home/john/oracle/lib -L/app/gcc-3.3.4/lib -L/app/gcc-3.2.3/lib -ldl -lpthread -lnsl -lrt -lstdc++ -lvs -lclntsh -L/home/cdev/pkgs/oas/Linux64/oaslinux64_2_4_05_03/lib -loas Linux_2.6.5-7.308.PTF.352368.0-smp.gcc-4.2.3-64-R/db.o Linux_2.6.5-7.308.PTF.352368.0-smp.gcc-4.2.3-64-R/owl.o Linux_2.6.5-7.308.PTF.352368.0-smp.gcc-4.2.3-64-R/queue.o Linux_2.6.5-7.308.PTF.352368.0-smp.gcc-4.2.3-64-R/log.o Linux_2.6.5-7.308.PTF.352368.0-smp.gcc-4.2.3-64-R/titan.o -o /home/amehta17/sdc/bin/Linux_2.6.5-7.308.PTF.352368.0-smp.gcc-4.2.3-64/titan
    /usr/bin/ld: warning: libnnz10.so, needed by /home/john/oracle/lib/libclntsh.so, not found (try using -rpath or -rpath-link)
    /home/amehta17/oracle/lib/libclntsh.so: undefined reference to `nzos_ServiceWriteQueue'
    /home/amehta17/oracle/lib/libclntsh.so: undefined reference to `nzosCipherSpecToStr'
    /home/amehta17/oracle/lib/libclntsh.so: undefined reference to `nzos_setCRLPath'
    /home/amehta17/oracle/lib/libclntsh.so: undefined reference to `nzteOpenPersona'
    /home/amehta17/oracle/lib/libclntsh.so: undefined reference to `nzdsi_initialize'
    All these symbols are not defined in libclntsh.so and also does not exist in libnnz10.so.
    I checked 32bit version of libnnz10.so has all above undefined symbols. This looks really weird to me why 64 bit version of libnnz10.so doesn't define these symbols.
    Let me know if you have any idea.

  • Linking problems compiling Lua shared library (nixio)

    I am trying to create a PKGBUILD for nixio (see http://dev.luci.freifunk-halle.net/nixio/doc/). I am using this PKGBUILD:
    pkgname=nixio
    pkgver=0.3
    pkgrel=1
    pkgdesc="System, networking and I/O library for Lua"
    arch=('i686' 'x86_64')
    url="http://luci.subsignal.org/"
    license=('APACHE')
    depends=('lua>=5.1' 'openssl')
    makedepends=()
    optdepends=()
    provides=()
    options=('docs')
    source=(http://dev.luci.freifunk-halle.net/nixio/nixio-0.3.tar.bz2)
    md5sums=('7fa6a989cd2644347d969cb6e3a5c186')
    build() {
    cd "$srcdir/$pkgname-$pkgver"
    make LUA_MODULEDIR=/usr/share/lua/5.1 LUA_LIBRARYDIR=/usr/lib/lua/5.1
    package() {
    cd "$srcdir/$pkgname-$pkgver"
    cp -R dist/* $pkgdir
    (The package contents are rather irregular.) When building, it produces this output:
    ==> Starting build()...
    mkdir -p dist/usr/share/lua/5.1
    cp -pR lua/* dist/usr/share/lua/5.1 2>/dev/null || true
    for i in $(find dist -name .svn); do rm -rf $i || true; done
    gcc -O2 --std=gnu99 -Wall -Werror -pedantic -fPIC -c -o src/nixio.o src/nixio.c
    gcc -O2 --std=gnu99 -Wall -Werror -pedantic -fPIC -c -o src/socket.o src/socket.c
    gcc -O2 --std=gnu99 -Wall -Werror -pedantic -fPIC -c -o src/sockopt.o src/sockopt.c
    # 15 more pretty much identical object code files...
    gcc -Wl,--hash-style=gnu -Wl,--as-needed -shared -lcrypt -lssl -o src/nixio.so src/nixio.o src/socket.o src/sockopt.o src/bind.o src/address.o src/poll.o src/io.o src/file.o src/splice.o src/process.o src/syslog.o src/bit.o src/binary.o src/fs.o src/user.o src/tls-crypto.o src/tls-context.o src/tls-socket.o
    mkdir -p dist/usr/lib/lua/5.1
    cp src/nixio.so dist/usr/lib/lua/5.1/nixio.so
    The package seems to build fine, although namcap produces these warnings:
    nixio W: Dependency included and not needed ('lua')
    nixio W: Dependency included and not needed ('openssl')
    But when I install it and launch Lua:
    Lua 5.1.4 Copyright (C) 1994-2008 Lua.org, PUC-Rio
    > require 'nixio'
    error loading module 'nixio' from file '/usr/lib/lua/5.1/nixio.so':
    /usr/lib/lua/5.1/nixio.so: undefined symbol: MD5_Init
    stack traceback:
    [C]: ?
    [C]: in function 'require'
    stdin:1: in main chunk
    [C]: ?
    Doing some research, I found that MD5_Init is part of the OpenSSL library (which nixio uses for its cryptographic functions), and that "undefined symbol" errors are indicative of a program compiling and linking properly, but not being able to load a shared library at runtime. However, OpenSSL is installed properly and libssl.so is in my /usr/lib.
    What should I do to fix this error? It builds properly when installed using LuaRocks. I tried adding various flags from the rockspec (run "luarocks download nixio" and "luarocks unpack nixio-0.3-1.src.rock" to look at it) but still can't get it to work.

    You probably did not install the required C++ shared library patches on the system where you are running the compiler. On Solaris 9 for SPARC, Studio 11 requires patches 111711-12 and 111712-12. Studio 11 also requires other patches, which are in the installation image.
    You can find out what shared library version you have by running these commands:
    version /usr/lib/libCstd.so.1
    version /usr/lib/sparcv9/libCstd.so.1
    If the patch versions are not -12 or later, run the Studio 11 installer again, and this time have it install the Solaris patches (but nothing else).

  • Compile rtorrent as a static binary

    I'd like to run rtorrent as a static binary and im having an issue.
    I figured out i needed the '.a' file from libtorrent - so i got that from ABS, changed one of the lines in build to
    ./configure --prefix=/usr --disable-debug --enable-static --disable-shared || return 1
    That gives me my happy .a file in /usr/lib
    So i do a recompile of rtorrent, with its build() now being:
    build() {
    cd "$srcdir/$pkgname-$pkgver"
    patch -Np1 -i "$srcdir/gcc43.patch" || return 1
    patch -Np1 -i "$srcdir/gcc44.patch" || return 1
    CXXFLAGS="$CXXFLAGS -fno-strict-aliasing" \
    ./configure LDFLAGS=-static --enable-static --disable-shared --prefix=/usr --disable-debug --with-xmlrpc-c || return 1
    make LDFLAGS="-static" || return 1
    make DESTDIR="$pkgdir" install
    That added the libtorrent.a file into it, but when i try to run in on the other computer it says
    ./rtorrent: error while loading shared libraries: libsigc-2.0.so.0: cannot open shared object file: No such file or directory
    So, figuring im gonna need to be recompiling some more libs so that theres the .a files there, i go to the ABS, grab the PKGBUILD, change the ./configure line to include the same options i did with libtorrent, recompile and install. Then i go back to rtorrent, recompile... but its the same file. Didn't grow in size like it did when i remade the libtorrent library. And gives me the same error when i try to run it on the other computer. So - im missing something. Any ideas? Words of wisdom?

    Rob,
    Linking to MFC as a static library is not supported in the current version
    of MeasurementStudio.
    The NI MeasurementStudio AppWizard is built on top of the MFC AppWizard.
    The MFC AppWizard is not fully customizable, so we were not able to disable
    this choice.
    In the next version of MeasurementStudio, we are considering adding support
    for linking to MFC statically. Is this capability important to you?
    David Rohacek
    National Instruments
    "Rob Bryers" wrote:
    >>I have compiled and run the "Plot Styles" example project using "Use MFC
    in>a Shared DLL". However, after changing the project settings to "Use MFC
    in>a Static Library" I get numerous linking errors. This option is avilable>in
    the NI Appwizard so I would expect there to be
    no problems. Can anyone>enlighten
    me?

  • Compiling a program with i486-mingw32-g++ with a static binary[SOLVED]

    Hi,
    I need to compile a program for win with whatever open cross compiler, I tried mingw32-g++, with the following command>
    i486-mingw32-g++ main.cpp main.h `/usr/i486-mingw32/bin/wx-config --libs` `/usr/i486-mingw32/bin/wx-config --cxxflags` -o test.exe
    but now my program depends on the dll lib mingwm10.dll which kind a sucks cause my goal is to have one executable file.
    Is there any other compiler or a command switch to make a static binary ?
    Last edited by gnu_D (2009-08-10 11:07:59)

    Ok, I did searched that, and I come up with this.
    Which means I need to remove the -mthread option, there is only one problem, if I compile like this>
    i486-mingw32-g++ `/usr/i486-mingw32/bin/wx-config --libs` `/usr/i486-mingw32/bin/wx-config --cxxflags` -o test.exe
    then I have to expand the command like this>
    i486-mingw32-g++ main.cpp main.h -Wl,--subsystem,windows -mwindows /usr/i486-mingw32/lib/libwx_mswu_richtext-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_mswu_aui-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_mswu_xrc-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_mswu_qa-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_mswu_html-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_mswu_adv-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_mswu_core-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_baseu_xml-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_baseu_net-2.8-i486-mingw32.a /usr/i486-mingw32/lib/libwx_baseu-2.8-i486-mingw32.a -lwxregexu-2.8-i486-mingw32 -lwxexpat-2.8-i486-mingw32 -lwxtiff-2.8-i486-mingw32 -lwxjpeg-2.8-i486-mingw32 -lwxpng-2.8-i486-mingw32 -lwxzlib-2.8-i486-mingw32 -lrpcrt4 -loleaut32 -lole32 -luuid -lwinspool -lwinmm -lshell32 -lcomctl32 -lcomdlg32 -lctl3d32 -ladvapi32 -lwsock32 -lgdi32 -I/usr/i486-mingw32/lib/wx/include/i486-mingw32-msw-unicode-release-static-2.8 -I/usr/i486-mingw32/include/wx-2.8 -D__WXMSW__-fno-rtti -o
    If someone can scrap me a Makefile which will do that will be lovely.

  • OCCI Link problem (Error LNK2019: unresolved external symbol) in VS2012

    Hi,
    I'm having a hard time with this. I'm trying to implement OCCI within my application. Error I'm getting is:
    Error     1     error LNK2019: unresolved external symbol "public: static class oracle::occi::Environment * __cdecl oracle::occi::Environment::createEnvironment(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,enum oracle::occi::Environment::Mode,void *,void * (__cdecl*)(void *,unsigned int),void * (__cdecl*)(void *,void *,unsigned int),void (__cdecl*)(void *,void *))" (?createEnvironment@Environment@occi@oracle@@SAPAV123@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0W4Mode@123@PAXP6APAX2I@ZP6APAX22I@ZP6AX22@Z@Z) referenced in function "private: bool __thiscall ServerDataLoader::getPreSuffixesFromDB(void)" (?getPreSuffixesFromDB@ServerDataLoader@@AAE_NXZ)     P:\code\VizTool\VizPortal\DwgDgnConverter\ServerDataLoader.obj     DwgDgnConverter
    Error     2     error LNK1120: 1 unresolved externals     P:\code\VizTool\VizPortal\Debug\DwgDgnConverter.exe     1     1     DwgDgnConverter
    Yes, it looks like linking problem,...but for me everything seems set-up.
    - Included header files (from instantclient-sdk-windows.x64-11.2.0.3.0.zip)
    - Included library path from OCCI download (11.2.0.3.0)
    - Added oraocci11d.lib in linker
    Please, what am I doing wrong?
    Millions of thanks for any kind of feedback ;-)

    Have you succeeded? I tried vs2012 and it passed compilation, but gave the run-time error of _crtisvalidheappointer. But the same code runs well with vs2010. I think Oracle needs to publish the new patch for vs2012                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Problems compiling C in XCODE using VISA / NI

    Hi,
    I'm developing a program in C to communicate with my Tektronix oscilloscope. I inherited this project from a friend (who is currently incommunicado), so I can't talk to him about it.
    Basically, my problem is that my program will not build due to a linker problem. I am using functions from the NI-VISA 5.4 package for OS X 10.8. However, the linker cannot seem to find the correct functions for my system:
    Undefined symbols for architecture x86_64:
      "_viClose", referenced from:
          _setupVI in oscilloscope.o
          _getData in oscilloscope.o
          _closeInstr in oscilloscope.o
      "_viOpen", referenced from:
          _setupVI in oscilloscope.o
      "_viOpenDefaultRM", referenced from:
          _setupVI in oscilloscope.o
      "_viRead", referenced from:
          _setupVI in oscilloscope.o
          _getData in oscilloscope.o
      "_viStatusDesc", referenced from:
          _setupVI in oscilloscope.o
          _getData in oscilloscope.o
      "_viWrite", referenced from:
          _setupVI in oscilloscope.o
          _getData in oscilloscope.o
    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    These are all pretty basic VISA functions. I struggled in just including the correct header file, as
    #include <visa.h>
    didn't work. When I went to the verbose form, it worked:
    #include "/Library/Frameworks/VISA.framework/Versions/A/Headers/visa.h"
    However, then the problem started happening that I'm having now -- the object linker can't find the code for the VISA functions. I've tried changing build architctures from x86_64 to just x86, without avail. I'm currently building in i386 x86. I've also tried (under Build Phases -> Link Binary with Libraries) to link the VISA.framework to the project, but this simply gives the linker error "cannot find VISA".
    I feel like I am missing something very obvious. I'm still operating under the notion that either NI-VISA did not install to the correct location, or that my build settings are incorrect.
    Does anyone have any insight to lend? I've been searching through different forums for help for almost 2 days now, with no avail.

    atucker-hs wrote:
    That is a good point that I hadn't thought of--I didn't run any install operations before installing 5.4. I'll try uninstalling all of 5.4 (there's not an uninstaller; just a text file of files to delete) and then doing a clean install after a restart. I'll let you know how it goes.
    As far as their included examples, I tried to compile them both when I had 5.3 and 5.4 installed. I used gcc from the command line, and there were tons of errors - far more than I have in my XCODE project.
    Did you try the Instruments/NI-VISA/Examples/C/ExamplesProject.pbproj?

  • "Link Problem" in Incident Form does not seem to work right? How do I do it correctly?

    1. The Link Problem tool in the task pane on our Incidents, do not seem to actually link the Incident to the Problem.
    2. I can link the two by going to the Problem and adding it on the related items tab, but this is very time consuming in a call center environment, especially during an outage where we are relying a lot more on Problem and root cause analysis.
    3. I have tried creating the incident and applying, then doing the Link Problem tool and selecting the problem, then applying again and selecting OK to close the incident. Again it doesn't work for me.
    What am I doing wrong, number one?
    Can we do this without manually opening the problem for every incident and attaching from there?
    3. Can I build an incident template that will automate the Attachment to the problem at creation? (Tried this today to and it wouldn't work, but then again, the Link Problem might again be the culprit) This would be great for real time  saving during
    an outage. Once outage is found, I could create the template with all the necessary items filled out, and would like to have it automatically attach to the specific problem I choose at template creation, and that way analysts can simply apply template, and
    click OK when they get a call related to the outage.

    Thanks  for the response Thomas!
    The functionality seems to work just fine. I use the LINK PROBLEM and it pops up the problem search box, I search for and select a Problem, I then select it and click ok, and I get no error saying the relationship was not created.
    The problem is, when I open the problem after that, there is never any relationship showing in related items there, as it says there should be.
    Also, to point out, I am talking about newly created Incidents. I tried even using APPLY prior to doing the LINK PROBLEM but it still did not work. I suspect it may be a workflow problem, where the workflow to create the incident has not completed, there
    for the relationship is not completed.... and I get no error.
    In my work environment, we have analysts during outages taking a call every 30 seconds, and I need a more efficient way for this system to work. As of now, they spend 1-2 minutes doing the ticket, and that is too long.
    I have decided to try a newb way, where I created an Incident (GENERIC OUTAGE) that folks can use, and every 15-30 minutes during an outage, I can open the problem and search for open incidents with that title, and attach all that I find from the problem
    side. This is assuming that once attached they will not show up in the search to attach the next time lol. Also this assumes that if attached from the problem, they will auto resolve when the problem is resolved.
    I am rusty on my programming, and am currently trying to get refreshed. I am sure that would come in handy for this :)
    Oh and lastly, one additional tidbit that will make this clearer, with regard to work flow, we re also running our Service Manager in our help desk, virtualized, as they have not upgraded to Win 7 yet :(. So that compiles my time to add ticket issue :(.

  • Re: Fwd: Link Problems With Borland C++ 4.52

    I have seen this problem before in another context, and I'll offer the
    cause and solution in the hope that they will apply to the Crystal problem.
    Many Windows based applications rely on PASCAL calling conventions, which
    change the way parameters are handled in function/method calls. They
    indicate this by placing one of the following immediately before the
    function name in the prototype declarations:
    - pascal_far (or something like that)
    - WINAPI
    - some other typedef of either of the above
    For example:
    int WINAPI AddTotal(int valueA, int valueB);
    Unfortunately, v2.0 of Forte does not provide any mechanisms for changing
    the calling conventions of the prototypes in the generated C++ wrapper
    library, so when you compile that code, the linker fails. I think that the
    compiler may generate different symbols depending on calling conventions,
    so that's why it fails.
    To fix this, don't autocompile your code, but generate the distribution, go
    into the generated C++ files and look for the function prototypes (I think
    you can search for FORTE_NO_PROTOTYPES), add WINAPI to the appropriate
    places in the prototype definitions (see above) and use fcompile to build
    the library. Instructions for fcompile are in the Interfacing With
    External Systems manual.
    Hope this helps,
    James
    At 11:05 AM 5/29/97 PDT, you wrote:
    >
    We are trying to wrapper Crystal Reports from Forte. I know that there
    are a number of other people in this same boat, as I've seen messages
    posted here at various points during the past few weeks. We are having
    a particular problem with getting the compile to go through, which we
    have sent in to Forte Tech Support. I'm forwarding the message I sent
    Tech Support to this group in the hopes that someone here may have
    already seen and resolved a similar problem.
    Thanks in advance for any help you can offer!
    Dale V. Georg
    Indus Consultancy Services [email protected]
    Mack Trucks, Inc. [email protected]
    >
    Date: Wed, 28 May 97 13:47:20 PDT
    From: dg7077a
    To: Forte Technical Support
    Cc: Gardner, Steve
    Subject: Link Problems With Borland C++ 4.52
    Name of requestor: [Dale V. Georg / Alaiah Chandrashekar]
    Company: [Indus Consultancy Services]
    Phone for callback: [(610) 709-3956]
    Customer Site: [Mack Trucks, Inc.]
    Product: [Forte]
    Version of Forte: [2.0.H.1]
    Server OS: [SunOS 5.5.1]
    Client OS: [Windows 3.1]
    DBMS: [Oracle 7.2.3]
    Reproducible?: [Yes]
    Brief description: [Link Problems With Borland C++ 4.52]
    Complete description of problem or question:
    We are attempting to write a C-wrapper interface from Forte to Crystal
    Reports' Report Engine. We are using Borland C++ version 4.52.
    Unfortunately, we have been unable to get a clean compile after a day
    and half of effort. We get as far as the link stage of the
    compilation, and
    the compiler aborts with an "Unknown symbol" error message for each
    of the functions we are trying to wrapper. We have tried a number of
    ideas to fix this problem, and are continuing to try to solve it on
    our own,
    but any help would be greatly appreciated. Please have someone call
    Alaiah Chandrashekar at the number above as soon as possible.
    Thanks!
    Dale V. Georg
    Indus Consultancy Services [email protected]
    Mack Trucks, Inc. [email protected]
    James Urquhart [email protected]
    Product Manager phone: (510) 986-3513
    Forte Software, Inc. fax: (510) 869-2092

    James,
    Thanks for your quick response. Yesterday we had been running down
    the path of examining the calling conventions and trying to change them
    to PASCAL, but without much success. After receiving your note, we
    went back over it again, and this time we were able to finally to piece it
    together. In addition to editing the Forte-generated .cc file to declare
    the functions as PASCAL, we also had to turn off the compiler's case
    sensitivity. (The Crystal .lib file had the function names in mixed case,
    but the Borland compiler was generating all uppercase for the names.)
    Now I had actually tried this yesterday and it didn't work (in fact it
    generated a whole bunch of new errors) - because until we took a
    second look at it today, I didn't realize that Borland's linker actually has
    TWO flags that control case sensitivity. If you only turn one or the
    other off, things can get pretty ugly looking. As soon as we turned
    both of them off, the compile and link went beautifully. Again, thanks
    for your help; hopefully we are over the worst of it now!
    Dale
    I have seen this problem before in another context, and I'll offer the
    cause and solution in the hope that they will apply to the Crystalproblem.
    >
    Many Windows based applications rely on PASCAL callingconventions, which
    change the way parameters are handled in function/method calls.They
    indicate this by placing one of the following immediately before the
    function name in the prototype declarations:
    - pascal_far (or something like that)
    - WINAPI
    - some other typedef of either of the above
    For example:
    int WINAPI AddTotal(int valueA, int valueB);
    Unfortunately, v2.0 of Forte does not provide any mechanisms forchanging
    the calling conventions of the prototypes in the generated C++wrapper
    library, so when you compile that code, the linker fails. I think thatthe
    compiler may generate different symbols depending on callingconventions,
    so that's why it fails.
    To fix this, don't autocompile your code, but generate thedistribution, go
    into the generated C++ files and look for the function prototypes (I think
    you can search for FORTE_NO_PROTOTYPES), add WINAPI tothe appropriate
    places in the prototype definitions (see above) and use fcompile tobuild
    the library. Instructions for fcompile are in the Interfacing With
    External Systems manual.
    Hope this helps,
    James
    At 11:05 AM 5/29/97 PDT, you wrote:
    We are trying to wrapper Crystal Reports from Forte. I know that
    there
    are a number of other people in this same boat, as I've seenmessages
    posted here at various points during the past few weeks. We arehaving
    a particular problem with getting the compile to go through, whichwe
    have sent in to Forte Tech Support. I'm forwarding the message Isent
    Tech Support to this group in the hopes that someone here mayhave
    already seen and resolved a similar problem.
    Thanks in advance for any help you can offer!
    Dale V. Georg
    Indus Consultancy Services [email protected]
    Mack Trucks, Inc.
    [email protected]
    >
    >>
    Date: Wed, 28 May 97 13:47:20 PDT
    From: dg7077a
    To: Forte Technical Support
    Cc: Gardner, Steve
    Subject: Link Problems With Borland C++ 4.52
    Name of requestor: [Dale V. Georg / AlaiahChandrashekar
    Company: [Indus Consultancy Services]
    Phone for callback: [(610) 709-3956]
    Customer Site: [Mack Trucks, Inc.]
    Product: [Forte]
    Version of Forte: [2.0.H.1]
    Server OS: [SunOS 5.5.1]
    Client OS: [Windows 3.1]
    DBMS: [Oracle 7.2.3]
    Reproducible?: [Yes]
    Brief description: [Link Problems With Borland C++ 4.52]
    Complete description of problem or question:
    We are attempting to write a C-wrapper interface from Forte to
    Crystal
    >>
    Reports' Report Engine. We are using Borland C++ version 4.52.
    Unfortunately, we have been unable to get a clean compile after aday
    and half of effort. We get as far as the link stage of the
    compilation, and
    the compiler aborts with an "Unknown symbol" error message foreach
    of the functions we are trying to wrapper. We have tried a numberof
    ideas to fix this problem, and are continuing to try to solve it on
    our own,
    but any help would be greatly appreciated. Please have someonecall
    Alaiah Chandrashekar at the number above as soon as possible.
    Thanks!
    Dale V. Georg
    Indus Consultancy Services [email protected]
    Mack Trucks, [email protected]
    James Urquhart [email protected]
    Product Manager phone: (510) 986-3513
    Forte Software, Inc. fax: (510) 869-2092-----------------------------------------------------------------------------------
    Dale V. Georg
    Indus Consultancy Services [email protected]
    Mack Trucks, Inc. [email protected]
    [email protected]------------------

  • Pro*C linker problems

    System is Linux Mandrake 6.0 with Oracle 8i, with the 8i patch
    applied.
    What a nightmare that install was! Lots of permission problems,
    unreadable directories, programs with no execute permission on
    them and so on.
    I now have a database up and running, and am trying to get Pro*C
    working. The code was written on RedHat 5.2 with Oracle 8.0.5,
    and worked fine there, so I know it is not a fundamental code
    problem!
    I have patched the pcscfg.cfg file as detailed in the patch FAQ
    (with modifications for the slightly different paths under
    Mandrake Linux).
    When I compile the Pro*c file, I get many "undefined reference
    to 'dbcon'" and "undefined reference to 'ctx'" errors from the
    linker. This occurs whether I use a pre-defined list of specific
    libraries in my own Makefile, or if I use the standard
    demo_proc.mk makefile. I have used nm(1) on every place I can
    think of, to try to find the required library/object, but to no
    avail.
    I appreciate that Oracle have so far only certified Oracle for
    Linux against Redhat 6.0, but surely Mandrake can't be THAT
    different ;-)
    Does anybody have any ideas, known problems etc? I REALLY HOPE
    that I don't have to switch to Redhat as the only solution - no
    problem with Redhat, it would just require a tedious and
    complicated system rebuild, which I don't have the time to do :-(
    TIA
    Mike Holden
    null

    Robert B     gin (self) (guest) wrote:
    : Robert B     gin (guest) wrote:
    : : Since I've last posted, I've installed RedHat 5.2 and
    ditched
    : : Slackware!
    : : (btw, what a breeze - Hat's off to RH! very nice install!).
    : : I've then installed oracle, have managed to setup
    tnsnames.ora
    : : so I can connect via sqlplus to my remote database (on
    : VAX/VMS).
    : : But now I have Pro*C linker problems with:
    : : make -f demo_proc.mk build OBJS=test.o exe=test
    : : (blah,blah,blah)
    : : /usr/lib/crt1.o(.text+0x36): undefined reference to `main'
    : : make: *** [build] Error 1
    : : Does anybody out there have a similar problem?
    : : Rob
    : Duh! forget it... (EXE has to be caps... RTFM)
    : (cryptic error message though?)
    : works great!!!
    Could you please tell me where I can get demo_proc.mk file
    for Linux (RedHat)?
    Thanks
    null

  • OCCI Link Problem

    Hi,
    I am using Oracle 9.2.0.1.0, Redhat 9, gcc 2.96, glibc 2.3.2-11.9. I continually receive the following link problem:
    /usr/bin/ld: warning: libclntsh.so, needed by /opt/ora9/product/9.2//lib/libvdc.so, not found (try using -rpath or -rpath-link)
    /opt/ora9/product/9.2//lib/libocci9.a(occiUtil.o)(.text+0x99f): In function `oracle::occi::toUpperCase(basic_string&lt;char, string_char_traits&lt;char&gt;, __default_alloc_template&lt;true, 0&gt; &gt; const &)':
    : undefined reference to `__ctype_toupper'
    collect2: ld returned 1 exit status
    Can anyone assist in resolving this issue?
    Thanks
    JD

    Removed libocci9 and it compiled.
    JD

  • Having problems compiling script

    I am rather new to java an started a couple of days ago and I ran into a problem compiling this script in the command line
    class VariableDemo {
    public static void main (String args[]) {
    int num = 1000;
    System.out.println (num + " is the value of num") ;
    At first I forgot to capitolize the 'S' in System (which is why I was getting errors) but after I had corrected it , I still could not get it to compile in a command prompt
    even after I corrected my mistakes, I still get this error:
    error: cannot read: VariableDemo.java
    1 error
    When I ran it through JCreator it compiled it just fine and found no errors. SO I just want to know if it is some thing that has to do with the command line or is there an error I am not seeing?
    I am running Windows XP Pro with service pack 2 and using JCreator 3.50.010

    Sorry, I am new to this I just called it script out of ignorance, but, yes it is in the same directory. I even Pathed it out again to be sure.

  • Element link problem in datamodel

    Hi,
    We created 2 datasets in Datamodel, When we tried to put element level links for both the datasets , its showing error when we generate sample xml.
    The error is displayed as shown below:
    XML Parsing Error: no element found
    Location: http://localhost:9704/xmlpserver/servlet/xdo
    Line Number 4, Column 1:
    Also in bipublisher.log file, i'm getting this error:
    *[2012-03-02T10:54:01.438+05:30] [bi_server1] [WARNING] [] [oracle.xdo] [tid: 38] [userId: <anonymous>] [ecid: 4b1d6eaff3f572e1:6d93021e:135c76b9078:-8000-0000000000015be5,0] [APP: bipublisher#11.1.1] java.sql.SQLException: java.io.IOException: prepare query failed[nQSError: 43113] Message returned from OBIS.[[*
    *[nQSError: 27002] Near <=>: Syntax error [nQSError: 26012] .*
    the column which 'm trying to link is having same datatype as VARCHAR only.
    What should be done for this error? can anyone help in this issue?
    Thanks & Regards,
    Surya

    Thanks  for the response Thomas!
    The functionality seems to work just fine. I use the LINK PROBLEM and it pops up the problem search box, I search for and select a Problem, I then select it and click ok, and I get no error saying the relationship was not created.
    The problem is, when I open the problem after that, there is never any relationship showing in related items there, as it says there should be.
    Also, to point out, I am talking about newly created Incidents. I tried even using APPLY prior to doing the LINK PROBLEM but it still did not work. I suspect it may be a workflow problem, where the workflow to create the incident has not completed, there
    for the relationship is not completed.... and I get no error.
    In my work environment, we have analysts during outages taking a call every 30 seconds, and I need a more efficient way for this system to work. As of now, they spend 1-2 minutes doing the ticket, and that is too long.
    I have decided to try a newb way, where I created an Incident (GENERIC OUTAGE) that folks can use, and every 15-30 minutes during an outage, I can open the problem and search for open incidents with that title, and attach all that I find from the problem
    side. This is assuming that once attached they will not show up in the search to attach the next time lol. Also this assumes that if attached from the problem, they will auto resolve when the problem is resolved.
    I am rusty on my programming, and am currently trying to get refreshed. I am sure that would come in handy for this :)
    Oh and lastly, one additional tidbit that will make this clearer, with regard to work flow, we re also running our Service Manager in our help desk, virtualized, as they have not upgraded to Win 7 yet :(. So that compiles my time to add ticket issue :(.

  • Problems compiling program

    hello.
    this is james mcfadden. i'm having problems compiling the Demo.java program. the Demo.java program is shown below along with the MediaPanel.java and MediaTest.java programs. when i compile the Demo.java program i get the following errors. i really need help in getting rid of these errors.
    ----jGRASP exec: javac -g X:\CP4B Project\Demo.java
    Demo.java:297: cannot find symbol
    symbol : class Media
    location: class Demo
    MediaTest media=new Media();
    ^
    Demo.java:301: cannot find symbol
    symbol : class Media
    location: class Demo
    MediaTest media=new Media();
    ^
    Demo.java:305: cannot find symbol
    symbol : class Media
    location: class Demo
    MediaTest media=new Media();
    ^
    3 errors
    ----jGRASP wedge2: exit code for process is 1.
    ----jGRASP: operation complete.
    //Written by:Seamus McFadden
    //Class:CP4B
    //Program Number:1
    //Program Name:Demo.java
    //Description:
    //Supervisor:Gerard McCloskey
    import java.awt.*;//Contains all of the classes for creating user interfaces and for painting graphics and images
    import java.awt.event.*;//Provides interfaces and classes for dealing with different types of events fired by AWT components
    import javax.swing.*;//Provides a set of lightweight components that, to the maximum degree possible, work the same on all platforms
    public class Demo extends JFrame{
        public static void main(String[] args){
            int choice=-1;//a variable of type int that is set to -1
            choice=getChoice();//invokes the method getChoice()
            if(choice!=0){
               getSelected(choice);//invokes the method getSelected(choice)
            }//end if
        }//end main
        public static int getChoice(){
            String choice;//a variable of type string
            int ch;//a variable of type int
            choice=JOptionPane.showInputDialog(null,
                    "1. Product Menu\n" +
                    "2. Member Menu\n" +
                    "3. Rental Menu\n" +
                          "4. Media Menu\n" +
                    "5. Log Off\n\n" +
                    "Enter your choice");//asks the user for some input
            ch=Integer.parseInt(choice);//a class that wraps a value of the primitive type int in an object
            return ch;//a method that returns an integer value
        }//end getChoice
        public static void getSelected(int choice){
            if(choice == 1) {
                   product();
            }//end if
            if(choice==2){
               member();
            }//end if
            if(choice==3){
               rental();
            }//end if
                if(choice==4){
               media();
            }//end if
                if(choice==5){
                   LogOff logoff=new LogOff();
                }//end if
                else{
                   ErrorMessage error=new ErrorMessage();
        }//end getSelected
        public static void product(){
             int productChoice=-1;//a variable of type int that is set to -1
           productChoice=getProductChoice();//invokes the method getChoice()
           if(productChoice!=0){
              getProductSelected(productChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice(); 
        public static void member(){
           int memberChoice=-1;//a variable of type int that is set to -1
           memberChoice=getMemberChoice();//invokes the method getChoice()
           if(memberChoice!=0){
              getMemberSelected(memberChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice(); 
        public static void rental(){
           int rentalChoice=-1;//a variable of type int that is set to -1
           rentalChoice=getRentalChoice();//invokes the method getChoice()
           if(rentalChoice!=0){
              getRentalSelected(rentalChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice();
          public static void media(){
           int mediaChoice=-1;//a variable of type int that is set to -1
           mediaChoice=getMediaChoice();//invokes the method getChoice()
           if(mediaChoice!=0){
              getMediaSelected(mediaChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice(); 
          public static int getProductChoice(){
           String productChoice;//a variable of type string
           int pch;//a variable of type int
           productChoice=JOptionPane.showInputDialog(null,
                   "1. Add product details\n" +
                   "2. View product details\n" +
                   "3. Edit product details\n" +
                         "4. Delete product details\n" +
                   "5. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           pch=Integer.parseInt(productChoice);//a class that wraps a value of the primitive type int in an object
           return pch;//a method that returns an integer value
        }//end getProductChoice
          public static int getMemberChoice(){
           String memberChoice;//a variable of type string
           int mch;//a variable of type int
           memberChoice=JOptionPane.showInputDialog(null,
                   "1. Add member details\n" +
                   "2. View member details\n" +
                   "3. Edit member details\n" +
                             "4. Delete member details\n" +
                   "5. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           mch=Integer.parseInt(memberChoice);//a class that wraps a value of the primitive type int in an object
           return mch;//a method that returns an integer value
        }//end getMemberChoice
          public static int getRentalChoice(){
           String rentalChoice;//a variable of type string
           int rch;//a variable of type int
           rentalChoice=JOptionPane.showInputDialog(null,
                   "1. Add rental details\n" +
                   "2. View rental details\n" +
                   "3. Edit rental details\n" +
                             "4. Delete rental details\n" +
                   "5. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           rch=Integer.parseInt(rentalChoice);//a class that wraps a value of the primitive type int in an object
           return rch;//a method that returns an integer value
        }//end getRentalChoice
          public static int getMediaChoice(){
           String mediaChoice;//a variable of type string
           int mtch;//a variable of type int
           mediaChoice=JOptionPane.showInputDialog(null,
                   "1. Listen to songs\n" +
                             "2. View movie previews\n" +
                             "3. View game previews\n" +
                   "4. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           mtch=Integer.parseInt(mediaChoice);//a class that wraps a value of the primitive type int in an object
           return mtch;//a method that returns an integer value
        }//end getMediaChoice
          public static void getProductSelected(int productChoice){
           if(productChoice==1){
                  addProducts();
           }//end if
           if(productChoice==2){
              viewProducts();
           }//end if
           if(productChoice==3){
              editProducts();
           }//end if
               if(productChoice==4){
              deleteProducts();
           }//end if
               else{
                   ErrorMessage error=new ErrorMessage();
        }//end getProductSelected
          public static void getMemberSelected(int memberChoice){
           if(memberChoice==1){
                  addMembers();
           }//end if
           if(memberChoice==2){
              viewMembers();
           }//end if
           if(memberChoice==3){
              editMembers();
           }//end if
               if(memberChoice==4){
              deleteMembers();
           }//end if
               else{
                   ErrorMessage error=new ErrorMessage();
        }//end getMemberSelected
          public static void getRentalSelected(int rentalChoice){
           if(rentalChoice==1){
                  addRentals();
           }//end if
           if(rentalChoice==2){
              viewRentals();
           }//end if
           if(rentalChoice==3){
              editRentals();
           }//end if
               if(rentalChoice==4){
              deleteRentals();
           }//end if
               else{
                   ErrorMessage error=new ErrorMessage();
        }//end getRentalSelected
          public static void getMediaSelected(int mediaChoice){
           if(mediaChoice==1){
                  hearSongs();
           }//end if
           if(mediaChoice==2){
              viewMovies();
           }//end if
           if(mediaChoice==3){
              viewGames();
           }//end if
               else{
                   ErrorMessage error=new ErrorMessage();
        }//end getMediaSelected
          public static void addProducts(){
           ProductForm product=new ProductForm();
           product.getInput();
               product.setVisible(true);
          public static void viewProducts(){
           DatabaseTest tt=new DatabaseTest();
               tt.setVisible(true);
          public static void editProducts(){
           ProductForm product=new ProductForm();
               product.getInput();
               product.setVisible(true);
          public static void deleteProducts(){
           ProductForm product=new ProductForm();
               product.setVisible(true);
          public static void addMembers(){
           MemberForm member=new MemberForm();
               member.getInput();
               member.setVisible(true);
          public static void viewMembers(){
           DatabaseTest tt=new DatabaseTest();
               tt.setVisible(true);
          public static void editMembers(){
           MemberForm member=new MemberForm();
               member.getInput();
               member.setVisible(true);
          public static void deleteMembers(){
           MemberForm member=new MemberForm();
               member.setVisible(true);
          public static void addRentals(){
           RentalForm rental=new RentalForm();
               rental.getInput();
               rental.setVisible(true);
          public static void viewRentals(){
           DatabaseTest tt=new DatabaseTest();
               tt.setVisible(true);
          public static void editRentals(){
           RentalForm rental=new RentalForm();
               rental.getInput();
               rental.setVisible(true);
          public static void deleteRentals(){
           RentalForm rental=new RentalForm();
               rental.setVisible(true);
        public static void hearSongs(){
           MediaTest media=new Media(); 
        public static void viewMovies(){
           MediaTest media=new Media();   
        public static void viewGames(){
           MediaTest media=new Media();   
    }//end class Demo
    import java.awt.BorderLayout;
    import java.awt.Component;
    import java.io.IOException;
    import java.net.URL;
    import javax.media.CannotRealizeException;
    import javax.media.Manager;
    import javax.media.NoPlayerException;
    import javax.media.Player;
    import javax.swing.JPanel;
    public class MediaPanel extends JPanel{
       public MediaPanel(URL mediaURL){
          setLayout(new BorderLayout());//use a BorderLayout
          //Use lightweight components for Swing compatibility
          Manager.setHint(Manager.LIGHTWEIGHT_RENDERER,true);
          try{
             //create a player to play the media specified in the URL
             Player mediaPlayer=Manager.createRealizedPlayer(mediaURL);
             //get the components for the video and the playback controls
             Component video=mediaPlayer.getVisualComponent();
             Component controls=mediaPlayer.getControlPanelComponent();
             if(video!=null)
                add(video,BorderLayout.CENTER);//add video component
             if(controls!=null)
                add(controls,BorderLayout.SOUTH);//add controls
             mediaPlayer.start();//start playing the media clip
          }//end try
          catch(NoPlayerException noPlayerException){
             System.err.println("No media player found");
          }//end catch
          catch(CannotRealizeException cannotRealizeException){
             System.err.println("Could not realize media player");
          }//end catch
          catch(IOException iOException){
             System.err.println("Error reading from the source");
          }//end catch
       }//end MediaPanel constructor
    }//end class MediaPanel
    import java.io.File;
    import java.net.MalformedURLException;
    import java.net.URL;
    import javax.swing.JFileChooser;
    import javax.swing.JFrame;
    public class MediaTest{
       //launch the application
       public static void main(String args[]){
          //create a file chooser
          JFileChooser fileChooser=new JFileChooser();
          //show open file dialog
          int result=fileChooser.showOpenDialog(null);
          if(result==JFileChooser.APPROVE_OPTION){//user chose a file
             URL mediaURL=null;
             try{
                //get the file as URL
                mediaURL=fileChooser.getSelectedFile().toURL();
             }//end try
             catch(MalformedURLException malformedURLException){
                System.err.println("Could not create URL for the file");
             }//end catch
             if(mediaURL!=null) {//only display if there is a valid URL
                JFrame mediaTest=new JFrame("Media Tester");
                mediaTest.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                MediaPanel mediaPanel=new MediaPanel(mediaURL);
                mediaTest.add(mediaPanel);
                mediaTest.setSize(300,300);
                mediaTest.setVisible(true);
             }//end inner if
          }//end outer if
       }//end main
    }//end class MediaTest

    hello.
    this is james mcfadden. thanks for the reply. i did what you told me to do, but i am still having trouble trying to use the 2 JMF programs (MediaPanel.java and MediaTest.java) with the Demo.java program. the Demo.java program compiles and runs ok, but when i press 1 (for listening to songs) in the media menu i get a JOptionPane (An Error Message) displayed on screen. how can i fix this problem?
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class Demo extends JFrame{
        public static void main(String[] args){
            int choice=-1;//a variable of type int that is set to -1
            choice=getChoice();//invokes the method getChoice()
            if(choice!=0){
               getSelected(choice);//invokes the method getSelected(choice)
            }//end if
        }//end main
        public static int getChoice(){
            String choice;//a variable of type string
            int ch;//a variable of type int
            choice=JOptionPane.showInputDialog(null,
                    "1. Product Menu\n" +
                    "2. Member Menu\n" +
                    "3. Rental Menu\n" +
                          "4. Media Menu\n" +
                    "5. Log Off\n\n" +
                    "Enter your choice");//asks the user for some input
            ch=Integer.parseInt(choice);//a class that wraps a value of the primitive type int in an object
            return ch;//a method that returns an integer value
        }//end getChoice
        public static void getSelected(int choice){
            if(choice == 1) {
                   product();
            }//end if
            if(choice==2){
               member();
            }//end if
            if(choice==3){
               rental();
            }//end if
                if(choice==4){
               media();
            }//end if
                if(choice==5){
                   LogOff logoff=new LogOff();
                }//end if
                else{
                   JOptionPane.showMessageDialog(null,"Error\n\nInvalid options\nPlease choose 1, 2, 3, 4 or 5 on the main menu\nPlease choose 1, 2, 3, 4 or 5 on the product menu\nPlease choose 1, 2, 3, 4 or 5 on the member menu\nPlease choose 1, 2, 3, 4 or 5 on the rental menu\nPlease choose 1, 2, 3 or 4 on the media menu");
                   System.exit(0);
        }//end getSelected
        public static void product(){
             int productChoice=-1;//a variable of type int that is set to -1
           productChoice=getProductChoice();//invokes the method getChoice()
           if(productChoice!=0){
              getProductSelected(productChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice(); 
        public static void member(){
           int memberChoice=-1;//a variable of type int that is set to -1
           memberChoice=getMemberChoice();//invokes the method getChoice()
           if(memberChoice!=0){
              getMemberSelected(memberChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice(); 
        public static void rental(){
           int rentalChoice=-1;//a variable of type int that is set to -1
           rentalChoice=getRentalChoice();//invokes the method getChoice()
           if(rentalChoice!=0){
              getRentalSelected(rentalChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice();
          public static void media(){
           int mediaChoice=-1;//a variable of type int that is set to -1
           mediaChoice=getMediaChoice();//invokes the method getChoice()
           if(mediaChoice!=0){
              getMediaSelected(mediaChoice);//invokes the method getSelected(choice)
           }//end if
           getChoice(); 
          public static int getProductChoice(){
           String productChoice;//a variable of type string
           int pch;//a variable of type int
           productChoice=JOptionPane.showInputDialog(null,
                   "1. Add product details\n" +
                   "2. View product details\n" +
                   "3. Edit product details\n" +
                         "4. Delete product details\n" +
                   "5. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           pch=Integer.parseInt(productChoice);//a class that wraps a value of the primitive type int in an object
           return pch;//a method that returns an integer value
        }//end getProductChoice
          public static int getMemberChoice(){
           String memberChoice;//a variable of type string
           int mch;//a variable of type int
           memberChoice=JOptionPane.showInputDialog(null,
                   "1. Add member details\n" +
                   "2. View member details\n" +
                   "3. Edit member details\n" +
                             "4. Delete member details\n" +
                   "5. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           mch=Integer.parseInt(memberChoice);//a class that wraps a value of the primitive type int in an object
           return mch;//a method that returns an integer value
        }//end getMemberChoice
          public static int getRentalChoice(){
           String rentalChoice;//a variable of type string
           int rch;//a variable of type int
           rentalChoice=JOptionPane.showInputDialog(null,
                   "1. Add rental details\n" +
                   "2. View rental details\n" +
                   "3. Edit rental details\n" +
                             "4. Delete rental details\n" +
                   "5. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           rch=Integer.parseInt(rentalChoice);//a class that wraps a value of the primitive type int in an object
           return rch;//a method that returns an integer value
        }//end getRentalChoice
          public static int getMediaChoice(){
           String mediaChoice;//a variable of type string
           int mtch;//a variable of type int
           mediaChoice=JOptionPane.showInputDialog(null,
                   "1. Listen to songs\n" +
                             "2. View movie previews\n" +
                             "3. View game previews\n" +
                   "4. Return to main menu\n\n" +
                   "Enter your choice");//asks the user for some input
           mtch=Integer.parseInt(mediaChoice);//a class that wraps a value of the primitive type int in an object
           return mtch;//a method that returns an integer value
        }//end getMediaChoice
          public static void getProductSelected(int productChoice){
           if(productChoice==1){
                  addProducts();
           }//end if
           if(productChoice==2){
              viewProducts();
           }//end if
           if(productChoice==3){
              editProducts();
           }//end if
               if(productChoice==4){
              deleteProducts();
           }//end if
               else{
                   JOptionPane.showMessageDialog(null,"Error\n\nInvalid options\nPlease choose 1, 2, 3, 4 or 5 on the main menu\nPlease choose 1, 2, 3, 4 or 5 on the product menu\nPlease choose 1, 2, 3, 4 or 5 on the member menu\nPlease choose 1, 2, 3, 4 or 5 on the rental menu\nPlease choose 1, 2, 3 or 4 on the media menu");
                   System.exit(0);
        }//end getProductSelected
          public static void getMemberSelected(int memberChoice){
           if(memberChoice==1){
                  addMembers();
           }//end if
           if(memberChoice==2){
              viewMembers();
           }//end if
           if(memberChoice==3){
              editMembers();
           }//end if
               if(memberChoice==4){
              deleteMembers();
           }//end if
               else{
                   JOptionPane.showMessageDialog(null,"Error\n\nInvalid options\nPlease choose 1, 2, 3, 4 or 5 on the main menu\nPlease choose 1, 2, 3, 4 or 5 on the product menu\nPlease choose 1, 2, 3, 4 or 5 on the member menu\nPlease choose 1, 2, 3, 4 or 5 on the rental menu\nPlease choose 1, 2, 3 or 4 on the media menu");
                   System.exit(0);
        }//end getMemberSelected
          public static void getRentalSelected(int rentalChoice){
           if(rentalChoice==1){
                  addRentals();
           }//end if
           if(rentalChoice==2){
              viewRentals();
           }//end if
           if(rentalChoice==3){
              editRentals();
           }//end if
               if(rentalChoice==4){
              deleteRentals();
           }//end if
               else{
                   JOptionPane.showMessageDialog(null,"Error\n\nInvalid options\nPlease choose 1, 2, 3, 4 or 5 on the main menu\nPlease choose 1, 2, 3, 4 or 5 on the product menu\nPlease choose 1, 2, 3, 4 or 5 on the member menu\nPlease choose 1, 2, 3, 4 or 5 on the rental menu\nPlease choose 1, 2, 3 or 4 on the media menu");
                   System.exit(0);
        }//end getRentalSelected
          public static void getMediaSelected(int mediaChoice){
           if(mediaChoice==1){
                  hearSongs();
           }//end if
           if(mediaChoice==2){
              viewMovies();
           }//end if
           if(mediaChoice==3){
              viewGames();
           }//end if
               else{
                   JOptionPane.showMessageDialog(null,"Error\n\nInvalid options\nPlease choose 1, 2, 3, 4 or 5 on the main menu\nPlease choose 1, 2, 3, 4 or 5 on the product menu\nPlease choose 1, 2, 3, 4 or 5 on the member menu\nPlease choose 1, 2, 3, 4 or 5 on the rental menu\nPlease choose 1, 2, 3 or 4 on the media menu");
                   System.exit(0);
        }//end getMediaSelected
          public static void addProducts(){
           ProductForm product=new ProductForm();
           product.getInput();
               product.setVisible(true);
          public static void viewProducts(){
           DatabaseTest tt=new DatabaseTest();
               tt.setVisible(true);
          public static void editProducts(){
           ProductForm product=new ProductForm();
               product.getInput();
               product.setVisible(true);
          public static void deleteProducts(){
           ProductForm product=new ProductForm();
               product.setVisible(true);
          public static void addMembers(){
           MemberForm member=new MemberForm();
               member.getInput();
               member.setVisible(true);
          public static void viewMembers(){
           DatabaseTest tt=new DatabaseTest();
               tt.setVisible(true);
          public static void editMembers(){
           MemberForm member=new MemberForm();
               member.getInput();
               member.setVisible(true);
          public static void deleteMembers(){
           MemberForm member=new MemberForm();
               member.setVisible(true);
          public static void addRentals(){
           RentalForm rental=new RentalForm();
               rental.getInput();
               rental.setVisible(true);
          public static void viewRentals(){
           DatabaseTest tt=new DatabaseTest();
               tt.setVisible(true);
          public static void editRentals(){
           RentalForm rental=new RentalForm();
               rental.getInput();
               rental.setVisible(true);
          public static void deleteRentals(){
           RentalForm rental=new RentalForm();
               rental.setVisible(true);
        public static void hearSongs(){
           MediaTest media=new MediaTest(); 
        public static void viewMovies(){
           MediaTest media=new MediaTest();   
        public static void viewGames(){
           MediaTest media=new MediaTest();   
    }//end class Demo
    import java.awt.BorderLayout;
    import java.awt.Component;
    import java.io.IOException;
    import java.net.URL;
    import javax.media.CannotRealizeException;
    import javax.media.Manager;
    import javax.media.NoPlayerException;
    import javax.media.Player;
    import javax.swing.JPanel;
    public class MediaPanel extends JPanel{
       public MediaPanel(URL mediaURL){
          setLayout(new BorderLayout());//use a BorderLayout
          //Use lightweight components for Swing compatibility
          Manager.setHint(Manager.LIGHTWEIGHT_RENDERER,true);
          try{
             //create a player to play the media specified in the URL
             Player mediaPlayer=Manager.createRealizedPlayer(mediaURL);
             //get the components for the video and the playback controls
             Component video=mediaPlayer.getVisualComponent();
             Component controls=mediaPlayer.getControlPanelComponent();
             if(video!=null)
                add(video,BorderLayout.CENTER);//add video component
             if(controls!=null)
                add(controls,BorderLayout.SOUTH);//add controls
             mediaPlayer.start();//start playing the media clip
          }//end try
          catch(NoPlayerException noPlayerException){
             System.err.println("No media player found");
          }//end catch
          catch(CannotRealizeException cannotRealizeException){
             System.err.println("Could not realize media player");
          }//end catch
          catch(IOException iOException){
             System.err.println("Error reading from the source");
          }//end catch
       }//end MediaPanel constructor
    }//end class MediaPanel
    import java.io.File;
    import java.net.MalformedURLException;
    import java.net.URL;
    import javax.swing.JFileChooser;
    import javax.swing.JFrame;
    public class MediaTest{
       //launch the application
       public static void main(String args[]){
          //create a file chooser
          JFileChooser fileChooser=new JFileChooser();
          //show open file dialog
          int result=fileChooser.showOpenDialog(null);
          if(result==JFileChooser.APPROVE_OPTION){//user chose a file
             URL mediaURL=null;
             try{
                //get the file as URL
                mediaURL=fileChooser.getSelectedFile().toURL();
             }//end try
             catch(MalformedURLException malformedURLException){
                System.err.println("Could not create URL for the file");
             }//end catch
             if(mediaURL!=null) {//only display if there is a valid URL
                JFrame mediaTest=new JFrame("Media Tester");
                mediaTest.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                MediaPanel mediaPanel=new MediaPanel(mediaURL);
                mediaTest.add(mediaPanel);
                mediaTest.setSize(300,300);
                mediaTest.setVisible(true);
             }//end inner if
          }//end outer if
       }//end main
    }//end class MediaTest

  • Problems compiling at91 driver for samutils-0.2.1

    Hello All!
    I'm having problems compiling the usb driver for sam7 tools. I am receiving the following errors:
    make -C /lib/modules/2.6.39-ARCH/build SUBDIRS=/home/bailey/Source/sam7utils-0.2.1/driver modules
    make[1]: Entering directory `/usr/src/linux-2.6.39-ARCH'
    CC [M] /home/bailey/Source/sam7utils-0.2.1/driver/at91.o
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c: In function âat91_write_bulk_callbackâ:
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:154:2: error: implicit declaration of function âusb_buffer_freeâ [-Werror=implicit-function-declaration]
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:140:19: warning: variable âdevâ set but not used [-Wunused-but-set-variable]
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c: In function âat91_writeâ:
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:178:2: error: implicit declaration of function âusb_buffer_allocâ [-Werror=implicit-function-declaration]
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:178:6: warning: assignment makes pointer from integer without a cast [enabled by default]
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:192:6: warning: passing argument 6 of âusb_fill_bulk_urbâ from incompatible pointer type [enabled by default]
    include/linux/usb.h:1266:20: note: expected âusb_complete_tâ but argument is of type âvoid (*)(struct urb *, struct pt_regs *)â
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c: In function âat91_probeâ:
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:305:2: error: implicit declaration of function âinfoâ [-Werror=implicit-function-declaration]
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c: In function âat91_disconnectâ:
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:320:2: error: implicit declaration of function âlock_kernelâ [-Werror=implicit-function-declaration]
    /home/bailey/Source/sam7utils-0.2.1/driver/at91.c:328:2: error: implicit declaration of function âunlock_kernelâ [-Werror=implicit-function-declaration]
    cc1: some warnings being treated as errors
    make[2]: *** [/home/bailey/Source/sam7utils-0.2.1/driver/at91.o] Error 1
    make[1]: *** [_module_/home/bailey/Source/sam7utils-0.2.1/driver] Error 2
    make[1]: Leaving directory `/usr/src/linux-2.6.39-ARCH'
    make: *** [default] Error 2
    output of uname -a
    2.6.39-ARCH #1 SMP PREEMPT Mon Jun 27 22:01:13 CEST 2011 i686 Intel(R) Pentium(R) 4 CPU 1.50GHz GenuineIntel GNU/Linux
    I am running gcc 4.6.1-1 and have installed kernel26headers. If there is any info I'm missing plz let me know.
    Thanks for your help in advance

    Thank you for the reply, I noticed that the post below (its for Ubuntu) shows the gcc version to be 4.0.3
    [link]http://www.makingthings.com/documentati … -sam7utils[/link]
    I poked around the Makefile in /usr/src/linux-2.6.39 and got rid of "-Wall" and "-Wno-implicit-function-declaration"
    it compiled with the following warnings:
    make[1]: Entering directory `/usr/src/linux-2.6.39-ARCH'
    Building modules, stage 2.
    MODPOST 1 modules
    WARNING: "info" [/home/bailey/Source/sam7utils-0.2.1/driver/at91.ko] undefined!
    WARNING: "unlock_kernel" [/home/bailey/Source/sam7utils-0.2.1/driver/at91.ko] undefined!
    WARNING: "lock_kernel" [/home/bailey/Source/sam7utils-0.2.1/driver/at91.ko] undefined!
    WARNING: "usb_buffer_alloc" [/home/bailey/Source/sam7utils-0.2.1/driver/at91.ko] undefined!
    WARNING: "usb_buffer_free" [/home/bailey/Source/sam7utils-0.2.1/driver/at91.ko] undefined!
    CC /home/bailey/Source/sam7utils-0.2.1/driver/at91.mod.o
    LD [M] /home/bailey/Source/sam7utils-0.2.1/driver/at91.ko
    make[1]: Leaving directory `/usr/src/linux-2.6.39-ARCH'
    but when I tried to install, the output was
    insmod: error inserting 'at91.ko': -1 Unknown symbol in module
    Unfortunately, I tried grabbing the package from the AUR, but I ran into the same issues. Seems the only common factor in this process is gcc.
    Thanks for the help

Maybe you are looking for