Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Dave Yeo

Pages: [1] 2 3 ... 301
1
Hardware / Re: ArcaOS on a HP EliteBook 840 G3?
« on: Today at 09:47:11 am »
Ok, see  readusb.txt in ArcaOS-5.1.0-en.7z and how to use dfsanwin.exe to create your stick under Windows. I've never done it

2
Programming / Re: Duplicate symbol error
« on: Today at 09:38:49 am »
So what does "moc_screensaver.cpp" contain ?

Good question. Seems to be a generated file that is not compiled and only in build/ which I created to do the compile in.
Code: [Select]
/****************************************************************************
** Meta object code from reading C++ file 'screensaver.h'
**
** Created by: The Qt Meta Object Compiler version 67 (Qt 5.15.2)
**
** WARNING! All changes made in this file will be lost!
*****************************************************************************/

#include <memory>
#include "../src/screensaver.h"
#include <QtCore/qbytearray.h>
#include <QtCore/qmetatype.h>
#if !defined(Q_MOC_OUTPUT_REVISION)
#error "The header file 'screensaver.h' doesn't include <QObject>."
#elif Q_MOC_OUTPUT_REVISION != 67
#error "This file was generated using the moc from 5.15.2. It"
#error "cannot be used with the include files from this version of Qt."
#error "(The moc has changed too much.)"
#endif

QT_BEGIN_MOC_NAMESPACE
QT_WARNING_PUSH
QT_WARNING_DISABLE_DEPRECATED
struct qt_meta_stringdata_ScreenSaver_t {
    QByteArrayData data[4];
    char stringdata0[28];
};
#define QT_MOC_LITERAL(idx, ofs, len) \
    Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
    qptrdiff(offsetof(qt_meta_stringdata_ScreenSaver_t, stringdata0) + ofs \
        - idx * sizeof(QByteArrayData)) \
    )
static const qt_meta_stringdata_ScreenSaver_t qt_meta_stringdata_ScreenSaver = {
    {
QT_MOC_LITERAL(0, 0, 11), // "ScreenSaver"
QT_MOC_LITERAL(1, 12, 6), // "enable"
QT_MOC_LITERAL(2, 19, 0), // ""
QT_MOC_LITERAL(3, 20, 7) // "disable"

    },
    "ScreenSaver\0enable\0\0disable"
};
#undef QT_MOC_LITERAL

static const uint qt_meta_data_ScreenSaver[] = {

 // content:
       8,       // revision
       0,       // classname
       0,    0, // classinfo
       2,   14, // methods
       0,    0, // properties
       0,    0, // enums/sets
       0,    0, // constructors
       0,       // flags
       0,       // signalCount

 // slots: name, argc, parameters, tag, flags
       1,    0,   24,    2, 0x0a /* Public */,
       3,    0,   25,    2, 0x0a /* Public */,

 // slots: parameters
    QMetaType::Void,
    QMetaType::Void,

       0        // eod
};

void ScreenSaver::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
{
    if (_c == QMetaObject::InvokeMetaMethod) {
        auto *_t = static_cast<ScreenSaver *>(_o);
        Q_UNUSED(_t)
        switch (_id) {
        case 0: _t->enable(); break;
        case 1: _t->disable(); break;
        default: ;
        }
    }
    Q_UNUSED(_a);
}

QT_INIT_METAOBJECT const QMetaObject ScreenSaver::staticMetaObject = { {
    QMetaObject::SuperData::link<QObject::staticMetaObject>(),
    qt_meta_stringdata_ScreenSaver.data,
    qt_meta_data_ScreenSaver,
    qt_static_metacall,
    nullptr,
    nullptr
} };


const QMetaObject *ScreenSaver::metaObject() const
{
    return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
}

void *ScreenSaver::qt_metacast(const char *_clname)
{
    if (!_clname) return nullptr;
    if (!strcmp(_clname, qt_meta_stringdata_ScreenSaver.stringdata0))
        return static_cast<void*>(this);
    return QObject::qt_metacast(_clname);
}

int ScreenSaver::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QObject::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::InvokeMetaMethod) {
        if (_id < 2)
            qt_static_metacall(this, _c, _id, _a);
        _id -= 2;
    } else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
        if (_id < 2)
            *reinterpret_cast<int*>(_a[0]) = -1;
        _id -= 2;
    }
    return _id;
}
QT_WARNING_POP
QT_END_MOC_NAMESPACE

As it doesn't seem to get compiled, can probably be ignored, but maybe can be treated as an include.

3
Programming / Re: Duplicate symbol error
« on: Today at 02:50:28 am »
Are you sure the codepath below isn't being called?
Code: [Select]
#ifdef OS_UNIX_NOT_MAC
#include "powersaving.h"
#endif

https://github.com/smplayer-dev/smplayer/blob/master/src/screensaver.cpp#L24C1-L26C7

Afterall, we are often OS_UNIX and not MAC :)

Anyways, commented out the OS_UNIX_NOT_MAC chunk, no difference. Also fixed the pro file so winscreensaver.cpp is compiled.
Ran emxexp on screensaver.obj and don't see the duplicate symbol,
Code: [Select]
K:\work\smplayer\build>emxexp screensaver.obj
  ; segment DATA32
  "__ZN11ScreenSaver16staticMetaObjectE"                                ; magics
