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

Integrate build instructions into the GHDL documentation #280

Closed
Paebbels opened this issue Feb 13, 2017 · 39 comments
Closed

Integrate build instructions into the GHDL documentation #280

Paebbels opened this issue Feb 13, 2017 · 39 comments
Assignees
Labels
Documentation: General General documentation issues.
Milestone

Comments

@Paebbels
Copy link
Member

This is a collective issue to gather notes and workitems for the integration of the build documentation into the official documentation on ReadTheDocs.

I think we need a new table of contents structure like this:

  • Introduction (Project overview, quick start)
  • GHDL usage (explain all options and work flows)
  • Getting GHDL (from package, distribution, GH releases, ...)
  • Building instructions
    • GHDL
      • GCC backend
        • Linux
      • LLVM backend
        • Linux
        • Mac OS?
        • Windows MinGW 32/64
      • Mcode backend
        • Linux
        • Windows GNAT GPL
        • Windows MinGW 32/64
    • Containers
    • Vendor Primitives
      • Alters / Intel
      • Lattice
      • Xilinx ISE
      • Xilinx Vivado
  • Contributing
  • License
@eine
Copy link
Collaborator

eine commented Feb 13, 2017

These are the files I found, which I think could be moved to the doc:

  • BUILD.txt

  • dist/mcode/README

  • dist/gcc/INSTALL

  • gcc/README

  • dist/gcc/ANNOUNCE

  • NEWS

  • COPYING

However,

  • I think that it is still interesting to keep a copy of 'COPYING' and a minimum version of 'BUILD.txt' in the root. Maybe just extending the section in the ./README can be enough, instead of 'BUILD.txt'. At the same time, 'COPYING' can be written in markdown and copied to doc as 'License' on readthedocs deploy.
  • It'd be very useful to add some README/INSTALL and COPYING to each release. Some parts of the doc can be used to generate these on travis-ci deploy.
  • I'd add a specific 'NEWS' section (maybe renamed to 'Release log'), but keep the file in the root (renamed to *.md) so that it is copied on deploy.
  • dist/gcc/README, dist/gcc/INSTALL and dist/mcode/README would go directly to the doc.
  • No idea where to put dist/gcc/ANNOUNCE. But I think that it should be kept somewhere.

Additional notes:

  • gcov only with gcc
  • Backtraces optional -patchable-

@tgingold
Copy link
Member

tgingold commented Feb 14, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 14, 2017

Please, do not modify COPYING as that's legal stuff. It is OK to get an official COPYING.md (if that does exist) from the FSF, but otherwise keep it as it.

Just a pair of weeks ago: https://gist.github.com/jnrbsn/708961#gistcomment-1984787
https://www.gnu.org/licenses/gpl-3.0.md


Readthedocs allows to show multiple versions (see [example], bottom left). I tried to activate branches ghdl-0.31, ghdl-0.32, ghdl-0.33, but it looks like there was still no a readthedocs-prepared doc. I think, it would be interesting to activate at least two versions from now on: the lates stable realease (0.33 now) and the pre-release/dev-release/nightly-release (0.34-dev now).

The doc targets the end user. It is ok to have a chapter on building/installing ghdl (as well as a chapter on the internals), but if that gets too long, I think we'd better to have two doc.

Two doc? Or one in master and another one in a different branch? I think it is easier to try to keep it in a single doc with separated chapters. It it gets too long, I think that a dev-doc branch can be more useful than having two doc dirs.

Very old file, not used anymore. To be removed ?

Proposed to save it because it seems to be your very first announce of GHDL, isn't it? Just for nostalgic reasons then.


By the way, there are some additional branches/tags shown in the readthedocs settings:

  • v0.33 (d3d07ba)
  • ghdl-0.31_release
  • ghdl_0.31dev

Are they used for something?

@tgingold
Copy link
Member

tgingold commented Feb 14, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 18, 2017

@tgingold
Copy link
Member

tgingold commented Feb 18, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 20, 2017

Since the content of BUILD.txt is moved to the docs, what shall we do with this line?
gcc version 6.3 [do not modify this line as this is read by scripts].

@Paebbels
Copy link
Member Author

@tgingold
Can we move this security check to configure and maybe also integrate the switching of ortho-lang.c based on the configured / found GCC version?

@tgingold
Copy link
Member

Yes, we should select the right ortho-lang.c according to the gcc version.

@eine
Copy link
Collaborator

eine commented Feb 20, 2017

@tgingolg, should the contributor list be included in Copyrights or in Contributing?

@tgingold
Copy link
Member

tgingold commented Feb 20, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 21, 2017

