KarthikRIyer / swiftplot

Swift library for Data Visualization :bar_chart:
Apache License 2.0
398 stars 36 forks source link

Include 'agg_renderer_base.h' explicitly in 'agg_blur.h' #128

Closed fwcd closed 3 years ago

fwcd commented 3 years ago

Fixes #127

This PR fixes the build on Swift 5.4, apparently a header didn't get included correctly.

KarthikRIyer commented 3 years ago

@fwcd Apologies for the delay. I've updated the CI to use Swift 5.4. Could you please rebase your PR to the latest master?

fwcd commented 3 years ago

Sure, I'll rebase it.

KarthikRIyer commented 3 years ago

There seems to be a test failure on Ubuntu which will need some investigation. Since the macOS test are passing I'm merging this.

Thanks a lot for your contribution @fwcd ! Really appreciate it.

mizhkeao commented 3 years ago

Thanks for merging @KarthikRIyer! I just pulled from master and building works but swift test is failing with the following errors:

  ~/05mz/sw     master    3  1  swift build                                                                  ✔  10014  23:34:27 
Updating https://github.com/KarthikRIyer/swiftplot
Updating https://github.com/koher/swift-image.git
Resolving https://github.com/KarthikRIyer/swiftplot at master
[1/1] Planning build

* Build Completed!%

Do I need to install AGGRenderer separately in my project directory?

  ~/05mz/sw     master    3  1  swift test                                                                   ✔  10014  10:03:40 
[1/1] Planning build

/Users/mike/05mz/sw/.build/checkouts/swiftplot/Sources/SwiftPlot/Histogram.swift:283:21: warning: initialization of immutable value 'series' was never used; consider replacing with assignment to '_' or removing it
                let series = allSeries[seriesIdx]
                ~~~~^~~~~~
                _
/Users/mike/05mz/sw/.build/checkouts/swiftplot/Sources/SwiftPlot/Histogram.swift:283:21: warning: initialization of immutable value 'series' was never used; consider replacing with assignment to '_' or removing it
                let series = allSeries[seriesIdx]
                ~~~~^~~~~~
                _
/Users/mike/05mz/sw/.build/checkouts/swiftplot/Sources/SwiftPlot/Histogram.swift:283:21: warning: initialization of immutable value 'series' was never used; consider replacing with assignment to '_' or removing it
                let series = allSeries[seriesIdx]
                ~~~~^~~~~~
                _
/Users/mike/05mz/sw/.build/checkouts/swiftplot/Sources/SwiftPlot/Histogram.swift:283:21: warning: initialization of immutable value 'series' was never used; consider replacing with assignment to '_' or removing it
                let series = allSeries[seriesIdx]
                ~~~~^~~~~~
                _
/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/module.modulemap:2:12: error: header '/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h' not found
    header "/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h"
           ^
/Users/mike/05mz/sw/Tests/swTests/approxMultTests.swift:10:8: error: could not build Objective-C module 'AGGRenderer'
import AGGRenderer
       ^
/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/module.modulemap:2:12: error: header '/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h' not found
    header "/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h"
           ^
/Users/mike/05mz/sw/Tests/swTests/approxMultTests.swift:10:8: error: could not build Objective-C module 'AGGRenderer'
import AGGRenderer
       ^
/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/module.modulemap:2:12: error: header '/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h' not found
    header "/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h"
           ^
/Users/mike/05mz/sw/Tests/swTests/approxMultTests.swift:10:8: error: could not build Objective-C module 'AGGRenderer'
import AGGRenderer
       ^
/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/module.modulemap:2:12: error: header '/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h' not found
    header "/Users/mike/05mz/sw/.build/x86_64-apple-macosx/debug/AGGRenderer.build/AGGRenderer-Swift.h"
           ^
/Users/mike/05mz/sw/Tests/swTests/approxMultTests.swift:10:8: error: could not build Objective-C module 'AGGRenderer'
import AGGRenderer
       ^

error: fatalError
KarthikRIyer commented 3 years ago

I'm not sure about this error. AGGRenderer is not an objective-C module. I do not have access to a mac to test it out.