[GH-ISSUE #5] OSX yosemite make results in: unknown type name 'z_crc_t' #5

Closed
opened 2026-05-05 11:23:18 -06:00 by gitea-mirror · 6 comments
Owner

Originally created by @aalvarado on GitHub (Jun 19, 2015).
Original GitHub issue: https://github.com/jmcnamara/libxlsxwriter/issues/5

Originally assigned to: @jmcnamara on GitHub.

Unable to compile on OSX Yosemite

I installed both zlib from homebrew-dupes and minizip but I'm unable to use export flags in the Makefile.

Please advice.

> ~/projects/libxlsxwriter $ make
zip.c:160:11: error: unknown type name 'z_crc_t'
    const z_crc_t* pcrc_32_tab;
          ^
In file included from zip.c:186:
./crypt.h:35:53: error: unknown type name 'z_crc_t'
static int decrypt_byte(unsigned long* pkeys, const z_crc_t* pcrc_32_tab)
                                                    ^
./crypt.h:48:51: error: unknown type name 'z_crc_t'
static int update_keys(unsigned long* pkeys,const z_crc_t* pcrc_32_tab,int c)
                                                  ^
./crypt.h:65:69: error: unknown type name 'z_crc_t'
static void init_keys(const char* passwd,unsigned long* pkeys,const z_crc_t* pcrc_32_tab)
                                                                    ^
./crypt.h:94:28: error: unknown type name 'z_crc_t'
                     const z_crc_t* pcrc_32_tab,
                           ^
5 errors generated.
make[1]: *** [zip.so] Error 1
make: *** [all] Error 2
``
Originally created by @aalvarado on GitHub (Jun 19, 2015). Original GitHub issue: https://github.com/jmcnamara/libxlsxwriter/issues/5 Originally assigned to: @jmcnamara on GitHub. Unable to compile on OSX Yosemite I installed both zlib from homebrew-dupes and minizip but I'm unable to use export flags in the Makefile. Please advice. ``` > ~/projects/libxlsxwriter $ make zip.c:160:11: error: unknown type name 'z_crc_t' const z_crc_t* pcrc_32_tab; ^ In file included from zip.c:186: ./crypt.h:35:53: error: unknown type name 'z_crc_t' static int decrypt_byte(unsigned long* pkeys, const z_crc_t* pcrc_32_tab) ^ ./crypt.h:48:51: error: unknown type name 'z_crc_t' static int update_keys(unsigned long* pkeys,const z_crc_t* pcrc_32_tab,int c) ^ ./crypt.h:65:69: error: unknown type name 'z_crc_t' static void init_keys(const char* passwd,unsigned long* pkeys,const z_crc_t* pcrc_32_tab) ^ ./crypt.h:94:28: error: unknown type name 'z_crc_t' const z_crc_t* pcrc_32_tab, ^ 5 errors generated. make[1]: *** [zip.so] Error 1 make: *** [all] Error 2 `` ```
gitea-mirror 2026-05-05 11:23:18 -06:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@jmcnamara commented on GitHub (Jun 20, 2015):

Hi Adan,

I don't normally use homebrew to get libs so I'll look into that. I have an idea why it isn't working.

In the meantime can you install Zlib using the method suggested in the Getting Started section of the docs. I use that on OS X and it works fine.

John

<!-- gh-comment-id:113737706 --> @jmcnamara commented on GitHub (Jun 20, 2015): Hi Adan, I don't normally use homebrew to get libs so I'll look into that. I have an idea why it isn't working. In the meantime can you install Zlib using the method suggested in the [Getting Started](http://libxlsxwriter.github.io/getting_started.html) section of the docs. I use that on OS X and it works fine. John
Author
Owner

@aalvarado commented on GitHub (Jun 22, 2015):

will do, and will report back, thanks!

<!-- gh-comment-id:114173734 --> @aalvarado commented on GitHub (Jun 22, 2015): will do, and will report back, thanks!
Author
Owner

@aalvarado commented on GitHub (Jun 22, 2015):

following the getting started guide did work, thanks!

<!-- gh-comment-id:114254620 --> @aalvarado commented on GitHub (Jun 22, 2015): following the getting started guide did work, thanks!
Author
Owner

@aalvarado commented on GitHub (Jul 28, 2015):

I was able to compile zlib separately and make minizip compile by placing the libs from zlib two directories above and running make.

<!-- gh-comment-id:125760738 --> @aalvarado commented on GitHub (Jul 28, 2015): I was able to compile zlib separately and make minizip compile by placing the libs from zlib two directories above and running make.
Author
Owner

@jeroen commented on GitHub (Aug 22, 2017):

I just ran into exactly the same problem. I found that you can also make it work by compiling with

CPPFLAGS=-DNOCRYPT

This skips over the crypto types. I don't think these are used by libxlswriter? @jmcnamara

<!-- gh-comment-id:324007016 --> @jeroen commented on GitHub (Aug 22, 2017): I just ran into exactly the same problem. I found that you can also make it work by compiling with CPPFLAGS=-DNOCRYPT This skips over the crypto types. I don't think these are used by `libxlswriter`? @jmcnamara
Author
Owner

@jmcnamara commented on GitHub (Aug 22, 2017):

I just ran into exactly the same problem.

I doubt you encountered the same issue but you may have seen the same symptoms. Probably best to open a new bug report with the steps to reproduce it.

This skips over the crypto types. I don't think these are used by libxlswriter?

Correct. They aren't used and libxlsxwriter compiles it's local copy of minizip with:

CFLAGS += -O3 -DNOCRYPT -DNOUNCRYPT
<!-- gh-comment-id:324011153 --> @jmcnamara commented on GitHub (Aug 22, 2017): > I just ran into exactly the same problem. I doubt you encountered the same issue but you may have seen the same symptoms. Probably best to open a new bug report with the steps to reproduce it. > This skips over the crypto types. I don't think these are used by libxlswriter? Correct. They aren't used and libxlsxwriter compiles it's local copy of minizip with: CFLAGS += -O3 -DNOCRYPT -DNOUNCRYPT
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/libxlsxwriter#5
No description provided.