Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use make install on Windows (MSYS2) #355

Merged
merged 3 commits into from
May 25, 2021

Conversation

umarcor
Copy link
Contributor

@umarcor umarcor commented May 18, 2021

The first commit in this PR adds a PKGBUILD recipe for building and installing FFTS, instead of doing it manually. The recipe is equivalent to the ones used upstream, but the main branch is built, instead of using a fixed commit.

Then, make install is used for packaging the MSYS2 build of scopehal-apps, instead of manually specifying the artifacts to be uploaded. The result looks almost correct, but liblog.dll is missing:

dist
└── mingw64
    ├── bin
    │   ├── glscopeclient.exe
    │   ├── libgraphwidget.dll
    │   ├── libscopehal.dll
    │   └── libscopeprotocols.dll
    ├── lib
    │   ├── libgraphwidget.dll.a
    │   ├── libscopehal.dll.a
    │   └── libscopeprotocols.dll.a
    └── share
        ├── applications
        │   └── glscopeclient.desktop
        └── glscopeclient
            ├── gradients
            │   ├── eye-gradient-crt.rgba
            │   ├── eye-gradient-grayscale.rgba
            │   ├── eye-gradient-ironbow.rgba
            │   ├── eye-gradient-krain.rgba
            │   ├── eye-gradient-rainbow.rgba
            │   └── eye-gradient-viridis.rgba
            ├── icons
            │   ├── 24x24
            │   │   ├── clear-sweeps.png
            │   │   ├── fullscreen-enter.png
            │   │   ├── fullscreen-exit.png
            │   │   ├── history.png
            │   │   ├── refresh-settings.png
            │   │   ├── trigger-single.png
            │   │   ├── trigger-start.png
            │   │   └── trigger-stop.png
            │   ├── 48x48
            │   │   ├── clear-sweeps.png
            │   │   ├── fullscreen-enter.png
            │   │   ├── fullscreen-exit.png
            │   │   ├── history.png
            │   │   ├── refresh-settings.png
            │   │   ├── trigger-single.png
            │   │   ├── trigger-start.png
            │   │   └── trigger-stop.png
            │   └── scalable
            │       ├── clear-sweeps.svg
            │       ├── fullscreen-enter.svg
            │       ├── fullscreen-exit.svg
            │       ├── history.svg
            │       ├── refresh-settings.svg
            │       ├── trigger-single.svg
            │       ├── trigger-start.svg
            │       └── trigger-stop.svg
            ├── kernels
            │   ├── DeEmbedFilter.cl
            │   ├── FFTNormalization.cl
            │   ├── FIRFilter.cl
            │   └── WindowFunctions.cl
            ├── shaders
            │   ├── cairo-fragment.glsl
            │   ├── cairo-vertex.glsl
            │   ├── colormap-fragment.glsl
            │   ├── colormap-vertex.glsl
            │   ├── eye-fragment.glsl
            │   ├── eye-vertex.glsl
            │   ├── spectrogram-fragment.glsl
            │   ├── spectrogram-vertex.glsl
            │   ├── waveform-compute-analog.glsl
            │   ├── waveform-compute-core.glsl
            │   ├── waveform-compute-digital.glsl
            │   ├── waveform-compute-head.glsl
            │   ├── waveform-compute-head-noint64.glsl
            │   └── waveform-compute-histogram.glsl
            └── styles
                └── glscopeclient.css

@bvernoux
Copy link
Contributor

bvernoux commented May 18, 2021

