Commit 0f7fb911 authored by Ralf Mueller's avatar Ralf Mueller 🎣
Browse files

major clean for rb/py interfaces

* rm Lib-interface
* unify filenames for config and test
* rm pre-build wrapper code - now SWIG is always needed
parent 2987efc5
import CdiLib
ifile = "../testdata/"
streamID = CdiLib.streamOpenRead(ifile)
vlistID = CdiLib.streamInqVlist(streamID)
nvars = CdiLib.vlistNvars(vlistID)
for i in range(0,nvars):
print(CdiLib.vlistInqVarCode(vlistID, i))
This diff is collapsed.
This diff is collapsed.
require 'mkmf'
load "extconf.rb"
$libs = append_library($libs, "stdc++")
$srcs = %w[cdilib_wrap.c]
$objs = %w[cdilib_wrap.o]
require './CdiLib'
include CdiLib
ifile = ARGV[0].nil? ? "../testdata/" : ARGV[0]
streamID = streamOpenRead(ifile)
vlistID = streamInqVlist(streamID)
nvars = vlistNvars(vlistID)
(0...nvars).each {|i|
print vlistInqVarCode(vlistID, i).to_s + ' '
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment