Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Sven Barth via fpc-pascal
Ryan Joseph  schrieb am Do., 3. Mai 2018, 04:54:

> Can someone put a simple guide to building on the wiki? I tried to build
> from my existing FPC sources and got this error. I never got UNIX down well
> so I don’t know what else I’m supposed to do besides cd to the directory
> and use the “make” command. Uploading a stable binary would be nice also
> but I’m on Mac so maybe only Ingemar has built this before.
>
> Ryans-MacBook-Pro:pas2js ryanjoseph$ make
> /usr/local/bin/ppc386 fpmake.pp -n -Fu../../rtl/units/i386-darwin
> -Fu../../packages/paszlib -Fu../../packages/fcl-process
> -Fu../../packages/hash -Fu../../packages/libtar
> -Fu../../packages/fpmkunit/units_bs/i386-darwin
> PPU Loading /Developer/ObjectivePascal/fpc/rtl/units/i386-darwin/system.ppu
> PPU Invalid Version 196
> Fatal: Can't find unit system used by fpmake
> Fatal: Compilation aborted
> make: *** [fpmake] Error 1
>

A "make all" in the top level directory should suffice (yes, that will
build all of FPC, but that is at least more or less guaranteed to work).
You can then pick the pas2js binary from the utils/pas2js/bin directory.

Regards,
Sven

>
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Ryan Joseph
Can someone put a simple guide to building on the wiki? I tried to build from 
my existing FPC sources and got this error. I never got UNIX down well so I 
don’t know what else I’m supposed to do besides cd to the directory and use the 
“make” command. Uploading a stable binary would be nice also but I’m on Mac so 
maybe only Ingemar has built this before.

Ryans-MacBook-Pro:pas2js ryanjoseph$ make
/usr/local/bin/ppc386 fpmake.pp -n -Fu../../rtl/units/i386-darwin 
-Fu../../packages/paszlib -Fu../../packages/fcl-process -Fu../../packages/hash 
-Fu../../packages/libtar -Fu../../packages/fpmkunit/units_bs/i386-darwin  
PPU Loading /Developer/ObjectivePascal/fpc/rtl/units/i386-darwin/system.ppu
PPU Invalid Version 196
Fatal: Can't find unit system used by fpmake
Fatal: Compilation aborted
make: *** [fpmake] Error 1

Regards,
Ryan Joseph

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Ryan Joseph


> On May 2, 2018, at 11:36 PM, Sven Barth via fpc-pascal 
>  wrote:
> 
> It's "Typename = class external name 'foobar' (Basetype)", not "class 
> Typename = external name 'foobar' (Basetype)". We're not in C++ after all :P
> 
>   public
> const READ_BUFFER: nativeint;
> const UNPACK_ROW_LENGTH: nativeint;
> 
> Just in case you aren't aware of it: "const", "type" and "var" start 
> sections, even inside classes/records, so you don't need to repeat the 
> "const". Instead it is common to write "public const" and then write all 
> constant members. 
> 

Not paying attention at all yesterday going from PHP to Pascal. It’s fixed now 
and looks better but the formatting is not standard perhaps.

The .idls still had those lines I wasn’t sure what to do with so I ignored 
them. I think enums should be string types followed by constants (if that’s 
allowed by the parser).

enum WebGLPowerPreference should probably be:

type
  TWebGLPowerPreference = string;
const
  TWebGLPowerPreferenceDefault = ‘default’;
  etc…

Who knows about or’d typedefs though. better to do those by hand or dump them 
as comments.

enum WebGLPowerPreference { "default", "low-power", "high-performance" };

typedef (ImageBitmap or
 ImageData or
 HTMLImageElement or
 HTMLCanvasElement or
 HTMLVideoElement) TexImageSource;

typedef ([AllowShared] Float32Array or sequence) Float32List;
typedef ([AllowShared] Int32Array or sequence) Int32List;

==

unit webgl2;

{$mode objfpc}
{$modeswitch externalclass}

interface
uses
  JS, Web;

  type
GLint64 = nativeint;
GLuint64 = longword;
  type
TJSWebGLQuery = class external name 'WebGLQuery' (TJSWebGLObject);
TJSWebGLSampler = class external name 'WebGLSampler' (TJSWebGLObject);
TJSWebGLSync = class external name 'WebGLSync' (TJSWebGLObject);
TJSWebGLTransformFeedback = class external name 'WebGLTransformFeedback' 
(TJSWebGLObject);
TJSWebGLVertexArrayObject = class external name 'WebGLVertexArrayObject' 
(TJSWebGLObject);
  type  
TJSWebGL2RenderingContextBase = class external name 
'WebGL2RenderingContextBase' (TJSObject)
public
const
  READ_BUFFER: nativeint;
  UNPACK_ROW_LENGTH: nativeint;
  UNPACK_SKIP_ROWS: nativeint;
  UNPACK_SKIP_PIXELS: nativeint;
  PACK_ROW_LENGTH: nativeint;
  PACK_SKIP_ROWS: nativeint;
  PACK_SKIP_PIXELS: nativeint;
  COLOR: nativeint;
  DEPTH: nativeint;
  STENCIL: nativeint;
  RED: nativeint;
  RGB8: nativeint;
  RGBA8: nativeint;
  RGB10_A2: nativeint;
  TEXTURE_BINDING_3D: nativeint;
  UNPACK_SKIP_IMAGES: nativeint;
  UNPACK_IMAGE_HEIGHT: nativeint;
  TEXTURE_3D: nativeint;
  TEXTURE_WRAP_R: nativeint;
  MAX_3D_TEXTURE_SIZE: nativeint;
  UNSIGNED_INT_2_10_10_10_REV: nativeint;
  MAX_ELEMENTS_VERTICES: nativeint;
  MAX_ELEMENTS_INDICES: nativeint;
  TEXTURE_MIN_LOD: nativeint;
  TEXTURE_MAX_LOD: nativeint;
  TEXTURE_BASE_LEVEL: nativeint;
  TEXTURE_MAX_LEVEL: nativeint;
  MIN: nativeint;
  MAX: nativeint;
  DEPTH_COMPONENT24: nativeint;
  MAX_TEXTURE_LOD_BIAS: nativeint;
  TEXTURE_COMPARE_MODE: nativeint;
  TEXTURE_COMPARE_FUNC: nativeint;
  CURRENT_QUERY: nativeint;
  QUERY_RESULT: nativeint;
  QUERY_RESULT_AVAILABLE: nativeint;
  STREAM_READ: nativeint;
  STREAM_COPY: nativeint;
  STATIC_READ: nativeint;
  STATIC_COPY: nativeint;
  DYNAMIC_READ: nativeint;
  DYNAMIC_COPY: nativeint;
  MAX_DRAW_BUFFERS: nativeint;
  DRAW_BUFFER0: nativeint;
  DRAW_BUFFER1: nativeint;
  DRAW_BUFFER2: nativeint;
  DRAW_BUFFER3: nativeint;
  DRAW_BUFFER4: nativeint;
  DRAW_BUFFER5: nativeint;
  DRAW_BUFFER6: nativeint;
  DRAW_BUFFER7: nativeint;
  DRAW_BUFFER8: nativeint;
  DRAW_BUFFER9: nativeint;
  DRAW_BUFFER10: nativeint;
  DRAW_BUFFER11: nativeint;
  DRAW_BUFFER12: nativeint;
  DRAW_BUFFER13: nativeint;
  DRAW_BUFFER14: nativeint;
  DRAW_BUFFER15: nativeint;
  MAX_FRAGMENT_UNIFORM_COMPONENTS: nativeint;
  MAX_VERTEX_UNIFORM_COMPONENTS: nativeint;
  SAMPLER_3D: nativeint;
  SAMPLER_2D_SHADOW: nativeint;
  FRAGMENT_SHADER_DERIVATIVE_HINT: nativeint;
  PIXEL_PACK_BUFFER: nativeint;
  PIXEL_UNPACK_BUFFER: nativeint;
  PIXEL_PACK_BUFFER_BINDING: nativeint;
  PIXEL_UNPACK_BUFFER_BINDING: nativeint;
  FLOAT_MAT2x3: nativeint;
  FLOAT_MAT2x4: nativeint;
  FLOAT_MAT3x2: nativeint;
  FLOAT_MAT3x4: nativeint;
  FLOAT_MAT4x2: nativeint;
  FLOAT_MAT4x3: nativeint;
  SRGB: nativeint;
  SRGB8: nativeint;
  SRGB8_ALPHA8: nativeint;
  COMPARE_REF_TO_TEXTURE: nativeint;
  RGBA32F: nativeint;
  RGB32F: nativeint;
  RGBA16F: nativeint;
  RGB16F: nativeint;
  VERTEX_ATTRIB_ARRAY_INTEGER: nativeint;
  MAX_ARRAY_TEXTURE_LAYERS: nativeint;
  

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Sven Barth via fpc-pascal
Ryan Joseph  schrieb am Mi., 2. Mai 2018, 15:57:

