Developer forums (C::B DEVELOPMENT STRICTLY!) > Plugins development

FortranProject plugin building via autotools in Linux

(1/2) > >>

grem:
Hello, all!

Recently I start to use FortranProject plugin (in windows binary) and little later was surprised that in Linux (I also use Gentoo)
the building the Code::Blocks  with "--with-contrib-plugins=all" doesn't build mentioned plugin.
So I tried to write patch for Code::Blocks autotools files that allows also to build this plugin too.

I wrote it within Gentoo codeblocks-17.12 package update (codeblocks-17.12.ebuild) and at the moment it could be found on my github.
The only thing is that after it's applying autoconf and automake must be reruned as the "configure.ac" file will be modified.

I tested this patch for FortranProject that supplied with codeblocks 17.12 source code. After codeblocks and plugins building the COde::Blocks launches
and plugin works successfully (even with automake-1.15 while other codeblocks sources makefiles were generated with automake-1.13).

oBFusCATed:
1. Please post a patch to the sf.net ticket page. Here it will be forgotten.
2. FortranProject is a separate external repo. So probably it is better idea to make it a separate installation/package with its own autotools. Here you can see how to setup autotools for cb plugin https://github.com/obfuscated/cb_editor_navigation

grem:

--- Quote from: oBFusCATed on February 26, 2018, 01:38:56 pm ---1. Please post a patch to the sf.net ticket page. Here it will be forgotten.

--- End quote ---

Thank you for reply!
I also shall post patch at sf codeblocks tickets page later.


--- Quote from: oBFusCATed on February 26, 2018, 01:38:56 pm ---2. FortranProject is a separate external repo. So probably it is better idea to make it a separate installation/package with its own autotools. Here you can see how to setup autotools for cb plugin https://github.com/obfuscated/cb_editor_navigation

--- End quote ---

The problem is that FortranProject plugin sources are already presented in "codeblocks_17.12.tar.xz" release source-archive (under /src/plugins/contrib)
that is avalable at Code::Blocks download page.
And also it was presented early in the "codeblocks_16.01.tar.gz" release source-archive.

So patch is for official Code::Blocks tarball and it not only adds "FortranProject" Makefile.am files
and also modifies "src/plugins/contrib/Makefile.am" and "configure.ac" of codeblocks sources itself.

The patch is written in a way that corresponds the others plugins "Makefile.am" and has similar structure.

I hope it will be usefull for official tarballs that contains all plugins and allows to build also FortranProject plugin for Linux systems
when "--with-contrib-plugins=all" or "--with-contrib-plugins=FortranProject" is set. Or could be disabled when "--with-contrib-plugins=all,-FortanProject"  is set.

oBFusCATed:
Ok, but patches cannot be applied against released source code. They can only be applied against current trunk/master branches.

There are several problems with your patch (random order):
1. FortranProject cannot be part of "all" because the source code is not present in git clones of the svn repo. So adding it to "all" will break the build for all people using git.
2. Testing the patch with git based repo is not easy, because the code is not present in git.
3. Modifying files in  src/plugins/contrib/FortranProject is not possible, because these are files in another repository. This repository is managed by another project.

@Morten: It would be good if you can post why the fortran project repo has been made as external repo...

grem:
I created Code::Blocks ticket today.


--- Quote from: oBFusCATed on February 26, 2018, 08:50:41 pm ---Ok, but patches cannot be applied against released source code. They can only be applied against current trunk/master branches.

--- End quote ---

Yes, it's a problem. I don't know how release-tarballs of Code::Blocks are formed and when FortranProject sources are added/merged to/with it.
So the patch really could be applied only to release-tarball and as I can see release-17.12 branch actually doesn't contain this plugin folder.

It's pity that only windows binaries offers this plugin, so I proposed this patch for linux release tarball when it forms.


--- Quote from: oBFusCATed on February 26, 2018, 08:50:41 pm ---There are several problems with your patch (random order):
1. FortranProject cannot be part of "all" because the source code is not present in git clones of the svn repo. So adding it to "all" will break the build for all people using git.
2. Testing the patch with git based repo is not easy, because the code is not present in git.
3. Modifying files in  src/plugins/contrib/FortranProject is not possible, because these are files in another repository. This repository is managed by another project.

@Morten: It would be good if you can post why the fortran project repo has been made as external repo...

--- End quote ---

Navigation

[0] Message Index

[#] Next page

Go to full version