You are not logged in.

#1 2010-03-21 10:18:39

Andrwe
Member
From: Leipzig/Germany
Registered: 2009-06-17
Posts: 322
Website

Citrix-client: general knowledge about iconv would be helpful

Hi,

Sorry for double posting this, but I think the first place I've posted this problem may be the wrong place.
I'm looking for help getting the "normal" client of citrix running on x86_64.
I'm the maintainer of citrix-PKGBUILD in AUR at the moment.

The problem which occures is that the client tries to convert UTF8 characters to Unicode.
Here are some pictures showing the problem:

tM3FiMg
tM3FiNA

Because our citrix-server don't support http-connection I can't use the firefox plugin and therefore I'm trying to get the client working but I don't have an idea anymore.

Here is the latest PKGBUILD for x86_64:

# Maintainer: Andrwe <lord-weber-andrwe at renona-studios dot org>

pkgname=citrix-client
pkgver=11.100
pkgrel=2
pkgdesc="Provides XenApp(Citrix) for linux."
url="http://www.citrix.com"
arch=('i686' 'x86_64')
license=('CAL')
depends=('gtk2' 'libx11' 'libxaw' 'libxext' 'libxft' 'libxmu' 'libxp' 'libxpm' 'libxt' 'openmotif' 'printproto' 'xextproto')
[ "$CARCH" == "x86_64" ] && depends=('gtk2' 'lib32-libjpeg' 'lib32-libpng' 'lib32-libx11' 'lib32-libxaw' 'lib32-libxext' 'lib32-libxft' 'lib32-libxinerama' 'lib32-libxmu' 'lib32-libxp' 'lib32-libxpm' 'lib32-libxt' 'lib32-openmotif' 'lib32-printproto' 'xextproto')
source=('http://www.citrix.com//English/SS/downloads/EULA_p.asp?downloadID=3323&versionID=1862392&productID=186')
install=citrix-client.install
md5sums=('069bb3337791b0b55cbbf666c95403e5')

