Comments (8)
Interesting -- I am not seeing this. Can you tell me what your development environment looks like? For me, running via stack works fine:
C:\Users\Krajc>mkdir temp
C:\Users\Krajc>cd temp
C:\Users\Krajc\temp>stack unpack bindings-GLFW-3.3.2.0
Unpacked bindings-GLFW (from Hackage) to C:\Users\Krajc\temp\bindings-GLFW-3.3.2.0\
C:\Users\Krajc\temp>cd bindings-GLFW-3.3.2.0
C:\Users\Krajc\temp\bindings-GLFW-3.3.2.0>stack init
Looking for .cabal or package.yaml files to use to init the project.
Using cabal packages:
- .\
Selecting the best among 18 snapshots...
* Matches lts-16.5
Selected resolver: lts-16.5
Initialising configuration using resolver: lts-16.5
Total number of user packages considered: 1
Writing configuration to file: stack.yaml
All done.
C:\Users\Krajc\temp\bindings-GLFW-3.3.2.0>stack build
bindings-DSL > using precompiled package
bindings-GLFW> configure (lib)
Configuring bindings-GLFW-3.3.2.0...
bindings-GLFW> build (lib)
Preprocessing library for bindings-GLFW-3.3.2.0..
Building library for bindings-GLFW-3.3.2.0..
[1 of 1] Compiling Bindings.GLFW
bindings-GLFW> copy/register
Installing library in C:\Users\Krajc\temp\bindings-GLFW-3.3.2.0\.stack-work\install\dfacab28\lib\x86_64-windows-ghc-8.8.3\bindings-GLFW-3.3.2.0-59P015H4CpvITasZ77eQwl
Registering library for bindings-GLFW-3.3.2.0..
Completed 2 action(s).
C:\Users\Krajc\temp\bindings-GLFW-3.3.2.0>
from bindings-glfw.
@Mokosha I use Cabal and have a very simple setup, basically just MSYS, Cabal and GHC in my path. I've tried cleaning my default environment but with no success. Same problem every time.
Here are the exact details of my setup (it served me well over the years :) :
- GHC : 8.10.1
- Cabal : 3.2.0.0
Path
C:\msys64\usr\bin
C:\msys64\mingw64\bin
C:\Program Files\Haskell\ghc-8.10.1\bin
C:\Program Files\Haskell\cabal-install-3.2.0.0
Initially I tried installing it as a dependency in my project, but I get the same thing If I try to build it from source:
PS C:\Users\mastarija\Desktop\bindings-GLFW> cabal build Resolving dependencies...
Build profile: -w ghc-8.10.1 -O1
In order, the following will be built (use -v for more details):
- bindings-GLFW-3.3.2.0 (lib) (first run)
Configuring library for bindings-GLFW-3.3.2.0..
Preprocessing library for bindings-GLFW-3.3.2.0..
Bindings\GLFW.hsc:62 directive num cannot be handled in cross-compilation mode
PS C:\Users\mastarija\Desktop\bindings-GLFW>
from bindings-glfw.
bindings-DSL
, the package that this library is based on, is a macro library meant to be used with the tool hsc2hs
. You will need to make sure that hsc2hs
is in your path as well.
from bindings-glfw.
@Mokosha I do have it in my path, and cabal also downloads it and builds it once I start the build. I'm going to try and purge my package store today and see if that changes anything.
from bindings-glfw.
@Mokosha I still have no success even after purging all the packages from my store. Can you perhaps try building with Cabal as well?
from bindings-glfw.
Can you give me the list of commands you're running, and I'll try to run them locally?
from bindings-glfw.
@Mokosha I've wiped my cabal
and .ghc
directories to have a fresh environment once again. Here's exact commands and output once I've tried to build the bindings:
> git clone https://github.com/bsl/bindings-GLFW.git
> cd .\bindings-GLFW\
> cabal update
> cabal build
PS C:\Users\mastarija> cd Desktop
PS C:\Users\mastarija\Desktop> git clone https://github.com/bsl/bindings-GLFW.git
Cloning into 'bindings-GLFW'...
remote: Enumerating objects: 19, done.
remote: Counting objects: 100% (19/19), done.
remote: Compressing objects: 100% (18/18), done.
remote: Total 1218 (delta 1), reused 5 (delta 0), pack-reused 1199
Receiving objects: 100% (1218/1218), 1.48 MiB | 3.41 MiB/s, done.
Resolving deltas: 100% (717/717), done.
PS C:\Users\mastarija\Desktop> cd .\bindings-GLFW\
PS C:\Users\mastarija\Desktop\bindings-GLFW> cabal update
Config file path source is default config file.
Config file C:\Users\mastarija\AppData\Roaming\cabal\config not found.
Writing default configuration to
C:\Users\mastarija\AppData\Roaming\cabal\config
Downloading the latest package list from hackage.haskell.org
PS C:\Users\mastarija\Desktop\bindings-GLFW> cabal build
Resolving dependencies...
Build profile: -w ghc-8.10.1 -O1
In order, the following will be built (use -v for more details):
- bindings-DSL-1.0.25 (lib) (requires download & build)
- hsc2hs-0.68.7 (exe:hsc2hs) (requires download & build)
- bindings-GLFW-3.3.2.0 (lib) (first run)
Downloading bindings-DSL-1.0.25
Downloaded bindings-DSL-1.0.25
Downloading hsc2hs-0.68.7
Starting bindings-DSL-1.0.25 (lib)
Downloaded hsc2hs-0.68.7
Starting hsc2hs-0.68.7 (exe:hsc2hs)
Building bindings-DSL-1.0.25 (lib)
Building hsc2hs-0.68.7 (exe:hsc2hs)
Installing bindings-DSL-1.0.25 (lib)
Completed bindings-DSL-1.0.25 (lib)
Installing hsc2hs-0.68.7 (exe:hsc2hs)
Completed hsc2hs-0.68.7 (exe:hsc2hs)
Configuring library for bindings-GLFW-3.3.2.0..
Preprocessing library for bindings-GLFW-3.3.2.0..
Bindings\GLFW.hsc:62 directive num cannot be handled in cross-compilation mode
from bindings-glfw.
@Mokosha I just remembered I had problems building network
package some time ago using cabal-3.2.0.0
so I downgraded to cabal-3.0.0.0
and now it works!
from bindings-glfw.
Related Issues (20)
- Update glfw to 3.1.1 HOT 1
- Should the dependency to Xxf86vm be made optional? HOT 1
- Expose GLFW_USE_DWM_SWAP_INTERVAL as build flag.
- glfw3native.h bindings HOT 3
- Submit to Stackage HOT 2
- Package needs a new maintainer HOT 10
- HUnit 1.3 support HOT 2
- update glfw to 3.2.1 HOT 9
- License mismatch between Cabal and LICENSE file HOT 1
- Make the glfw source to a submodule? HOT 1
- unable to load package `bindings-GLFW-3.1.2.2' HOT 5
- Stack install failing HOT 11
- Duplicate link in README
- glfw_config.h on linux doesn't support multiple window managers.
- MoltenVK support HOT 3
- Upgrade to 3.3
- OpenBSD support for bindings-GLFW HOT 7
- Upgrade to 3.3.4 or 3.3.6 HOT 1
- broken on M1 macs HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bindings-glfw.