>
>   class TJSWebGL2RenderingContextBase = external name
> 'WebGL2RenderingContextBase' (TJSObject)
>

It's "Typename = class external name 'foobar' (Basetype)", not "class
Typename = external name 'foobar' (Basetype)". We're not in C++ after all :P

  public
> const READ_BUFFER: nativeint;
> const UNPACK_ROW_LENGTH: nativeint;


Just in case you aren't aware of it: "const", "type" and "var" start
sections, even inside classes/records, so you don't need to repeat the
"const". Instead it is common to write "public const" and then write all
constant members.

Regards,
Sven

>
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Ryan Joseph


> On May 2, 2018, at 6:20 PM, Michael Van Canneyt  
> wrote:
> 
> Yes: You posted the link to 1.0.

I think it’s actually an extension to the original so nothing was lost. The 
original didn’t have vertex array objects so it’s best to have both.

https://www.khronos.org/registry/webgl/specs/latest/2.0/webgl2.idl

That’s what my parser dumps out in current state (some bugs I know). I think 
TJSWebGL2RenderingContextBase is supposed to be a subclass of the first context 
base class to make it work.

unit webgl2;

{$mode objfpc}
{$modeswitch externalclass}

interface
uses
  JS, Web;

  type GLint64 = nativeint;
  type GLuint64 = unsigned long long;
  class TJSWebGLQuery = external name 'WebGLQuery' (TJSWebGLObject);
  class TJSWebGLSampler = external name 'WebGLSampler' (TJSWebGLObject);
  class TJSWebGLSync = external name 'WebGLSync' (TJSWebGLObject);
  class TJSWebGLTransformFeedback = external name 'WebGLTransformFeedback' 
(TJSWebGLObject);
  class TJSWebGLVertexArrayObject = external name 'WebGLVertexArrayObject' 
(TJSWebGLObject);
  class TJSWebGL2RenderingContextBase = external name 
'WebGL2RenderingContextBase' (TJSObject)
  public
