Giter Site home page Giter Site logo

PB6 C-Outout about pbasmui HOT 7 CLOSED

tajmone avatar tajmone commented on August 19, 2024
PB6 C-Outout

from pbasmui.

Comments (7)

tajmone avatar tajmone commented on August 19, 2024 1

There seems also a "Optimize generated code" option now. I guess this activates the optimizer of the c compiler and was the reason why they changed to C.

From what I understood, that's part of the options that can be passed to GCC, which is something that will need to be considered when integrating the C backend into PBAsmUI — my guess is that in most cases users will require just the raw (and unoptimized) C code for this tool, since the goal would be having access to the C sources to tweak them before recompiling them again.

If I remember correctly, GCC optimizations operate on bytecode directly, so the goal for PBAsmUI should be to allow compiling to C sources, edit them, and then recompile them again (with whatever options GCC offers).

But these are just guesses based on my past experience with GCC, and I haven't tried it PB6 yet.

I'm using windows most of the time, too. But I think I could also do simple tests with linux, if you tell me what do you want to have tested.

That's fine. I know some Linux and macOS PB users which I might ask to join for testing.

Once I've managed to finish and publish the current project I'm working on, I'll start looking into this.

from pbasmui.

tajmone avatar tajmone commented on August 19, 2024

That's a good idea! And it would also be a chance to clean-up the current repository and its code, which haven't been updated for quite a while.

I was thinking of waiting for PB6 to be officially released before embarking on this, just to make sure we have access to all the latest changes in the language and (most important) it's documentation, especially regarding the new compiler backend, all of which right now might still be subject to change.

But then, when I find some free time, I can start to polish up the repository and install the current Beta of PB6 and look into it, and maybe create a development branch for PB6, so that the tool could be almost ready for when PB6 is officially released.

Furthermore, a missing feature that the original author always wanted to add was the possibility of preserving the application Version Info (metadata manifest) on Windows, which now should be easy to achieve now that the PB IDE is open source.

Give me a few days (right now I have some work to finish) and I'll look into it.

BTW, @SIRprise, on which OSs do you use PB on? I'm only using PB under Windows right now, so it would be good to have someone who could help with cross-platform compatibility for the tool.

from pbasmui.

SIRprise avatar SIRprise commented on August 19, 2024

Oh, thanks for the quick response!
There seems also a "Optimize generated code" option now. I guess this activates the optimizer of the c compiler and was the reason why they changed to C.
I'm using windows most of the time, too. But I think I could also do simple tests with linux, if you tell me what do you want to have tested.

from pbasmui.

tajmone avatar tajmone commented on August 19, 2024

@SIRprise, I've been looking into this and I realize that we might be facing a problem regarding integration of the IDE code to handle version info, and other code that might be required to interface with the C backend, i.e. that this project is MIT Licensed and the PB IDE repository is GNU GPL, which are incompatible licenses.

One of the main reasons the PBAsmUI project was never finished was because we didn't have access to the required info on how to handle application version info, so that we could reuse that info when recompiling from custom tweaked FASM sources. That, and also some complicate aspects of handling PB project files (which can become quite entangled when some options are enabled, and which is not documented). Probably similar needs will be encountered for the new backend.

Now the IDE code is public, but due to license incompatibility it can't be integrated here. I could ask the original author if it's OK to switch to the GPL license, but the majority of the other libraries and assets I've collected so far are all MIT licensed. Also, the IDE project is dual licensed under GPL and Fantaise Software license, which might complicate things even further.