eg='DATA32' len=36

  ; segment TEXT32
  "__ZN11ScreenSaverD2Ev"                                               ; magics
eg='TEXT32' len=21
  "__ZN11ScreenSaverD1Ev"                                               ; magics
eg='TEXT32' len=21
  "__ZN11ScreenSaverD0Ev"                                               ; magics
eg='TEXT32' len=21
  "__ZNK11ScreenSaver10metaObjectEv"                                    ; magics
eg='TEXT32' len=32
  "__ZN11ScreenSaver18qt_static_metacallEP7QObjectN11QMetaObject4CallEiPPv"
            ; magicseg='TEXT32' len=71
  "__ZN11ScreenSaverC2EP7QObject"                                       ; magics
eg='TEXT32' len=29
  "__ZN11ScreenSaverC1EP7QObject"                                       ; magics
eg='TEXT32' len=29
  "__ZN11ScreenSaver6enableEv"                                          ; magics
eg='TEXT32' len=26
  "__ZN11ScreenSaver7disableEv"                                         ; magics
eg='TEXT32' len=27
  "__ZN11ScreenSaver11qt_metacastEPKc"                                  ; magics
eg='TEXT32' len=34
  "__ZN11ScreenSaver11qt_metacallEN11QMetaObject4CallEiPPv"             ; magics
eg='TEXT32' len=55
  "__ZTV11ScreenSaver"                                                  ; magics
eg='TEXT32' len=18  weak
  "__ZTS7QObject"                                                       ; magics
eg='TEXT32' len=13  weak
  "__ZTI7QObject"                                                       ; magics
eg='TEXT32' len=13  weak
  "__ZTS11ScreenSaver"                                                  ; magics
eg='TEXT32' len=18  weak
  "__ZTI11ScreenSaver"                                                  ; magics
eg='TEXT32' len=18  weak

Irritating.

4
Programming / Re: Duplicate symbol error
« on: Today at 02:27:43 am »
Pretty sure, there was a lot of errors about powermanager before I added the OS/2 defines.
I do see that winscreensaver.cpp isn't being compiled. I patched smplayer.pro like this,
Code: [Select]
--- a/src/smplayer.pro
+++ b/src/smplayer.pro
@@ -593,7 +593,7 @@ contains( DEFINES, SCREENSAVER_OFF ) {
                HEADERS += powersaving.h
                SOURCES += powersaving.cpp
        }
