Re: Using ec instead of ecb

Jocelyn <[email protected]> Mon, 22 Mar 2010 11:32:31 +0100
Newsgroups gmane.comp.lang.eiffel.gobo.general
Message-ID <[email protected]>
On 3/22/2010 10:49 AM, Eric Bezault wrote:
> Jocelyn wrote:
>   
>> In the meantime, this would make sense to use for instance an
>> environment variable to overwrite this default.
>> What about using   GOBO_EC_NAME  to precise which executable to use?
>> For instance   "ec" or "ecb".
>>
>> This is just an idea to make the tool flexible.
>>     
> How about making ec/ecb flexible? Just an idea... :-)
>   
I guess my idea is more likely to be done in a few minutes than yours
But I agree this would help to have ec's data compatible with ecb's data.

Now, Gobo Eiffel is open source, as well as Eiffel Studio.
So any contribution might be welcome.

If my idea is accepted, I can spend a few minutes to submit a patch to
make geant support a GOBO_EC_NAME environment variable.
as far as I can see, their is only one line impacted
line:151 of src/geant/command/geant_ise_command.e

I guess something like that would do the job

diff --git a/src/geant/command/geant_ise_command.e
b/src/geant/command/geant_ise_command.e
index 0c87102..c64e553 100644
--- a/src/geant/command/geant_ise_command.e
+++ b/src/geant/command/geant_ise_command.e
@@ -16,6 +16,8 @@ inherit

        GEANT_COMMAND

+       KL_SHARED_EXECUTION_ENVIRONMENT
+
 create

        make
@@ -148,7 +150,8 @@ feature -- Execution
                        a_filename: STRING
                do
                        create cmd.make (128)
-                       cmd.append_string ("ecb -batch")
+                       cmd.append_string (ise_ec_name)
+                       cmd.append_string (" -batch")
                        if ace_filename /= Void and then
ace_filename.count > 0 then
                                cmd.append_string (" -config ")
                                a_filename :=
file_system.pathname_from_file_system (ace_filename, unix_file_system)
@@ -285,4 +288,19 @@ feature -- Execution
                        end
                end

+feature {NONE} -- Implementation
+
+       ise_ec_name: STRING is
+                       -- ISE's ec name to use
+               local
+                       s: STRING
+               do
+                       s := Execution_environment.variable_value
("GOBO_EC_NAME")
+                       if s /= Void then
+                               Result := s
+                       else
+                               Result := "ecb"
+                       end
+               end
+
 end

Of course  we could also use  "EC_NAME" instead of "GOBO_EC_NAME"

Now, I could try to suggest a patch to make ec and ecb compatible, but
don't expect it today (neither tomorrow).

-- Jocelyn



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

To Post a message, send it to:   [email protected]
To Unsubscribe, send a blank message to: [email protected]! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/gobo-eiffel/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/gobo-eiffel/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/