Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new SDK layout #23

Closed
zwetan opened this issue Dec 28, 2015 · 9 comments
Closed

new SDK layout #23

zwetan opened this issue Dec 28, 2015 · 9 comments
Milestone

Comments

@zwetan
Copy link
Member

zwetan commented Dec 28, 2015

improve the SDK

the file/directory structure need to change
it will be similar to other lang distribution
and follow the Filesystem Hierarchy Standard (FHS)

under Windows: hard dependency on Cygwin ?
yes

@zwetan
Copy link
Member Author

zwetan commented Dec 28, 2015

our main SDK will install in

/usr/share/redtamarin
               |_ bin
               |   |_ abcrun
               |   |_ as3run
               |   |_ swfrun
               |   |_ redbean
               |   |_ redshell
               |   |_ redshell_d
               |   |_ redshell_dd
               |
               |_ lib
               |   |_ asc.jar
               |   |_ asc2.jar
               |
               |_ lib-abc
               |       |_ redtamarin.abc
               |       |_ redbean.abc
               |
               |_ runtimes
               |       |_ avmshell
               |       |
               |       |_ redshell
               |             |_ linux
               |             |
               |             |_ macintosh
               |             |
               |             |_ windows
               |_ ...

and have symlink

/usr/bin
      |
      |_ redshell    -> /usr/share/redtamarin/bin/redshell
      |_ redshell_d  -> /usr/share/redtamarin/bin/redshell_d
      |_ redshell_dd -> /usr/share/redtamarin/bin/redshell_dd
      |
      |_ redbean     -> /usr/share/redtamarin/bin/redbean

the ABC libraries will be in

/usr/lib/redtamarin
               |_ redtamarin.abc -> /usr/share/redtamarin/lib-abc/redtamarin.abc
               |_ redbean.abc    -> /usr/share/redtamarin/lib-abc/redbean.abc
               |
               |_ uanalytics.abc

@zwetan
Copy link
Member Author

zwetan commented Dec 28, 2015

from now on the install of the redtamarin SDK will be versioned as a debian package

eg
sudo dpkg -i redtamarin-0.4.1.deb

notes

  • we need a version external file somewhere
  • if the package is updated everything should be replaced
    but individual ABC libraries in /usr/lib/redtamarin should be left alone
  • the tool redbean is part of the SDK, not additional or separate install
  • dependencies of the package should be glibc (>= 2.14)
    maybe java (to run asc.jar from redbean) or redbean can deal with it individually
    eg. detect java with which java, display a warning that java is not installed
  • as3shebang or other tools are additional/separate install
    with special case for as3shebang which need only a dep on glibc (>= 2.14)
    other tools may need a dep on redtamarin itself eg redtamarin (>= 0.4.1)
  • we need an additional install for Linux for binfmt_misc in etc/init.d/
  • we need clear procedures for
    • installing an exe
    • installing an ABC lib
    • installing an AS3 shell script

@zwetan
Copy link
Member Author

zwetan commented Dec 28, 2015

special case on Linux

we need to install binfmt_misc

have a script

/etc/init.d
       |_ redtamarin_run

redtamarin_run

#!/bin/bash
echo ':SWF:E::swf::/usr/bin/swfrun:' > /proc/sys/fs/binfmt_misc/register
echo ':ABC:E::abc::/usr/bin/abcrun:' > /proc/sys/fs/binfmt_misc/register
echo ':AS3:E::as3::/usr/bin/as3run:' > /proc/sys/fs/binfmt_misc/register

so when a system reboot binfmt_misc can register the .as3, .abc, .swf extensions automatically

@zwetan
Copy link
Member Author

zwetan commented Dec 28, 2015

special case on Windows

we need a hard dependency on Cygwin
so before installing redtamarin we need to install Cygwin

ideally we want an exe/msi installer that will automate

  • installing cygwin
  • installing apt-cyg
  • installing wpkg

so we can simply install redtamarin as a debian package for windows
eg
sudo wpkg -i redtamarin-0.4.1_win64.deb

and where we can adapt the install path to Cygwin
for ex: /usr/bin is in fact C:\cygwin\bin

