projects
/
fw
/
stlink
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Allowed CONFIG_USE_LIBSG=0 to suppress STLink/V1 compilation
[fw/stlink]
/
flash
/
main.c
diff --git
a/flash/main.c
b/flash/main.c
index a443f95f6bb58b59460e3231a5a650d637763d6c..e474174377b1ac154d17cfaf96e46823f087e551 100644
(file)
--- a/
flash/main.c
+++ b/
flash/main.c
@@
-86,9
+86,14
@@
int main(int ac, char** av)
if (o.devname != NULL) /* stlinkv1 */
{
if (o.devname != NULL) /* stlinkv1 */
{
+#if CONFIG_USE_LIBSG
static const int scsi_verbose = 2;
sl = stlink_quirk_open(o.devname, scsi_verbose);
if (sl == NULL) goto on_error;
static const int scsi_verbose = 2;
sl = stlink_quirk_open(o.devname, scsi_verbose);
if (sl == NULL) goto on_error;
+#else
+ printf("not compiled for use with STLink/V1");
+ goto on_error;
+#endif
}
else /* stlinkv2 */
{
}
else /* stlinkv2 */
{