Linux-Development-Apps Digest #302, Volume #7    Wed, 28 Mar 01 04:13:13 EST

Contents:
  Re: Macromedia Flash - development tools, support in community etc. ("Jürgen 
Schneider")
  LILO  ([EMAIL PROTECTED])
  make Warning!! ("Leo Naboro")
  Re: LILO  (Chronos Tachyon)
  dynamic linking functions FROM an executable (Jiun-Yao Huang)
  Re: make Warning!! ("Leo Naboro")
  Re: increasing open file limit? ("Victor")
  Slackware runs on Yopy, the first Linux PDA in the world. ("jina")
  colors in a console ("Mihai C.")
  Re: LILO (John in SD)
  Re: colors in a console (Chronos Tachyon)
  Re: Getting directory sizes - fast (Jem Berkes)
  Re: colors in a console (David Tanzer)
  Re: Processor ID (Jonadab the Unsightly One)
  Re: dynamic linking functions FROM an executable (Chris Rankin)
  Re: Shared library linking problem (Chris Rankin)
  Re: dynamic linking functions FROM an executable (Jiun-Yao Huang)

----------------------------------------------------------------------------

From: "Jürgen Schneider" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.misc,no.it.os.unix.linux.diverse,alt.os.linux.mandrake
Subject: Re: Macromedia Flash - development tools, support in community etc.
Date: Wed, 28 Mar 2001 02:17:32 +0200

I'm a newbie on Linux but I'm also reading the interrsting newsgroups on
Linux.
I have heard about a programm named 'swish' which is also able to create
swf files. I run this under windoof, but I know that the version for Linux
is also available.
So serach for 'swish'

Greetings from Odenwald, Germany
Jürgen
www.witchcraft.de



Thomas Weholt <[EMAIL PROTECTED]> schrieb in im Newsbeitrag:
Aa_v6.1801$[EMAIL PROTECTED]
> Hi,
>
> I'm just doing some research on Macromedia FLASH ( swf );
>
> 1. What development tools are available for linux users?
> 2. What are the views on flash among linux users?
>
> Any info, opinions, flames etc. related to flash are welcome
>
> Best regards,
> Thomas
>
>



------------------------------

From: [EMAIL PROTECTED]
Subject: LILO 
Date: Tue, 27 Mar 2001 20:04:13 -0500
Crossposted-To:  comp.os.linux.development.system

hi,

i hv this rather perculiar problem wif LILO that
i first noticed when i recompiled my kernel (coz it
does a LILO reconfig later).

i hv a scsi hd and a primary ide hd.. but booting
is done via scsi not the ide hd. the ide hd was
actually added later. now LILO complains that
"Warning .. sda3 is not the first disk.."
and when i reboot.. LILO fails to load and it
actually stops at "LI".

so wat i did was to disable the primary ide controller
via bios and reboot via another boot disk/cdrom then
mount up this scsi hd and do a LILO once more. this time
of coz.. there wasnt that warning again and after that
i reenabled the primary ide controller. everything
now works fine.

well i was wondering if there is a simpler work around
coz i need to recompile my kernel pretty often.

thanks.

jason


------------------------------

From: "Leo Naboro" <[EMAIL PROTECTED]>
Subject: make Warning!!
Date: Wed, 28 Mar 2001 09:28:22 +0800

when i make my kernel,there is a warning
:
make ***Warning: Clock skew detected. \
   Your build may be incomplete
why does the error occur? thanks!
                    Leo Naboro






------------------------------

From: Chronos Tachyon <[EMAIL PROTECTED]>
Subject: Re: LILO 
Crossposted-To:  comp.os.linux.development.system
Date: Wed, 28 Mar 2001 01:35:10 GMT

On Tue 27 Mar 2001 07:04, [EMAIL PROTECTED] wrote:

> hi,
> 
> i hv this rather perculiar problem wif LILO that
> i first noticed when i recompiled my kernel (coz it
> does a LILO reconfig later).
> 
> i hv a scsi hd and a primary ide hd.. but booting
> is done via scsi not the ide hd. the ide hd was
> actually added later. now LILO complains that
> "Warning .. sda3 is not the first disk.."
> and when i reboot.. LILO fails to load and it
> actually stops at "LI".
> 
> so wat i did was to disable the primary ide controller
> via bios and reboot via another boot disk/cdrom then
> mount up this scsi hd and do a LILO once more. this time
> of coz.. there wasnt that warning again and after that
> i reenabled the primary ide controller. everything
> now works fine.
> 
> well i was wondering if there is a simpler work around
> coz i need to recompile my kernel pretty often.
> 
> thanks.
> 
> jason
> 
> 

If LILO partially starts up but stalls at "LI", the problem is almost 
always that the kernel image is now in a different place.  Basically, the 
problem is that LILO stores the exact address on the disk where the kernel 
image is located; the data is stored in the LILO boot sector.  When you 
recompile the kernel, you've created a new kernel on disk that's located at 
a different place.  To fix the problem, you need to tell LILO to reinstall 
your boot sector, which you can accomplish by typing "lilo" as root after 
copying the new kernel to /vmlinuz (or whatever) but before rebooting.

-- 
Chronos Tachyon
Guardian of Eristic Paraphernalia
Gatekeeper of the Region of Thud
[Reply instructions:  My real domain is "echo <address> | cut -d. -f6,7"]


------------------------------

From: Jiun-Yao Huang <[EMAIL PROTECTED]>
Subject: dynamic linking functions FROM an executable
Date: 28 Mar 2001 01:49:18 GMT
Reply-To: [EMAIL PROTECTED]

We know we can use dlopen/dlsym functions to dynamically link and load 
functions from a shared library. I wonder whether we can dynamically
link and load functions from an executable? I use gcc with -shared option 
to compile the source file, say exe.c. The client file, say client.c,
is able to load the function of exe.c well, but when I run the
executable of exe.c, it cries: "Segmentation fault".

Can we dynamically link and load functions from a shared library
from an executable, such as the out-of-process activation in MS COM ?

-- 
Jiun-Yao Huang <[EMAIL PROTECTED]>                [http://jyhuang.wizs.org]
class JiunYaoHuang : public Hacker, protected Artist, private Vocalist {};

------------------------------

From: "Leo Naboro" <[EMAIL PROTECTED]>
Subject: Re: make Warning!!
Date: Wed, 28 Mar 2001 10:31:08 +0800

And at the boot time
the error:
Kernel panic : VFS: Unable to mount root fs on 03:03

Leo Naboro <[EMAIL PROTECTED]> wrote in message
news:99reg4$hk2$[EMAIL PROTECTED]...
> when i make my kernel,there is a warning
> :
> make ***Warning: Clock skew detected. \
>    Your build may be incomplete
> why does the error occur? thanks!
>                     Leo Naboro
>
>
>
>
>



------------------------------

From: "Victor" <[EMAIL PROTECTED]>
Subject: Re: increasing open file limit?
Date: Wed, 28 Mar 2001 10:49:02 +0800
Reply-To: "Victor" <[EMAIL PROTECTED]>

You can change /proc/sys/fs/file-max (sometimes also inode-max) to expand
the system's limitation.
Then use "ulimit -HSn [number]" to change current user's limitation(you must
be a root).
And you can change FD_SETSIZE in "/usr/include/bits/types.h" to get around
the select() issue.

--

E-mail: [EMAIL PROTECTED]
==============================================
http://www.baidu.com
¡°Behind Your e-Success!¡±

"Dustin Puryear" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
> On Tue, 27 Mar 2001 04:35:42 GMT, John Liu <[EMAIL PROTECTED]> wrote:
> >As root you can set system resources limit, if you want increase number
of
> >opened file, just call setrlim, like fowlling:
> >/****************************************************
> >struct rlimit   rl;
> >
> >rl.rlim_cur = rl.rlim_max = 3000;
> >setrlimit(RLIMIT_NOFILE, &rl);
> >****************************************************/
>
> I still have a problem that FD_SETSIZE is set to 1024 under Linux 2.2. I
found
> a document describing changes to /etc/security/limits.conf,
/etc/pam.d/login,
> and /proc/sys/fs/file-max and .../inode-max that allow me to open > 1024
> files. However, how do I get around the select() issue?
>
> Regards, Dustin
>
> --
> Dustin Puryear <[EMAIL PROTECTED]>
> http://members.telocity.com/~dpuryear
> Integrate Linux Solutions into Your Windows Network
> - http://www.prima-tech.com/integrate-linux
>



------------------------------

From: "jina" <[EMAIL PROTECTED]>
Subject: Slackware runs on Yopy, the first Linux PDA in the world.
Date: Wed, 28 Mar 2001 11:58:35 +0900

Dear Sir or Ma'am
  We, at G.Mate Inc., have developed and manufactured PDA based on Embedded
Linux OS since its
  foundation in November of 1998.
  The people from all of world paid great attention to our world-first
multimedia PDA by the name of YOPY
  when it was exhibited in the CeBIT Show in Hanover of Germany and in the
Comdex/Fall in Las Vegas of
  USA in February and November of 2000 respectively. Ever since we have been
devoting all our energy to
  developing PDA integrating either Cellular module or Bluetooth module and
to the mobile communication
  IMT-2000 PDA business for the next generation
  In order to make Linux supporters and developers enthusiastically
participate in enlarging and developing
  the environment of Linux and applied programs, we have started to sell the
development kit of multimedia
  PDA based on Linux from January 21, 2001 through our website
(www.gmate.co.kr) and many people of the
  world have shown their interests and encouragement generously.
  The YDK product includes YOPY hardware, software environment, Linux Source
Package Solution, etc. By
  sharing with you solutions and knowledge related to Embedded Linux PDA we
have developed so far, we
  expect that there would be absolutely outstanding realization of desirable
Linux environment and
  development of invaluable Linux PDA in the near future.



------------------------------

From: "Mihai C." <[EMAIL PROTECTED]>
Subject: colors in a console
Date: Tue, 27 Mar 2001 21:46:36 -0500

Hi all,
I'm porting to unix an app that generates tones of logs, some important than
others. Do you have a hint how I could add some colors to the output (in
win32 I use SetConsoleTextAttribute() ).
thanx,
Mihai



------------------------------

From: John in SD <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.system
Subject: Re: LILO
Reply-To: [EMAIL PROTECTED]
Date: Wed, 28 Mar 2001 04:06:59 GMT

LILO stores the BIOS device code and sector address of each kernel sector that
it will load.  On pure IDE systems, most BIOSs assign device codes in
ascending order.  Likewise on pure SCSI systems.  There are various methods
used on mixed IDE/ SCSI systems.

In 'lilo.conf', you can tell LILO the exact correspondence between your disks
and BIOS device codes.  Use:

  disk=/dev/hda
     bios=0x80
  disk=/dev/sda
     bios=0x81
etc.

The source distribution of LILO comes with two diagnostics which will help you
to sort this out:

   lilo -T geom

will work on many systems.  (LILO 21.6 and later)

"make floppy" in the LILO source directory; then boot the floppy disk, will
work on ALL systems, and will tell you the correspondence between your drives
and BIOS codes.

--John



On Tue, 27 Mar 2001 20:04:13 -0500, [EMAIL PROTECTED] wrote:

>hi,
>
>i hv this rather perculiar problem wif LILO that
>i first noticed when i recompiled my kernel (coz it
>does a LILO reconfig later).
>
>i hv a scsi hd and a primary ide hd.. but booting
>is done via scsi not the ide hd. the ide hd was
>actually added later. now LILO complains that
>"Warning .. sda3 is not the first disk.."
>and when i reboot.. LILO fails to load and it
>actually stops at "LI".
>
>so wat i did was to disable the primary ide controller
>via bios and reboot via another boot disk/cdrom then
>mount up this scsi hd and do a LILO once more. this time
>of coz.. there wasnt that warning again and after that
>i reenabled the primary ide controller. everything
>now works fine.
>
>well i was wondering if there is a simpler work around
>coz i need to recompile my kernel pretty often.
>
>thanks.
>
>jason


LILO version 21.7 (24-Feb-2001) source at
http://www.ibiblio.org/pub/Linux/system/boot/lilo
patches to -2 at ftp://brun.dyndns.org/pub/linux/lilo

------------------------------

From: Chronos Tachyon <[EMAIL PROTECTED]>
Subject: Re: colors in a console
Date: Wed, 28 Mar 2001 04:09:07 GMT

On Tue 27 Mar 2001 08:46, Mihai C. wrote:

> Hi all,
> I'm porting to unix an app that generates tones of logs, some important
> than others. Do you have a hint how I could add some colors to the output
> (in win32 I use SetConsoleTextAttribute() ).
> thanx,
> Mihai
> 
> 
> 

The correct way is to use termcap (ancient) or terminfo.  The easy way is 
to use VT-100 or ANSI X.364 escape codes, which most modern terminals 
emulate anyway.  The gist of it (ESC is '\x1F' in C):

ESC[2J                  Clear screen
ESC[...m                Change colors or attributes
ESC[<r>;<c>H            Move to row <r>, col <c> (Origin is 1;1)

You can find a more exact reference to the [m codes, but basically 30-37 is 
foreground colors, 40-47 is background colors, and 0-8 are attributes (0 
resets all attributes).

-- 
Chronos Tachyon
Guardian of Eristic Paraphernalia
Gatekeeper of the Region of Thud
[Reply instructions:  My real domain is "echo <address> | cut -d. -f6,7"]


------------------------------

From: Jem Berkes <[EMAIL PROTECTED]>
Subject: Re: Getting directory sizes - fast
Date: Tue, 27 Mar 2001 23:38:43 -0600

> >  is there a way to programmatically get the size of directories that is
> >faster than calling and parsing the output of du (i.e. "du
> >/usr/local/src/") ?
> [-]
> lstat()

lstat returns the size of a file, but for directories (at least on the
systems I tried it on) it just returns 4096.

Maybe try taking a look at the source for du? It might have some clues.

-- 
http://www.pc-tools.net/
DOS, Win32, Linux software

------------------------------

Date: Wed, 28 Mar 2001 08:42:19 +0200
From: David Tanzer <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Subject: Re: colors in a console

Look in "ncurses" if you find the functionality you need.
I think the starting point is "man ncurses" or "man curses" or 
something like that.

"Mihai C." wrote:
> 
> Hi all,
> I'm porting to unix an app that generates tones of logs, some important than
> others. Do you have a hint how I could add some colors to the output (in
> win32 I use SetConsoleTextAttribute() ).
> thanx,
> Mihai

------------------------------

From: [EMAIL PROTECTED] (Jonadab the Unsightly One)
Crossposted-To: comp.os.linux.hardware,comp.os.linux.development.system
Subject: Re: Processor ID
Date: Wed, 28 Mar 2001 07:29:37 GMT

Matt Woodyard <[EMAIL PROTECTED]> wrote:

> Most hardware vendors don¹t supply developers with API's that allow people
> to track transactions by hardware part numbers over the internet. That¹s
> about the last thing we need, next you'll have processor specific liscenses
> and "dongling". 

Could be worse...  

[Insert pseudoparanoid rambling about global-positioning 
chips with banking capabilities surgically implanted 
into every citizen at birth.]

- jonadab

------------------------------

From: Chris Rankin <pacbell.net@{no.spam}rankinc>
Subject: Re: dynamic linking functions FROM an executable
Date: Wed, 28 Mar 2001 00:02:51 -0800

Jiun-Yao Huang wrote:
> Can we dynamically link and load functions from a shared library
> from an executable, such as the out-of-process activation in MS COM ?

I have no idea what happens in MS COM. In the following paragraph I
assume that the client is a shared object which the executable loads.

That said, if the exe file has exported the symbol that the client needs
to call then the client should be able to use that symbol without you
calling dlsym(). You don't need the -shared option for the exe file, but
you probably do need to use -Wl,--export-dynamic. This tells the linker
to export all of the exe's symbols for dynamic linking, so that the
client can find them when it loads.

Chris

------------------------------

From: Chris Rankin <pacbell.net@{no.spam}rankinc>
Subject: Re: Shared library linking problem
Date: Wed, 28 Mar 2001 00:05:17 -0800

Or maybe -Werror if you want warnings to be treated as errors?

John Liu wrote:
> 
> I don't think there is a command line option "-errors", maybe you want apply
> "-pedantic-errors" ?
> 
> --
> John Liu
> 640K thought to be enough for anybody.
>         (Bill Gates, Microsoft, 1981)
> http://www.may10.ca
> 
> "Tomasz Karczewski" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]...
> > Hello,
> >
> > I have warning mesage:
> > /usr/bin/ld: warning: cannot find entry symbol rrors; defaulting to
> 08048560
> >
> > when comile program with my shared library (mylib):
> > gcc -g -errors -Wall -Iinclude -o bin/test src/linux/test.c -Llib -lmylib
> >
> > Any solutions?
> >
> >
> > Best regards
> > KaTo
> >

------------------------------

From: Jiun-Yao Huang <[EMAIL PROTECTED]>
Subject: Re: dynamic linking functions FROM an executable
Date: 28 Mar 2001 08:38:07 GMT
Reply-To: [EMAIL PROTECTED]

Chris Rankin <pacbell.net@{no.spam}rankinc> wrote:
> Jiun-Yao Huang wrote:
> > Can we dynamically link and load functions from a shared library
> > from an executable, such as the out-of-process activation in MS COM ?
> I have no idea what happens in MS COM. In the following paragraph I
> assume that the client is a shared object which the executable loads.

Sorry, I misunderstands what happens in the out-of-process activation
in MS COM. The out-of-process activation in COM involoves RPC mechanism,
not dynamically links and loads symbols from an executable file.

> That said, if the exe file has exported the symbol that the client needs
> to call then the client should be able to use that symbol without you
> calling dlsym(). You don't need the -shared option for the exe file, but
> you probably do need to use -Wl,--export-dynamic. This tells the linker
> to export all of the exe's symbols for dynamic linking, so that the
> client can find them when it loads.

It still fails. The following is the test programs.

exe.c
=====
#include <stdio.h>

void foo()
{
        printf("this is the foo() in exe.c\n");
}

int main(int argc, char *argv[])
{
        foo();
        return 0;
}

client.c
========
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <dlfcn.h>

int main(int argc, char *argv[])
{
        void *handle;
        void (*func)();
        char    *dyfile = "./exe";
        char    *dyfunc = "foo";
        
        
        handle = dlopen(dyfile, RTLD_LAZY);
        if (handle == NULL) {
                fprintf(stderr, "cannot load %s\n", dyfile);
                exit(1);
        }
        
        func = dlsym(handle, dyfunc);
        if (func == 0) {
                fprintf(stderr, "cannot load symbol %s\n", dyfunc);
                exit(1);
        }
        
        (*func)();
        
        dlclose(handle);

        return 0;
}

Compilation & Execution
=======================
Case 1:

> gcc -g -Wl,--export-dynamic -o exe exe.c
> gcc -g -o client client.c -ldl
> ./exe
this is the foo() in exe.c
> ./client
Segmentation fault (core dumped)

Case 2:

> gcc -g -shared -o exe exe.c
> gcc -g -o client client.c -ldl
> ./exe
Segmentation fault (core dumped)
> ./client
this is the foo() in exe.c

-- 
Jiun-Yao Huang <[EMAIL PROTECTED]>                [http://jyhuang.wizs.org]
class JiunYaoHuang : public Hacker, protected Artist, private Vocalist {};

------------------------------


** FOR YOUR REFERENCE **

The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:

    Internet: [EMAIL PROTECTED]

You can send mail to the entire list by posting to the
comp.os.linux.development.apps newsgroup.

Linux may be obtained via one of these FTP sites:
    ftp.funet.fi                                pub/Linux
    tsx-11.mit.edu                              pub/linux
    sunsite.unc.edu                             pub/Linux

End of Linux-Development-Apps Digest
******************************

Reply via email to