@zwetan
Copy link
Member Author

zwetan commented Dec 28, 2015

special case on Macintosh (Mac OS X)

we need a .pkg to install redtamarin without any other dependencies

eg
$ sudo installer -pkg redtamarin-0.4.1.pkg -target /

and/or

a debian package depending on macports and dpkg
eg
$ sudo dpkg -i redtamarin-0.4.1_darwin-amd64.deb

the debian package install would be prefered as it allow us to define dependencies

@zwetan
Copy link
Member Author

zwetan commented Dec 28, 2015

special case for installing redshell runtimes

if we install only the redshell for the current operating system we have

redtamarin/runtimes/
│
└── redshell
    │
    └── windows
        ├── 32
        │   ├── redshell.exe
        │   ├── redshell_d.exe
        │   └── redshell_dd.exe
        └── 64
            ├── redshell.exe
            ├── redshell_d.exe
            └── redshell_dd.exe

if we install all runtimes for all operating systems we have

redtamarin/runtimes/
│
└── redshell
    ├── linux
    │   ├── 32
    │   │   ├── redshell
    │   │   ├── redshell_d
    │   │   └── redshell_dd
    │   └── 64
    │       ├── redshell
    │       ├── redshell_d
    │       └── redshell_dd
    ├── macintosh
    │   ├── 32
    │   │   ├── redshell
    │   │   ├── redshell_d
    │   │   └── redshell_dd
    │   └── 64
    │       ├── redshell
    │       ├── redshell_d
    │       └── redshell_dd
    └── windows
        ├── 32
        │   ├── redshell.exe
        │   ├── redshell_d.exe
        │   └── redshell_dd.exe
        └── 64
            ├── redshell.exe
            ├── redshell_d.exe
            └── redshell_dd.exe

so when we install redtamarin with
$ sudo wpkg -i redtamarin-0.4.1_win64.deb
should it be "all" or "only the current OS" (in this case windows) ?

with all
the package would be big, it is mainly a problem of size
eg. install 50MB vs install 150MB

with current OS
size is smaller
but then we need additional packages
$ sudo wpkg -i redshell-macintosh-0.4.1_win64.deb
$ sudo wpkg -i redshell-linux-0.4.1_win64.deb

for now we decide to install all, reasons

  • people or at least developer usually have a fast Internet connection
  • in the spirit of other SDK (like the AIR SDK)
    1x SDK should be able to produce for different OS targets
  • it keep the production of .deb packages simpler

@zwetan
Copy link
Member Author

zwetan commented Dec 28, 2015

what a SDK release should produce ?

Windows

  • retamarin-installer.exe (then download/install a .deb)
    or redtamarin-0.4.1.exe (with the .deb embedded)
  • redtamarin-0.4.1_win64.deb
  • redtamarin-0.4.1_win32.deb

Macintosh

  • redtamarin-0.4.1.pkg
  • redtamarin-0.4.1_darwin-amd64.deb
  • redtamarin-0.4.1_darwin-i386.deb (do we really need 32-bit for Mac OS X?)

Linux

  • redtamarin-0.4.1_amd64.deb
  • redtamarin-0.4.1_i386.deb

what about the HTML doc generated by asdoc ?

  • additional package redtamarin-doc-0.4.1_amd64.deb ?
  • another tool to open online asdoc ?
    eg $ as3doc Shell which open http://docs.redtamarin.com/latest/shell/package-detail.html ?
  • another tool that convert HTML doc to CLI output ?
    usually it is the opposite, man to html is more researched than html to man
  • AIR app that open a local HTML doc ?
  • what about the HTML doc of additional tools like redbean ?
  • TBD

@zwetan
Copy link
Member Author

zwetan commented Jan 21, 2016

this issue take over #32 create a redtamarin SDK (google code Issue 53)

we already created a redtamarin as a zip
tested, not good enough

@zwetan zwetan added this to the 0.4.1 milestone Jan 29, 2016
@zwetan
Copy link
Member Author

zwetan commented Jan 29, 2016

see Redtamarin Packaging

@zwetan zwetan closed this as completed Jan 30, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant