List Info

Thread: Directory Contents




Directory Contents
country flaguser name
United States
2008-03-04 15:25:42

Hello,

I was wondering if there was an Eiffel class that handled copying the
contents from Directory A to Directory B.

I can do this using Windows system commands but I was wondering if there
was an alternative solution.

Thanks,
Hubert

--
Fury Software
http://www.furysoftware.com

Battlefront.com
http://www.battlefront.com

__._,_.___
.

__,_._,___
Getting EiffelStudio 6.2 to work with Visual Studio 2008
country flaguser name
Canada
2008-03-04 18:00:10

I have Microsoft Visual Studio 2008 installed and installed EiffelStudio
6.2 as well. The installation of EiffelStudio went with no complaints but
when I try to compile a project I get these errors:

Eiffel C/C++ Compilation Tool - Version: 6.2

Copyright Eiffel Software 1985-2007. All Rights Reserved.

Preparing C compilation...

eoption.c

big_file_C2_c.c

big_file_C1_c.c

c:program fileseiffel softwareeiffelstudio 6.2
gplstudiospecwin64includeeif_main.h(44) : fatal error C1083: Cannot
open include file: 'windows.h': No such file or directory

NMAKE : fatal error U1077: '"C:Program Files (x86)Microsoft Visual Studio
9.0VCBINamd64cl.EXE"' : return code '0x2'

Stop.

c:program fileseiffel softwareeiffelstudio 6.2
gplstudiospecwin64includeeif_main.h(44) : fatal error C1083: Cannot
open include file: 'windows.h': No such file or directory

c:program fileseiffel softwareeiffelstudio 6.2
gplstudiospecwin64includeeif_main.h(44) : fatal error C1083: Cannot
open include file: 'windows.h': No such file or directory

NMAKE : fatal error U1077: '"C:Program Files (x86)Microsoft Visual Studio
9.0VCBINamd64cl.EXE"' : return code '0x2'

Stop.

NMAKE : fatal error U1077: '"C:Program Files (x86)Microsoft Visual Studio
9.0VCBINamd64cl.EXE"' : return code '0x2'

Stop.

Is there a way for me to fix EiffelStudio so that it works with Visual
Studio 2008?

Regards

Chris Saunders

[Non-text portions of this message have been removed]

__._,_.___
.

__,_._,___
Re: Directory Contents
country flaguser name
United States
2008-03-04 21:13:53

I wrote the following `recursive_copy¡¯ for you. And tested, it works.

recursive_copy (a_source_dir, a_target_dir: DIRECTORY) is
-- Copy all items (include sub directories) from `a_source_dir' to
`a_target_dir'.
require
exists: a_source_dir /= Void and then a_source_dir.exists
exists: a_target_dir /= Void and then a_target_dir.exists
local
l_sub_items: ARRAYED_LIST [STRING]
l_file_name: FILE_NAME
l_src_dir_name, l_target_dir_name: DIRECTORY_NAME
l_sub_src_dir, l_sub_target_dir: DIRECTORY
l_src_file, l_target_file: RAW_FILE
l_dot, l_dot_dot: FILE_NAME
do
from
create l_dot.make_from_string (".")
create l_dot_dot.make_from_string ("..")
l_sub_items := a_source_dir.linear_representation
l_sub_items.start
until
l_sub_items.after
loop

-- Prepare
create l_src_dir_name.make_from_string (a_source_dir.name)
l_src_dir_name.extend (l_sub_items.item)
create l_sub_src_dir.make (l_src_dir_name)

create l_file_name.make_from_string (a_source_dir.name)
l_file_name.set_file_name (l_sub_items.item)
create l_src_file.make (l_file_name)

create l_file_name.make_from_string (l_sub_items.item)

-- Switch
if l_file_name.is_equal (l_dot) or l_file_name.is_equal (l_dot_dot) then
-- We ignore `.' and `..'.
elseif l_sub_src_dir.exists then
create l_target_dir_name.make_from_string (a_target_dir.name)
l_target_dir_name.extend (l_sub_items.item)
create l_sub_target_dir.make (l_target_dir_name)
if not l_sub_target_dir.exists then
l_sub_target_dir.create_dir
end

recursive_copy (l_sub_src_dir, l_sub_target_dir)
elseif l_src_file.exists then
l_src_file.open_read

create l_file_name.make_from_string (a_target_dir.name)
l_file_name.set_file_name (l_sub_items.item)
create l_target_file.make (l_file_name)
if not l_target_file.exists then
l_target_file.create_read_write
end
l_src_file.copy_to (l_target_file)
l_src_file.close
l_target_file.close
end

l_sub_items.forth
end
end

To test the feature, just have something like:

test is
-- Test `recursive_copy'
local
l_dir_src, l_dir_target: DIRECTORY
do
create l_dir_src.make_open_read ("E:a")
create l_dir_target.make ("E:b")
recursive_copy (l_dir_src, l_dir_target)
end

--- In eiffel_software%40yahoogroups.com">eiffel_softwareyahoogroups.com, Hubert Cater <hcater...> wrote:
&gt;
> Hello,
&gt;
> I was wondering if there was an Eiffel class that handled copying the
> contents from Directory A to Directory B.
>
> I can do this using Windows system commands but I was wondering if
there
> was an alternative solution.
>
> Thanks,
> Hubert
&gt;
> --
> Fury Software
> http://www.furysoftware.com
>
> Battlefront.com
&gt; http://www.battlefront.com
&gt;

__._,_.___
.

__,_._,___
RE: Getting EiffelStudio 6.2 to work with Visual Studio 2008
user name
2008-03-05 16:01:54

Which version of VS 2008 did you install? And did you made a complete
install? We definitely recommend using the Windows SDK, but when VS 2008 is
installed, we default to VS 2008.

Regards,
Manu

__._,_.___
.

__,_._,___
RE: Getting EiffelStudio 6.2 to work with Visual Studio 2008
country flaguser name
Canada
2008-03-07 07:02:45

Sorry if my reply took awhile - my email account was broken. I have
installed Microsoft Visual Studio 2008 Professional. I did the full install
with everything going to its default location, When installing EiffelStudio
6.2 everything seemed to go normally.

Regards

Chris Saunders

From: eiffel_software%40yahoogroups.com">eiffel_softwareyahoogroups.com
[mailto: eiffel_software%40yahoogroups.com">eiffel_softwareyahoogroups.com] On Behalf Of Emmanuel Stapf [ES]
Sent: Wednesday, March 05, 2008 5:02 PM
To: eiffel_software%40yahoogroups.com">eiffel_softwareyahoogroups.com
Subject: RE: [eiffel_software] Getting EiffelStudio 6.2 to work with Visual
Studio 2008

Which version of VS 2008 did you install? And did you made a complete
install? We definitely recommend using the Windows SDK, but when VS 2008 is
installed, we default to VS 2008.

Regards,
Manu

[Non-text portions of this message have been removed]

__._,_.___
.

__,_._,___
[1-5]

about | contact  Other archives ( Real Estate discussion Medical topics )