LOGIN   :::   RECOVER PASS   :::   GET ACCOUNT    
Browse
  • Projects
  • Code (CVS)
  • Forums
  • News
  • Articles
  • Polls
  •  
    OpenCores
  • FAQ
  • CVS HowTo
  • Mission
  • Media
  • Tools
  • Advertise
  • Mirrors
  • Logos
  • Contact us
  • Find Resources
  • Job Opportunity
  •  
    Tools
  • Search
      
  • Download Cores (CVSGet)
  •  
    More
  • Wishbone
  • Perlilog
  • EDA tools
  • OpenTech CD
  •  
    Navigation: All forums > Openrisc > Message List > Message Post

    Message

    Reply | Reply all
    Date Prev | Date Next | Thread Prev | Thread Next Date Index | Thread Index

    From: windsoul smth<windsoul@g...>
    Date: Fri Jan 28 13:02:18 CET 2005
    Subject: [openrisc] Re: OpenRISC Digest, Vol 14, Issue 8
    Top
    the configure script error is because the defference of the "new line"
    between windows and linux. one is "0d0a" while the other is "0d", this
    is a small tool i found on www.tcl.tk to convert whole directory from
    one format to another:
    http://www.tcl.tk/scripting/Dos2unix.txt

    be careful for it will also convert binary files
    the source of the file is:

    #!/usr/local/bin/tclsh8.0

    # Dos2Unix
    # Convert a file to Unix-style line endings
    # If the file is a directory, then recursively
    # convert all the files in the directory and below.
    #
    # Arguments
    # f The name of a file or directory.
    #
    # Side Effects:
    # Rewrites the file to have LF line-endings

    proc Dos2Unix {f} {
    puts $f
    if {[file isdirectory $f]} {
    foreach g [glob [file join $f *]] {
    Dos2Unix $g
    }
    } else {
    set in [open $f]
    set out [open $f.new w]
    fconfigure $out -translation lf
    puts -nonewline $out [read $in]
    close $out
    close $in
    file rename -force $f.new $f
    }
    }

    # Process each command-line argument

    foreach f $argv {
    Dos2Unix $f
    }

    Follow upAuthor
    [openrisc] Re: OpenRISC Digest, Vol 14, Issue 8Richard Herveille

     
    Copyright (c) 1999 OPENCORES.ORG. All rights reserved.