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

About ROM Library (IDFGH-8759) #10192

Closed
3 tasks done
nopnop2002 opened this issue Nov 17, 2022 · 4 comments
Closed
3 tasks done

About ROM Library (IDFGH-8759) #10192

nopnop2002 opened this issue Nov 17, 2022 · 4 comments
Labels
Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally

Comments

@nopnop2002
Copy link

nopnop2002 commented Nov 17, 2022

Answers checklist.

  • I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
  • I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
  • I have searched the issue tracker for a similar issue and not found a similar issue.

General issue report

I used ESP-IDF V5.1 to compile the code below.

#include <stdio.h>
#include <string.h>
#include "rom/miniz.h"
#include "rom/ets_sys.h"
#include "rom/tjpgd.h"
#include "rom/md5_hash.h"

void app_main()
{
    uint8_t buf[64];
    memset(buf, 0, sizeof(buf));
    mz_crc32(MZ_CRC32_INIT, (const mz_uint8 *)(buf), 4);
}

For some reason, only miniz is a warning.

$ idf.py --version
ESP-IDF v5.1-dev-1840-gaad600c9ca

$ idf.py set-target esp32

$ idf.py build

    7 | #warning "{target}/rom/miniz.h is deprecated, please use (#include "miniz.h") instead"
      |  ^~

Reference:
#10177

@nopnop2002 nopnop2002 changed the title bout ROM Library About ROM Library Nov 17, 2022
@espressif-bot espressif-bot added the Status: Opened Issue is new label Nov 17, 2022
@github-actions github-actions bot changed the title About ROM Library About ROM Library (IDFGH-8759) Nov 17, 2022
@gm-jiang
Copy link
Collaborator

gm-jiang commented Nov 17, 2022

@nopnop2002 please use #include "miniz.h" instead of #include "rom/miniz.h"

@nopnop2002
Copy link
Author

nopnop2002 commented Nov 17, 2022

@gm-jiang

#include "miniz.h" is not a warning.

I wonder why only miniz becomes a warning.

@gm-jiang
Copy link
Collaborator

gm-jiang commented Nov 17, 2022

@nopnop2002 Since this is a small breaking change that we moved esp_rom/include/{target}/rom/miniz.h to esp_rom/include/miniz.h . In case the user outside has already used rom/miniz.h or esp32/rom/miniz.h, we put a warning code in original miniz.h for notice that changes.

#warning "{target}/rom/miniz.h is deprecated, please use (#include "miniz.h") instead"
#include "../../miniz.h"

@nopnop2002
Copy link
Author

nopnop2002 commented Nov 17, 2022

@gm-jiang

small breaking change

Thank you.

@espressif-bot espressif-bot added Status: In Progress Work is in progress Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally and removed Status: Opened Issue is new Status: In Progress Work is in progress labels Nov 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally
Projects
None yet
Development

No branches or pull requests

3 participants