const READ_BUFFER: nativeint;
const UNPACK_ROW_LENGTH: nativeint;
const UNPACK_SKIP_ROWS: nativeint;
const UNPACK_SKIP_PIXELS: nativeint;
const PACK_ROW_LENGTH: nativeint;
const PACK_SKIP_ROWS: nativeint;
const PACK_SKIP_PIXELS: nativeint;
const COLOR: nativeint;
const DEPTH: nativeint;
const STENCIL: nativeint;
const RED: nativeint;
const RGB8: nativeint;
const RGBA8: nativeint;
const RGB10_A2: nativeint;
const TEXTURE_BINDING_3D: nativeint;
const UNPACK_SKIP_IMAGES: nativeint;
const UNPACK_IMAGE_HEIGHT: nativeint;
const TEXTURE_3D: nativeint;
const TEXTURE_WRAP_R: nativeint;
const MAX_3D_TEXTURE_SIZE: nativeint;
const UNSIGNED_INT_2_10_10_10_REV: nativeint;
const MAX_ELEMENTS_VERTICES: nativeint;
const MAX_ELEMENTS_INDICES: nativeint;
const TEXTURE_MIN_LOD: nativeint;
const TEXTURE_MAX_LOD: nativeint;
const TEXTURE_BASE_LEVEL: nativeint;
const TEXTURE_MAX_LEVEL: nativeint;
const MIN: nativeint;
const MAX: nativeint;
const DEPTH_COMPONENT24: nativeint;
const MAX_TEXTURE_LOD_BIAS: nativeint;
const TEXTURE_COMPARE_MODE: nativeint;
const TEXTURE_COMPARE_FUNC: nativeint;
const CURRENT_QUERY: nativeint;
const QUERY_RESULT: nativeint;
const QUERY_RESULT_AVAILABLE: nativeint;
const STREAM_READ: nativeint;
const STREAM_COPY: nativeint;
const STATIC_READ: nativeint;
const STATIC_COPY: nativeint;
const DYNAMIC_READ: nativeint;
const DYNAMIC_COPY: nativeint;
const MAX_DRAW_BUFFERS: nativeint;
const DRAW_BUFFER0: nativeint;
const DRAW_BUFFER1: nativeint;
const DRAW_BUFFER2: nativeint;
const DRAW_BUFFER3: nativeint;
const DRAW_BUFFER4: nativeint;
const DRAW_BUFFER5: nativeint;
const DRAW_BUFFER6: nativeint;
const DRAW_BUFFER7: nativeint;
const DRAW_BUFFER8: nativeint;
const DRAW_BUFFER9: nativeint;
const DRAW_BUFFER10: nativeint;
const DRAW_BUFFER11: nativeint;
const DRAW_BUFFER12: nativeint;
const DRAW_BUFFER13: nativeint;
const DRAW_BUFFER14: nativeint;
const DRAW_BUFFER15: nativeint;
const MAX_FRAGMENT_UNIFORM_COMPONENTS: nativeint;
const MAX_VERTEX_UNIFORM_COMPONENTS: nativeint;
const SAMPLER_3D: nativeint;
const SAMPLER_2D_SHADOW: nativeint;
const FRAGMENT_SHADER_DERIVATIVE_HINT: nativeint;
const PIXEL_PACK_BUFFER: nativeint;
const PIXEL_UNPACK_BUFFER: nativeint;
const PIXEL_PACK_BUFFER_BINDING: nativeint;
const PIXEL_UNPACK_BUFFER_BINDING: nativeint;
const FLOAT_MAT2x3: nativeint;
const FLOAT_MAT2x4: nativeint;
const FLOAT_MAT3x2: nativeint;
const FLOAT_MAT3x4: nativeint;
const FLOAT_MAT4x2: nativeint;
const FLOAT_MAT4x3: nativeint;
const SRGB: nativeint;
const SRGB8: nativeint;
const SRGB8_ALPHA8: nativeint;
const COMPARE_REF_TO_TEXTURE: nativeint;
const RGBA32F: nativeint;
const RGB32F: nativeint;
const RGBA16F: nativeint;
const RGB16F: nativeint;
const VERTEX_ATTRIB_ARRAY_INTEGER: nativeint;
const MAX_ARRAY_TEXTURE_LAYERS: nativeint;
const MIN_PROGRAM_TEXEL_OFFSET: nativeint;
const MAX_PROGRAM_TEXEL_OFFSET: nativeint;
const MAX_VARYING_COMPONENTS: nativeint;
const TEXTURE_2D_ARRAY: nativeint;
const TEXTURE_BINDING_2D_ARRAY: nativeint;
const R11F_G11F_B10F: nativeint;
const UNSIGNED_INT_10F_11F_11F_REV: nativeint;
const RGB9_E5: nativeint;
const UNSIGNED_INT_5_9_9_9_REV: nativeint;
const TRANSFORM_FEEDBACK_BUFFER_MODE: nativeint;
const MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS: nativeint;
const TRANSFORM_FEEDBACK_VARYINGS: nativeint;
const TRANSFORM_FEEDBACK_BUFFER_START: nativeint;
const TRANSFORM_FEEDBACK_BUFFER_SIZE: nativeint;
const 

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Michael Van Canneyt



On Wed, 2 May 2018, Ryan Joseph wrote:





On May 2, 2018, at 5:28 PM, Mattias Gaertner  wrote:

What is the difference to the existing webgl.pas?


It’s missing a couple types and missing comments. :) I can fix that of course 
and works for other .idl’s also I presume (if you have any other examples send 
them and I’ll try). The current file is WebGL 1.0 but I noticed there’s a 2.0 
file also. Any reason we used 1.0?


Yes: You posted the link to 1.0.

Michael.___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Mattias Gaertner
On Wed, 2 May 2018 16:28:10 +0700
Ryan Joseph  wrote:

> > On May 2, 2018, at 2:08 PM, Michael Van Canneyt  
> > wrote:
> > 
> > Yes. the fpmkunit needs to be the latest version, for the AddLibrary call. 
> > I will see if I can work around it.  
> 
> So I need to build the entire compiler and I get pas2js in the end? I didn’t 
> realize it was built on the entire FPC compiler but I guess that makes sense.

