hosted by liquidweb


Go Back   Web Hosting Talk : Other Forums : Web Hosting Lounge : Multiline #defines in gcc with wrong EOL
Reply

Forum Jump

Multiline #defines in gcc with wrong EOL

Reply Post New Thread In Web Hosting Lounge Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 01-28-2002, 10:03 PM
cperciva cperciva is offline
Retired Moderator
 
Join Date: Jan 2001
Posts: 2,603

Multiline #defines in gcc with wrong EOL


Does anyone know how to make multiline #defines work when the wrong (windows vs. unix) EOL character is being used?

__________________
Dr. Colin Percival, FreeBSD Security Officer
Online backups for the truly paranoid: http://www.tarsnap.com/



Sponsored Links
  #2  
Old 01-28-2002, 10:23 PM
Lawrence Lawrence is offline
Closed
 
Join Date: Oct 2000
Location: Australia
Posts: 538
I suspect it's not possible without converting the line endings, although I'm not sure. Is converting them not plausible for one reason or another?

  #3  
Old 01-28-2002, 10:32 PM
cperciva cperciva is offline
Retired Moderator
 
Join Date: Jan 2001
Posts: 2,603
Well, it's plausible, just a nuisance. I'm writing code on my windows system and testing it on my unix system, and it's annoying to reconvert the EOLs every time I upload my code.

__________________
Dr. Colin Percival, FreeBSD Security Officer
Online backups for the truly paranoid: http://www.tarsnap.com/

Sponsored Links
  #4  
Old 01-28-2002, 10:38 PM
qslack qslack is offline
Junior Guru
 
Join Date: Apr 2001
Location: IL
Posts: 184
You can just run them through a regexp. Try this for converting the files from Windows to Unix line break format:

perl -pe 's/\015\012/\012/g' FILE.C > FILE.C

It seems to work after a bit of testing, but don't hold me responsible if it does anything bad.

Reply

Related posts from TheWhir.com
Title Type Date Posted
Verizon Argues Against Net Neutrality in US Court of Appeal Web Hosting News 2013-11-05 16:31:25
Cloud-Enabling Technologies Market to Reach $22.6B by 2016: Report Web Hosting News 2013-09-20 17:19:23
Phoenix NAP Aims to Improve Cloud Hosting through Customer Feedback Website Web Hosting News 2013-01-17 13:59:49
Cloud Storage Vendor Scality Releases CDMI Server Dewpoint Web Hosting News 2012-09-20 11:18:21
Partnerships Done Right with Lance Crosby - HostingCon 2012 Web Hosting News 2012-07-16 09:25:27


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?