This type of install does not allow to install multiple different version of glscopeclient/dll I clearly do not like that
I will prefer to keep all files dependent to a directory i will say Keep it simple, stupid
My install so far is like that:
glscopeclient_v0_x (installed in any directory)
└── glscopeclient.exe
└── libffts.dll
└── libgraphwidget.dll
└── liblog.dll
└── libscopehal.dll
└── libscopeprotocols.dll
└── libstdc++-6.dll
├── gradients
│ ├── eye-gradient-crt.rgba
│ ├── eye-gradient-grayscale.rgba
│ ├── eye-gradient-ironbow.rgba
│ ├── eye-gradient-krain.rgba
│ ├── eye-gradient-rainbow.rgba
│ └── eye-gradient-viridis.rgba
├── icons
│ ├── 24x24
│ │ ├── clear-sweeps.png
│ │ ├── fullscreen-enter.png
│ │ ├── fullscreen-exit.png
│ │ ├── history.png
│ │ ├── refresh-settings.png
│ │ ├── trigger-single.png
│ │ ├── trigger-start.png
│ │ └── trigger-stop.png
│ ├── 48x48
│ │ ├── clear-sweeps.png
│ │ ├── fullscreen-enter.png
│ │ ├── fullscreen-exit.png
│ │ ├── history.png
│ │ ├── refresh-settings.png
│ │ ├── trigger-single.png
│ │ ├── trigger-start.png
│ │ └── trigger-stop.png
│ └── scalable
│ ├── clear-sweeps.svg
│ ├── fullscreen-enter.svg
│ ├── fullscreen-exit.svg
│ ├── history.svg
│ ├── refresh-settings.svg
│ ├── trigger-single.svg
│ ├── trigger-start.svg
│ └── trigger-stop.svg
├── kernels
│ ├── DeEmbedFilter.cl
│ ├── FFTNormalization.cl
│ ├── FIRFilter.cl
│ └── WindowFunctions.cl
├── shaders
│ ├── cairo-fragment.glsl
│ ├── cairo-vertex.glsl
│ ├── colormap-fragment.glsl
│ ├── colormap-vertex.glsl
│ ├── eye-fragment.glsl
│ ├── eye-vertex.glsl
│ ├── spectrogram-fragment.glsl
│ ├── spectrogram-vertex.glsl
│ ├── waveform-compute-analog.glsl
│ ├── waveform-compute-core.glsl
│ ├── waveform-compute-digital.glsl
│ ├── waveform-compute-head.glsl
│ ├── waveform-compute-head-noint64.glsl
│ └── waveform-compute-histogram.glsl
└── styles
└── glscopeclient.css
...

@umarcor
Copy link
Contributor Author

umarcor commented May 18, 2021

@bvernoux I think you are misunderstanding the purpose of this PR: upstreaming the package to msys2/MINGW-packages#8676, Therefore, the layout of the files needs to follow the standard structure in GNU/Linux systems. Precisely, the structure used in MSYS2. If we kept the structure as you suggest, it would not be possible to install glscopeclient together with other tools in the system, because conflicts would/might arise. Naturally, you are free to pick the artifact and reorganise/rename the content as you wish.

@azonenberg
Copy link
Collaborator

@bvernoux I plan to also offer a standalone Windows install package which will dump all of the artifacts somewhere under Program Files. This is separate from that.

@umarcor So is this ready to merge? Or do you still need to fix something about liblog? On Linux liblog is statically linked so there's no artifacts to install.

@umarcor
Copy link
Contributor Author

umarcor commented May 18, 2021

@bvernoux I plan to also offer a standalone Windows install package which will dump all of the artifacts somewhere under Program Files. This is separate from that.

Note that there is interest in achieving this with multiple projects: GTKWave, GHDL, this one. All of those are built on MSYS2, but some users would like to use them as standalone zipfiles. See, for instance, https://github.com/achadwick/styrene. See also ghdl/ghdl#1560 (comment).

@umarcor So is this ready to merge? Or do you still need to fix something about liblog? On Linux liblog is statically linked so there's no artifacts to install.

If liblog is statically linked on Windows too, then we don't need it in the package. So, this would be ready to merge, and I'd update the docs accordingly.

@umarcor
Copy link
Contributor Author

umarcor commented May 18, 2021

According to https://github.com/azonenberg/logtools/blob/232e03e44572e048114f1e20fff841df6f165f29/CMakeLists.txt, liblog.dll is required on Windows. Hence, logtools needs an install target on Windows only.

@azonenberg
Copy link
Collaborator

According to https://github.com/azonenberg/logtools/blob/232e03e44572e048114f1e20fff841df6f165f29/CMakeLists.txt, liblog.dll is required on Windows. Hence, logtools needs an install target on Windows only.

Please send a PR to logtools to fix this.

@azonenberg
Copy link
Collaborator

azonenberg commented May 22, 2021

According to https://github.com/azonenberg/logtools/blob/232e03e44572e048114f1e20fff841df6f165f29/CMakeLists.txt, liblog.dll is required on Windows. Hence, logtools needs an install target on Windows only.

Please send a PR to logtools to fix this.

@umarcor Reminder to send the PR for install of logtools.

@umarcor
Copy link
Contributor Author

umarcor commented May 25, 2021

@azonenberg, I think this is ready to merge.

@azonenberg azonenberg merged commit 07cd746 into ngscopeclient:master May 25, 2021
@umarcor umarcor deleted the cmake-install branch May 25, 2021 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants