RolandHughes / ls-cs

Cross platform C++ libraries
18 stars 0 forks source link

Test on MX Linux #8

Open RolandHughes opened 5 days ago

RolandHughes commented 5 days ago

I have merged into master ls-cs-0.1.0. On Unbuntu 20.04 it can be built, the -dev debian installed, and the first example program will run. Need it tested on MX in case there are tweaks.

  1. Pull Master
  2. cd to where you pulled
  3. ./LsCs-Deb-build-dependencies.sh
  4. ./build-LsCs-deb.sh (assuming dependencies install)
  5. Install the -dev.deb it creates. I use the GUI installer, but you should already have all dependencies.
  6. cd to the examples directory
  7. ./build-examples.sh choose only the console-hello

I'm off to create some more examples then test on RPM

chatchoi commented 3 days ago

GObject2 is reported to be not found, even though it's there on CMakeCache.txt.

Could NOT find GObject2 (missing: NAME_MISMATCHED)

https://cmake.org/cmake/help/latest/module/FindPackageHandleStandardArgs.html

chatchoi commented 3 days ago

$ cmake --version cmake version 3.25.1

CMake suite maintained and supported by Kitware (kitware.com/cmake).

RolandHughes commented 2 days ago

What version and flavor of Linux?

I will check what version of CMake I have on Ubuntu 20.04. I will also test a build on Linux Mint since I have that running on another machine.

Guess I will try to create an MX VM and try to reproduce.

Well, I don't like AI generated answers . . . but . . . this one makes sense.

[AI] If you're encountering the error "gobject2 missing" while using CMake on Linux, it likely means that the development package for gobject-introspection is not installed on your system. [/AI]

The version number may be off here. Use my Linux Cheats post to command line search for proper package name.

sudo apt-get update sudo apt-get install libgirepository1.0-dev

Someone on MX team pooched the packaging because CMake is only partially installed.

For Fedora/CentOS/RHEL

sudo yum update sudo yum install gobject-introspection-devel

Arch based distros

sudo pacman -Syu gobject-introspection

Be sure to remember the name of the package. Hopefully it has a "meta" package so we don't have to play games in the dependecies scripts. You should also report the bug to kitware.com if this really solves the problem. They have a packaging issue.

chatchoi commented 2 days ago

The package libgirepository1.0-dev is indeed not installed. Thank you.

chatchoi commented 1 day ago

Even if I have libgirepository1.0-dev installed, it still said it can't find GObject2. But it will build anyway. I don't understand why there is a separate find for GObject2, because GLib2 will also pull GObject2.

chatchoi commented 1 day ago

There are two packages generated: LsCs-0.1.1-amd64.deb and LsCs-0.1.1-amd64-dev.deb. You told me to install the -dev package so I installed it. But I found something strange. Synaptic Package Manager reports the size of lscs to be 178GB. Yes, it really reports lscs to be 178GB in size. This is definitely wrong.

chatchoi commented 1 day ago

gui-hello example failed to build.

-- Configuring done CMake Error at src/CMakeLists.txt:12 (add_executable): No SOURCES given to target: gui-hello

chatchoi commented 13 hours ago

Fixed all of the build issues of examples due to mistakes in find and replace. All examples build now and running fine. gui-hello prints these gibberish on the terminal, though:

QPixmap::load() Unable to load pixmap file :LsCs/styles/commonstyle/images/fusion_groupbox.png QXcbConnection::handleXcbError() XCB error = 3 (BadWindow), sequence = 536, resource id = 19271398, major code = 40 (TranslateCoords), minor code = 0

RolandHughes commented 10 hours ago

Don't try to make gui-hello work.

I don't know what you "fixed" with search and replace. I have a ton of fixes in the new branch. I just pushed what I had to 0.1.1 branch.

There are some heinous coding issues in qdireiterator.cpp that have to be fixed. I just don't have the time right now. Still have about 350 acres of corn to get out.

