erlang.mk icon indicating copy to clipboard operation
erlang.mk copied to clipboard

Start inets in release

Open benjamin-bergia opened this issue 3 years ago • 2 comments

My project depends on inets and I would like it to be started automatically. From what I understand, I need to add inets to LOCAL_DEPS for it to be added to application resource file. It does seem to work but each time I build or run my release, I get the following warnings:

Warnings generating release:
*WARNING* inets: Source code not found: inets.erl
*WARNING* inets: Source code not found: inets_sup.erl
*WARNING* inets: Source code not found: inets_app.erl
*WARNING* inets: Source code not found: inets_service.erl
*WARNING* inets: Source code not found: inets_trace.erl
*WARNING* inets: Source code not found: inets_lib.erl
*WARNING* inets: Source code not found: httpc.erl
*WARNING* inets: Source code not found: httpc_handler.erl
*WARNING* inets: Source code not found: httpc_handler_sup.erl
*WARNING* inets: Source code not found: httpc_manager.erl
*WARNING* inets: Source code not found: httpc_profile_sup.erl
*WARNING* inets: Source code not found: httpc_request.erl
*WARNING* inets: Source code not found: httpc_response.erl
*WARNING* inets: Source code not found: httpc_sup.erl
*WARNING* inets: Source code not found: httpc_cookie.erl
*WARNING* inets: Source code not found: http_chunk.erl
*WARNING* inets: Source code not found: http_request.erl
*WARNING* inets: Source code not found: http_response.erl
*WARNING* inets: Source code not found: http_transport.erl
*WARNING* inets: Source code not found: http_util.erl
*WARNING* inets: Source code not found: http_uri.erl
*WARNING* inets: Source code not found: httpd.erl
*WARNING* inets: Source code not found: httpd_acceptor.erl
*WARNING* inets: Source code not found: httpd_acceptor_sup.erl
*WARNING* inets: Source code not found: httpd_cgi.erl
*WARNING* inets: Source code not found: httpd_connection_sup.erl
*WARNING* inets: Source code not found: httpd_conf.erl
*WARNING* inets: Source code not found: httpd_custom.erl
*WARNING* inets: Source code not found: httpd_custom_api.erl
*WARNING* inets: Source code not found: httpd_esi.erl
*WARNING* inets: Source code not found: httpd_example.erl
*WARNING* inets: Source code not found: httpd_file.erl
*WARNING* inets: Source code not found: httpd_instance_sup.erl
*WARNING* inets: Source code not found: httpd_log.erl
*WARNING* inets: Source code not found: httpd_logger.erl
*WARNING* inets: Source code not found: httpd_manager.erl
*WARNING* inets: Source code not found: httpd_misc_sup.erl
*WARNING* inets: Source code not found: httpd_request.erl
*WARNING* inets: Source code not found: httpd_request_handler.erl
*WARNING* inets: Source code not found: httpd_response.erl
*WARNING* inets: Source code not found: httpd_script_env.erl
*WARNING* inets: Source code not found: httpd_socket.erl
*WARNING* inets: Source code not found: httpd_sup.erl
*WARNING* inets: Source code not found: httpd_util.erl
*WARNING* inets: Source code not found: mod_actions.erl
*WARNING* inets: Source code not found: mod_alias.erl
*WARNING* inets: Source code not found: mod_auth.erl
*WARNING* inets: Source code not found: mod_auth_dets.erl
*WARNING* inets: Source code not found: mod_auth_mnesia.erl
*WARNING* inets: Source code not found: mod_auth_plain.erl
*WARNING* inets: Source code not found: mod_auth_server.erl
*WARNING* inets: Source code not found: mod_cgi.erl
*WARNING* inets: Source code not found: mod_dir.erl
*WARNING* inets: Source code not found: mod_disk_log.erl
*WARNING* inets: Source code not found: mod_esi.erl
*WARNING* inets: Source code not found: mod_get.erl
*WARNING* inets: Source code not found: mod_head.erl
*WARNING* inets: Source code not found: mod_log.erl
*WARNING* inets: Source code not found: mod_range.erl
*WARNING* inets: Source code not found: mod_responsecontrol.erl
*WARNING* inets: Source code not found: mod_security.erl
*WARNING* inets: Source code not found: mod_security_server.erl
*WARNING* inets: Source code not found: mod_trace.erl

I found a similar issue reporter on rebar https://github.com/erlang/rebar3/discussions/2494. Is this a bug or am I doing it wrong?

benjamin-bergia avatar May 24 '22 08:05 benjamin-bergia

You're not doing anything wrong, this is a bug.

The release handling code is relx, the same as rebar3, which in turn uses systools. It is likely that you are running into the exact same issue. The recommendation from the user to add {dev_mode, false} might work, only for Erlang.mk they are to be added to relx.config instead.

essen avatar May 24 '22 09:05 essen

I just realized that {dev_mode, false} was already set in my relx.config file. For some reason it doesn't seem to do anything. I also tried to add RELX_OPTS = -d false to my Makefile but it didn't have any effect.

Anyhow, it's not a big deal and it doesn't prevent me from running my project so I guess there is no need to spend more time on this.

benjamin-bergia avatar May 24 '22 09:05 benjamin-bergia

OK I'll close this and hope things to work better in a future Relx release. Thanks!

essen avatar May 16 '23 07:05 essen