pas2js can be built with the released fpc 3.0.4 too.
The problem is the fpmake files as Michael pointed out. They should be
adapted to support fpc 3.0.4.

 
> Just for fun I made a PHP script to parse that .idl file. :) Not sure if it 
> works on other files but it only took a few hours and seems to work ok. 
> Should be easy to hack with.
> 
> https://github.com/genericptr/pas2js-IDL-parser
> 
> php pas2js_idl_parser.php /Users/ryanjoseph/Downloads/webgl.idl 
> 
> 
> 
> unit webgl;

What is the difference to the existing webgl.pas?

Mattias
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Ryan Joseph


> On May 2, 2018, at 2:08 PM, Michael Van Canneyt  
> wrote:
> 
> Yes. the fpmkunit needs to be the latest version, for the AddLibrary call. I 
> will see if I can work around it.

So I need to build the entire compiler and I get pas2js in the end? I didn’t 
realize it was built on the entire FPC compiler but I guess that makes sense.

Just for fun I made a PHP script to parse that .idl file. :) Not sure if it 
works on other files but it only took a few hours and seems to work ok. Should 
be easy to hack with.

https://github.com/genericptr/pas2js-IDL-parser

php pas2js_idl_parser.php /Users/ryanjoseph/Downloads/webgl.idl 



unit webgl;

{$mode objfpc}
{$modeswitch externalclass}

interface
uses
  JS, Web;

  type GLenum = cardinal;
  type GLboolean = boolean;
  type GLbitfield = cardinal;
  type GLbyte = shortint;
  type GLshort = short;
  type GLint = integer;
  type GLsizei = integer;
  type GLintptr = nativeint;
  type GLsizeiptr = nativeint;
  type GLubyte = byte;
  type GLushort = word;
  type GLuint = cardinal;
  type GLfloat = double;
  type GLclampf = double;
  class TJSWebGLContextAttributes = external name 'WebGLContextAttributes' 
(TJSObject)
  public
alpha: GLboolean;
depth: GLboolean;
stencil: GLboolean;
antialias: GLboolean;
premultipliedAlpha: GLboolean;
preserveDrawingBuffer: GLboolean;
powerPreference: WebGLPowerPreference;
failIfMajorPerformanceCaveat: GLboolean;
  end;

  class TJSWebGLObject = external name 'WebGLObject' (TJSObject);
  class TJSWebGLBuffer = external name 'WebGLBuffer' (TJSWebGLObject);
  class TJSWebGLFramebuffer = external name 'WebGLFramebuffer' (TJSWebGLObject);
  class TJSWebGLProgram = external name 'WebGLProgram' (TJSWebGLObject);
  class TJSWebGLRenderbuffer = external name 'WebGLRenderbuffer' 
(TJSWebGLObject);
  class TJSWebGLShader = external name 'WebGLShader' (TJSWebGLObject);
  class TJSWebGLTexture = external name 'WebGLTexture' (TJSWebGLObject);
  class TJSWebGLUniformLocation = external name 'WebGLUniformLocation' 
(TJSObject);
  class TJSWebGLActiveInfo = external name 'WebGLActiveInfo' (TJSObject)
  private
Fsize: GLint; external name 'size';
Ftype: GLenum; external name 'type';
Fname: DOMString; external name 'name';
  public
property size: GLint read Fsize;
property type: GLenum read Ftype;
property name: DOMString read Fname;
  end;

  class TJSWebGLShaderPrecisionFormat = external name 
'WebGLShaderPrecisionFormat' (TJSObject)
  private
FrangeMin: GLint; external name 'rangeMin';
FrangeMax: GLint; external name 'rangeMax';
Fprecision: GLint; external name 'precision';
  public
property rangeMin: GLint read FrangeMin;
property rangeMax: GLint read FrangeMax;
property precision: GLint read Fprecision;
  end;

  class TJSWebGLRenderingContextBase = external name 
'WebGLRenderingContextBase' (TJSObject)
  private
Fcanvas: HTMLCanvasElement; external name 'canvas';
FdrawingBufferWidth: GLsizei; external name 'drawingBufferWidth';
FdrawingBufferHeight: GLsizei; external name 'drawingBufferHeight';
  public
