From d9356954176eba875138e38b5cf0fb131e1ac925 Mon Sep 17 00:00:00 2001 From: Cedric Nugteren Date: Sat, 19 Mar 2016 11:09:09 +0100 Subject: Added __declspec(dllexport) to create a DLL on Windows --- scripts/generator/generator.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'scripts/generator/generator.py') diff --git a/scripts/generator/generator.py b/scripts/generator/generator.py index 99f326cd..867fe520 100644 --- a/scripts/generator/generator.py +++ b/scripts/generator/generator.py @@ -175,8 +175,8 @@ def clblast_cc(routines): result += " return StatusCode::kNotImplemented;\n" result += "}\n" for flavour in routine.flavours: - indent2 = " "*(23 + routine.Length() + len(flavour.template)) - result += "template StatusCode "+routine.name.capitalize()+"<"+flavour.template+">(" + indent2 = " "*(34 + routine.Length() + len(flavour.template)) + result += "template StatusCode PUBLIC_API "+routine.name.capitalize()+"<"+flavour.template+">(" result += (",\n"+indent2).join([a for a in routine.ArgumentsType(flavour)]) result += ",\n"+indent2+"cl_command_queue*, cl_event*);\n" return result @@ -189,7 +189,7 @@ def clblast_c_h(routines): for routine in routines: result += "\n// "+routine.description+": "+routine.ShortNames()+"\n" for flavour in routine.flavours: - result += routine.RoutineHeaderC(flavour, 20)+";\n" + result += routine.RoutineHeaderC(flavour, 20, "")+";\n" return result # The C API implementation (.cc) @@ -200,7 +200,7 @@ def clblast_c_cc(routines): for flavour in routine.flavours: template = "<"+flavour.template+">" if routine.NoScalars() else "" indent = " "*(26 + routine.Length() + len(template)) - result += routine.RoutineHeaderC(flavour, 20)+" {\n" + result += routine.RoutineHeaderC(flavour, 31, " PUBLIC_API")+" {\n" result += " auto status = clblast::"+routine.name.capitalize()+template+"(" result += (",\n"+indent).join([a for a in routine.ArgumentsCast(flavour, indent)]) result += ",\n"+indent+"queue, event);" @@ -247,7 +247,7 @@ files = [ path_clblast+"/src/clblast_c.cc", path_clblast+"/test/wrapper_clblas.h", ] -header_lines = [84, 63, 80, 24, 22] +header_lines = [84, 64, 80, 25, 22] footer_lines = [6, 3, 5, 2, 6] # Checks whether the command-line arguments are valid; exists otherwise -- cgit v1.2.3