-       win32 {
+       win32:os2 {
                HEADERS += winscreensaver.h
                SOURCES += winscreensaver.cpp
        }
Is that the correct way to add OS/2 support?

5
Programming / Duplicate symbol error
« on: Today at 01:07:51 am »
So I tried to compile the latest smplayer, it went pretty well, a couple of minor fixes, until it got to screensaver.cpp where it tried to take the *nix path of disabling power savings.
Investigation showed that winscreensaver.cpp had the code to disable Doodles screensaver, so fixed screensaver.cpp/h by changing all the #ifdef Q_OS_WIN to #if defined (Q_OS_WIN) || defined (Q_OS_OS2), made sure that winscreensaver.cpp was compiled on OS/2 and screensaver.cpp compiled fine. Linking died with,
Code: [Select]
weakld: K:\work\smplayer\build\screensaver.obj - error: Duplicate symbol '__ZN11ScreenSaverD2Ev' ('__ZN11ScreenSaverD2Ev').
weakld: K:\work\smplayer\build\screensaver.obj - error: Symbol previosly defined in this module.
weakld: info: fFlags new 0x0001  fFlags old 0x0001 (PUBLIC).
emxomfld: weak prelinker failed. (rc=-1)
make.exe: *** [Makefile:794: smplayer.exe] Error 1

K:\work\smplayer\build>c++filt __ZN11ScreenSaverD2Ev
ScreenSaver::~ScreenSaver()

I don't understand where the duplicate symbol is coming from. The code,
Code: [Select]
#include "screensaver.h"

#if defined (Q_OS_WIN) || defined (Q_OS_OS2)
#include "winscreensaver.h"
#endif
#ifdef OS_UNIX_NOT_MAC
#include "powersaving.h"
#endif
#ifdef Q_OS_MACX
#include "powersaving_mac.h"
#endif

ScreenSaver::ScreenSaver(QObject * parent) : QObject(parent) {
#if defined (Q_OS_WIN) || defined (Q_OS_OS2)
win_screensaver = new WinScreenSaver();
#else
power_saving = new PowerSaving(this);
#endif
}

ScreenSaver::~ScreenSaver() {
#if defined (Q_OS_WIN) || defined (Q_OS_OS2)
delete win_screensaver;
#endif
}

void ScreenSaver::enable() {
#if defined (Q_OS_WIN) || defined (Q_OS_OS2)
win_screensaver->enable();
#else
power_saving->uninhibit();
#endif
}

void ScreenSaver::disable() {
#if defined (Q_OS_WIN) || defined (Q_OS_OS2)
win_screensaver->disable();
#else
power_saving->inhibit();
#endif
}

#include "moc_screensaver.cpp"

screensaver.h
Code: [Select]
#ifndef SCREENSAVER_H
#define SCREENSAVER_H

#include <QObject>

class PowerSaving;
class WinScreenSaver;

class ScreenSaver : public QObject
{
        Q_OBJECT

public:
        ScreenSaver(QObject * parent = 0);
        ~ScreenSaver();

public slots:
        void enable();
        void disable();

protected:
#if defined (Q_OS_WIN) || defined (Q_OS_OS2)
        WinScreenSaver * win_screensaver;
#else
        PowerSaving * power_saving;
#endif
};

#endif

Winscreensaver.cpp is at https://github.com/smplayer-dev/smplayer/blob/master/src/winscreensaver.cpp change the .cpp to h for the header.
Ideas?

6
Hardware / Re: ArcaOS on a HP EliteBook 840 G3?
« on: Today at 12:56:58 am »
You have to use the ArcaOS tool to create your installation USB stick, on OS/2, the USB stack is loaded late in the boot process so can't load an ISO from the stick, instead it creates a ram disk, boots from that and then it loads the ISO.
On your ArcaOS 5.07 install, double click the ISO and mount it, then switch to the drive letter you gave it and go to the AOSBOOT directory and read the txt file and then run aosboot.cmd with the stick inserted. The command is something like,
Code: [Select]
aosboot Q: C:\downloads\ArcaOS-5.1.isoAdjust drive letters and path as needed.

7
Applications / Re: Test build of dooble with qt5
« on: September 28, 2023, 01:59:49 am »
I built it on the 28th of Aug, ftp://dry@ftp.os2voice.org/rpm/dooble-2023.08.30-1.oc00.pentium4.rpm. Thought I announced it here.
Edit: the debug package and source package are also there.

8
Programming / Re: dart.h
« on: September 27, 2023, 12:44:59 am »
Thanks, that's probably it. Have to test.

9
Programming / Re: dart.h
« on: September 27, 2023, 12:16:46 am »
The github site only has some limited stuff such as the patches, which I should look at and apply.
Thanks for the reminder.

10
Programming / Re: shared memory value - Odin win32k or DosQuerySysInfo???
« on: September 26, 2023, 10:33:41 pm »
Wouldn't using win2k.h introduce a dependency in win2k.sys, which is now depreciated IIRC.

11
Applications / Re: General Software Testing
« on: September 26, 2023, 10:25:15 pm »
Demo, sample or a skeleton to be built on. It is small and running strings on it produces little,
Code: [Select]
H:\tmp>strings Ruki.sys
ruki
 ruki$
.sys 0.01 Device Driver
Copyright (C) 1998 Alex Romanov (2:50340/759)
All R
4s Reserved.

12
Programming / dart.h
« on: September 26, 2023, 09:53:43 pm »
Seems this has been discussed before. Where to find dart.h as I'm building MPlayer and its configure script tests for it.

13
DPMS is not supported with an UEFI boot on any system. Need to know where the vsync and hsync registers are located.
While on the subject, XFree86 also is unsupported and simply doesn't work with the VESA driver failing with
Code: [Select]
(EE) VESA(0): V_BIOS address 0x98000 out of range
Same error with the VGA driver.

14
Applications / Re: [LOOKING] OS/2 1.x, Word/Excel for OS/2 related stuff
« on: September 22, 2023, 12:05:41 am »
The applets I have here that were installed with WLO and with the needed DLLs on the LIBPATH run fine without Windows and look native, though without the close button, so it is kind of like running a Win32 or Win32s program with Odin. Likely those program objects would work with the DLLs on the LIBPATH and particularly handy if WinOS2 seamless doesn't work like here with AOS 5.0.x
Without the DLLs, they complain about missing user but if I run them from WinOS2 filemanager, they run as a Windows program.
I'd suggest testing with the DLLs on the LIBPATH or better get https://hobbes.nmsu.edu/download/pub/os2/dev/libraries/misc/WLO_1-0.zip and install them as I think they're newer.
BTW, Odin used to, and maybe still does, create a correct program object when running pe setup or pe install to install a Win32 program.

15
Applications / Re: [LOOKING] OS/2 1.x, Word/Excel for OS/2 related stuff
« on: September 21, 2023, 04:14:41 pm »
Hi Doug,
The WLO stuff is "Microsoft (R) Windows Libraries for OS/2 (WLO)", from the readme,
Code: [Select]
As a brief introduction to this technology, the WLO mapping-layer is
comprised of a set of dynamic-link libraries (DLLs) which map Windows
API calls to OS/2 API calls at run time.  This DLL layer operates
like having Windows sitting on top of OS/2 PM and enabling relinked
Windows applications to run side-by-side PM applications.  WLO is
required for Windows applications to run on OS/2, in this manner.
So perhaps those Program Objects that don't work need the WLO DLLs installed.
Here's the full readme, IIRC, WLO is on Hobbes
Full readme attached.

Pages: [1] 2 3 ... 301