Skip to content

Commit

Permalink
Do not link to OCT_LINK_DEPS when building a .mex file.
Browse files Browse the repository at this point in the history
* mkoctfile.in.cc (main): Do not link to OCT_LINK_DEPS when building a .mex
file. It contains flags that are needed to link to liboctinterp and liboctave.
.mex files no longer need to (and should not) link to these libraries.
  • Loading branch information
mmuetzel committed Sep 30, 2024
1 parent 7e544b9 commit c57f18f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/mkoctfile.in.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1364,7 +1364,10 @@ main (int argc, char **sys_argv)
+ pass_on_options + " -o " + octfile + ' ' + objfiles + ' '
+ libfiles + ' ' + ldflags + ' ' + vars["DL_LDFLAGS"] + ' '
+ vars["LDFLAGS"] + ' ' + octave_libs + ' '
+ vars["OCT_LINK_OPTS"] + ' ' + vars["OCT_LINK_DEPS"]);
+ vars["OCT_LINK_OPTS"]);

if (! creating_mex_file)
cmd += ' ' + vars["OCT_LINK_DEPS"];

#if defined (OCTAVE_USE_WINDOWS_API) || defined (CROSS)
if (! f77files.empty () && ! vars["FLIBS"].empty ())
Expand Down

0 comments on commit c57f18f

Please sign in to comment.