Author Topic: SmartIndent refactoring question  (Read 33827 times)

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9693
Re: SmartIndent refactoring question
« Reply #30 on: November 06, 2012, 10:04:10 am »
I will look into it as soon as possible.
A very easy solution would be to move the manifest into sub-folders "HDL", "Cpp".... Then you don't need to rename and can run the ZIP commands in parallel w/o hassle.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: SmartIndent refactoring question
« Reply #31 on: November 06, 2012, 10:04:46 am »
you are correct I have run into issues, but that was very often pch problems (which seem to be the very nature of pch builds)  :P
and probably a few I don't remember, I can't even remember which wrong commands I used (could you please point them out to me again, would be good to have my mind refreshed   ;D )
Doesn't matter what kind of issues you've been having. I've almost never had issues with the package generators, because they know how to build software reliably and then install/uninstall it correctly.
In gentoo the two steps are tied together, but in rpm based distros is a tree step activity or two (if you make a repo, but I don't want to bother with this).

But never such problem where actually the build process itself is screwing up things (like those manifest files / zip files getting broken (?) for SmartIndent with parallel build).
Probably this is an exception, but the break-ability of manual make based builds is still there, especially if you don't use non-default prefix.


But never such problem where actually the build process itself is screwing up things (like those manifest files / zip files getting broken (?) for So could we adjust the makefile uninstall to just remove those directories (rm -rf - wise) at the end ?
No, because it is not safe. Stick to packages for healthy linux systems. This is the general rule. Every system maintainer will tell you this. This is of course if you want to be able to update the system. If you prefer to reinstall the whole system often doesn't matter much.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5516
Re: SmartIndent refactoring question
« Reply #32 on: November 06, 2012, 12:48:26 pm »
so basically what you are saying is, don't do sudo make install anymore.
But even when I specify a prefix, the problem will remain, since the uninstall in that area will also not clean up stuff correctly. It is however does manually delete things then.

Aside from that, I really do think, that a makefile should always clean up whatever it generated, even leaving empty directories is not nice.

Well I might go to a prefixe-ed cb install, but still based upon make install, because I am the only user on the system, it will be no problem that the other accounts will be unable to run it ;-)

I have no idea, how to end up with packages locally, could you give me some information on this ? (Opensuse)

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: SmartIndent refactoring question
« Reply #33 on: November 06, 2012, 01:28:04 pm »
so basically what you are saying is, don't do sudo make install anymore.
Yes, at least I don't do it

But even when I specify a prefix, the problem will remain, since the uninstall in that area will also not clean up stuff correctly. It is however does manually delete things then.
I don't use make uninstall, but a straight delete...

Aside from that, I really do think, that a makefile should always clean up whatever it generated, even leaving empty directories is not nice.
Probably there are errors or this is just how it works. I won't bother to fix it as I never use it. I would even vote to remove it if we make a poll.
at the other accounts will be unable to run it ;-)

I have no idea, how to end up with packages locally, could you give me some information on this ? (Opensuse)
Search the internet, I'm not sure what is used by opensuse for the building, but I'm sure there are some docs.
You can even start to provide opensuse repo for the nightlies. :)
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: SmartIndent refactoring question
« Reply #34 on: November 06, 2012, 01:35:25 pm »
You can even start to provide opensuse repo for the nightlies. :)
Looks like it already exists: http://forums.codeblocks.org/index.php/topic,17038.msg116402.html#msg116402

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: SmartIndent refactoring question
« Reply #35 on: November 08, 2012, 12:57:22 am »
I will look into it as soon as possible.
A very easy solution would be to move the manifest into sub-folders "HDL", "Cpp".... Then you don't need to rename and can run the ZIP commands in parallel w/o hassle.

@killerbot:

can you test the following patch, please:

Code
Index: src/plugins/contrib/SmartIndent/Makefile.am
===================================================================
--- src/plugins/contrib/SmartIndent/Makefile.am
+++ src/plugins/contrib/SmartIndent/Makefile.am
@@ -99,6 +99,8 @@

 CLEANFILES = $(pkgdata_DATA)

+.NOTPARALLEL: $(pkgdata_DATA)
+
 SmartIndentHDL.zip: manifest_hdl.xml
        PWD=`pwd` cd $(srcdir) && \
        cp manifest_hdl.xml ./manifest.xml && \
I can build with it, but there haven't been any issues before (with -j 2).
I tested with -j 4, but I have just a core2duo, so I might not have enough cores to break the build.

« Last Edit: November 08, 2012, 06:26:47 am by jens »

Offline Alpha

  • Developer
  • Lives here!
  • *****
  • Posts: 1513
Re: SmartIndent refactoring question
« Reply #36 on: November 08, 2012, 02:13:08 am »
Code
+.NOTPARALLELL: $(pkgdata_DATA)
Slightly off topic, but "parallel" is spelled with only one "l" at the end (so I assume this means a double "l" ending is the secret code used throughout the build system ;)).

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: SmartIndent refactoring question
« Reply #37 on: November 08, 2012, 06:29:12 am »
Code
+.NOTPARALLELL: $(pkgdata_DATA)
Slightly off topic, but "parallel" is spelled with only one "l" at the end (so I assume this means a double "l" ending is the secret code used throughout the build system ;)).


Oops, thank you.
I corrected the patch above.

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5516
Re: SmartIndent refactoring question
« Reply #38 on: November 08, 2012, 07:54:15 am »
yes, that works, I have committed this fix.