Please don't waste any time on gui-hello.

I believe with the code in the 0.1.1 branch that I just pushed it "might" run if you copy the xcb file it wants to the local executable directory. Don't know, waiting on build, then I have to find supper and get some sleep. 4am isn't getting further away.

RolandHughes commented 9 hours ago

Ummmm

Please don't work in Master. I know that needed to be done for the README, but it can create some significant merge issues.

Either checkout and work in the current dev branch 0.1.1 or create a branch to work in. We need to coordinate the stuff you wish to work on so it isn't the same stuff I'm working on. :)

If you want to take a stab at something that won't conflict with anything anytime soon, create a branch from Master and fix the Cups compiler warnings like this.

      |                      ^~~~~~~~~~~~~
/home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.cpp:248:62: warning: ‘ppd_option_t* ppdFindOption(ppd_file_t*, const char*)’ is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
  248 |         resolutions = ppdFindOption( m_ppd, "HPPrintQuality" );
      |                                                              ^
In file included from privateinclude/QtGui/private/qprint_p.h:33,
                 from include/QtGui/qplatform_printdevice.h:27,
                 from /home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.h:30,
                 from /home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.cpp:24:
/usr/include/cups/ppd.h:380:22: note: declared here
  380 | extern ppd_option_t *ppdFindOption(ppd_file_t *ppd, const char *keyword)
      |                      ^~~~~~~~~~~~~
/home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.cpp:266:69: warning: ‘ppd_option_t* ppdFindOption(ppd_file_t*, const char*)’ is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
  266 |         resolutions = ppdFindOption( m_ppd, "DefaultHPPrintQuality" );
      |                                                                     ^
In file included from privateinclude/QtGui/private/qprint_p.h:33,
                 from include/QtGui/qplatform_printdevice.h:27,
                 from /home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.h:30,
                 from /home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.cpp:24:
/usr/include/cups/ppd.h:380:22: note: declared here
  380 | extern ppd_option_t *ppdFindOption(ppd_file_t *ppd, const char *keyword)
      |                      ^~~~~~~~~~~~~
/home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.cpp:266:69: warning: ‘ppd_option_t* ppdFindOption(ppd_file_t*, const char*)’ is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
  266 |         resolutions = ppdFindOption( m_ppd, "DefaultHPPrintQuality" );
      |                                                                     ^
In file included from privateinclude/QtGui/private/qprint_p.h:33,
                 from include/QtGui/qplatform_printdevice.h:27,
                 from /home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.h:30,
                 from /home/developer/github_projects/ls-cs/src/plugins/printerdrivers/cups/qppdprintdevice.cpp:24:
/usr/include/cups/ppd.h:380:22: note: declared here
  380 | extern ppd_option_t *ppdFindOption(ppd_file_t *ppd, const char *keyword)
      |                      ^~~~~~~~~~~~~

20.04 Ubuntu is the oldest we will support . . . now that Canonical is extorting people to keep 18.04 alive.

Depending on how much machine you have, you may want to install Oracle VirtualBox and set up a 20.04 VM to do dev in then test stuff in MX. Hint, create a shared directory for your VM to mount so you can just copy stuff between host and VM.

Updating the Cups calls should be rather straight forward . . . operative word being should. One would think there is some documentation online on how to convert.

RolandHughes commented 9 hours ago

Unless you are really good with git command line (I'm not) you might want to get a free version of GitKraken.

Btw, no, latest changes did not fix gui-hello. As I said, there are some deeply rooted coding errors that have to be worked around.

Ultimately, we should never need to tweak RPATH. The only files one should ever have to deploy are the executable and any translation/data files you need. Every executable must run using the system installed runtime.

Can't look at it anymore tonight. It will be several weeks before I "free up" enough to actually code.

Thanks

mh466lfa commented 7 hours ago

If you need performance then you should use KVM instead of VirtualBox. VirtualBox is very slow.