I'm no so sure it's worth the effort. Currently I'm using some custom scripts to generate ASM and/or preprocessed files from PB sources, which I've integrated directly in my file navigation tool (I don't use File Explorer, I use Altap Salamander, a proprietary tool which allows integration of scripts and plugins). Using a batch script, or creating a Ruby or Python script is quicker and doesn't require IDE integration via a tool.

Let's see what PB6 will look like once it's released in stable version. Honestly, I don't have big expectations like many others do. My general impression is that the PB language is becoming every year less usable, mostly due to poor standards choices which make it impractical to use it in production projects, especially in collaborative projects, since it doesn't blend-in well with the general ecosystem of the open source community.

Also, I don't really use much the PB IDE any more, I find it very clunky and impractical, and I prefer modern editors like SublimeText and VSCode. I only use the IDE for debugging, and a few other operations which are more practical therein, but almost never to actually edit code. So in the end, it would be better to invest time in a PB package for a decent editor, which could also support these features natively, rather than spending time writing a PB IDE tool.

from pbasmui.

SIRprise avatar SIRprise commented on August 19, 2024

@tajmone I don't understand that licensing problem: It is just a GUI for some CLI tools. I like the tool, but I don't see that there is an intellectual property to protect.

You are right with your thoughts about the editor and I also mensioned some problems I have with it in the german PB forum. And I also think the language could be dead in a few years. But for now I think the language itself is ok, it feels consistent if I don't use the examples from the help file.

from pbasmui.

tajmone avatar tajmone commented on August 19, 2024

I don't understand that licensing problem: It is just a GUI for some CLI tools. I like the tool, but I don't see that there is an intellectual property to protect.

The PBAsmUI was written by Horst Schaeffer, who originally made it available on his website as a freeware but without a license, then I asked him if it could releases it under MIT License, so I (and others) were free to change it, reuse it in other projects, etc.

Any source code is copyright of its creator by default, so it can't be reused in any way without explicit permission of its author. The MIT License is very permissive, it allows to reuse the code in any way (including commercial use) with the condition that the original MIT License text is fully quoted in the final application.

The PB IDE source code is released under the GNU GPL license + Fantasie Software License. The former is a well known open source license which imposes a long list of restrictions to its use (among them, the obligation of releasing any derivative work under the same license, and providing the full source code to end user). Unfortunately, the GPL license doesn't work well with other open source licenses due to some of its legal clauses being incompatible, which ultimately means that practically you can only use GPL licensed code and components in projects with the same license, and were all other components have the same license too. The additional Fantasie Software License complicates things further, for it's not clear whether it implies that derivative works should also be governed by the same license too, and whether it might affect compatibility with GPL licensed libraries, etc.

Legally speaking, the GPL license(s) are among the harder to interpret, and you really need to consult a lawyer to ensure that you're not violating its terms when using third party components under that license in your work.

For a tool like this one, it's strongly desirable that we might reuse part of the IDE sources, e.g. to handle scanning project files (the PB project file has undergone some tweaks in the last year), to handle the Manifesto info for Windows binaries (also stored in the project files), etc. Otherwise, we'll have to reimplement the whole projects systems from scratch, and tweak it whenever its format changes (undocumented), which is probably going to happen with PB6, since it's introducing a secondary backend and it will have to store C preferences in project files too (either implicitly on a per file or per folder base, depending on user settings, or explicitly in case of a project file).

I remember that when I was working on the PBAsmUI I wasn't able to handle some edge cases, e.g. the IDE can compile a single module with different settings, depending on whether you're compiling it as part of a project or as a standalone file. The PBAsmUI needs to be able to parse project files and IDE settings to work out these options in order to correct recompile the modified ASM/C sources, since it has to bypass the PBCompiler to achieve that. For these same reasons the original author never managed to complete the project.

Originally, PB projects files were neither documented nor their code available for study, whereas now we have at least access to their sources to study them, but we can't reuse that code except at the conditions of the GPL License.

Licenses compatibility is a known problem. With open source languages the tendency is to release libraries for that language in the same license as the language project, to maximize usability in its ecosystem, so in the Python world the most used license is MIT, in Rust MIT + Apache, etc. With proprietary languages is harder, since every user will chose an arbitrary FOSS license for its code, depending on personal choices, so the best we can hope if that most users will use permissive licenses (MIT, Apache, BSD, etc.).

Truth is that in the PB community it's common practice to just share code without a license, by saying "enjoy" or similar phrases which clearly indicate the author's will to share it with others, but which provides no legal ground for its reuse in any contexts beside personal use. When publishing third party code and assets here on GitHub, you have to strictly abide to Copyright laws and licenses, as indicated in the GitHub terms of use and EULA.

from pbasmui.

tajmone avatar tajmone commented on August 19, 2024

I'm moving this Issue to Discussions, since it's implementation is still an open possibility once PB6 is out and/or we can solve the license issues.

from pbasmui.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.