const DEPTH_BUFFER_BIT: nativeint;
const STENCIL_BUFFER_BIT: nativeint;
const COLOR_BUFFER_BIT: nativeint;
const POINTS: nativeint;
const LINES: nativeint;
const LINE_LOOP: nativeint;
const LINE_STRIP: nativeint;
const TRIANGLES: nativeint;
const TRIANGLE_STRIP: nativeint;
const TRIANGLE_FAN: nativeint;
const ZERO: nativeint;
const ONE: nativeint;
const SRC_COLOR: nativeint;
const ONE_MINUS_SRC_COLOR: nativeint;
const SRC_ALPHA: nativeint;
const ONE_MINUS_SRC_ALPHA: nativeint;
const DST_ALPHA: nativeint;
const ONE_MINUS_DST_ALPHA: nativeint;
const DST_COLOR: nativeint;
const ONE_MINUS_DST_COLOR: nativeint;
const SRC_ALPHA_SATURATE: nativeint;
const FUNC_ADD: nativeint;
const BLEND_EQUATION: nativeint;
const BLEND_EQUATION_RGB: nativeint;
const BLEND_EQUATION_ALPHA: nativeint;
const FUNC_SUBTRACT: nativeint;
const FUNC_REVERSE_SUBTRACT: nativeint;
const BLEND_DST_RGB: nativeint;
const BLEND_SRC_RGB: nativeint;
const BLEND_DST_ALPHA: nativeint;
const BLEND_SRC_ALPHA: nativeint;
const CONSTANT_COLOR: nativeint;
const ONE_MINUS_CONSTANT_COLOR: nativeint;
const CONSTANT_ALPHA: nativeint;
const ONE_MINUS_CONSTANT_ALPHA: nativeint;
const BLEND_COLOR: nativeint;
const ARRAY_BUFFER: nativeint;
const ELEMENT_ARRAY_BUFFER: nativeint;
const ARRAY_BUFFER_BINDING: nativeint;
const ELEMENT_ARRAY_BUFFER_BINDING: nativeint;
const STREAM_DRAW: nativeint;
const STATIC_DRAW: nativeint;
const DYNAMIC_DRAW: nativeint;
const BUFFER_SIZE: nativeint;
const BUFFER_USAGE: nativeint;
const CURRENT_VERTEX_ATTRIB: nativeint;
const FRONT: nativeint;
const BACK: nativeint;
const FRONT_AND_BACK: nativeint;
const CULL_FACE: nativeint;
const BLEND: 

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Michael Van Canneyt



On Wed, 2 May 2018, Ryan Joseph wrote:





On May 2, 2018, at 1:24 PM, Michael Van Canneyt  wrote:

It will only work with trunk.


trunk of what? Do mean the entire fpc sources?


Yes. the fpmkunit needs to be the latest version, for the AddLibrary call. 
I will see if I can work around it.


Michael.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Ryan Joseph


> On May 2, 2018, at 1:24 PM, Michael Van Canneyt  
> wrote:
> 
> It will only work with trunk.

trunk of what? Do mean the entire fpc sources?

cd /Users/ryanjoseph/Downloads/pas2js 
ls
Makefilecompilerfpmake.pp   utils
Makefile.fpcdemopackages

Regards,
Ryan Joseph

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] pas2js Webgl unit committed

2018-05-02 Thread Michael Van Canneyt



On Wed, 2 May 2018, Ryan Joseph wrote:





On May 2, 2018, at 8:18 AM, Ryan Joseph  wrote:

On Mac cd’ing to the directory and using make gives this error:

/usr/local/bin/ppc386 fpmake.pp -n 
Fatal: Can't find unit system used by fpmake

Fatal: Compilation aborted
make: *** [fpmake] Error 1


Sorry that was the wrong directory. Root directory gives me this:

Ryans-MacBook-Pro:pas2js ryanjoseph$ make
make: pas2js: Command not found
/usr/local/bin/ppc386 fpmake.pp 
Free Pascal Compiler version 3.0.2 [2017/02/12] for i386

Copyright (c) 1993-2017 by Florian Klaempfl and others
Target OS: Darwin for i386
Compiling fpmake.pp
fpmake.pp(134,15) Error: identifier idents no member "AddLibrary"
fpmake.pp(197) Fatal: There were 1 errors compiling module, stopping
Fatal: Compilation aborted
make: *** [fpmake] Error 1


It will only work with trunk.

Michael.___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal