Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
TLMSP curl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CYBER - Cyber Security
TS 103 523 MSP
TLMSP
TLMSP curl
Commits
683f2b83
Commit
683f2b83
authored
11 years ago
by
Kamil Dudka
Browse files
Options
Downloads
Patches
Plain Diff
src/Makefile.am: build static lib for unit tests if enabled
parent
2de20dd9
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/Makefile.am
+8
-0
8 additions, 0 deletions
src/Makefile.am
src/tool_main.c
+4
-0
4 additions, 0 deletions
src/tool_main.c
tests/unit/Makefile.am
+9
-2
9 additions, 2 deletions
tests/unit/Makefile.am
with
21 additions
and
2 deletions
src/Makefile.am
+
8
−
0
View file @
683f2b83
...
...
@@ -66,6 +66,14 @@ curl_LDFLAGS = @LIBMETALINK_LDFLAGS@
curl_CPPFLAGS
=
$(
AM_CPPFLAGS
)
$(
LIBMETALINK_CPPFLAGS
)
curl_DEPENDENCIES
=
$(
top_builddir
)
/lib/libcurl.la
# if unit tests are enabled, build a static library to link them with
if
BUILD_UNITTESTS
noinst_LTLIBRARIES
=
libcurltool.la
libcurltool_la_CFLAGS
=
-DUNITTESTS
libcurltool_la_LDFLAGS
=
-static
$(
LINKFLAGS
)
libcurltool_la_SOURCES
=
$(
curl_SOURCES
)
endif
BUILT_SOURCES
=
tool_hugehelp.c
CLEANFILES
=
tool_hugehelp.c
# Use the C locale to ensure that only ASCII characters appear in the
...
...
This diff is collapsed.
Click to expand it.
src/tool_main.c
+
4
−
0
View file @
683f2b83
...
...
@@ -55,6 +55,9 @@
int
vms_show
=
0
;
#endif
/* if we build a static library for unit tests, there is no main() function */
#ifndef UNITTESTS
/*
* Ensure that file descriptors 0, 1 and 2 (stdin, stdout, stderr) are
* open before starting to run. Otherwise, the first three network
...
...
@@ -118,3 +121,4 @@ int main(int argc, char *argv[])
#endif
}
#endif
/* ndef UNITTESTS */
This diff is collapsed.
Click to expand it.
tests/unit/Makefile.am
+
9
−
2
View file @
683f2b83
...
...
@@ -40,6 +40,7 @@ AM_CPPFLAGS = -I$(top_builddir)/include/curl \
-I
$(
top_srcdir
)
/include
\
-I
$(
top_builddir
)
/lib
\
-I
$(
top_srcdir
)
/lib
\
-I
$(
top_srcdir
)
/src
\
-I
$(
top_srcdir
)
/tests/libtest
\
-I
$(
top_builddir
)
/ares
\
-I
$(
top_srcdir
)
/ares
...
...
@@ -49,6 +50,7 @@ AM_CPPFLAGS = -I$(top_builddir)/include/curl \
-I
$(
top_srcdir
)
/include
\
-I
$(
top_builddir
)
/lib
\
-I
$(
top_srcdir
)
/lib
\
-I
$(
top_srcdir
)
/src
\
-I
$(
top_srcdir
)
/tests/libtest
endif
...
...
@@ -57,8 +59,13 @@ EXTRA_DIST = Makefile.inc
# Prevent LIBS from being used for all link targets
LIBS
=
$(
BLANK_AT_MAKETIME
)
LDADD
=
$(
top_builddir
)
/lib/libcurlu.la @LDFLAGS@ @LIBCURL_LIBS@
DEPENDENCIES
=
$(
top_builddir
)
/lib/libcurlu.la
LDADD
=
$(
top_builddir
)
/src/libcurltool.la
\
$(
top_builddir
)
/lib/libcurlu.la
\
@LDFLAGS@ @LIBCURL_LIBS@
DEPENDENCIES
=
$(
top_builddir
)
/src/libcurltool.la
\
$(
top_builddir
)
/lib/libcurlu.la
AM_CPPFLAGS
+=
-DCURL_STATICLIB
-DUNITTESTS
# Makefile.inc provides neat definitions
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment