Pharo-dev
By thread
pharo-dev@lists.pharo.org
By month
Messages by month
- ----- 2026 -----
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
January 2012
- 118 participants
- 1442 messages
Re: [Pharo-project] Cog+linux: external module not found
by Schwab,Wilhelm K
Nick,
Partial success. After a false start with getting output from strace (my fault), it showed me that the vm was looking a lot in the vm's directory. A symlink by the same name, allowed it to see the library. Clearly, this is not a fix, because one should not be forced to make links to any/every library on the system. However, it *was* nice to see the version string in an inspector :)
Looking at the strace output (relevant parts below), it tries with prepending lib, appending .so, .so.dylib. It looks in the vm's directory, and in the root directory, not /usr/lib.
It has been almost a year (based on a dated comment) since I last really strained my synapses on the workings of ldconfig. On my systems, it would tell one to look for the library as follows:
ldconfig -p | grep Acces
libAccesIO-USB.so (libc6) => /usr/lib/libAccesIO-USB.so
#moduleName answers 'libAccesIO-USB.so', and Ian's vm finds it. My (and I use the term LOOSELY) understanding is that Ubuntu no longer uses LD_LIBRARY_PATH. dlopen() seems to prefer that one use the names as reported by ldconfig. The best explanation I have found is that the change was a security measure.
How does one get ldconfig to "know" where something lives? Putting a .so file in /usr/lib (and perhaps other places too) and then running ldconfig as sudo appears to build a cache. Then ldconfig -p (anyone can run this) will show the map, and one can grep the result to find something specifc, as above.
Putting files in /usr/lib is a pain for things under active development. A file can live anywhere if one puts a .conf file in /etc/ld.so.confd; the .conf files should contain paths to directories to be searched for .so files - or at least that's how it *appears* to work. Run ldconfig as sudo to refresh the mapping, and verify with ldconfig - p.
The fix might be as simply as having the cog vm try passing the #moduleName to dlopen().
Nick, thanks for the nudge in a working direction. I will probably symlink another file and see if a mix of hardware and software will get closer to cooperating with me.
Bill
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/liblibAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/liblibAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/liblibAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("./libAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("./libAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("./libAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("./liblibAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("./liblibAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("./liblibAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("libAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("libAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("libAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("liblibAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("liblibAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("liblibAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/libAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/libAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/libAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/liblibAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/liblibAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/liblibAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so/.libs/libAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so/.libs/libAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so/.libs/libAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so/.libs/liblibAccesIO-USB.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so/.libs/liblibAccesIO-USB.so.so", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
stat64("/home/bills/Work2010/Pharo-1.1.1/libAccesIO-USB.so/.libs/liblibAccesIO-USB.so.dylib", 0xbfd66c5c) = -1 ENOENT (No such file or directory)
read(10, ">externalCallFailed\nAccesIOUSBLi"..., 3424) = 3424
read(10, ">externalCallFailed\nAccesIOUSBLi"..., 4096) = 3424
write(10, "FileAccess: ", 12) = 12
write(10, "SocketAccess: ", 14) = 14
write(10, "an AccesIOUSBLibrary", 20) = 20
write(10, "'libAccesIO-USB.so'", 19) = 19
write(10, "an AccesIOUSBLibrary", 20) = 20
write(10, "'libAccesIO-USB.so'", 19) = 19
write(10, "an AccesIOUSBLibrary", 20) = 20
write(10, "'libAccesIO-USB.so'", 19) = 19
write(10, "an AccesIOUSBLibrary", 20) = 20
write(10, "'libAccesIO-USB.so'", 19) = 19
write(10, "#'Hardware-AccesIO'", 19) = 19
write(10, "\t\ttextOrStream: \t'\t^AccesIOUSBLi"..., 65) = 65
write(10, "\t^ AccesIOUSBLibrary default AIO"..., 46) = 46
write(10, "a ReadStream '\t^AccesIOUSBLibrar"..., 61) = 61
write(10, "\t^AccesIOUSBLibrar...etc...", 27) = 27
write(10, "\t^AccesIOUSBLibrar...etc...", 27) = 27
write(10, "\t^AccesIOUSBLibrary defau...etc."..., 34) = 34
________________________________
From: pharo-project-bounces(a)lists.gforge.inria.fr [pharo-project-bounces(a)lists.gforge.inria.fr] on behalf of Schwab,Wilhelm K [bschwab(a)anest.ufl.edu]
Sent: Saturday, January 07, 2012 8:55 AM
To: Pharo-project(a)lists.gforge.inria.fr
Subject: Re: [Pharo-project] Cog+linux: external module not found
It would also be nice to see (either via syslog()/OutputDebugString()) or (if possible) in the error itself, what library (full path) was being loaded. The output will generally be of interest only when something fails.
Similar comments would apply to serial ports that won't open - what did the vm actually try to do when something failed? Most problems that I have had with getting Pharo to open something (library or port) have been relatively obvious to solve as soon as I saw how my intent was translated before it was passed on to the hardware (e.g. /usr/lib//this/that/something.so).
Bill
________________________________
From: pharo-project-bounces(a)lists.gforge.inria.fr [pharo-project-bounces(a)lists.gforge.inria.fr] on behalf of Mariano Martinez Peck [marianopeck(a)gmail.com]
Sent: Saturday, January 07, 2012 5:20 AM
To: Pharo-project(a)lists.gforge.inria.fr
Subject: Re: [Pharo-project] Cog+linux: external module not found
BTW, Eliot, is there a way so that FFI throws something different from "Module not found" when the module is there but not 32 bits? like "Module found but it is not 32 bits" ?
cheers
On Sat, Jan 7, 2012 at 10:04 AM, Nick Ager <nick.ager(a)gmail.com<mailto:nick.ager@gmail.com>> wrote:
Hi Bill,
Have you tried strace to determine what library it's failing to load?
Nick
On 7 January 2012 03:26, Schwab,Wilhelm K <bschwab(a)anest.ufl.edu<mailto:bschwab@anest.ufl.edu>> wrote:
Eliot,
There is no /lib32 or /usr/lib32. As a double check,
locate lib32
returns nothing. I put the library in /usr/lib, which is what I have done on two other Lucid systems. ldconfig shows it registered there.
What's next?
Bill
________________________________
From: pharo-project-bounces(a)lists.gforge.inria.fr<mailto:pharo-project-bounces@lists.gforge.inria.fr> [pharo-project-bounces(a)lists.gforge.inria.fr<mailto:pharo-project-bounces@lists.gforge.inria.fr>] on behalf of Eliot Miranda [eliot.miranda(a)gmail.com<mailto:eliot.miranda@gmail.com>]
Sent: Friday, January 06, 2012 7:29 PM
To: Pharo-project(a)lists.gforge.inria.fr<mailto:Pharo-project@lists.gforge.inria.fr>
Subject: Re: [Pharo-project] Cog+linux: external module not found
On Fri, Jan 6, 2012 at 4:18 PM, Schwab,Wilhelm K <bschwab(a)anest.ufl.edu<mailto:bschwab@anest.ufl.edu>> wrote:
Paul,
The library is 32 bit - I build it from source because it ships with 64 bit binaries.
Then try changing your LD_LIBRARY_PATH to /lib32:/usr/lib32:$LD_LIBRARY_PATH and see if that helps (if you have /lib32 & /usr/lib32 that is)
Bill
________________________________________
From: pharo-project-bounces(a)lists.gforge.inria.fr<mailto:pharo-project-bounces@lists.gforge.inria.fr> [pharo-project-bounces(a)lists.gforge.inria.fr<mailto:pharo-project-bounces@lists.gforge.inria.fr>] on behalf of Paul DeBruicker [pdebruic(a)gmail.com<mailto:pdebruic@gmail.com>]
Sent: Friday, January 06, 2012 6:59 PM
To: pharo-project(a)lists.gforge.inria.fr<mailto:pharo-project@lists.gforge.inria.fr>
Subject: Re: [Pharo-project] Cog+linux: external module not found
Schwab,Wilhelm K wrote
>
> Eliot,
>
> I'm getting the same error with your latest VM. Any ideas?
>
> Bill
>
>
>
When I had trouble with this it was a 64bit vs 32bit library mismatch on a
64bit OS.
Is it a 32 bit or 64 bit OS? Is the library you're trying to reach 32bit?
64bit libs won't work with the 32bit CogVM, but are installed by default by
the Ubuntu package manager on a 64bit Ubuntu.
Ubuntu also moved some mandatory (from Cog's perspectvie) 32 bit libs from
their ia32-libs package to the ia32-libs-multiarch recently but I don't know
if that change affects Lucid.
--
View this message in context: http://forum.world.st/Cog-linux-external-module-not-found-tp4271136p4271354…
Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
--
best,
Eliot
--
Mariano
http://marianopeck.wordpress.com
Jan. 7, 2012
Re: [Pharo-project] Process questions about configurationOfâ¦.
by Stéphane Ducasse
>>
> Some questions out of curiosity since I'm not yet involved in publishing any packages
>
> Is there some way to tag for the submitter to be emailed the Jenkins results? Perhaps a method like 'emailJenkinsResultsTo:' inthe configuration or alternatively Jenkins might unzip the mcz to directly search the ".st" files for a specific string.
>
> As I understand it, the ConfigurationOfXXX contains information on multiple versions and multiple platforms. Thinking ahead to when there is a MetaRepoForPharo14, are there any concerns keeping two versions of ConfigurationOfXXX in sync between the two repos? For example when an application releases a new version for Pharo13, do you only update the ConfigurationOfXXX in MetaRepoForPharo13? And do you then end up with further forks for ConfigurationOfXXX on other platforms?
the idea is that you should keep the master in your project and publish to the repository when you want to make
your configuration available.
> What about a single repository (if not the existing MetacelloRepository then perhaps MetaRepoCI), which Jenkins processes and then if that single file works for Pharo13 it is copied toMetaRepoForPharo13 and if it works for Pharo14 then it is copied to toMetaRepoForPharo14. Other platforms can do the same. That way the application developer has to manage a single location.
Jan. 7, 2012
Re: [Pharo-project] Bug in FileSystem
by Stéphane Ducasse
How can we build and improve FS?
I'm too busy with other topics but I would love to get some momentum on that topic.
Stef
> On 07 Jan 2012, at 14:19, Henrik Sperre Johansen wrote:
>>
>>> 1) There's no next: into: (which returns the amount read). It's really the only way to do buffers without garbage allocations.
>>
>> The 2 key methods for efficient IO are:
>>
>> readInto: collection startingAt: offset count: requestedCount
>> "Read requestedCount elements into collection starting at offset,
>> returning the number of elements read, there could be less elements available."
>>
>> next: count putAll: collection startingAt: offset
>> "Write count bytes from collection starting at offset."
>>
>> All other bulk operations can be written in terms of these (see for example Zodiac streams).
>>
>> Sven
>
> +1.
> All streams should provide these API, and if possible, provide an
> optimized implementation.
> It was not the case in Squeak, i started to refactor a bit, but
> incrementally modifying this dinosaurus without creating circularities
> is a sport!
> I still have 3 years old refactorings unpublished because I'm not sure
> how to reproduce the changes in a safe order ;)
>
> Nicolas
>
Jan. 7, 2012
Re: [Pharo-project] Misc. newbie questions
by Frank Shearar
On 7 January 2012 15:11, Nicolas Cellier
<nicolas.cellier.aka.nice(a)gmail.com> wrote:
> 2012/1/7 Frank Shearar <frank.shearar(a)gmail.com>:
>> On 7 January 2012 14:14, Nicolas Cellier
>> <nicolas.cellier.aka.nice(a)gmail.com> wrote:
>>> 2012/1/6 Lukas Renggli <renggli(a)gmail.com>:
>>>> On 6 January 2012 11:20, Peter Hugosson-Miller <oldmanlink(a)gmail.com> wrote:
>>>>> On 6 jan 2012, at 06:41, "Gerry Weaver" <gerryw(a)compvia.com> wrote:
>>>>>
>>>>> 2. There appear to be some tool choices in the Pharo image. I would like to
>>>>> be able to create a class and it's methods in an editor in one go. I like
>>>>> being able to see all of the class code at once. Is there a way to do this?
>>>>> Â I just want to be able to type it all in and accept (evaluate?) all at
>>>>> once.
>>>>>
>>>>> This is an interesting question to me personally. After 15 years of working
>>>>> exclusively in Smalltalk I've recently been forced to start programming in
>>>>> Java, where the source code is always (as far as I know) arranged in the way
>>>>> you describe.
>>>>>
>>>>> This organization just emphasizes the dead and compiled nature of Java (and
>>>>> similar languages), compared to the living objects of Smalltalk, where even
>>>>> methods are objects, created by sending messages to other objects. Source
>>>>> code is relegated to being a mere artifact, which can be saved and organized
>>>>> in any way one wishes, and preferably never shows its ugly face to the coder
>>>>> :-p
>>>>
>>>> Which of course is no argument why Smalltalk code could not be
>>>> displayed in a more programmer friendly way as a continuous block of
>>>> text. There is no technical reason why source ranges in text box
>>>> couldn't correspond to life method objects. Compared to other
>>>> languages it is extremely tedious in Smalltalk to get an overview over
>>>> a project, a package, or even a single class or to navigate between
>>>> entities.
>>>>
>>>>> And yes, I really *really* miss a good, object oriented class browser!
>>>>
>>>> Eclipse is pretty good, especially with the Java Browsing Perspective.
>>>>
>>>> Lukas
>>>>
>>>
>>> As soon as you would display the code for many methods in a single text pane,
>>> you will find file-based-educated people making large refactorings in
>>> a single pass...
>>> Imagine this leads to many syntax errors, they will soon be willing to
>>> save their changes for a later rework...
>>> This would be a complete change in programming flow and if we really
>>> want to support this, we would have to:
>>> - add a way to save syntactically incorrect code
>>> - let IDE tools work on partially correct code (syntax highlighting,
>>> navigation, etc...)
>>>
>>> IMHO, these features add a lot of complexity... Is it really worth?
>>> I like the discipline of focusing on a single method until it is at
>>> least syntactically correct.
>>
>> The Pharo community has extremely limited resources so it seems quite
>> fair to me for Pharo to say "yes, but it's up to you because we have
>> no time". It _is_ very useful to be able to see and edit long reams of
>> text: my favourite text editor's been beaten on since the late 70s. It
>> is now very, very good at manipulating text, in multiple programming
>> languages, in multiple human languages, on many platforms. That I
>> can't use this text editor to manipulate a textual representation of
>> my favourite language is extremely annoying!
>>
>> frank
>
> Yeah, but my take was that re-inventing a very narrow subset of these
> 40 years old text editors in Smalltalk would likely be a failure...
> (or a big project)
It would be a fairlly big piece of work although we do have lots of
pieces lying around:
* Coral's working on a scripting/REPL-like interface,
* the Common Lisp community has been using SLIME to provide a REPL to
a running image for years while also using files to store their code,
* we have Gitocello (which also translates Squeak/Pharo to gst),
* we have LanguageBoxes (*) allowing us to permit craziness like
storing code outside the image in one format without affecting the
entire language (letting us store Smalltalk code in something other
than chunk format)
(*) watch this space: I'm making progress on breaking up the Helvetia
image into a bootstrappable bunch of packages
> There is also this recent related post which touch this subject:
>
> http://railsrx.com/2011/12/29/getting-back-to-smalltalk/
Amusingly, I only just finished reading that in my newsreader. I think
_personally_ that I need to port TWM to Squeak because I'm tired of
being the window manager, and hopefully that would solve my other
pain, which Noel points out - the ability to see multiple methods at a
time is _really useful_.
(Trivial example: think of how clear code in ML or Haskell looks when
pattern matching on type, versus having five browsers open on various
subclasses' implementations of #foo.)
I guess I'm saying: the rest of the world isn't automatically wrong
because they're not using Smalltalk, and I want to bring the best
parts of the non-Smalltalk stuff to Smalltalk (like having the
_option_ of using my favourite version control system, text editor,
IDE, etc.)
frank
> Nicolas
>
>>
>>> On the other hand, in Smalltalk we have to transfer the complexity of
>>> multi-method changes in the refactoring engines/menus when some simple
>>> modify/replace in a file would work.
>>>
>>> Nicolas
>>>
>>>> --
>>>> Lukas Renggli
>>>> www.lukas-renggli.ch
>>>>
>>>
>>
>
Jan. 7, 2012
Re: [Pharo-project] Misc. newbie questions
by Nicolas Cellier
2012/1/7 Frank Shearar <frank.shearar(a)gmail.com>:
> On 7 January 2012 14:14, Nicolas Cellier
> <nicolas.cellier.aka.nice(a)gmail.com> wrote:
>> 2012/1/6 Lukas Renggli <renggli(a)gmail.com>:
>>> On 6 January 2012 11:20, Peter Hugosson-Miller <oldmanlink(a)gmail.com> wrote:
>>>> On 6 jan 2012, at 06:41, "Gerry Weaver" <gerryw(a)compvia.com> wrote:
>>>>
>>>> 2. There appear to be some tool choices in the Pharo image. I would like to
>>>> be able to create a class and it's methods in an editor in one go. I like
>>>> being able to see all of the class code at once. Is there a way to do this?
>>>> Â I just want to be able to type it all in and accept (evaluate?) all at
>>>> once.
>>>>
>>>> This is an interesting question to me personally. After 15 years of working
>>>> exclusively in Smalltalk I've recently been forced to start programming in
>>>> Java, where the source code is always (as far as I know) arranged in the way
>>>> you describe.
>>>>
>>>> This organization just emphasizes the dead and compiled nature of Java (and
>>>> similar languages), compared to the living objects of Smalltalk, where even
>>>> methods are objects, created by sending messages to other objects. Source
>>>> code is relegated to being a mere artifact, which can be saved and organized
>>>> in any way one wishes, and preferably never shows its ugly face to the coder
>>>> :-p
>>>
>>> Which of course is no argument why Smalltalk code could not be
>>> displayed in a more programmer friendly way as a continuous block of
>>> text. There is no technical reason why source ranges in text box
>>> couldn't correspond to life method objects. Compared to other
>>> languages it is extremely tedious in Smalltalk to get an overview over
>>> a project, a package, or even a single class or to navigate between
>>> entities.
>>>
>>>> And yes, I really *really* miss a good, object oriented class browser!
>>>
>>> Eclipse is pretty good, especially with the Java Browsing Perspective.
>>>
>>> Lukas
>>>
>>
>> As soon as you would display the code for many methods in a single text pane,
>> you will find file-based-educated people making large refactorings in
>> a single pass...
>> Imagine this leads to many syntax errors, they will soon be willing to
>> save their changes for a later rework...
>> This would be a complete change in programming flow and if we really
>> want to support this, we would have to:
>> - add a way to save syntactically incorrect code
>> - let IDE tools work on partially correct code (syntax highlighting,
>> navigation, etc...)
>>
>> IMHO, these features add a lot of complexity... Is it really worth?
>> I like the discipline of focusing on a single method until it is at
>> least syntactically correct.
>
> The Pharo community has extremely limited resources so it seems quite
> fair to me for Pharo to say "yes, but it's up to you because we have
> no time". It _is_ very useful to be able to see and edit long reams of
> text: my favourite text editor's been beaten on since the late 70s. It
> is now very, very good at manipulating text, in multiple programming
> languages, in multiple human languages, on many platforms. That I
> can't use this text editor to manipulate a textual representation of
> my favourite language is extremely annoying!
>
> frank
Yeah, but my take was that re-inventing a very narrow subset of these
40 years old text editors in Smalltalk would likely be a failure...
(or a big project)
There is also this recent related post which touch this subject:
http://railsrx.com/2011/12/29/getting-back-to-smalltalk/
Nicolas
>
>> On the other hand, in Smalltalk we have to transfer the complexity of
>> multi-method changes in the refactoring engines/menus when some simple
>> modify/replace in a file would work.
>>
>> Nicolas
>>
>>> --
>>> Lukas Renggli
>>> www.lukas-renggli.ch
>>>
>>
>
Jan. 7, 2012
Re: [Pharo-project] Bug in #pointsTo: ?
by Levente Uzonyi
On Fri, 6 Jan 2012, Mariano Martinez Peck wrote:
>>
>>>> Thanks Levente. However, #pointersToExcept: does a GC at the
>>> beginning...
>>> so.. am I missing something?
>>>
>>
>> Yes, at the beginning The MethodContexts are created after that GC.
>>
>>
> But those MC shouldn't be excluded by the instVar objectsToAlwaysExclude ?
>
> objectsToAlwaysExclude := {
> results collector.
> thisContext.
> thisContext sender.
> thisContext sender sender.
> objectsToExclude.
> }.
Since #pointsTo: is not a primitive anymore, it will create at least one
new MethodContext which is not included in that list.
Levente
>
>
>
>
>
>>
>> Levente
>>
>>
>>> Thanks again.
>>>
>>>
>>>
>>>> Levente
>>>>
>>>>
>>>>
>>>>
>>>>> Do you mean what I understand :)? that some tools compiled methods? :)
>>>>>
>>>>>
>>>>>> Stef
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>> --
>>>>> Mariano
>>>>> http://marianopeck.wordpress.****com <http://marianopeck.wordpress.**
>>>>> com <http://marianopeck.wordpress.com>>
>>>>>
>>>>>
>>>>
>>>
>>> --
>>> Mariano
>>> http://marianopeck.wordpress.**com <http://marianopeck.wordpress.com>
>>>
>>
>
>
> --
> Mariano
> http://marianopeck.wordpress.com
>
Jan. 7, 2012
Re: [Pharo-project] Misc. newbie questions
by Frank Shearar
On 7 January 2012 14:14, Nicolas Cellier
<nicolas.cellier.aka.nice(a)gmail.com> wrote:
> 2012/1/6 Lukas Renggli <renggli(a)gmail.com>:
>> On 6 January 2012 11:20, Peter Hugosson-Miller <oldmanlink(a)gmail.com> wrote:
>>> On 6 jan 2012, at 06:41, "Gerry Weaver" <gerryw(a)compvia.com> wrote:
>>>
>>> 2. There appear to be some tool choices in the Pharo image. I would like to
>>> be able to create a class and it's methods in an editor in one go. I like
>>> being able to see all of the class code at once. Is there a way to do this?
>>> Â I just want to be able to type it all in and accept (evaluate?) all at
>>> once.
>>>
>>> This is an interesting question to me personally. After 15 years of working
>>> exclusively in Smalltalk I've recently been forced to start programming in
>>> Java, where the source code is always (as far as I know) arranged in the way
>>> you describe.
>>>
>>> This organization just emphasizes the dead and compiled nature of Java (and
>>> similar languages), compared to the living objects of Smalltalk, where even
>>> methods are objects, created by sending messages to other objects. Source
>>> code is relegated to being a mere artifact, which can be saved and organized
>>> in any way one wishes, and preferably never shows its ugly face to the coder
>>> :-p
>>
>> Which of course is no argument why Smalltalk code could not be
>> displayed in a more programmer friendly way as a continuous block of
>> text. There is no technical reason why source ranges in text box
>> couldn't correspond to life method objects. Compared to other
>> languages it is extremely tedious in Smalltalk to get an overview over
>> a project, a package, or even a single class or to navigate between
>> entities.
>>
>>> And yes, I really *really* miss a good, object oriented class browser!
>>
>> Eclipse is pretty good, especially with the Java Browsing Perspective.
>>
>> Lukas
>>
>
> As soon as you would display the code for many methods in a single text pane,
> you will find file-based-educated people making large refactorings in
> a single pass...
> Imagine this leads to many syntax errors, they will soon be willing to
> save their changes for a later rework...
> This would be a complete change in programming flow and if we really
> want to support this, we would have to:
> - add a way to save syntactically incorrect code
> - let IDE tools work on partially correct code (syntax highlighting,
> navigation, etc...)
>
> IMHO, these features add a lot of complexity... Is it really worth?
> I like the discipline of focusing on a single method until it is at
> least syntactically correct.
The Pharo community has extremely limited resources so it seems quite
fair to me for Pharo to say "yes, but it's up to you because we have
no time". It _is_ very useful to be able to see and edit long reams of
text: my favourite text editor's been beaten on since the late 70s. It
is now very, very good at manipulating text, in multiple programming
languages, in multiple human languages, on many platforms. That I
can't use this text editor to manipulate a textual representation of
my favourite language is extremely annoying!
frank
> On the other hand, in Smalltalk we have to transfer the complexity of
> multi-method changes in the refactoring engines/menus when some simple
> modify/replace in a file would work.
>
> Nicolas
>
>> --
>> Lukas Renggli
>> www.lukas-renggli.ch
>>
>
Jan. 7, 2012
Re: [Pharo-project] Misc. newbie questions
by Philippe Marschall
On 06.01.2012 06:41, Gerry Weaver wrote:
> Hello All,
>
> Firstly, let me say that I am enjoying Pharo very much at this point. I
> wish I would have found the time to look at this a long time ago.
>
> I have a few misc. newbie questions.
>
> 1. VisualWorks - I am doing a lot of thinking about projects that I
> could use Smalltalk on. I have a consulting project coming up that might
> be a good candidate, but I'm sure I would be required to use a
> commercial Smalltalk version for it. I guess it may be odd to ask about
> VisualWorks on this list, but I'm not really looking for a comparison to
> Pharo. What I'm interested in is your opinion of the product. I would
> like to know if any of you would consider using it on a project. I would
> appreciate anything y'all could share in the form of experiences good or
> bad. I am trying to get my hands on it, but Cincom's mail server
> (windoze) is having issues. I am also having some trouble getting
> pricing out of them. Anyway, I would like to get your take on the Cincom
> products.
>
> 2. There appear to be some tool choices in the Pharo image. I would like
> to be able to create a class and it's methods in an editor in one go. I
> like being able to see all of the class code at once. Is there a way to
> do this? I just want to be able to type it all in and accept (evaluate?)
> all at once.
>
> 3. I've seen some discussion about images and image sizes. What is the
> current state of this. Is it possible to strip an image down to just the
> required components for an application (ie; no world menu, etc.). I
> would like to be able to run an image that would bring my gui
> application up filling the image window such that it looks a close as
> possible to a conventional gui application.
>
> 4. I have been reading about something called "Opentalk". It is a way
> for images to be able to comminucate with each other over the network.
> I've also seen something callesd "rST" that appears to do a similar
> thing. In addition, I notice that someone has done some FFI bindings for
> zeromq. What would y'all recommend as the best option to achieve
> something like this in Pharo?
>
> 5. I'm trying to figure out exactly what the Pharo gui toolkit provides
> in the way of widgets. Is there a widget gallery type thing somewhere
> that shows all of them? I know I can play with them in the image, but it
> would be nice to see a list of what is there with a brief description.
>
> 6. I know Pharo doesn't currently support OS threads in an image, but
> I'm wondering about the FFI. Is it possible to call a foreign function
> in a separate OS thread or asynchronously in Pharo?
My understanding is with the very latest mt Cog VMs that FFI call-outs
happen in a native OS thread. I'm not sure whether the required
infrastructure is already in Pharo.
Cheers
Philippe
Jan. 7, 2012
Re: [Pharo-project] Bug in FileSystem
by Nicolas Cellier
2012/1/7 Sven Van Caekenberghe <sven(a)beta9.be>:
>
> On 07 Jan 2012, at 14:19, Henrik Sperre Johansen wrote:
>
>> 1) There's no next: into: (which returns the amount read). It's really the only way to do buffers without garbage allocations.
>
> The 2 key methods for efficient IO are:
>
> readInto: collection startingAt: offset count: requestedCount
> Â Â Â Â "Read requestedCount elements into collection starting at offset,
> Â Â Â Â returning the number of elements read, there could be less elements available."
>
> next: count putAll: collection startingAt: offset
> Â Â Â Â "Write count bytes from collection starting at offset."
>
> All other bulk operations can be written in terms of these (see for example Zodiac streams).
>
> Sven
+1.
All streams should provide these API, and if possible, provide an
optimized implementation.
It was not the case in Squeak, i started to refactor a bit, but
incrementally modifying this dinosaurus without creating circularities
is a sport!
I still have 3 years old refactorings unpublished because I'm not sure
how to reproduce the changes in a safe order ;)
Nicolas
Jan. 7, 2012
Re: [Pharo-project] Misc. newbie questions
by Nicolas Cellier
2012/1/6 Lukas Renggli <renggli(a)gmail.com>:
> On 6 January 2012 11:20, Peter Hugosson-Miller <oldmanlink(a)gmail.com> wrote:
>> On 6 jan 2012, at 06:41, "Gerry Weaver" <gerryw(a)compvia.com> wrote:
>>
>> 2. There appear to be some tool choices in the Pharo image. I would like to
>> be able to create a class and it's methods in an editor in one go. I like
>> being able to see all of the class code at once. Is there a way to do this?
>> Â I just want to be able to type it all in and accept (evaluate?) all at
>> once.
>>
>> This is an interesting question to me personally. After 15 years of working
>> exclusively in Smalltalk I've recently been forced to start programming in
>> Java, where the source code is always (as far as I know) arranged in the way
>> you describe.
>>
>> This organization just emphasizes the dead and compiled nature of Java (and
>> similar languages), compared to the living objects of Smalltalk, where even
>> methods are objects, created by sending messages to other objects. Source
>> code is relegated to being a mere artifact, which can be saved and organized
>> in any way one wishes, and preferably never shows its ugly face to the coder
>> :-p
>
> Which of course is no argument why Smalltalk code could not be
> displayed in a more programmer friendly way as a continuous block of
> text. There is no technical reason why source ranges in text box
> couldn't correspond to life method objects. Compared to other
> languages it is extremely tedious in Smalltalk to get an overview over
> a project, a package, or even a single class or to navigate between
> entities.
>
>> And yes, I really *really* miss a good, object oriented class browser!
>
> Eclipse is pretty good, especially with the Java Browsing Perspective.
>
> Lukas
>
As soon as you would display the code for many methods in a single text pane,
you will find file-based-educated people making large refactorings in
a single pass...
Imagine this leads to many syntax errors, they will soon be willing to
save their changes for a later rework...
This would be a complete change in programming flow and if we really
want to support this, we would have to:
- add a way to save syntactically incorrect code
- let IDE tools work on partially correct code (syntax highlighting,
navigation, etc...)
IMHO, these features add a lot of complexity... Is it really worth?
I like the discipline of focusing on a single method until it is at
least syntactically correct.
On the other hand, in Smalltalk we have to transfer the complexity of
multi-method changes in the refactoring engines/menus when some simple
modify/replace in a file would work.
Nicolas
> --
> Lukas Renggli
> www.lukas-renggli.ch
>
Jan. 7, 2012