GithubHelp home page GithubHelp logo

svgcairo's People

Contributors

pgavin avatar dcoutts avatar manateelazycat avatar hamishmack avatar hvanthiel avatar int-e avatar jmillikin avatar mgsloan avatar cmcq avatar saizan avatar dmwit avatar loisch avatar nh2 avatar mauricioca avatar ashleyyakeley avatar benyafallenstein avatar dufresnep avatar hansroland avatar simonmar avatar nominolo avatar toby-allsopp avatar agl avatar jutaro avatar mklca avatar

Stargazers

CBlueUI avatar  avatar Miguel Rios avatar Ian-Woo Kim avatar

Watchers

Ollie Charles avatar Miguel Rios avatar  avatar  avatar James Cloos avatar Deniz Alp Durmaz avatar  avatar

svgcairo's Issues

Cannot compile with GHC 8.10.3 under Windows

Lots of error messages about incorrect types in .h files. The following is a short extract from stack build

svgcairo                         > C:/Users/Paul Johnson/AppData/Local/Programs/stack/x86_64-windows/ghc-8.10.3/mingw/lib/gcc/x86_64-w64-mingw32/9.2.0/include/xopintrin.h:606:45: note: expected '__vector(8) short int' but argument is of type 'short int'
svgcairo                         > C:/Users/Paul Johnson/AppData/Local/Programs/stack/x86_64-windows/ghc-8.10.3/mingw/lib/gcc/x86_64-w64-mingw32/9.2.0/include/xopintrin.h:606:58: error: incompatible type for argument 2 of '__builtin_ia32_vpcomgew'
svgcairo                         >   606 |   return (__m128i) __builtin_ia32_vpcomgew ((__v8hi)__A, (__v8hi)__B);
svgcairo                         >       |                                                          ^~~~~~~~~~~
svgcairo                         >       |                                                          |
svgcairo                         >       |                                                          short int
svgcairo                         > C:/Users/Paul Johnson/AppData/Local/Programs/stack/x86_64-windows/ghc-8.10.3/mingw/lib/gcc/x86_64-w64-mingw32/9.2.0/include/xopintrin.h:606:58: note: expected '__vector(8) short int' but argument is of type 'short int'

Building with current stack.

Hi, I'm trying to use svgcairo in a new project using Stack. There seems to be a build dependency on Cabal 1.24 here, which is playing havoc on the dependency tree. Is there a way around this, or is there a more recent library that is better suited to the new haskell-gi ecosystem?
Cheers, Johan

Please bump Cabal upper bound

The current upper bound is < 3.1, which is making this challenging to package in gentoo.

I have personally made the change and everything still seems to compile fine.

Cannot install with Stack?

I am running Stack with LTS 6.1 on Mac OS X. I get this strange error:

➜  ~ stack install svgcairo
Run from outside a project, using implicit global project config
Using resolver: lts-6.1 from implicit global project's config file: /Users/chen/.stack/global-project/stack.yaml
svgcairo-0.13.1.0: configure

--  While building package svgcairo-0.13.1.0 using:
      /Users/chen/.stack/programs/x86_64-osx/ghc-7.10.3/bin/ghc --make -odir /private/var/folders/xz/z3wrll111zn03hdhkd_pxs5w0000gp/T/stack30762/svgcairo-0.13.1.0/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/setup -hidir /private/var/folders/xz/z3wrll111zn03hdhkd_pxs5w0000gp/T/stack30762/svgcairo-0.13.1.0/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/setup -i -i. -package=Cabal-1.22.5.0 -clear-package-db -global-package-db -package-db=/Users/chen/.stack/snapshots/x86_64-osx/lts-6.1/7.10.3/pkgdb /private/var/folders/xz/z3wrll111zn03hdhkd_pxs5w0000gp/T/stack30762/svgcairo-0.13.1.0/Setup.hs -o /private/var/folders/xz/z3wrll111zn03hdhkd_pxs5w0000gp/T/stack30762/svgcairo-0.13.1.0/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/setup/setup
    Process exited with code: ExitFailure 1
    Logs have been written to: /Users/chen/.stack/global-project/.stack-work/logs/svgcairo-0.13.1.0.log


    /private/var/folders/xz/z3wrll111zn03hdhkd_pxs5w0000gp/T/stack30762/svgcairo-0.13.1.0/Setup.hs:5:8:
        Could not find module ‘Gtk2HsSetup’
        Use -v to see a list of the files searched for.

fatal error: librsvg/librsvg-features.h: No such file or directory

I want to build svgcairo because of ghc-vis. I am running into this:

$ cabal install svgcairo --lib --allow-newer
Resolving dependencies...
Build profile: -w ghc-8.10.7 -O1
...
Configuring svgcairo-0.13.2.1...
./svgcairo.h:6:10: fatal error: librsvg/librsvg-features.h: No such file or directory
    6 | #include <librsvg/librsvg-features.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

I do have librsvg2-devel (on Fedora 35) but the header is named differently:

$ ls /usr/include/librsvg-2.0/librsvg/
rsvg-cairo.h  rsvg-features.h  rsvg.h  rsvg-version.h

Build failure invalid use of '__builtin_va_arg_pack ()

I am trying to build svgcairo and I am running into this problem. This is on NixOS; I do not know yet if this is related to the issue:

$ LANG=C nix-shell -p ghc pkg-config  glib librsvg gtk3 --command "cabal install --env . --lib svgcairo --allow-newer Cabal"
Resolving dependencies...
Build profile: -w ghc-8.10.4 -O1
In order, the following will be built (use -v for more details):
 - svgcairo-0.13.2.1 (lib:svgcairo) (requires build)