build() {

    instdir="/usr/lib/ICAClient"
    # Create folder structure
    mkdir -p "${pkgdir}"/usr/lib/{ICAClient,mozilla/plugins}
    mkdir -p "${pkgdir}"/usr/bin/

    # copy needed files
    cp -r ./linuxx86/linuxx86.cor/* "${pkgdir}${instdir}"/
    cp ./setupwfc "${pkgdir}${instdir}"/
    
    # Create executable start wrapper
    echo -e "#!/bin/bash\n${instdir}/wfcmgr" > "${pkgdir}"/usr/bin/citrix-client.sh
    chmod a+x "${pkgdir}"/usr/bin/citrix-client.sh

    # Go to package directory
    cd "${pkgdir}${instdir}"/

    # Create executable wrapper for the binaries
    echo -e "#!/bin/sh\nICAROOT=/usr/lib/ICAClient\nexport \${ICAROOT}\n\${ICAROOT}/wfica -file \$1" > ./wfica.sh
    echo -e "#!/bin/sh\nICAROOT=/usr/lib/ICAClient\nexport \${ICAROOT}\n\${ICAROOT}/wfica -associate -fileparam \$1" > ./wfica_assoc.sh
    chmod a+x ./{wfica.sh,wfica_assoc.sh}
    
    # Create symlinks for the Npica.ad binary
    ln -s ./nls/en/Npica.ad ./Npica.ad
    ln -s ./Npica.ad ./Npica

    # Copy program inforamtion files to program root directory
    cp ${srcdir}/nls/en/{eula.txt,install.txt,readme.txt} ./

    # Copy default configuration files to config directory of the program and setting them readable
    cp ./nls/en/{appsrv.ini,wfclient.ini,module.ini} ./config/
    chmod 666 ./config/{appsrv.ini,wfclient.ini,module.ini}
    chmod 777 ./config

    # Copy Firefox plugin into plugin directory
    cp ./npica.so "${pkgdir}"/usr/lib/mozilla/plugins/
    
}

The lib32-packages e.g. lib32-openmotif you can find in my repo:

[andrwe]
Server = http://andrwe.dyndns.org/repo/x86_64

I'll commit the PKGBUILD for lib32-openmotif later to AUR.
Here is it for you if you don't want to use the package in my repo:

# Contributor: Andrwe Lord Weber <lord-weber-andrwe at renona-studios dot org>

pkgname=lib32-openmotif
pkgname32=${pkgname/lib32-/}
pkgver=2.3.2
pkgrel=2
pkgrel32=2
pkgdesc="Openmotif"
arch=('x86_64')
url="http://www.opengroup.org/openmotif/"
license=('GPL')
source=(ftp://ftp.archlinux.org/community/os/i686/${pkgname32}-${pkgver}-${pkgrel32}-i686.pkg.tar.gz)
noextract=()
md5sums=('58294043fc91e679a45d786b8b33fe24')

build() {
  mkdir -p ${pkgdir}/opt/lib32/usr/
  cp -rPf ${srcdir}/usr/lib ${pkgdir}/opt/lib32/usr/lib
}

Offline

#2 2010-04-19 15:05:23

Andrwe
Member
From: Leipzig/Germany
Registered: 2009-06-17
Posts: 322
Website

Re: Citrix-client: general knowledge about iconv would be helpful

lib32-openmotif is now available through my repository and AUR.

I couldn't solve the iconf problem until now.
Has noone any clue to it?

Offline

#3 2010-04-21 08:41:22

fettouhi
Member
Registered: 2007-05-07
Posts: 745

Re: Citrix-client: general knowledge about iconv would be helpful

I've tried using this my work place insists on using the webplugin and since it won't work under 64 bit I can't run it sad.

Offline

#4 2010-04-29 08:17:31

Schuster
Member
From: Austria
Registered: 2010-04-29
Posts: 6

Re: Citrix-client: general knowledge about iconv would be helpful

I haven't solved the problem, wfica segfaults for me, but maybe you can use some debug output...

gdb ./wfica
    ...
(gdb) run foo.ica
    ...
Program received signal SIGSEGV, Segmentation fault.
0xf7f3804d in _XtGetApplicationResources () from /opt/lib32/usr/lib/libXt.so.6
(gdb) bt
#0  0xf7f3804d in _XtGetApplicationResources () from /opt/lib32/usr/lib/libXt.so.6
#1  0xf7f380f0 in XtGetApplicationResources () from /opt/lib32/usr/lib/libXt.so.6
#2  0x0811b6bf in XYesNoConfirm ()
#3  0xf7fda63f in StringFromCharsetToUnicode () from /opt/ICAClient/CHARICONV.DLL
#4  0x081738cf in Encoding_convertCharsetToWchar ()
#5  0x08173a58 in Encoding_convertPlatformToWcharAllocate ()
#6  0x0817789f in ConfigurationManagerInt_SetConfigurationDirectory ()
#7  0x08174690 in ConfigurationManager_SetConfigurationDirectory ()
#8  0x080f01d7 in miLoadICAFile ()
#9  0x0807a48f in ReadINIConfig ()
#10 0x08136e7b in HostInit ()
#11 0x08077c3b in OldMain ()
#12 0x08137f4a in PlatAppMain ()
#13 0x080feda6 in AppMain ()
#14 0x08137eda in main ()

and strace says:

open("foo.ica", O_RDONLY)   = 4
fstat64(4, {st_mode=S_IFREG|0600, st_size=1400, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xfffffffff7765000
fstat64(4, {st_mode=S_IFREG|0600, st_size=1400, ...}) = 0
_llseek(4, 0, [0], SEEK_SET)            = 0
read(4, "[Encoding]\r\nInputEncoding=UTF8\r\n"..., 1400) = 1400
_llseek(4, 1400, [1400], SEEK_SET)      = 0
close(4)                                = 0
munmap(0xf7765000, 4096)                = 0
open("/usr/lib/gconv/gconv-modules.cache", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/lib/gconv/gconv-modules", O_RDONLY) = 4
fstat64(4, {st_mode=S_IFREG|0644, st_size=56028, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xfffffffff7765000
read(4, "# GNU libc iconv configuration.\n"..., 4096) = 4096
read(4, "B1.002//\nalias\tJS//\t\t\tJUS_I.B1.0"..., 4096) = 4096
read(4, "59-3\t1\nmodule\tINTERNAL\t\tISO-8859"..., 4096) = 4096
read(4, "859-14//\nalias\tISO-IR-199//\t\tISO"..., 4096) = 4096
read(4, "CDIC-DK-NO-A//\tEBCDIC-DK-NO-A\t1\n"..., 4096) = 4096
read(4, "\t\tIBM281//\t\tIBM281\t\t1\n\n#\tfrom\t\t\t"..., 4096) = 4096
read(4, "\tIBM863\t\t1\n\n#\tfrom\t\t\tto\t\t\tmodule"..., 4096) = 4096
read(4, "//\t\tIBM937//\nalias\tCSIBM937//\t\tI"..., 4096) = 4096
read(4, "JAPANESE//\tEUC-JP//\nalias\tOSF000"..., 4096) = 4096
read(4, "MACINTOSH//\t\tMACINTOSH\t1\n\n#\tfrom"..., 4096) = 4096
read(4, "367-BOX//\nalias\tISO_10367BOX//\t\t"..., 4096) = 4096
read(4, "EUC-JISX0213//\t\tINTERNAL\t\tEUC-JI"..., 4096) = 4096
read(4, "/\t\tIBM1130//\nalias\tCSIBM1130//\t\t"..., 4096) = 4096
read(4, "\t1\n\n#\tfrom\t\t\tto\t\t\tmodule\t\tcost\na"..., 4096) = 2780
read(4, "", 4096)                       = 0
close(4)                                = 0
munmap(0xf7765000, 4096)                = 0
futex(0xf7549a6c, FUTEX_WAKE_PRIVATE, 2147483647) = 0
open("/usr/lib/gconv/UNICODE.so", O_RDONLY) = 4
read(4, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0`\5\0\0\0\0\0\0"..., 512) = 512
close(4)                                = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---

What seems strange to me is that although wfica is 32bit, it's using 64bit-stuff like /usr/lib/gconv/UNICODE.so, although /opt/lib32/usr/lib/gconv/UNICODE.so would be available.

Offline

#5 2010-04-29 10:20:05

Schuster
Member
From: Austria
Registered: 2010-04-29
Posts: 6

Re: Citrix-client: general knowledge about iconv would be helpful

Okay, I was right. (I love it when this happens smile )

This trick made the ICA-Client working for me:

# cd /usr/lib
# mv gconv gconv64
# ln -s /opt/lib32/usr/lib/gconv

This will of course most likely break a lot of other stuff, but I think it shows that the main problem is that the 64bit-gconv-module is loaded.

Offline

#6 2010-04-29 11:00:30

Schuster
Member
From: Austria
Registered: 2010-04-29
Posts: 6

Re: Citrix-client: general knowledge about iconv would be helpful

Looks like a bug in lib32-glibc.

I found a somewhat better workaround (that shouldn't break the rest of the system):

export GCONV_PATH=/opt/lib32/usr/lib/gconv/
{start wfica or other 32bit-stuff that needs iconv()}

I guess you could create a wrapper for wfica that sets GCONV_PATH before calling wfica, but fixing lib32-glibc  is the right thing to do, imho.

Offline

#7 2010-04-29 11:09:38

Andrwe
Member
From: Leipzig/Germany
Registered: 2009-06-17
Posts: 322
Website

Re: Citrix-client: general knowledge about iconv would be helpful

Yeah, found this solution too.
Thank you very much Schuster.
I've already created a wrapper because citrix has to be started using "setarch i686".

I'm now creating the PKGBUILD for bin32-citrix will be ready in some minutes. big_smile

Last edited by Andrwe (2010-04-29 11:10:26)

Offline

#8 2010-04-29 11:50:58

Andrwe
Member
From: Leipzig/Germany
Registered: 2009-06-17
Posts: 322
Website

Re: Citrix-client: general knowledge about iconv would be helpful

bin32-citrix-client is now available in AUR and my repository. smile

Offline

#9 2010-04-29 12:05:26

Schuster
Member
From: Austria
Registered: 2010-04-29
Posts: 6

Re: Citrix-client: general knowledge about iconv would be helpful

Thanks!

3 minor issues:
* namcap reports a few problems
* Wrong path in the message

After creating this directory you have to copy the files All_Regions.ini, Trusted_Region.ini, Unknown_Region.ini, canonicalization.ini, regions.ini from /usr/lib/ICAClient/config/ to $HOME/.ICAClient/
        cp /usr/lib/ICAClient/config/{All_Regions.ini,Trusted_Region.ini,Unknown_Region.ini,canonicalization.ini,regions.ini} $HOME/.ICAClient/

(should be /opt/lib32/usr/lib/ICAClient/config/ I guess smile )
* What about providing /usr/bin/wfica and /usr/bin/wfcmgr as wrappers?

Offline

#10 2010-04-29 12:24:47

fettouhi
Member
Registered: 2007-05-07
Posts: 745

Re: Citrix-client: general knowledge about iconv would be helpful

Does the firefox plugin work now?

Offline

#11 2010-04-29 12:43:29

Andrwe
Member
From: Leipzig/Germany
Registered: 2009-06-17
Posts: 322
Website

Re: Citrix-client: general knowledge about iconv would be helpful

Schuster wrote:

Thanks!
* namcap reports a few problems

I didn't know that such a program exists. Very nice. lol
The dependecies error are wrong and the symlinks are working.

Schuster wrote:

* Wrong path in the message

After creating this directory you have to copy the files All_Regions.ini, Trusted_Region.ini, Unknown_Region.ini, canonicalization.ini, regions.ini from /usr/lib/ICAClient/config/ to $HOME/.ICAClient/
        cp /usr/lib/ICAClient/config/{All_Regions.ini,Trusted_Region.ini,Unknown_Region.ini,canonicalization.ini,regions.ini} $HOME/.ICAClient/

(should be /opt/lib32/usr/lib/ICAClient/config/ I guess smile )

fixed smile

Schuster wrote:

* What about providing /usr/bin/wfica and /usr/bin/wfcmgr as wrappers?

Done.

@fettouhi
Unfortunately I can't test the firefox-plugin because the server I can use doesn't support it.
But try and report back. Maybe I'm able to modify the PKGBUILD so it would work.

Offline

#12 2010-04-29 12:55:42

Schuster
Member
From: Austria
Registered: 2010-04-29
Posts: 6

Re: Citrix-client: general knowledge about iconv would be helpful

Andrwe wrote:
Schuster wrote:

* What about providing /usr/bin/wfica and /usr/bin/wfcmgr as wrappers?

Done.

/usr/bin/wfica is 0644 instead of 0755 smile

Offline

#13 2010-04-29 17:41:39

Andrwe
Member
From: Leipzig/Germany
Registered: 2009-06-17
Posts: 322
Website

Re: Citrix-client: general knowledge about iconv would be helpful

Schuster wrote:
Andrwe wrote:
Schuster wrote:

* What about providing /usr/bin/wfica and /usr/bin/wfcmgr as wrappers?

Done.

/usr/bin/wfica is 0644 instead of 0755 smile

lol
Now it has 0755.

Offline

#14 2010-04-29 17:44:41

fettouhi
Member
Registered: 2007-05-07
Posts: 745

Re: Citrix-client: general knowledge about iconv would be helpful

Andrwe wrote:

@fettouhi
Unfortunately I can't test the firefox-plugin because the server I can use doesn't support it.
But try and report back. Maybe I'm able to modify the PKGBUILD so it would work.

Nope it doesn't work and I can't get client itself to work either. My IT department just gave me the address to the server

https://server.com/

but it won't connect. Maybe I'm just configuring the client wrong...

Offline

#15 2010-04-30 08:23:15

Schuster
Member
From: Austria
Registered: 2010-04-29
Posts: 6

Re: Citrix-client: general knowledge about iconv would be helpful

fettouhi, try manually installing a 32bit Firefox from mozilla.com, i.e. http://www.mozilla.com/products/downloa … lang=en-US

unpack, then start that Firefox with

cd /directory/where/you/unpacked/it/
ICAROOT=/opt/lib32/usr/lib/ICAClient GCONV_PATH=/opt/lib32/usr/lib/gconv/ ./firefox

Offline

Board footer

Powered by FluxBB