~ubuntu-branches/ubuntu/intrepid/ruby1.9/intrepid-updates

« back to all changes in this revision

Viewing changes to template/vm.inc.tmpl

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2007-09-04 16:01:17 UTC
  • mfrom: (1.1.8 upstream)
  • Revision ID: james.westby@ubuntu.com-20070904160117-i15zckg2nhxe9fyw
Tags: 1.9.0+20070830-2ubuntu1
* Sync from Debian; remaining changes:
  - Add -g to CFLAGS.
* Fixes build failure on ia64.
* Fixes build failure with gcc-4.2 on lpia.
* Robustify check for target_os, fixing build failure on lpia.
* Set Ubuntu maintainer address.

Show diffs side-by-side

added added

removed removed

Lines of Context:
12
12
 */
13
13
 
14
14
<%=
15
 
ret = ''
16
 
offset = 15
17
 
line_no = 0
18
 
vm_body.each_line{|line|
19
 
  if line =~ /^\#line __CURRENT_LINE__/
20
 
    ret << line.sub(/__CURRENT_LINE__/, "#{line_no+offset}")
 
15
line = 15
 
16
vm_body.gsub(/\n|__CURRENT_LINE__|__CURRENT_FILE__/){|e|
 
17
  case e
 
18
  when '__CURRENT_LINE__'
 
19
    line.to_s
 
20
  when '__CURRENT_FILE__'
 
21
    "vm.inc"
21
22
  else
22
 
    ret <<line
 
23
    line += 1
 
24
    e
23
25
  end
24
 
  line_no += 1
25
26
}
26
 
ret
27
27
%>
28
28