@tgingold, what do you think about adding a Contributers License Agreement to the project? The following example is taken from PoC:

We require all contributers to sign a Contributor License Agreement (CLA). If you don't know whatfore a CLA is needed and how it prevents legal issues on both sides, read this short blog post. PoC uses the Apache Contributor License Agreement to match the Apache License 2.0.

So to get started, sign the Contributor License Agreement (CLA) at CLAHub.com. You can authenticate yourself with an existing GitHub account.

@Paebbels
Copy link
Member Author

We would need a CLA for GPLv2.

Both existing CLA services are not really good, but CLAHub seems to develop new features whereas the SAP service (CLAassistant) hasn't seen any updates ...

Are there other services that integrate into GitHub? Python uses a special service from Adobe :(

@eine
Copy link
Collaborator

eine commented Feb 21, 2017

We would need a CLA for GPLv2.

I think that it can be covered with http://contributoragreements.org/chooser/

However, I wanted to discuss about requiring it, since some/any potential contributors might not bother to contribute if they are required to sign.

Are there other services that integrate into GitHub?

I'm really new to this. Just saw your example and thought it is worth talking about it. I read this and then I found the following statement here:

Additionally, the GitHub CLA is presented with user experience in mind. It’s short, comes with a two point summary and this FAQ, and can be signed with one click when making a pull request.

Note the part I put in bold. If we add this requirement, it'd be great to have that option, so that it is just a checkbox when creating a new PR. There are still a few flaws:

  • What would happen when a maintainer directly pulls from an external repo (like the other day did @Paebbels with my branch, so that we didn't have to open a PR).
  • Could the contributor choose among a few options, instead of just checking a box?
  • How is that info stored? Ideally git would have a field added to each commit to reference the agreement, but I don't know if such a feature exists.

@Paebbels
Copy link
Member Author

Both mentioned services offer a CSV file for download.

CLA assistant is GIST based what I dislike, but supports CLA versioning

CLA hub has a nicer integration.

Contributing is then limited to PRs or we know we have a signed CLA for this users private repository. I must not contain content from other users.

I can give you access to a test repo or you create your own playground :)

@eine
Copy link
Collaborator

eine commented Feb 21, 2017

I can give you access to a test repo or you create your own playground :)

I'm quite busy now, leaving the doc tidy. We'll wait to see what @tgingold thinks, and I will ask you for access then ;)

@tgingold
Copy link
Member

tgingold commented Feb 22, 2017 via email

@Paebbels
Copy link
Member Author

We got one fix before the CLA was active. Currently, CLAs are active for all PRs, but a maintainer can merge even if the CLA plugin says unsigned. It's like a Travis did not build message, You can ignore it. But the user still sees the demand to sign the CLA while he submits the PR.

As far as I know all bigger open source projects go for CLAs. I have to sign one for Python (through a weird Acrobat online signing service).

In case of Apache, everything is included in the original License. The CLA is more or less an explicit notice that one rule of the License will now be applied to your code snippet :)

@eine
Copy link
Collaborator

eine commented Feb 22, 2017

As an intermediate solution, is there any way to show a note and a checkbox when a user is to send a PR? Contributing to a project explicitly licensed under GPLv2 implies giving the code under known conditions. Taking the idea of the Apache CLA, we could just provide a note claiming attention on the fact that they are contributing under GPLv2 (and/or CC-BY-SA-40).

The difference between this and the CLA is that the username and email in the commit would be enough to identify the user. The CLA requires more personal data, doesn't it?

If such a note is not possible, we could just make it clear in the 'Contributing' page, apart from 'Copyrights'.

@tgingold
Copy link
Member

tgingold commented Feb 22, 2017 via email

@tgingold
Copy link
Member

tgingold commented Feb 22, 2017 via email

@Paebbels
Copy link
Member Author

Did you sign on your own or did your employer sign ?

I'm a student, every code is mine :). But on the other hand, In Germany, your employer doesn't need to sign for your private code. It only applies to code created during work time. So it's not so restrictive like in the US where you have to ask your employer for every code snippet you want to supply.

For individual, CLA is somewhat easy. For employees, that could be much more difficult.

At that point, it's important to use well known CLAs or licenses in general, so they have to do only one check per license name/version.

We could adopt the same strategy.
The GPL doesn't work that way as far as I know.

Did you ever sign a CLA ?
I can send you a copy of my CLA for Python. (private email)

it allows to change the license.
Does GPL allow to change the license?

Are you thinking of changing the license? Personally I don't like GPL but that's why I write libraries and no end user tools. I'm OK with GPL if I contribute snippets.