Starting     svgcairo-0.13.2.1 (all, legacy fallback)
Building     svgcairo-0.13.2.1 (all, legacy fallback)

Failed to build svgcairo-0.13.2.1.
Build log (
/home/jojo/.cabal/logs/ghc-8.10.4/svgcairo-0.13.2.1-68a39d4f88dbd083ae6472f582970f652d6e266186a715acb905297992100bbb.log
):
[1 of 1] Compiling Main             ( /run/user/1000/cabal-install.-659504/dist-newstyle/tmp/src-659504/svgcairo-0.13.2.1/dist/setup/setup.hs, /run/user/1000/cabal-install.-659504/dist-newstyle/tmp/src-659504/svgcairo-0.13.2.1/dist/setup/Main.o )
Linking /run/user/1000/cabal-install.-659504/dist-newstyle/tmp/src-659504/svgcairo-0.13.2.1/dist/setup/setup ...
Warning: svgcairo.cabal:9:24: Packages with 'cabal-version: 1.12' or later
should specify a specific version of the Cabal spec of the form
'cabal-version: x.y'. Use 'cabal-version: 1.24'.
Configuring svgcairo-0.13.2.1...
Preprocessing library for svgcairo-0.13.2.1..
Building library for svgcairo-0.13.2.1..
[1 of 1] Compiling Graphics.Rendering.Cairo.SVG ( dist/build/Graphics/Rendering/Cairo/SVG.hs, dist/build/Graphics/Rendering/Cairo/SVG.o, dist/build/Graphics/Rendering/Cairo/SVG.dyn_o )
In file included from /nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/stdio.h:866,
                 from /nix/store/dlb3m1wyccb157yzfzjx9vpv6cgw212x-ghc-8.10.4/lib/ghc-8.10.4/include/rts/Flags.h:16,
                 from /nix/store/dlb3m1wyccb157yzfzjx9vpv6cgw212x-ghc-8.10.4/lib/ghc-8.10.4/include/rts/storage/GC.h:243,
                 from /nix/store/dlb3m1wyccb157yzfzjx9vpv6cgw212x-ghc-8.10.4/lib/ghc-8.10.4/include/Rts.h:210,

                 from /run/user/1000/ghc659813_0/ghc_3.c:2:0: error:
    
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function 'sprintf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:38:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
       38 |   return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       39 |       __bos (__s), __fmt, __va_arg_pack ());
          |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   |
38 |   return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
   |          ^
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function 'snprintf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:70:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
       70 |   return __builtin___snprintf_chk (__s, __n, __USE_FORTIFY_LEVEL - 1,
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       71 |        __bos (__s), __fmt, __va_arg_pack ());
          |        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   |
70 |   return __builtin___snprintf_chk (__s, __n, __USE_FORTIFY_LEVEL - 1,
   |          ^
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function 'fprintf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:103:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
      103 |   return __fprintf_chk (__stream, __USE_FORTIFY_LEVEL - 1, __fmt,
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      104 |    __va_arg_pack ());
          |    ~~~~~~~~~~~~~~~~~
    |
103 |   return __fprintf_chk (__stream, __USE_FORTIFY_LEVEL - 1, __fmt,
    |          ^
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function 'printf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:110:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
      110 |   return __printf_chk (__USE_FORTIFY_LEVEL - 1, __fmt, __va_arg_pack ());
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    |
110 |   return __printf_chk (__USE_FORTIFY_LEVEL - 1, __fmt, __va_arg_pack ());
    |          ^
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function 'dprintf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:147:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
      147 |   return __dprintf_chk (__fd, __USE_FORTIFY_LEVEL - 1, __fmt,
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      148 |    __va_arg_pack ());
          |    ~~~~~~~~~~~~~~~~~
    |
147 |   return __dprintf_chk (__fd, __USE_FORTIFY_LEVEL - 1, __fmt,
    |          ^
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function 'asprintf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:184:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
      184 |   return __asprintf_chk (__ptr, __USE_FORTIFY_LEVEL - 1, __fmt,
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      185 |     __va_arg_pack ());
          |     ~~~~~~~~~~~~~~~~~
    |
184 |   return __asprintf_chk (__ptr, __USE_FORTIFY_LEVEL - 1, __fmt,
    |          ^
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function '__asprintf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:192:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
      192 |   return __asprintf_chk (__ptr, __USE_FORTIFY_LEVEL - 1, __fmt,
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      193 |     __va_arg_pack ());
          |     ~~~~~~~~~~~~~~~~~
    |
192 |   return __asprintf_chk (__ptr, __USE_FORTIFY_LEVEL - 1, __fmt,
    |          ^
/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h: In function 'obstack_printf':

/nix/store/q141hd8jl7in5223jmf7kmx9h517km4p-glibc-2.32-54-dev/include/bits/stdio2.h:200:10: error:
     error: invalid use of '__builtin_va_arg_pack ()'
      200 |   return __obstack_printf_chk (__obstack, __USE_FORTIFY_LEVEL - 1, __fmt,
          |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      201 |           __va_arg_pack ());
          |           ~~~~~~~~~~~~~~~~~
    |
200 |   return __obstack_printf_chk (__obstack, __USE_FORTIFY_LEVEL - 1, __fmt,
    |          ^
`cc' failed in phase `C Compiler'. (Exit code: 1)
cabal: Failed to build svgcairo-0.13.2.1. See the build log above for details.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.