Hi,
I'm trying to "resurrect" old Turbo Vision library to use it on Linux/Solaris/*BSD.
I know that it is quite well-maintained version of TVision on
https://git.code.sf.net/p/tvision/code, but it contains many things which extend or changes many original Borland version functionalities, so I've started working on Ioannis Tziakos fork. Ioannis week ago transferred his tvision repo to my account so now it is available on
https://github.com/kloczek/tvision
If anyone may be interested help with this code feel free to join and/or sens some patches ar PR.
What I've stared has entirely non-commercial needs. Simple I plan to write few OSS TVision based applications which maybe even some people find useful :)
Simple, I always been dreaming about using TVision on U*nices as +20y ago I've been using TVision on DOS :P (both Pascal and C++ versions)
So far I've done:
- Full cleanup of the am/ac/lt build framework
- Fixed all compile errors using g++ 8.1.1 and most of the compile warnings
- Added easy build of the rpm package out of the source tree by:
"./boostrap.sh; ./configure; make dist-gzip; rpmbuild -ta tvision-0.8.0.tar.gz"
Everything passes as well dist-check target
- Added support for pkgconfig to detect tvsion library is it installed or not
- The whole git repo is now hooked to travis-ci.com where after each commit or PR request whole code (+ eventual PR patches as well) passes test build
So here starts kind of obstacles.
As I never passed regular C++ course and I'm still learning C++, I found some issue with my current code. Simple it fails on gcc/g++ 4.8.4 used on travis-ci.com. What is odd to me that I don't see reported on gcc/g++ 4.8.4 on my system where I have gcc 8.1.1.
Here is last build log
https://travis-ci.org/kloczek/tvision/builds/389881026
also, here are two files involved in this error:
https://github.com/kloczek/tvision/blob/master/tvision/new.cc#L171
https://github.com/kloczek/tvision/blob/master/tvision/buffers.h#L75
I would glad if someone would help me understand nature of this error and/or write affected lines to be able to use this code on gcc/g++ 4.8.x and 8.1.x :)
I have as well the second kind of question(s).
I found that TVision is not well indented/formatted. Looks like different parts of the code are indented slightly different styles or indentation has been done manually. So far usually I've been using GNU indent. However most of my own work on this area was related to write C code, and typical local directory .indent.pro file content like with
-kr
-i8
-bad
-pcs
-l80
Was enough to have well formatted C code. However, I just found that the same set of intent options does not work well enough with C++. Additionally, I found that indent trashes C++ code. If it is used multiple times, it multiplies "const" keyword. Just found that GNU indent maintainer has no time to maintain indent code (
https://github.com/thentenaar/indent).
GNU indent changes cde like
Complex method_name(arguments) const {
}
to:
Complex method_name(arguments) const const {
}
Nevertheless, my questions related to C++ indentation are:
- does anyone fixed "const" keywords "multiplication issue?(using google I was unable to find any traces of such fixes)
- maybe someone has some set of indent options which could format TVision code with as much as possible similar style to original style?
- maybe someone can recommend some other C++ indentation tool?
Thank you for any help or suggestions
kloczek