@eine
Copy link
Collaborator

eine commented Feb 22, 2017

Did you ever sign a CLA ?

No, I did not. I just read the quoted part from PoC, the references there, and these:

@tgingold
Copy link
Member

tgingold commented Feb 22, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 22, 2017

@tgingold, still, you could remove the contributions made by others and, if needed, reimplement those yourself. Most of the contributions are auxiliary to the GHDL core, isn't it? Not proposing it, just pushing the case to the limit.

@tgingold
Copy link
Member

tgingold commented Feb 22, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 22, 2017

Once you will have rewritten the doc, it would be much difficult for the doc!

Please, don't you dare compare a 15 years of works with less than a week effort!

@eine
Copy link
Collaborator

eine commented Feb 24, 2017

@tgingold, I am with the QuickStartGuide now:

  • Exporting to GtkWave is mentioned. Currently the following formats are supported by GtkWave: VCD, FST, LXT, LXT2, VZT, and GHW. However, supports 'only' three of them (VCD, FST and GHW). Shall I move --read-opt-file, --write-opt-file, --vcd, --vcdgz, --fst and --wave from GHDL Usage / Simulation and runtime / Simulation options a new subsection named GHDl Usage / Simulation and runtime / Export waves? The point is to add a brief explanation on why those three formats where chosen only. I'm not making it imply it is insufficient, but to explain why other additional formats add no functionality.

  • On top of that, in the manual of GtkWave, this is said:

Source code annotation is currently not available for VHDL, however all of GTKWave's other debug features are readily accessible. VHDL support is planned for a future release.

Does that depend on you/GHDL or is GtkWave which needs to be adapted? Is it somewhere in your todo's? Not trying to push it up, I just want to have a reference to write a sentence about it. It seems that interactive or pseudo-interactive simulation for Verilog is supported. Then, I think it is worth mentioning, so that people who have previously used icarus (because of icestorm) are aware of the differences. Making it explicit might help contributions.

  • Is XML/JSON output documented anywhere? Are those additional options for disp-tree or separate options?
  • Does --no-run have any other use besides elaborating the design only, when mcode backend is used? Can I put a note telling it is useless with GCC/LLVM?

@tgingold
Copy link
Member

tgingold commented Feb 24, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 24, 2017

@tgingold, thanks. Just edited. Can you check the last two questions?

@tgingold
Copy link
Member

Sorry, I missed them from the email.

The json format is not documented, except it should be self-documented. Maybe worth adding a small example ?

The XML format (for --file-to-xml) is not documented and it may change as it shows internal stuff.

--no-run can be useful for gcc/llvm/mcode. It simply stops simulation just before the first cycle. But it can be used to display the hierarchy (with --disp-tree).

@eine
Copy link
Collaborator

eine commented Feb 24, 2017

The json format is not documented, except it should be self-documented. Maybe worth adding a small example ?

I'll put a todo and recheck when I arrive there.

--no-run can be useful for gcc/llvm/mcode. It simply stops simulation just before the first cycle. But it can be used to display the hierarchy (with --disp-tree).

I get it. With GCC/LLVM, it does something besides disp-tree? Will any check be done with was not done during elaboration?

@tgingold
Copy link
Member

tgingold commented Feb 24, 2017 via email

@eine
Copy link
Collaborator

eine commented Feb 24, 2017

Then, as a final clarification, it is not exactly the same to run the binary executable generated after -e directly, than to actually use -r? Is it only true for the first example of the Quick Start Guide where a single VHDL Hello world program is compiled?

Since I've always used the mcode version, I thought that the binary generated with GCC/LLVM was a replace for GHDL. That is, that I could distribute that binary alone, without GHDL itself.

@tgingold
Copy link
Member

tgingold commented Feb 24, 2017 via email

@tgingold
Copy link
Member

tgingold commented Feb 25, 2017 via email

@Paebbels Paebbels added this to the v0.34-b6 milestone May 31, 2017
@Paebbels Paebbels self-assigned this May 31, 2017
@eine
Copy link
Collaborator

eine commented Dec 9, 2017

I thought we had partially merged this to master, and the remaining parts where docker and longer tutorials. My bad.

I rebased, updated, cleaned up and rechecked it. I think it is ready to merge now: #482.

@eine
Copy link
Collaborator

eine commented Dec 10, 2017

@Paebbels , @tgingold , now that it is merged, branch new-documentation-structure should be either reset or deleted. Also, the version should be disabled or wiped in RTD.

@tgingold
Copy link
Member

tgingold commented Dec 10, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation: General General documentation issues.
Projects
None yet
Development

No branches or pull requests

3 participants